Create and Send an Invoice Immediately

Creating and sending an invoice publishes a payable invoice that is automatically emailed to the customer. In addition to the sent email, you can also share the invoice by sending the customer the redirect URL generated in the
invoiceInformation.paymentLink
response field.
Itemized Invoices
An invoice can display a single billed amount or list up to 30 billed items. To list the billed items in the invoice, include the items in the request using the line item array fields. An invoice with line items is known as an
itemized
invoice. For more information about how to include line items in your request, see Including Line Items in an Invoice.
Invoice Numbers
You can assign a unique invoice number in the
invoiceInformation.invoiceNumber
request field. The invoice number is required for follow-on API requests and tracking. You should store the invoice number in your system so that you can optimally perform the follow-on requests. If you do not include a unique invoice number when creating an invoice,
Cybersource
generates a unique invoice number for you in the
invoiceInformation.invoiceNumber
response field.
IMPORTANT
You cannot update the invoice number after it is generated.
Installment Payments
Invoices can be paid in installment payments when these fields and values are included in the request. If an invoice is payable in installments, multiple customers can make payments towards the same invoice.
invoiceInformation.allowPartialPayments
Set to
true
.
orderInformation.amountDetails.minimumPartialAmount
Set to the minimum amount allowed for a partial payment.
Partner Information
If your merchant account is associated with a
Cybersource
partner, you can include your partner solution ID (PSID) in the request message for tracking and reporting purposes. To include your PSID, use the
clientReferenceInformation.partner.solutionId
request field and set its field value to your PSID.
Alternative Methods to Create an Invoice
To create a new invoice that is
not
immediately sent in an email to the customer, see Create an Invoice without Sending it.
To create an invoice
draft
that is not payable or viewable to the customer, see Create a Draft Invoice.

Endpoint

Send an API POST request message to one of these endpoints:
Test:
POST
https://apitest.cybersource.com
/invoicing/v2/invoices
Production:
POST
https://api.cybersource.com
/invoicing/v2/invoices
India Production:
POST https://api.in.cybersource.com/invoicing/v2/invoices

Successful Response

A successfully created and sent invoice is indicated by the
SENT
status in the
status
response field. The response message also includes the newly created invoice's details.