AttestwireRule referenceBR-DE-10

BR-DE-10 XRechnung requires a city in the delivery address

noun · XRechnung · fatal · BT-77

For a sample invoice, the library reports: XRechnung requires the element "Deliver to city" (BT-77) whenever the deliver-to address group (BG-15) is present. BG-15 is optional, but it is all-or-nothing: a delivery address consisting only of a country code is rejected, even though core EN 16931 accepts it.

Diese Regel auf Deutsch: BR-DE-10 — auf Deutsch erklärt.

Business term
BT-77
Severity
fatal

The fix

Either set deliverTo.city, or drop deliverTo entirely and keep only deliveryDate (BT-72) — unless a rule such as BR-IC-12 requires the destination country, in which case you must supply the full address.

A passing value

the shape this field expects
"deliverTo": { "city": "Lyon", "postalCode": "69001", "countryCode": "FR" }

What the library returns

The full error returned by @attestwire/en16931. It includes the rule ID, affected field and suggested correction. Developers can use this object in their application:

TeachingError
{
  "rule": "BR-DE-10",
  "field": "BT-77",
  "severity": "fatal",
  "message": "XRechnung requires the element \"Deliver to city\" (BT-77) whenever the deliver-to address group (BG-15) is present. BG-15 is optional, but it is all-or-nothing: a delivery address consisting only of a country code is rejected, even though core EN 16931 accepts it.",
  "fix": "Either set deliverTo.city, or drop deliverTo entirely and keep only deliveryDate (BT-72) — unless a rule such as BR-IC-12 requires the destination country, in which case you must supply the full address.",
  "example": "\"deliverTo\": { \"city\": \"Lyon\", \"postalCode\": \"69001\", \"countryCode\": \"FR\" }",
  "xpath": "/ubl:Invoice/cac:Delivery/cac:DeliveryLocation/cac:Address/cbc:CityName",
  "docsUrl": "https://attestwire.com/rules/BR-DE-10"
}

xpath is always a UBL path. On a CII invoice, look for the matching CII field instead.