Attributes
- idstring
Unique identifier for the transaction.
- objectstring
String representing the object’s type. Objects of the same type share the same value.
- currencystring
Three-letter ISO currency code, in lowercase. Must be a supported currency.
- customer_
detailsobject The customer’s details, such as address and tax IDs.
- customer_details.
addressnullable object The customer’s postal address (for example, home or business location).
- customer_details.
address. citynullable string City, district, suburb, town, or village.
- customer_details.
address. countrystring Two-letter country code (ISO 3166-1 alpha-2).
- customer_details.
address. line1nullable string Address line 1 (e.g., street, PO Box, or company name).
- customer_details.
address. line2nullable string Address line 2 (e.g., apartment, suite, unit, or building).
- customer_details.
address. postal_ codenullable string ZIP or postal code.
- customer_details.
address. statenullable string State/province as an ISO 3166-2 subdivision code, without country prefix. Example: “NY” or “TX”.
- customer_details.
address_ sourcenullable enum The type of customer address provided.
Possible enum valuesbilling
Denotes the address as billing address.
shipping
Denotes the address as shipping address.
- customer_details.
ip_ addressnullable string The customer’s IP address (IPv4 or IPv6).
- customer_details.
tax_ idsarray of objects The customer’s tax IDs (for example, EU VAT numbers).
- customer_details.
tax_ids. typeenum The type of the tax ID, one of
ad_
,nrt ar_
,cuit eu_
,vat bo_
,tin br_
,cnpj br_
,cpf cn_
,tin co_
,nit cr_
,tin do_
,rcn ec_
,ruc eu_
,oss_ vat hr_
,oib pe_
,ruc ro_
,tin rs_
,pib sv_
,nit uy_
,ruc ve_
,rif vn_
,tin gb_
,vat nz_
,gst au_
,abn au_
,arn in_
,gst no_
,vat no_
,voec za_
,vat ch_
,vat mx_
,rfc sg_
,uen ru_
,inn ru_
,kpp ca_
,bn hk_
,br es_
,cif tw_
,vat th_
,vat jp_
,cn jp_
,rn jp_
,trn li_
,uid li_
,vat my_
,itn us_
,ein kr_
,brn ca_
,qst ca_
,gst_ hst ca_
,pst_ bc ca_
,pst_ mb ca_
,pst_ sk my_
,sst sg_
,gst ae_
,trn cl_
,tin sa_
,vat id_
,npwp my_
,frp il_
,vat ge_
,vat ua_
,vat is_
,vat bg_
,uic hu_
,tin si_
,tin ke_
,pin tr_
,tin eg_
,tin ph_
,tin al_
,tin bh_
,vat kz_
,bin ng_
,tin om_
,vat de_
,stn ch_
,uid tz_
,vat uz_
,vat uz_
,tin md_
,vat ma_
,vat by_
,tin ao_
,tin bs_
,tin bb_
,tin cd_
,nif mr_
,nif me_
,pib zw_
,tin ba_
,tin gn_
,nif mk_
,vat sr_
,fin sn_
,ninea am_
,tin np_
,pan tj_
,tin ug_
,tin zm_
,tin kh_
,tin aw_
,tin az_
,tin bd_
,bin bj_
,ifu et_
,tin kg_
,tin la_
,tin cm_
,niu cv_
,nif bf_
, orifu unknown
Possible enum valuesad_
nrt ae_
trn al_
tin am_
tin ao_
tin ar_
cuit au_
abn au_
arn aw_
tin az_
tin Show 101 more - customer_details.
tax_ids. valuestring The value of the tax ID.
- customer_details.
taxability_ overrideenum The taxability override used for taxation.
Possible enum valuescustomer_
exempt The customer is exempt of tax.
none
No taxability override (default).
reverse_
charge The customer is entitled to reverse charge tax treatment.
- line_
itemsnullable objectExpandable The tax collected or refunded, by line item.
- line_items.
objectstring String representing the object’s type. Objects of the same type share the same value. Always has the value
list
. - line_items.
dataarray of objects Details about each object.
- line_items.
data. idstring Unique identifier for the object.
- line_items.
data. objectstring String representing the object’s type. Objects of the same type share the same value.
- line_items.
data. amountinteger The line item amount in the smallest currency unit. If
tax_
, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.behavior=inclusive - line_items.
data. amount_ taxinteger The amount of tax calculated for this line item, in the smallest currency unit.
- line_items.
data. livemodeboolean Has the value
true
if the object exists in live mode or the valuefalse
if the object exists in test mode. - line_items.
data. metadatanullable object Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- line_items.
data. productnullable string The ID of an existing Product.
- line_items.
data. quantityinteger The number of units of the item being purchased. For reversals, this is the quantity reversed.
- line_items.
data. referencestring A custom identifier for this line item in the transaction.
- line_items.
data. reversalnullable object If
type=reversal
, contains information about what was reversed.- line_items.
data. reversal. original_ line_ itemstring The
id
of the line item to reverse in the original transaction.
- line_items.
data. tax_ behaviorenum Specifies whether the
amount
includes taxes. Iftax_
, then the amount includes taxes.behavior=inclusive Possible enum valuesexclusive
Taxes are calculated on top of the line item amount (default).
inclusive
Taxes are included in the line item amount.
- line_items.
data. tax_ codestring The tax code ID used for this resource.
- line_items.
data. typeenum If
reversal
, this line item reverses an earlier transaction.Possible enum valuesreversal
Represents a partial or full reversal of an earlier transaction.
transaction
Represents a customer sale or order.
- line_items.
has_ moreboolean True if this list has another page of items after this one that can be fetched.
- line_items.
urlstring The URL where this list can be accessed.
- metadatanullable object
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
- referencestring
A custom unique identifier, such as ‘myOrder_123’.
- typeenum
If
reversal
, this transaction reverses an earlier transaction.Possible enum valuesreversal
Represents a partial or full reversal of an earlier transaction.
transaction
Represents a customer sale or order.
More attributes
- createdtimestamp
Time at which the object was created. Measured in seconds since the Unix epoch.
- customernullable string
The ID of an existing Customer used for the resource.
- livemodeboolean
Has the value
true
if the object exists in live mode or the valuefalse
if the object exists in test mode. - posted_
attimestamp The Unix timestamp representing when the tax liability is assumed or reduced.
- reversalnullable object
If
type=reversal
, contains information about what was reversed.- reversal.
original_ transactionnullable string The
id
of the reversedTransaction
object.
- ship_
from_ detailsnullable object The details of the ship from location, such as the address.
- ship_from_details.
addressobject The address from which the goods in the transaction are shipped from.
- ship_from_details.
address. citynullable string City, district, suburb, town, or village.
- ship_from_details.
address. countrystring Two-letter country code (ISO 3166-1 alpha-2).
- ship_from_details.
address. line1nullable string Address line 1 (e.g., street, PO Box, or company name).
- ship_from_details.
address. line2nullable string Address line 2 (e.g., apartment, suite, unit, or building).
- ship_from_details.
address. postal_ codenullable string ZIP or postal code.
- ship_from_details.
address. statenullable string State/province as an ISO 3166-2 subdivision code, without country prefix. Example: “NY” or “TX”.
- shipping_
costnullable object The shipping cost details for the transaction.
- shipping_cost.
amountinteger The shipping amount in the smallest currency unit. If
tax_
, then this amount includes taxes. Otherwise, taxes were calculated on top of this amount.behavior=inclusive - shipping_cost.
amount_ taxinteger The amount of tax calculated for shipping, in the smallest currency unit.
- shipping_cost.
shipping_ ratenullable string The ID of an existing ShippingRate.
- shipping_cost.
tax_ behaviorenum Specifies whether the
amount
includes taxes. Iftax_
, then the amount includes taxes.behavior=inclusive Possible enum valuesexclusive
Taxes are calculated on top of the shipping cost amount (default).
inclusive
Taxes are included in the shipping cost amount.
- shipping_cost.
tax_ codestring The tax code ID used for shipping.
- tax_
datetimestamp Timestamp of date at which the tax rules and rates in effect applies for the calculation.
{ "id": "tax_1NaS0I2eZvKYlo2CRuMhUcmz", "object": "tax.transaction", "created": 1690932566, "currency": "usd", "customer": null, "customer_details": { "address": { "city": "South San Francisco", "country": "US", "line1": "354 Oyster Point Blvd", "line2": "", "postal_code": "94080", "state": "CA" }, "address_source": "shipping", "ip_address": null, "tax_ids": [], "taxability_override": "none" }, "line_items": { "object": "list", "data": [ { "id": "tax_li_ONCP443tgfS8I1", "object": "tax.transaction_line_item", "amount": 1499, "amount_tax": 148, "livemode": false, "metadata": null, "product": null, "quantity": 1, "reference": "Pepperoni Pizza", "reversal": null, "tax_behavior": "exclusive", "tax_code": "txcd_40060003", "type": "transaction" } ], "has_more": false, "url": "/v1/tax/transactions/tax_1NaS0I2eZvKYlo2CRuMhUcmz/line_items" }, "livemode": false, "metadata": null, "posted_at": 1690932566, "reference": "myOrder_123", "reversal": null, "shipping_cost": { "amount": 300, "amount_tax": 0, "tax_behavior": "exclusive", "tax_code": "txcd_92010001" }, "ship_from_details": { "address": { "postal_code": "75001", "state": "TX", "country": "US" } }, "tax_date": 1690932566, "type": "transaction"}