This resource represents an invoice. An invoice can be created one-off or as part of a recurring subscription.

An invoice consists of line items which can be connected to Products & Prices or be one-off items.

All amounts are in the minor unit of the currency. For example, 1000 represents $10.00 for USD, £10.00 for GBP, or ¥1000 for JPY.

Properties

id string
The unique identifier for this item.

createdAt string
The date this item was created in RFC3339 format.

object string
The object type of this resource.

collectionMethod string
How the payment for this invoice is collected. It will be sendInvoice when an invoice is sent to a recipient for payment. It will be chargeAutomatically if the invoice is charged at the time of creation.

currency string
The 3 letter currency code representing the settlement currency for this invoice.

dueDate string
The date when this invoice is due in RFC3339 format. This only applies when the collectionMethod is sendInvoice.

memo string
The memo added to the invoice.

number string
A unique number generated for this invoice. Invoice numbers are commonly used for accounting purposes.

recipientId string
The ID of the recipient of the invoice. This can either be a Client or a Company.

sentDate string
The date this invoice was sent to a client in RFC3339 format.

paymentSuccessDate string
The date this invoice was paid in RFC3339 format. This property is only set when there is a successful payment associated with an invoice. When an invoice is marked as manually paid, there is no associated payment so this property is ignored.

status string
The status of the invoice. One of draft, open, paid, void.

StatusDescription
draftWhen an invoice is duplicated it will initially be in a draft state. In this state the invoice is not yet visible to the recipient. This gives you the opportunity to modify the invoice before sending it.
openThis invoice is ready for payment. Open invoices can not be edited.
paidThis invoice has been paid. A successful payment was received or the invoice was marked as manually paid.
voidThis invoice has been voided. Only open invoices can be voided.

taxPercentage number
The percentage of tax set on this invoice.

taxAmount number
The amount of tax on this invoice based on the percentage amount and lineItems.

total number
The total amount of this invoice to be paid. This is the total of the lineItems and taxAmount.

lineItems array(lineItems)

  • amount string 
    The amount for a single unit of this line item. The total amount due for this line item is the product of this amount and quantity
  • description string
    The description given to this line item
  • quantity string
    How many units of this item are being invoiced
  • priceId string
    The ID of the price that this line item is based off. The amount property is set based on the amount of specified on the Price. This is not relevant for one-off line items.
  • productId string
    The ID of the product that this line item is based off. The description property is set based on the description of set on the product. This is not relevant for one-off line items.

{
    "collectionMethod": "sendInvoice",
    "createdAt": "2024-07-08T21:31:51.372130763Z",
    "currency": "usd",
    "dueDate": "2024-07-12T21:31:16.789Z",
    "id": "in_1PaPA1FdviIIk120fj92SW1",
    "lineItems": [
      {
        "amount": 1000,
        "description": "item a",
        "quantity": 3
      },
      {
        "amount": 100000,
        "description": "Item B",
        "priceId": "ZC9UiqQSR",
        "productId": "9e1e238f-25e5-4aff-b5f3-6793f8f2703f",
        "quantity": 1
      }
    ],
    "memo": "this invoice has a product and one off item.",
    "number": "3K1G4GG2-0002",
    "object": "invoice",
    "paymentSuccessDate": "2024-07-08T21:32:21Z",
    "recipientId": "d0000000-d7a5-473d-a75b-9821a8f4e180",
    "sentDate": "2024-07-08T21:31:51.36781915Z",
    "status": "paid",
    "taxAmount": 4635,
    "taxPercentage": 4.5,
    "total": 107635
  }