API Documentation
Alert
Customer
- GETList customers
- POSTCreate customer
- GETFetch customer by external ID
- PUTUpdate customer by external ID
- GETFetch customer costs by external ID
- POSTUpdate payment methods from payment provider
- GETFetch customer
- PUTUpdate customer
- DELDelete customer
- GETList balance transactions
- POSTCreate customer balance transaction
- GETFetch customer costs
- POSTUpdate payment methods from payment provider
Credit
- GETFetch customer credit balance by external customer id
- GETFetch customer credits ledger by external ID
- POSTCreate ledger entry by external ID
- GETList top-ups by external ID
- POSTCreate top-up by external ID
- DELDelete top-up by external ID
- GETFetch customer credit balance
- GETFetch customer credits ledger
- POSTCreate ledger entry
- GETList top-ups
- POSTCreate top-up
- DELDelete top-up
Dimensional Price Group
Event
Invoice
Availability
Plan
Price
Subscription
- GETList subscriptions
- POSTCreate subscription
- GETFetch subscription
- PUTUpdate subscription
- POSTCancel subscription
- GETFetch subscription costs
- GETFetch subscription schedule
- POSTSchedule plan change
- POSTTrigger phase
- POSTUnschedule subscription cancellation
- POSTUnschedule fixed fee quantity updates
- POSTUnschedule plan change
- POSTUpdate price quantity
- POSTUpdate trial for subscription
- GETFetch subscription usage
Price interval
List invoices
This endpoint returns a list of all Invoice
s for an account in a list format.
The list of invoices is ordered starting from the most recently issued invoice date. The response also includes
pagination_metadata
, which lets the caller retrieve the next page of results if they
exist.
By default, this only returns invoices that are issued
, paid
, or synced
.
When fetching any draft
invoices, this returns the last-computed invoice values for each draft invoice, which may
not always be up-to-date since Orb regularly refreshes invoices asynchronously.
Authorizations
API Keys can be issued in the Orb's web application.
Query Parameters
draft
, issued
, paid
, synced
, void
draft
, issued
, paid
, synced
, void
Filters invoices by their due dates within a specific time range in the past. Specify the range as a number followed by 'd' (days) or 'm' (months). For example, '7d' filters invoices due in the last 7 days, and '2m' filters those due in the last 2 months.
due_date
, invoice_date
The number of items to fetch. Defaults to 20.
1 < x < 100
Cursor for pagination. This can be populated by the next_cursor
value returned from the initial request.
Response
User specified key-value pairs for the resource. If not present, this defaults to an empty dictionary. Individual keys can be removed by setting the value to null
, and the entire metadata mapping can be cleared by setting metadata
to null
.
If the invoice has a status of void
, this gives a timestamp when the invoice was voided.
If the invoice has a status of paid
, this gives a timestamp when the invoice was paid.
If the invoice has been issued, this will be the time it transitioned to issued
(even if it is now in a different state.)
If the invoice is in draft, this timestamp will reflect when the invoice is scheduled to be issued.
If the invoice is scheduled for auto-collection, this field will reflect when the next attempt will occur. If dunning has been exhausted, or auto-collection is not enabled for this invoice, this field will be null
.
If Orb has ever attempted payment auto-collection for this invoice, this field will reflect when that attempt occurred. In conjunction with next_attempt_at
, this can be used to tell whether the invoice is currently in dunning (that is, previously_attempted_at
is non-null, and next_attempt_time
is non-null), or if dunning has been exhausted (previously_attempted_at
is non-null, but next_attempt_time
is null).
True only if auto-collection is enabled for this invoice.
Number of auto-collection payment attempts.
If the invoice failed to issue, this will be the last time it failed to issue (even if it is now in a different state.)
If the invoice failed to sync, this will be the last time an external invoicing provider sync was attempted. This field will always be null
for invoices using Orb Invoicing.
If payment was attempted on this invoice but failed, this will be the time of the most recent attempt.
If payment was attempted on this invoice, this will be the start time of the most recent attempt. This field is especially useful for delayed-notification payment mechanisms (like bank transfers), where payment can take 3 days or more.
This is the final amount required to be charged to the customer and reflects the application of the customer balance to the total
of the invoice.
The creation time of the resource in Orb.
An ISO 4217 currency string or credits
This field is deprecated in favor of discounts
. If a discounts
list is provided, the first discount in the list will be returned. If the list is empty, None
will be returned.
percentage
List of price_ids that this discount applies to. For plan/plan phase discounts, this can be a subset of prices.
Only available if discount_type is percentage
. This is a number between 0 and 1.
0 < x < 1
When the invoice payment is due. The due date is null if the invoice is not yet finalized.
The link to download the PDF representation of the Invoice
.
Automatically generated invoice number to help track and reconcile invoices. Invoice numbers have a prefix such as RFOBWG
. These can be sequential per account or customer.
The breakdown of prices in this invoice.
The final amount for a line item after all adjustments and pre paid credits have been applied.
percentage
List of price_ids that this discount applies to. For plan/plan phase discounts, this can be a subset of prices.
Only available if discount_type is percentage
. This is a number between 0 and 1.
0 < x < 1
The end date of the range of time applied for this line item's price.
[DEPRECATED] For configured prices that are split by a grouping key, this will be populated with the key and a value. The amount
and subtotal
will be the values for this particular grouping.
This field is deprecated in favor of adjustments
.
This field is deprecated in favor of adjustments
.
This field is deprecated in favor of adjustments
.
This field is deprecated in favor of adjustments
.
All adjustments (ie. maximums, minimums, discounts) applied to the line item.
True for adjustments that apply to an entire invocice, false for adjustments that apply to only one price.
The price IDs that this adjustment applies to.
The reason for the adjustment.
usage_discount
The number of usage units by which to discount the price this adjustment applies to in a given billing period.
The value applied by an adjustment.
The name of the price associated with this line item.
Either the fixed fee quantity or the usage during the service period.
The start date of the range of time applied for this line item's price.
The line amount before before any adjustments.
The line amount after any adjustments and before overage conversion, credits and partial invoicing.
The number of prepaid credits applied.
Any amount applied from a partial invoice
For complex pricing structures, the line item can be broken down further in sub_line_items
.
The total amount for this sub line item.
matrix
An array of tax rates and their incurred tax amounts. Empty if no tax integration is configured.
The human-readable description of the applied tax rate.
The tax rate percentage, out of 100.
The amount of additional tax incurred by this tax rate.
A unique ID for this line item.
The Price resource represents a price that can be billed on a subscription, resulting in a charge on an invoice in the form of an invoice line item. Prices take a quantity and determine an amount to bill.
Orb supports a few different pricing models out of the box. Each of these models is serialized differently in a given Price object. The model_type field determines the key for the configuration object that is present.
For more on the types of prices, see the core concepts documentation
User specified key-value pairs for the resource. If not present, this defaults to an empty dictionary. Individual keys can be removed by setting the value to null
, and the entire metadata mapping can be cleared by setting metadata
to null
.
usage_price
, fixed_price
unit
one_time
, monthly
, quarterly
, semi_annual
, annual
, custom
percentage
List of price_ids that this discount applies to. For plan/plan phase discounts, this can be a subset of prices.
Only available if discount_type is percentage
. This is a number between 0 and 1.
0 < x < 1
Rate per unit of usage
The total before any discounts and minimums are applied.
The total after any minimums and discounts have been applied.
A unique id for this transaction.
The creation time of this transaction.
The original value of the customer's balance prior to the transaction, in the customer's currency.
The new value of the customer's balance prior to the transaction, in the customer's currency.
The value of the amount changed in the transaction.
applied_to_invoice
, manual_adjustment
, prorated_refund
, revert_prorated_refund
, return_from_voiding
, credit_note_applied
, credit_note_voided
, overpayment_refund
, external_payment
An optional description provided for manual customer balance adjustments.
The Invoice id
increment
, decrement
issued
, paid
, synced
, void
, draft
subscription
, partial
, one_off
A URL for the customer-facing invoice portal. This URL expires 30 days after the invoice's due date, or 60 days after being re-generated through the UI.
This is true if the invoice will be automatically issued in the future, and false otherwise.
If the invoice has a status of draft
, this will be the time that the invoice will be eligible to be issued, otherwise it will be null
. If auto-issue
is true, the invoice will automatically begin issuing at this time.
Tax IDs are commonly required to be displayed on customer invoices, which are added to the headers of invoices.
Supported Tax ID Countries and Types
| Country | Type | Description |
|----------------|--------------|---------------------------------------------|
| Andorra | ad_nrt
| Andorran NRT Number |
| Argentina | ar_cuit
| Argentinian Tax ID Number |
| Australia | au_abn
| Australian Business Number (AU ABN) |
| Australia | au_arn
| Australian Taxation Office Reference Number |
| Austria | eu_vat
| European VAT Number |
| Bahrain | bh_vat
| Bahraini VAT Number |
| Belgium | eu_vat
| European VAT Number |
| Bolivia | bo_tin
| Bolivian Tax ID |
| Brazil | br_cnpj
| Brazilian CNPJ Number |
| Brazil | br_cpf
| Brazilian CPF Number |
| Bulgaria | bg_uic
| Bulgaria Unified Identification Code |
| Bulgaria | eu_vat
| European VAT Number |
| Canada | ca_bn
| Canadian BN |
| Canada | ca_gst_hst
| Canadian GST/HST Number |
| Canada | ca_pst_bc
| Canadian PST Number (British Columbia) |
| Canada | ca_pst_mb
| Canadian PST Number (Manitoba) |
| Canada | ca_pst_sk
| Canadian PST Number (Saskatchewan) |
| Canada | ca_qst
| Canadian QST Number (Québec) |
| Chile | cl_tin
| Chilean TIN |
| China | cn_tin
| Chinese Tax ID |
| Colombia | co_nit
| Colombian NIT Number |
| Costa Rica | cr_tin
| Costa Rican Tax ID |
| Croatia | eu_vat
| European VAT Number |
| Cyprus | eu_vat
| European VAT Number |
| Czech Republic | eu_vat
| European VAT Number |
| Denmark | eu_vat
| European VAT Number |
| Dominican Republic | do_rcn
| Dominican RCN Number |
| Ecuador | ec_ruc
| Ecuadorian RUC Number |
| Egypt | eg_tin
| Egyptian Tax Identification Number |
| El Salvador | sv_nit
| El Salvadorian NIT Number |
| Estonia | eu_vat
| European VAT Number |
| EU | eu_oss_vat
| European One Stop Shop VAT Number for non-Union scheme |
| Finland | eu_vat
| European VAT Number |
| France | eu_vat
| European VAT Number |
| Georgia | ge_vat
| Georgian VAT |
| Germany | eu_vat
| European VAT Number |
| Greece | eu_vat
| European VAT Number |
| Hong Kong | hk_br
| Hong Kong BR Number |
| Hungary | eu_vat
| European VAT Number |
| Hungary | hu_tin
| Hungary Tax Number (adószám) |
| Iceland | is_vat
| Icelandic VAT |
| India | in_gst
| Indian GST Number |
| Indonesia | id_npwp
| Indonesian NPWP Number |
| Ireland | eu_vat
| European VAT Number |
| Israel | il_vat
| Israel VAT |
| Italy | eu_vat
| European VAT Number |
| Japan | jp_cn
| Japanese Corporate Number (Hōjin Bangō) |
| Japan | jp_rn
| Japanese Registered Foreign Businesses' Registration Number (Tōroku Kokugai Jigyōsha no Tōroku Bangō) |
| Japan | jp_trn
| Japanese Tax Registration Number (Tōroku Bangō) |
| Kazakhstan | kz_bin
| Kazakhstani Business Identification Number |
| Kenya | ke_pin
| Kenya Revenue Authority Personal Identification Number |
| Latvia | eu_vat
| European VAT Number |
| Liechtenstein | li_uid
| Liechtensteinian UID Number |
| Lithuania | eu_vat
| European VAT Number |
| Luxembourg | eu_vat
| European VAT Number |
| Malaysia | my_frp
| Malaysian FRP Number |
| Malaysia | my_itn
| Malaysian ITN |
| Malaysia | my_sst
| Malaysian SST Number |
| Malta | eu_vat
| European VAT Number |
| Mexico | mx_rfc
| Mexican RFC Number |
| Netherlands | eu_vat
| European VAT Number |
| New Zealand | nz_gst
| New Zealand GST Number |
| Nigeria | ng_tin
| Nigerian Tax Identification Number |
| Norway | no_vat
| Norwegian VAT Number |
| Norway | no_voec
| Norwegian VAT on e-commerce Number |
| Oman | om_vat
| Omani VAT Number |
| Peru | pe_ruc
| Peruvian RUC Number |
| Philippines | ph_tin
| Philippines Tax Identification Number |
| Poland | eu_vat
| European VAT Number |
| Portugal | eu_vat
| European VAT Number |
| Romania | eu_vat
| European VAT Number |
| Romania | ro_tin
| Romanian Tax ID Number |
| Russia | ru_inn
| Russian INN |
| Russia | ru_kpp
| Russian KPP |
| Saudi Arabia | sa_vat
| Saudi Arabia VAT |
| Serbia | rs_pib
| Serbian PIB Number |
| Singapore | sg_gst
| Singaporean GST |
| Singapore | sg_uen
| Singaporean UEN |
| Slovakia | eu_vat
| European VAT Number |
| Slovenia | eu_vat
| European VAT Number |
| Slovenia | si_tin
| Slovenia Tax Number (davčna številka) |
| South Africa | za_vat
| South African VAT Number |
| South Korea | kr_brn
| Korean BRN |
| Spain | es_cif
| Spanish NIF Number (previously Spanish CIF Number) |
| Spain | eu_vat
| European VAT Number |
| Sweden | eu_vat
| European VAT Number |
| Switzerland | ch_vat
| Switzerland VAT Number |
| Taiwan | tw_vat
| Taiwanese VAT |
| Thailand | th_vat
| Thai VAT |
| Turkey | tr_tin
| Turkish Tax Identification Number |
| Ukraine | ua_vat
| Ukrainian VAT |
| United Arab Emirates | ae_trn
| United Arab Emirates TRN |
| United Kingdom | eu_vat
| Northern Ireland VAT Number |
| United Kingdom | gb_vat
| United Kingdom VAT Number |
| United States | us_ein
| United States EIN |
| Uruguay | uy_ruc
| Uruguayan RUC Number |
| Venezuela | ve_rif
| Venezuelan RIF Number |
| Vietnam | vn_tin
| Vietnamese Tax ID Number |
AD
, AE
, AR
, AT
, AU
, BE
, BG
, BH
, BO
, BR
, CA
, CH
, CL
, CN
, CO
, CR
, CY
, CZ
, DE
, DK
, EE
, DO
, EC
, EG
, ES
, EU
, FI
, FR
, GB
, GE
, GR
, HK
, HR
, HU
, ID
, IE
, IL
, IN
, IS
, IT
, JP
, KE
, KR
, KZ
, LI
, LT
, LU
, LV
, MT
, MX
, MY
, NG
, NL
, NO
, NZ
, OM
, PE
, PH
, PL
, PT
, RO
, RS
, RU
, SA
, SE
, SG
, SI
, SK
, SV
, TH
, TR
, TW
, UA
, US
, UY
, VE
, VN
, ZA
ad_nrt
, ae_trn
, ar_cuit
, eu_vat
, au_abn
, au_arn
, bg_uic
, bh_vat
, bo_tin
, br_cnpj
, br_cpf
, ca_bn
, ca_gst_hst
, ca_pst_bc
, ca_pst_mb
, ca_pst_sk
, ca_qst
, ch_vat
, cl_tin
, cn_tin
, co_nit
, cr_tin
, do_rcn
, ec_ruc
, eg_tin
, es_cif
, eu_oss_vat
, gb_vat
, ge_vat
, hk_br
, hu_tin
, id_npwp
, il_vat
, in_gst
, is_vat
, jp_cn
, jp_rn
, jp_trn
, ke_pin
, kr_brn
, kz_bin
, li_uid
, mx_rfc
, my_frp
, my_itn
, my_sst
, ng_tin
, no_vat
, no_voec
, nz_gst
, om_vat
, pe_ruc
, ph_tin
, ro_tin
, rs_pib
, ru_inn
, ru_kpp
, sa_vat
, sg_gst
, sg_uen
, si_tin
, sv_nit
, th_vat
, tr_tin
, tw_vat
, ua_vat
, us_ein
, uy_ruc
, ve_rif
, vn_tin
, za_vat
Free-form text which is available on the invoice PDF and the Orb invoice portal.
A list of credit notes associated with the invoice
If the credit note has a status of void
, this gives a timestamp when the credit note was voided.
An optional memo supplied on the credit note.
A list of payment attempts associated with the invoice
The ID of the payment attempt.
The payment provider that attempted to collect the payment.
stripe
The ID of the payment attempt in the payment provider.
The amount of the payment attempt.
Whether the payment attempt succeeded.
The time at which the payment attempt was created.
The scheduled date of the invoice
Was this page helpful?