Invoices
Use the /invoices
resource to create, update, and send invoices and invoice reminders. To manage invoices, you can also list invoices, show details for invoices, delete draft invoices, and cancel sent invoices. You can also record payments for invoices to mark them as fully or partially paid, or record refunds for invoices to mark them as fully or partially refunded. You can create QR codes for invoices that can be scanned, viewed, and paid by a mobile phone.
The invoice details which includes all information of the invoice like items, billing information.
The ID of the invoice.
The parent ID to an invoice that defines the group invoice to which the invoice is related.
The status of the invoice.
The details of the invoice. Includes the invoice number, date, payment terms, and audit metadata.
The invoicer information. Includes the business name, email, address, phone, fax, tax ID, additional notes, and logo URL.
An array of one or more CC: emails to which notifications are sent. If you omit this parameter, a notification is sent to all CC: email addresses that are part of the invoice.Note: Valid values are email addresses in the additional_recipients
value associated with the invoice.
The invoice configuration details. Includes partial payment, tip, and tax calculated after discount.
The invoice object
Lists invoices. To filter the invoices that appear in the response, you can specify one or more optional query parameters.
The page number to be retrieved, for the list of templates. So, a combination of page=1
and page_size=20
returns the first 20 templates. A combination of page=2
and page_size=20
returns the next 20 templates.
1
The maximum number of templates to return in the response.
20
Indicates whether the to show total_pages and total_items in the response.
false
The fields to return in the response. Value is all
or none
. To return only the template name, ID, and default attributes, specify none
.
all
Pattern: (?i)^(all|none)$
Creates a draft invoice. To move the invoice from a draft to payable state, you must send the invoice.
In the JSON request body, include invoice details including merchant information. The invoice
object must include an items
array.
Note: The merchant that you specify in an invoice must have a PayPal account in good standing.
.
The invoice details which includes all information of the invoice like items, billing information.
The ID of the invoice.
The parent ID to an invoice that defines the group invoice to which the invoice is related.
The status of the invoice.
The details of the invoice. Includes the invoice number, date, payment terms, and audit metadata.
The invoicer information. Includes the business name, email, address, phone, fax, tax ID, additional notes, and logo URL.
An array of one or more CC: emails to which notifications are sent. If you omit this parameter, a notification is sent to all CC: email addresses that are part of the invoice.Note: Valid values are email addresses in the additional_recipients
value associated with the invoice.
The invoice configuration details. Includes partial payment, tip, and tax calculated after discount.
prefer=return=representation
.Sends or schedules an invoice, by ID, to be sent to a customer. The action depends on the invoice issue date:
If the invoice issue date is current or in the past, sends the invoice immediately.
If the invoice issue date is in the future, schedules the invoice to be sent on that date.
To suppress the merchant's email notification, set the send_to_invoicer
body parameter to false
. To send the invoice through a share link and not through PayPal, set the send_to_recipient
parameter to false
in the notification
object. The send_to_recipient
parameter does not apply to a future issue date because the invoice is scheduled to be sent through PayPal on that date.
Notes:
After you send an invoice, resending it has no effect.
To send a notification for updates, update the invoice and set the
send_to_recipient
body parameter totrue
.
The ID of the draft invoice to delete.
The email or SMS notification to send to the invoicer or payer on sending an invoice.
The subject of the email that is sent as a notification to the recipient.
A note to the payer.
Indicates whether to send a copy of the email to the merchant.
false
Indicates whether to send a copy of the email to the recipient.
true
An array of one or more CC: emails to which notifications are sent. If you omit this parameter, a notification is sent to all CC: email addresses that are part of the invoice.Note: Valid values are email addresses in the additional_recipients
value associated with the invoice.
Sends a reminder to the payer about an invoice, by ID. In the JSON request body, include a notification
object that defines the subject of the reminder and other details.
The ID of the draft invoice to delete.
The email or SMS notification to send to the invoicer or payer on sending an invoice.
The subject of the email that is sent as a notification to the recipient.
A note to the payer.
Indicates whether to send a copy of the email to the merchant.
false
Indicates whether to send a copy of the email to the recipient.
true
An array of one or more CC: emails to which notifications are sent. If you omit this parameter, a notification is sent to all CC: email addresses that are part of the invoice.Note: Valid values are email addresses in the additional_recipients
value associated with the invoice.
No content
Cancels a sent invoice, by ID, and, optionally, sends a notification about the cancellation to the payer, merchant, and CC: emails.
The ID of the draft invoice to delete.
The email or SMS notification to send to the invoicer or payer on sending an invoice.
The subject of the email that is sent as a notification to the recipient.
A note to the payer.
Indicates whether to send a copy of the email to the merchant.
false
Indicates whether to send a copy of the email to the recipient.
true
An array of one or more CC: emails to which notifications are sent. If you omit this parameter, a notification is sent to all CC: email addresses that are part of the invoice.Note: Valid values are email addresses in the additional_recipients
value associated with the invoice.
No content
Records a payment for the invoice. If no payment is due, the invoice is marked as PAID
. Otherwise, the invoice is marked as PARTIALLY PAID
.
The ID of the draft invoice to delete.
The payment details of the invoice. Includes payment type, method, date, discount, and transaction type.
The payment type in an invoicing flow which can be PayPal or an external cash or check payment.
The ID for a PayPal payment transaction. Required for the PAYPAL
payment type.
The date when the invoice was paid, in Internet date and time format. For example, yyyy-MM-dd z.
^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$
The payment mode or method through which the invoicer can accept the payment.
A note associated with an external cash or check payment.
The recipient's shipping information. Includes the user's contact information, which includes name and address.
Deletes an external payment, by invoice ID and transaction ID.
The ID of the draft invoice to delete.
The ID of the external refund transaction to delete.
No content
Records a refund for the invoice. If all payments are refunded, the invoice is marked as REFUNDED
. Otherwise, the invoice is marked as PARTIALLY REFUNDED
.
The ID of the draft invoice to delete.
The refund details of the invoice. Includes the refund type, date, amount, and method.
The PayPal refund type. Indicates whether the refund was paid through PayPal or externally in the invoicing flow. The record refund method supports the EXTERNAL
refund type. The PAYPAL
refund type is supported for backward compatibility.
The ID for a PayPal payment transaction. Required for the PAYPAL
payment type.
The date when the invoice was refunded, in Internet date format. For example, 2014-02-27
.
^[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])$
The payment mode or method through which the invoicer can accept the payments.
Deletes an external refund, by invoice ID and transaction ID.
The ID of the draft invoice to delete.
The ID of the external refund transaction to delete.
No content
Generates a QR code for an invoice, by ID. The QR code is a PNG image in Base64-encoded format that corresponds to the invoice ID. You can generate a QR code for an invoice and add it to a paper or PDF invoice. When customers use their mobile devices to scan the QR code, they are redirected to the PayPal mobile payment flow where they can view the invoice and pay online with PayPal or a credit card. Before you get a QR code, you must create an invoice and send an invoice to move the invoice from a draft to payable state. Do not include an email address if you do not want the invoice emailed.
The ID of the draft invoice to delete.
The configuration for a QR code.
The width, in pixels, of the QR code image. Value is from 150
to 500
.
500
The height, in pixels, of the QR code image. Value is from 150
to 500
.
500
The type of URL for which to generate a QR code. Valid values are pay
and details
.
pay
Pattern: (?i)^(pay|details)$
No content
Generates the next invoice number that is available to the merchant. The next invoice number uses the prefix and suffix from the last invoice number and increments the number by one. For example, the next invoice number after INVOICE-1234
is INVOICE-1235
.
Shows details for an invoice, by ID.
The ID of the draft invoice to delete.
Fully updates an invoice, by ID. In the JSON request body, include a complete invoice
object. This call does not support partial updates.
The ID of the draft invoice to delete.
Indicates whether to send the invoice update notification to the recipient.
true
Indicates whether to send the invoice update notification to the merchant.
true
The invoice details which includes all information of the invoice like items, billing information.
The ID of the invoice.
The parent ID to an invoice that defines the group invoice to which the invoice is related.
The status of the invoice.
The details of the invoice. Includes the invoice number, date, payment terms, and audit metadata.
The invoicer information. Includes the business name, email, address, phone, fax, tax ID, additional notes, and logo URL.
An array of one or more CC: emails to which notifications are sent. If you omit this parameter, a notification is sent to all CC: email addresses that are part of the invoice.Note: Valid values are email addresses in the additional_recipients
value associated with the invoice.
The invoice configuration details. Includes partial payment, tip, and tax calculated after discount.
prefer=return=representation
.Deletes a draft or scheduled invoice, by ID. Deletes invoices in the draft or scheduled state only. For invoices that have already been sent, you can cancel the invoice. After you delete a draft or scheduled invoice, you can no longer use it or show its details. However, you can reuse its invoice number.
The ID of the draft invoice to delete.
No content
Was this helpful?