2. Create a Backed Invoice

Revised: 25 January 2022

Task

Once you've received a PO from Coupa, it's time to flip it into an invoice. Create a invoice against the purchase order you retrieved in Scenario 1 and include multliple lines on the invoice. Don't worry about including taxes or header charges just yet.

Using the API

Refer to these cXML examples with the API to post a PO backed invoice in Coupa: Sample cXML Invoices with Taxes (PO-backed) or Sample cXML Invoice Backed by Multiple POs

Using Flat File

Use this CSV sample file to create a flat file invoice: 02-invoice-incoming-multi-line.csv. Drop the invoice file in the /Incoming/Invoices on Coupa's SFTP server. The folder path won't change for all inbound invoices across test or production instances. This is Coupa's background loader, which is used for flat file integration.

Testing

Create a simple invoice with a single line PO with no header charges thru cXML or CSV. Make sure your cXML invoice file passes Coupa validations by ensuring the following:

  • Line 2 references InvoiceDetail.dtd
  • Header credentials match the set up in Coupa
  • DocumentReference payloadID is a valid Coupa PO
  • lineNumber matches the Coupa PO line
  • UnitOfMeasure matches the Coupa PO line

Open the Invoice in Coupa and ensure that all fields appear as expected.