The InvoiceDetailRequest payload sends an invoice request from your eCommerce platform to the TradeCentric platform so that we can deliver the invoice to the buyer's eProcurement system. For standard integrations that send cXML payloads, we accept the InvoiceDetailRequest in our standard cXML format.
This article describes the standard cXML format to use for this payload.
Important: This invoice request payload is for invoices associated with purchase orders (POs) only. The payload must include the PO identifier from the PO request payload that we sent.
Jump to:
Request payload (to TradeCentric)
The code block below shows an example InvoiceDetailRequest payload in our standard cXML format:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE cXML SYSTEM "http://xml.cXML.org/schemas/cXML/1.2.014/InvoiceDetail.dtd">
<cXML payloadID="12345678" timestamp="2022-11-18T00:00:00Z" version="1.2.014">
<Header>
<From>
<Credential domain="NetworkID">
<Identity>SupplierSystem</Identity>
</Credential>
</From>
<To>
<Credential domain="NetworkID">
<Identity>BuyerSystem</Identity>
</Credential>
</To>
<Sender>
<Credential domain="NetworkID">
<Identity>SupplierSystem</Identity>
<SharedSecret>ABCD1234efgh5678.IJKL9012mnopq</SharedSecret>
</Credential>
<UserAgent>eCommerceInvoice</UserAgent>
</Sender>
</Header>
<Request deploymentMode="production">
<InvoiceDetailRequest>
<InvoiceDetailRequestHeader invoiceID="INV-789" purpose="standard" operation="new" invoiceDate="2022-11-18">
<InvoiceDetailHeaderIndicator/>
<InvoiceDetailLineIndicator isTaxInLine="yes"/>
<InvoicePartner>
<Contact role="billTo">
<Name xml:lang="en">Test Corp. - Nashville Branch</Name>
<PostalAddress name="Default">
<DeliverTo>Contact Name</DeliverTo>
<Street>123 Test St.</Street>
<City>Nashville</City>
<State>TN</State>
<PostalCode>37011</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Email>contact@buyer.com</Email>
<Phone>
<TelephoneNumber>
<CountryCode isoCountryCode="US"/>
<AreaOrCityCode/>
<Number>888-555-9876</Number>
</TelephoneNumber>
</Phone>
</Contact>
</InvoicePartner>
<InvoicePartner>
<Contact role="shipTo">
<Name xml:lang="en">Test Corp. - Nashville Branch</Name>
<PostalAddress name="Default">
<DeliverTo>Contact Name</DeliverTo>
<Street>123 Test St.</Street>
<City>Nashville</City>
<State>TN</State>
<PostalCode>37011</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Email>contact@buyer.com</Email>
</Contact>
</InvoicePartner>
<PaymentTerm payInNumberOfDays="30">
<Discount>
<DiscountPercent percent="3"/>
</Discount>
</PaymentTerm>
</InvoiceDetailRequestHeader>
<InvoiceDetailOrder>
<InvoiceDetailOrderInfo>
<OrderReference orderID="PO-123">
<DocumentReference payloadID="985274930687.1374859706.109.7733@zimbuyer.com"/>
</OrderReference>
</InvoiceDetailOrderInfo>
<InvoiceDetailItem invoiceLineNumber="101" quantity="2">
<UnitOfMeasure>EA</UnitOfMeasure>
<UnitPrice>
<Money currency="USD">41.15</Money>
</UnitPrice>
<InvoiceDetailItemReference lineNumber="1">
<ItemID>
<SupplierPartID>45L017</SupplierPartID>
</ItemID>
</InvoiceDetailItemReference>
<SubtotalAmount>
<Money currency="USD">82.30</Money>
</SubtotalAmount>
<InvoiceDetailLineShipping>
<InvoiceDetailShipping>
<Contact role="billTo">
<Name xml:lang="en">Test Corp. - Nashville Branch</Name>
<PostalAddress name="Default">
<DeliverTo>Contact Name</DeliverTo>
<Street>123 Test St.</Street>
<City>Nashville</City>
<State>TN</State>
<PostalCode>37011</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Email>contact@buyer.com</Email>
<Phone>
<TelephoneNumber>
<CountryCode isoCountryCode="US"/>
<AreaOrCityCode/>
<Number>888-555-9876</Number>
</TelephoneNumber>
</Phone>
</Contact>
<Contact role="shipTo">
<Name xml:lang="en">Test Corp. - Nashville Branch</Name>
<PostalAddress name="Default">
<DeliverTo>Contact Name</DeliverTo>
<Street>123 Test St.</Street>
<City>Nashville</City>
<State>TN</State>
<PostalCode>37011</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Email>contact@buyer.com</Email>
</Contact>
</InvoiceDetailShipping>
<Money currency="USD">2.25</Money>
</InvoiceDetailLineShipping>
<GrossAmount>
<Money currency="USD">86.80</Money>
</GrossAmount>
<InvoiceDetailDiscount percentageRate="5">
<Money currency="USD">4.12</Money>
</InvoiceDetailDiscount>
</InvoiceDetailItem>
</InvoiceDetailOrder>
<InvoiceDetailSummary>
<SubtotalAmount>
<Money currency="USD">86.80</Money>
</SubtotalAmount>
<Tax>
<Money currency="USD">8.64</Money>
<Description xml:lang="en"/>
</Tax>
<SpecialHandlingAmount>
<Money currency="USD">9.99</Money>
</SpecialHandlingAmount>
<ShippingAmount>
<Money currency="USD">10.09</Money>
</ShippingAmount>
<GrossAmount>
<Money currency="USD">103.97</Money>
</GrossAmount>
<InvoiceDetailDiscount>
<Money currency="USD">11.55</Money>
</InvoiceDetailDiscount>
<NetAmount>
<Money currency="USD">92.42</Money>
</NetAmount>
</InvoiceDetailSummary>
</InvoiceDetailRequest>
</Request>
</cXML>
Request element details
A standard cXML InvoiceDetailRequest payload has a root element, a Header element, and a Request element. The subsections below explain each element and its fields.
cXML root
Applies identifying information to the entire payload
<cXML payloadID="12345678" timestamp="2022-11-18T00:00:00Z" version="1.2.014"> ... </cXML>
Header
Identifies the organizations involved in the transaction
<Header>
<From>
<Credential domain="NetworkID">
<Identity>SupplierSystem</Identity>
</Credential>
</From>
<To>
<Credential domain="NetworkID">
<Identity>BuyerSystem</Identity>
</Credential>
</To>
<Sender>
<Credential domain="NetworkID">
<Identity>SupplierSystem</Identity>
<SharedSecret>ABCD1234efgh5678.IJKL9012mnopq</SharedSecret>
</Credential>
<UserAgent>eCommerceInvoice</UserAgent>
</Sender>
</Header>
Request
Provides the invoice details, which are described in the subsections below
Invoice identification
Provides identifying information about the invoice
<Request deploymentMode="production">
<InvoiceDetailRequest>
<InvoiceDetailRequestHeader invoiceID="INV-789" purpose="standard" operation="new" invoiceDate="2022-11-18">
<InvoiceDetailHeaderIndicator/>
<InvoiceDetailLineIndicator isTaxInLine="yes"/>
Contacts and addresses
Provides the invoice contact and address details
Note: Repeat the InvoicePartner element for each invoice address, such as a shipping or billing address.
<InvoicePartner>
<Contact role="billTo">
<Name xml:lang="en">Test Corp. - Nashville Branch</Name>
<PostalAddress name="Default">
<DeliverTo>Contact Name</DeliverTo>
<Street>123 Test St.</Street>
<City>Nashville</City>
<State>TN</State>
<PostalCode>37011</PostalCode>
<Country isoCountryCode="US">United States</Country>
</PostalAddress>
<Email>contact@buyer.com</Email>
<Phone>
<TelephoneNumber>
<CountryCode isoCountryCode="US"/>
<AreaOrCityCode/>
<Number>888-555-9876</Number>
</TelephoneNumber>
</Phone>
</Contact>
</InvoicePartner>
Payment terms
Provides the payment terms, including discount percentage, for the invoice
<PaymentTerm payInNumberOfDays="30">
<Discount>
<DiscountPercent percent="3"/>
</Discount>
</PaymentTerm>
Item details
Provides the PO reference and invoice line item details, which are described in the subsections below
PO reference
Provides the PO details that this invoice applies to
<InvoiceDetailOrder>
<InvoiceDetailOrderInfo>
<OrderReference orderID="PO-123">
<DocumentReference payloadID="985274930687.1374859706.109.7733@zimbuyer.com"/>
</OrderReference>
</InvoiceDetailOrderInfo>
Items
Provides details about each of the line items in the invoice
Note: Repeat the InvoiceDetailItem element for each line item.
<InvoiceDetailItem invoiceLineNumber="101" quantity="2">
<UnitOfMeasure>EA</UnitOfMeasure>
<UnitPrice>
<Money currency="USD">41.15</Money>
</UnitPrice>
<InvoiceDetailItemReference lineNumber="1">
<ItemID>
<SupplierPartID>45L017</SupplierPartID>
</ItemID>
</InvoiceDetailItemReference>
<SubtotalAmount>
<Money currency="USD">82.30</Money>
</SubtotalAmount>
<InvoiceDetailLineShipping>
<InvoiceDetailShipping>
...
</InvoiceDetailShipping>
<Money currency="USD">2.25</Money>
</InvoiceDetailLineShipping>
<GrossAmount>
<Money currency="USD">86.80</Money>
</GrossAmount>
<InvoiceDetailDiscount percentageRate="5">
<Money currency="USD">4.12</Money>
</InvoiceDetailDiscount>
</InvoiceDetailItem>
Value summary
Provides a value summary for the entire invoice
<InvoiceDetailSummary>
<SubtotalAmount>
<Money currency="USD">86.80</Money>
</SubtotalAmount>
<Tax>
<Money currency="USD">8.64</Money>
<Description xml:lang="en"/>
</Tax>
<SpecialHandlingAmount>
<Money currency="USD">9.99</Money>
</SpecialHandlingAmount>
<ShippingAmount>
<Money currency="USD">10.09</Money>
</ShippingAmount>
<GrossAmount>
<Money currency="USD">103.97</Money>
</GrossAmount>
<InvoiceDetailDiscount>
<Money currency="USD">11.55</Money>
</InvoiceDetailDiscount>
<NetAmount>
<Money currency="USD">92.42</Money>
</NetAmount>
</InvoiceDetailSummary>
Response payload (from TradeCentric)
Once our platform processes the invoice payload, we’ll return a cXML response payload. This response will indicate whether we created a final invoice payload to transmit to the buyer.
The code block below shows an example response in our standard cXML format:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE cXML SYSTEM "http://xml.cxml.org/schemas/cXML/1.2.0xx/cXML.dtd">
<cXML xml:lang="en-US" payloadID="12345678-response" timestamp="2022-11-18T00:00:01Z">
<Response>
<Status code="200" text="Successful">Successful</Status>
</Response>
</cXML>
Response element details
A standard cXML response has a root element and a Response element. The subsections below explain each element and its fields.
cXML root
Applies identifying information to the entire response payload
<cXML xml:lang="en-US" payloadID="12345678-response" timestamp="2022-11-18T00:00:01Z"> ... </cXML>
Response
Indicates that we either accepted or rejected the invoice
Note: The response only indicates the result of the initial validation. An error may happen later in the process, such as on the buyer side.
<Response> <Status code="200" text="Successful">Successful</Status> </Response>