Estimate transaction costs

POST https://api.tamio.com/v2/transactions/estimate

Calculates estimated transaction costs including taxes, shipping, and discounts without creating an actual transaction. Useful for checkout previews and price calculations. Requires either an existing customer or new_customer for tax and shipping estimation.

Body Parameters

estimates boolean*

Must be true for estimation mode.

currency string*

Currency code for price estimation.

affiliate string

Affiliate UUID for commission estimation.

convert_prices boolean

Enable currency conversion.

no_discounts boolean

Exclude discounts from estimation.

no_payment_validation boolean

Skip payment method validation.

referrer string

Referring page URL.

coupons array of string

Coupon codes to include in estimation.

products array of ProductItem*

Product line items (1–20).

custom_shipping object

Custom shipping option.

customer object

Existing customer for personalized estimation.

new_customer object

New customer for estimation.

Responses

200 Transaction estimate

Transaction estimate

status integer
transaction object

Estimated transaction breakdown with products, taxes, shipping, totals, and available payment methods.

400 Validation or business-logic error
401 Missing or invalid API key
/transactions/estimate
1const response = await fetch("https://api.tamio.com/v2/transactions/estimate", {
2 method: "POST",
3 headers: {
4 "Authorization": "Bearer YOUR_API_KEY",
5 "Content-Type": "application/json"
6 },
7 body: JSON.stringify({
8 // ... request body
9 })
10});
11const data = await response.json();
Responses
{
  "status": 200,
  "transaction": {}
}