Quaterio
Factur-X glossary

/AFRelationship

Also called AFRelationship, associated file relationship

/AFRelationship is the PDF key that declares how an embedded file relates to the document it sits in. Factur-X specifies it by profile: Data for MINIMUM and BASIC WL, Alternative for the richer profiles, because at those levels the XML is an alternative rendering of the same invoice.

Where it lives
The PDF embedded file specification
MINIMUM and BASIC WL
Data
BASIC, EN 16931, EXTENDED
Alternative
Mismatch severity
Warning, never fatal

Why the value depends on the profile

At MINIMUM and BASIC WL the XML carries less than the page does, so it is supplementary data rather than an equivalent view. At BASIC and above it carries the whole invoice, so it is an alternative representation of what the page shows.

The distinction is not pedantry. A receiving system deciding whether it may process the XML instead of reading the page needs to know which it is holding.

Where it goes wrong, and why we treat a mismatch as a warning

Generators that hardcode one value trip this for the other group. It is a common finding and rarely the real problem.

France and Germany have historically read this requirement differently, so we report a spec plausible mismatch as a warning rather than a failure. Failing an invoice over a disagreement between two national interpretations would be us picking a side we are not entitled to pick.

A limit worth naming on our own generation path: Gotenberg hardcodes Alternative with no way to change it, so it cannot produce a conformant MINIMUM or BASIC WL file. That does not affect us today because we emit EN 16931 only, which expects Alternative anyway.

Why it matters

  • It is a frequent finding on otherwise sound files, and knowing it is a warning saves you chasing it before the real failure.

Check it on your own file

Common questions

Should /AFRelationship be Data or Alternative?
It depends on the profile. Data for MINIMUM and BASIC WL, Alternative for BASIC, EN 16931 and EXTENDED. A mismatch is worth a warning rather than a rejection, because national interpretations differ.

Related terms