Skip to main content
PATCH
JavaScript

Authorizations

Authorization
string
header
required

An Account API key, account-scoped JWT, App API key, or user OAuth token. Prepend the key or token with Bearer, for example Bearer ***************************.

Path Parameters

id
string
required

The unique identifier of the invoice to update.

Example:

"inv_xxxxxxxxxxxxxx"

Body

application/json

Parameters for UpdateInvoice

automatically_finalizes_at
string<date-time> | null

The date and time when the invoice will be automatically finalized. For charge_automatically, triggers an automatic charge. For send_invoice, sends the invoice email at the specified time.

Example:

"2023-12-01T05:00:00.401Z"

billing_address
object | null

Inline billing address to create or update a mailing address for this invoice.

charge_buyer_fee
boolean | null

Whether to charge the customer a buyer fee on this invoice.

collection_method
enum<string> | null

How the invoice should be collected.

Available options:
send_invoice,
charge_automatically
customer_name
string | null

The name of the customer.

due_date
string<date-time> | null

The date by which the invoice must be paid.

Example:

"2023-12-01T05:00:00.401Z"

email_address
string | null

The email address of the customer.

line_items
object[] | null

Line items that break down the invoice total.

mailing_address_id
string | null

The unique identifier of an existing mailing address to attach.

Example:

"ma_xxxxxxxxxxxxxxx"

member_id
string | null

The unique identifier of a member to assign as the customer.

Example:

"mber_xxxxxxxxxxxxx"

payment_method_id
string | null

The unique identifier of the payment method to charge.

Example:

"pmt_xxxxxxxxxxxxxx"

plan
object | null

Updated plan attributes.

product_id
string | null

The unique identifier of an existing product to attach to this invoice. Only allowed while the invoice is still a draft.

Example:

"prod_xxxxxxxxxxxxx"

subscription_billing_anchor_at
string<date-time> | null

The date that defines when the subscription billing cycle should start.

Example:

"2023-12-01T05:00:00.401Z"

Response

A successful response

An invoice represents an itemized bill sent by a company to a customer for a specific product and plan, tracking the amount owed, due date, and payment status.

automatically_finalizes_at
string<date-time> | null
required

The date and time when the invoice will be automatically finalized. For charge_automatically, triggers an automatic charge. For send_invoice, sends the invoice email at the specified time.

Example:

"2023-12-01T05:00:00.401Z"

charge_buyer_fee
boolean
required

Whether the invoice includes a buyer processing fee on top of the plan price.

collection_method
enum<string>
required

The method used to collect payment for this invoice, such as automatic charging or manual payment.

Available options:
send_invoice,
charge_automatically
company
object
required

The company that issued this invoice.

created_at
string<date-time>
required

The datetime the invoice was created.

Example:

"2023-12-01T05:00:00.401Z"

current_plan
object
required

The plan that this invoice charges for.

customer_name
string | null
required

The full name of the customer this invoice is addressed to. Null if no name is on file.

Example:

"Jane Doe"

due_date
string<date-time> | null
required

The deadline by which payment is expected. Null if the invoice is collected automatically.

Example:

"2023-12-01T05:00:00.401Z"

email_address
string | null
required

The email address of the customer this invoice is addressed to. Null if no email is on file.

Example:

"customer@example.com"

fetch_invoice_token
string
required

A signed token that allows fetching invoice data publicly without authentication.

Example:

"eyJhbGciOiJIUzI1NiJ9..."

id
string
required

The unique identifier for the invoice.

Example:

"inv_xxxxxxxxxxxxxx"

line_items
object[]
required

Optional line items that break down the invoice total into individual charges.

mailing_address
object | null
required

The billing/mailing address associated with this invoice, if one was provided at creation time.

member
object | null
required

The member that the invoice was created for. Null when the invoice is addressed to an email address with no member record behind it.

number
string
required

The sequential invoice number for display purposes.

Example:

"#0001"

pay_online_url
string | null
required

The checkout URL where the customer can pay this invoice online, with their email address pre-filled and locked.

payment
object | null
required

The payment that settled this invoice. Null while the invoice is unpaid, when the invoice was marked paid manually, and on a subscription renewal invoice, where the settling payment cannot yet be identified.

payment_processing
boolean
required

Whether a payment on this invoice is still clearing. True while a delayed payment method such as ACH or SEPA settles, during which the invoice stays open and is not marked past due.

product
object
required

The product that this invoice was generated for.

status
enum<string>
required

The current payment status of the invoice, such as draft, open, paid, or void.

Available options:
draft,
open,
paid,
past_due,
uncollectible,
void
subscription_billing_anchor_at
string<date-time> | null
required

The date that defines when the subscription billing cycle starts. When set on a renewal plan invoice, all future billing periods anchor to this date.

Example:

"2023-12-01T05:00:00.401Z"

updated_at
string<date-time>
required

The datetime the invoice was last updated.

Example:

"2023-12-01T05:00:00.401Z"

user
object | null
required

The user this invoice is addressed to. Null if the user account has been removed.