# BR-57: Add the country code to the deliver-to address

A deliver-to address in `cac:DeliveryLocation/cac:Address` must include `cac:Country/cbc:IdentificationCode`. Only its presence is tested here.

- Layer: EN 16931
- Severity: fatal (the document is invalid)
- Topics: Parties and addresses
- Official definition: https://docs.peppol.eu/poacc/billing/3.0/rules/ubl-tc434/BR-57/
- Explanation last updated: 2026-09-24

## The short answer

`BR-57` fails when `cac:Delivery/cac:DeliveryLocation/cac:Address` has no `cac:Country/cbc:IdentificationCode`. Add the ISO 3166-1 alpha-2 code of the country the goods or services were delivered to, as the last child of that address.

The rule applies only where a deliver-to address is present. When tried, a `cac:DeliveryLocation` holding only an identifier, with no `cac:Address`, passed every layer; on an intra-community supply, though, `BR-IC-12` needs the country regardless.

## What the rule checks

Each `cac:Address` inside `cac:Delivery/cac:DeliveryLocation` is tested, and the finding points at that address. The rule asks only whether `cac:Country` contains an `cbc:IdentificationCode` element.

The value is not read, which sets this rule apart from the buyer rule `BR-11`. When tried, an empty deliver-to `cbc:IdentificationCode` passed `BR-57` and was reported by `BR-CL-14`, as not a country code, and by `PEPPOL-EN16931-R008`, as an empty element.

A country name is not a substitute: when tried, `cac:Country/cbc:Name` in place of the code reported `BR-57` with the warning `UBL-CR-378`.

An address written as `cac:Delivery/cac:DeliveryAddress` is outside the rule entirely. When tried, one with no country at all produced only the warning `UBL-CR-682`, and the document stayed valid.

| Term | Meaning | UBL element |
|---|---|---|
| BG-15 | Deliver to address | `cac:Delivery/cac:DeliveryLocation/cac:Address` |
| BT-80 | Deliver to country code | `cac:Delivery/cac:DeliveryLocation/cac:Address/cac:Country/cbc:IdentificationCode` |

## How an integration ends up here

Possible causes, from the shape of the rule rather than from measured usage:

- The ship-to address is copied from an order or despatch record that holds street and city but no country, because deliveries were assumed to be domestic.
- Delivery addresses are free text in the source, and only the first line is mapped, into `cbc:StreetName`.
- The country is written as a name under `cac:Country/cbc:Name`.
- The delivery country is held on the order header, and the address block is built from a delivery point table that lacks it.

## How to fix it

1. Take the country of the delivery point from the order or despatch record that supplied the rest of the address.
2. Add `cac:Country` with `cbc:IdentificationCode` as the final child of `cac:DeliveryLocation/cac:Address`, using the two-letter code, such as `GB`.
3. If the delivery country is not known, send no deliver-to address. Do not default it to the buyer or seller country unless that is where the delivery went.
4. Keep the address inside `cac:DeliveryLocation`. Moving it to `cac:DeliveryAddress` stops this rule from firing, but only because the address is then outside the model, which `UBL-CR-682` reports.

## Before and after

These are fragments, not complete documents. The complete synthetic documents they come from are linked below.

Fragment of the failing invoice: the deliver-to address has a street and no country

```xml
<cac:Delivery>
  <cbc:ActualDeliveryDate>2026-09-07</cbc:ActualDeliveryDate>
  <cac:DeliveryLocation>
    <cac:Address>
      <cbc:StreetName>3 Delivery Street</cbc:StreetName>
    </cac:Address>
  </cac:DeliveryLocation>
</cac:Delivery>
```

Fragment of the corrected invoice: the deliver-to address ends with country code GB

```xml
<cac:Delivery>
  <cbc:ActualDeliveryDate>2026-09-07</cbc:ActualDeliveryDate>
  <cac:DeliveryLocation>
    <cac:Address>
      <cbc:StreetName>3 Delivery Street</cbc:StreetName>
      <cac:Country>
        <cbc:IdentificationCode>GB</cbc:IdentificationCode>
      </cac:Country>
    </cac:Address>
  </cac:DeliveryLocation>
</cac:Delivery>
```

The corrected invoice has `cac:Country` with the code `GB` after `cbc:StreetName` in the deliver-to address; the failing invoice has the street alone. Nothing else differs, and `BR-57` is the only finding on the failing document.

### What the validator reported

- The failing invoice reports **BR-57**. The corrected document passes every layer with no findings.
  - [Download the failing XML](https://ironfang.uk/finance/rule-examples/BR-57-invalid.xml)
  - [Download the corrected XML](https://ironfang.uk/finance/rule-examples/invoice-rich.xml)

Recorded on phive 12.1.0 / phive-rules-peppol 4.5.6 / Saxon-HE 12.10, the engine behind the free validator, using synthetic data. A recorded result is regression evidence for these documents; it is not a certification.

## Where it applies

- Credit notes use the same `cac:Delivery` structure. When tried, a credit note with the deliver-to country removed reported `BR-57` at the address.
- When the document has a VAT breakdown in category `K`, intra-community supply, `BR-IC-12` goes further and requires a deliver-to country code of at least two characters.
- The deliver-to country requirement is an EN 16931 rule, and the recorded failing invoice passes the Peppol layer.

## Related rules

- [UBL-CR-682 warns when the deliver-to address is written as DeliveryAddress, which this rule does not read](https://ironfang.uk/docs/finance/rules/UBL-CR-682.md)
- [BR-IC-12 requires the deliver-to country code on intra-community supplies](https://ironfang.uk/docs/finance/rules/BR-IC-12.md)
- [BR-CL-14 checks the value of the deliver-to country code](https://ironfang.uk/docs/finance/rules/BR-CL-14.md)
- [BR-11 is the buyer address counterpart, which also rejects an empty code](https://ironfang.uk/docs/finance/rules/BR-11.md)

## Scope and source

Written for Peppol BIS Billing 3.0.21 (May 2026), EN 16931 1.3.16, as applied to UBL 2.1 Invoice and CreditNote documents. Other profiles, syntaxes and releases can define this identifier differently. Guidance version 2026-09-24.1: source checked 2026-09-24, explanation last updated 2026-09-24.

[The official definition of BR-57](https://docs.peppol.eu/poacc/billing/3.0/rules/ubl-tc434/BR-57/) carries the normative wording and test. This page is our explanation of it, not a copy.

Guidance does not change the engine verdict. Fixing this finding does not mean the document passes every layer, and validation does not certify legal or tax compliance or transmit a document over Peppol.

## Links

- [This rule as a web page](https://ironfang.uk/docs/finance/rules/BR-57)
- [Free Peppol invoice validator](https://ironfang.uk/tools/peppol-validator)
- [Rule index](https://ironfang.uk/docs/finance/rules.md)
- [Ironfang Finance API docs](https://ironfang.uk/docs/finance)
- The same rule is available to MCP clients as the tool `finance.rule.get` on https://mcp.ironfang.uk/mcp
