Skip to main content
POST
/
tax
/
platform
/
transactions
Create Platform Transaction
curl --request POST \
  --url https://api.numeralhq.com/tax/platform/transactions \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'X-API-Version: <x-api-version>' \
  --data '
{
  "platform_calculation_id": "plat_calc_abc123",
  "reference_order_id": "order_12345",
  "reference_payment_id": "pay_67890",
  "transaction_processed_at": 1736300000
}
'
{
"object": "list",
"transactions": [
{
"id": "tr_abc123",
"object": "tax.transaction",
"calculation_id": "plat_calc_abc123",
"reference_order_id": "order_12345",
"type": "order",
"client_role": [
"payment_processor"
],
"merchant": {
"id": "merch_abc123",
"reference_merchant_id": "my-seller-123"
},
"testmode": false
},
{
"id": "tr_def456",
"object": "tax.transaction",
"calculation_id": "plat_calc_abc123",
"reference_order_id": "order_12345",
"type": "fee",
"client_role": [],
"merchant": {
"id": "merch_abc123",
"reference_merchant_id": "my-seller-123"
},
"testmode": false
}
]
}

Platform Transactions Endpoint (2026-01-01)

Convert a platform calculation into recorded transactions for tax reporting and filing purposes.
Remember to include the X-API-Version: 2026-01-01 header in your request to use this API version.

How Platform Transactions Work

When you create a platform transaction from a platform calculation, the number of transactions created depends on your platform role:
Platform RoleOrder TransactionFee Transaction
payment_processorCreated with client_role: ["payment_processor"]Created separately with client_role: []
marketplace_providerCreated with client_role: ["marketplace_provider"]No separate fee transaction
merchant_of_recordCreated with client_role: ["merchant_of_record"]No separate fee transaction

Payment Processor Behavior

Payment processors (like Stripe) receive two separate transactions:
  1. Order Transaction - Records the merchant’s sale with taxes calculated on the order items
  2. Fee Transaction - Records the platform fee with applicable taxes
This separation allows for proper tax reporting where the platform fee tax liability may differ from the order tax liability.

Marketplace Provider / Merchant of Record Behavior

Marketplace providers and merchants of record receive a single transaction that includes all order items. Fee taxes (if calculated) are included in the same transaction.

Transaction Types

The type field in each transaction indicates what it represents:
  • order - A transaction for the actual sale/order
  • fee - A transaction specifically for platform fees (payment processors only)

Example Workflow

# Step 1: Create a platform calculation
curl -X POST https://api.numeralhq.com/tax/platform/calculations \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "X-API-Version: 2026-01-01" \
  -d '{
    "merchant_id": "merch_abc123",
    "line_items": [...],
    "fee_details": {...}
  }'

# Step 2: Convert to transactions when payment is complete
curl -X POST https://api.numeralhq.com/tax/platform/transactions \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "X-API-Version: 2026-01-01" \
  -d '{
    "platform_calculation_id": "plat_calc_abc123",
    "reference_order_id": "order_12345",
    "reference_payment_id": "pay_67890",
    "transaction_processed_at": 1736300000
  }'

Response Structure

The response is always a list containing one or more transactions:
{
  "object": "list",
  "transactions": [
    {
      "id": "tr_abc123",
      "object": "tax.transaction",
      "type": "order",
      "client_role": ["payment_processor"],
      "merchant": {
        "id": "merch_abc123",
        "reference_merchant_id": "my-seller-123"
      }
      // ... additional fields
    },
    {
      "id": "tr_def456",
      "object": "tax.transaction",
      "type": "fee",
      "client_role": [],
      "merchant": {
        "id": "merch_abc123",
        "reference_merchant_id": "my-seller-123"
      }
      // ... additional fields (payment_processor only)
    }
  ]
}

Authorizations

Authorization
string
header
required

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

Headers

X-API-Version
enum<string>
required
Available options:
2026-01-01

Body

application/json

Request body for creating transactions from a platform calculation

platform_calculation_id
string
required

The ID of the platform calculation to convert to transactions

reference_order_id
string
required

Your unique identifier for this order

reference_payment_id
string

Your unique identifier for the payment (optional)

transaction_processed_at
number

Unix timestamp when the transaction was processed

Response

Platform transaction list response

Response containing the list of created transactions. Payment processors receive two transactions (order + fee), while marketplace providers and merchants of record receive one.

object
string
Example:

"list"

transactions
object[]