Skip to main content
POST
Create a transaction

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
corporation_id
string
required

The unique identifier for the corporation associated with this transaction.

Example:

"b6d009b0-d174-463f-b030-94643c28e209"

transacted_at
string<date>
required

ISO 8601 formatted date string indicating date on which the transaction took place.

invoice_currency
string
required

ISO 4217 alpha-3 currency code for the transaction.

Example:

"USD"

transaction_type
enum<string>
required

Type of the transaction. Accepted values for creation: SALE or PURCHASE.

  • SALE: Standard sales transaction.
  • PURCHASE: Purchase transaction for input tax credit tracking. RETURN, REFUND, and PURCHASE_REFUND types are created via the refund endpoint.
Available options:
SALE,
RETURN,
REFUND,
PURCHASE,
PURCHASE_REFUND
customer_details
object
required
line_items
object
required
tax_date_override
string<date>

ISO 8601 formatted date string indicating the date on which the tax liability should be recognized for filings and for nexus tracking, if different from the transacted_at date.

calculation_date_override
string<date>

ISO 8601 formatted date string indicating the date to use for tax rate lookups, useful for ensuring returns use the same rates as the original sale.

reporting_date_override
string<date>

ISO 8601 formatted date string indicating when this transaction should appear in reports, if different from transacted_at.

invoice_number
string

Invoice or receipt number for this transaction.

subtotal
number<float>

Total amount before tax, shipping, handling, and discounts.

Required range: x >= 0
discount
number<float>

Total discount amount applied to the transaction.

Required range: x >= 0
Example:

0.99

shipping_and_handling
number<float>

Total shipping and handling charges.

Required range: x >= 0
total
number<float>

This is the total amount charged to the customer, which includes the subtotal, shipping and handling fees, tax, and reflects any applied discounts.

Required range: x >= 0
tax_collected
number<float>

Numeric value representing the amount of sales tax paid by the customer for this transaction.

Required range: x >= 0
calculation_id
string

Optional ID of a previous calculation used for this transaction.

parent_invoice_id
string

Required for RETURN transactions. The ID of the original sale transaction being returned. This links the return to the original sale for proper tax accounting.

refund_type
enum<string>

Required for RETURN transactions. Specifies whether this is a full or partial return.

  • FULL: The entire transaction amount is refunded
  • PARTIAL: Only specific items or amounts are refunded
Available options:
FULL,
PARTIAL
marketplace
string

Marketplace name if the transaction originates from a marketplace.

tax_remitter_type
enum<string>

Indicates which party is responsible for remitting tax on the transaction.

  • SELLER: The seller collects and remits tax (default).
  • MARKETPLACE_FACILITATOR: A marketplace facilitator collects and remits tax on behalf of the seller.
  • BUYER: The buyer is responsible for remitting tax (reverse-charge mechanism, common in B2B VAT transactions).
Available options:
SELLER,
MARKETPLACE_FACILITATOR,
BUYER
tax_included
boolean

Whether tax is included in the line item prices.

exemption_type
enum<string>

If this field is present, this transaction will be considered exempt.

Available options:
PURPOSE_RESALE,
ENTITY_TYPE_NONPROFIT,
GOVERNMENT,
MANUFACTURER,
AGRICULTURAL,
EXEMPT_PRODUCT,
OTHER,
EXEMPT_PRODUCT

Response

Transaction creation response

data
object
message
string
Example:

"Successfully created transaction."