cXML InvoiceDetailRequest: invoice example and element reference
The InvoiceDetailRequest is the cXML invoice. It refers back to a purchase order, lists what you are billing for, and carries the tax and totals the buyer’s accounts payable system checks before paying.
Where it fits
- You have received an OrderRequest and delivered against it, possibly with a ShipNoticeRequest.
- You send an InvoiceDetailRequest by HTTP POST to the buyer’s or network’s cXML endpoint, with your
Sendercredential and shared secret. - Each
InvoiceDetailOrdernames the order it bills throughInvoiceDetailOrderInfo, and eachInvoiceDetailItemnames the order line throughInvoiceDetailItemReference/@lineNumber. - The receiver answers with a cXML
ResponseandStatus. Business validation — price, quantity, tax, duplicates — often happens after that, and a rejection comes back later as a status update or in the network’s portal.
Nordwind Supplies invoices order PO-4500012345 with 19% VAT (cXML 1.2.061, InvoiceDetail.dtd).
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE cXML SYSTEM "http://xml.cxml.org/schemas/cXML/1.2.061/InvoiceDetail.dtd">
<cXML payloadID="1794302400.1190@punchout.example.com" timestamp="2026-11-10T09:00:00+01:00" xml:lang="en-US">
<Header>
<From>
<Credential domain="DUNS">
<Identity>000000000</Identity>
</Credential>
</From>
<To>
<Credential domain="NetworkID">
<Identity>AN00000000001</Identity>
</Credential>
</To>
<Sender>
<Credential domain="DUNS">
<Identity>000000000</Identity>
<SharedSecret>change-me</SharedSecret>
</Credential>
<UserAgent>Nordwind Supplies ERP</UserAgent>
</Sender>
</Header>
<Request deploymentMode="production">
<InvoiceDetailRequest>
<InvoiceDetailRequestHeader invoiceID="NW-INV-2026-00871" purpose="standard" operation="new" invoiceDate="2026-11-10T09:00:00+01:00">
<InvoiceDetailHeaderIndicator/>
<InvoiceDetailLineIndicator/>
<InvoicePartner>
<Contact role="remitTo">
<Name xml:lang="en">Nordwind Supplies Ltd</Name>
<PostalAddress>
<Street>Lagerweg 7</Street>
<City>Bremen</City>
<PostalCode>28195</PostalCode>
<Country isoCountryCode="DE">Germany</Country>
</PostalAddress>
</Contact>
</InvoicePartner>
<InvoicePartner>
<Contact role="billTo">
<Name xml:lang="en">Example Buyer GmbH, Accounts Payable</Name>
<PostalAddress>
<Street>Musterstrasse 1</Street>
<City>Hamburg</City>
<PostalCode>20095</PostalCode>
<Country isoCountryCode="DE">Germany</Country>
</PostalAddress>
</Contact>
</InvoicePartner>
<PaymentTerm payInNumberOfDays="30"/>
</InvoiceDetailRequestHeader>
<InvoiceDetailOrder>
<InvoiceDetailOrderInfo>
<OrderReference orderID="PO-4500012345" orderDate="2026-11-05T08:58:12+01:00">
<DocumentReference payloadID="1793870400.2207@buyer.example"/>
</OrderReference>
</InvoiceDetailOrderInfo>
<InvoiceDetailItem invoiceLineNumber="1" quantity="10">
<UnitOfMeasure>BX</UnitOfMeasure>
<UnitPrice>
<Money currency="EUR">8.90</Money>
</UnitPrice>
<InvoiceDetailItemReference lineNumber="1">
<ItemID>
<SupplierPartID>NW-GLV-NIT-L</SupplierPartID>
</ItemID>
<Description xml:lang="en">Nitrile gloves, size L - Powder-free, box of 100</Description>
</InvoiceDetailItemReference>
<SubtotalAmount>
<Money currency="EUR">89.00</Money>
</SubtotalAmount>
</InvoiceDetailItem>
<InvoiceDetailItem invoiceLineNumber="2" quantity="4">
<UnitOfMeasure>C62</UnitOfMeasure>
<UnitPrice>
<Money currency="EUR">18.10</Money>
</UnitPrice>
<InvoiceDetailItemReference lineNumber="2">
<ItemID>
<SupplierPartID>NW-TAPE-50</SupplierPartID>
</ItemID>
<Description xml:lang="en">Packing tape, 50 mm x 66 m</Description>
</InvoiceDetailItemReference>
<SubtotalAmount>
<Money currency="EUR">72.40</Money>
</SubtotalAmount>
</InvoiceDetailItem>
</InvoiceDetailOrder>
<InvoiceDetailSummary>
<SubtotalAmount>
<Money currency="EUR">161.40</Money>
</SubtotalAmount>
<Tax>
<Money currency="EUR">30.67</Money>
<Description xml:lang="en">VAT 19%</Description>
<TaxDetail purpose="tax" category="vat" percentageRate="19">
<TaxableAmount>
<Money currency="EUR">161.40</Money>
</TaxableAmount>
<TaxAmount>
<Money currency="EUR">30.67</Money>
</TaxAmount>
</TaxDetail>
</Tax>
<GrossAmount>
<Money currency="EUR">192.07</Money>
</GrossAmount>
<NetAmount>
<Money currency="EUR">192.07</Money>
</NetAmount>
<DueAmount>
<Money currency="EUR">192.07</Money>
</DueAmount>
</InvoiceDetailSummary>
</InvoiceDetailRequest>
</Request>
</cXML> The elements that matter
| Name | Needed? | Meaning |
|---|---|---|
InvoiceDetailRequestHeader/@invoiceID | Required | Your invoice number. Buyers reject a second invoice with the same number. |
InvoiceDetailRequestHeader/@invoiceDate | Required | Invoice date, in ISO 8601 with a time-zone offset. |
InvoiceDetailRequestHeader/@purpose | Optional | standard (the default), creditMemo, debitMemo, lineLevelCreditMemo or lineLevelDebitMemo. |
InvoiceDetailRequestHeader/@operation | Optional | new (the default) or delete to cancel an earlier invoice with the same invoiceID. |
InvoiceDetailHeaderIndicator | Required | Empty element whose attributes describe the invoice as a whole; with none set, it is a line-item invoice against an order. |
InvoiceDetailLineIndicator | Required | Empty element whose attributes say what appears at line level, for example isTaxInLine="yes" when each line carries its own Tax. |
InvoicePartner/Contact/@role | Optional | Parties on the invoice: remitTo, billTo, soldTo, from and others. Many buyers require remitTo and their own billTo. |
PaymentTerm/@payInNumberOfDays | Optional | Payment term in days. Should match the term on the order or contract. |
InvoiceDetailOrderInfo/OrderReference | Conditional | The purchase order being billed, with orderID and the order’s payloadID. Other forms such as OrderIDInfo are allowed when you do not have the original document. |
InvoiceDetailItem/@invoiceLineNumber | Required | Line number within this invoice. |
InvoiceDetailItem/@quantity | Required | Quantity billed on this line. |
InvoiceDetailItem/UnitOfMeasure, UnitPrice | Required | Unit and price, matching the order line. |
InvoiceDetailItemReference/@lineNumber | Required | The order line being billed, from ItemOut/@lineNumber. |
InvoiceDetailSummary/SubtotalAmount | Required | Sum of the line amounts before tax and charges. |
InvoiceDetailSummary/Tax | Required | Total tax with a Description, and usually a TaxDetail per rate. Required even when the amount is zero. |
InvoiceDetailSummary/NetAmount | Required | Amount after discounts and adjustments. GrossAmount and DueAmount are optional in the DTD but expected by most buyers. |
Mistakes that get it rejected
invoiceID detection is standard. A corrected invoice needs either a new number or a delete of the original first, according to the buyer’s rules.TaxDetail with category, rate and taxable amount, and buyers in those countries often require your and their VAT IDs as well. A bare total tax amount is not enough.Have a InvoiceDetailRequest that a buyer rejected? Paste it into the free cXML and OCI tester; it checks structure in your browser.
InvoiceDetailRequest questions
How is a credit note sent in cXML?
As an InvoiceDetailRequest with purpose="creditMemo" (or lineLevelCreditMemo for line-level credits), with amounts as negative values. Check the buyer’s guide, as their rules for referencing the original invoice vary.
Which DOCTYPE does an invoice use?
InvoiceDetail.dtd from the same cXML version, for example http://xml.cxml.org/schemas/cXML/1.2.061/InvoiceDetail.dtd.
Does a 200 response mean the invoice is approved?
No. It means the document was received and accepted for processing. Price, tax and matching checks often happen afterwards and can still reject it.
Rather we handled InvoiceDetailRequest for you?
Purchase orders, ship notices and invoices over cXML are part of our Order Loop tier: we receive or send the InvoiceDetailRequest documents, map them to your systems and handle the buyer’s test cycle. You pay nothing until it is live.
Send us the requirement See Order Loop pricing