Configuring Payment Amounts

Read about how to configure payment amounts in the requests that are sent to the API.

You can include amounts on the transaction line item level.

Fields

The following table summarizes the main fields that can be used to specify the amount:

Field

Description

amount

Pre-tax amount. You use this field for tax exclusive pricing. Taxamo calculates the tax on this amount and returns the tax_amount and total_amount fields.

total_amount

Post-tax amount. You use this field for tax inclusive pricing. Taxamo returns the amount and tax_amount fields.

The service supports two pricing options:

Tax Exclusive Pricing

If the prices that you list on your store do not include tax, you can send the amount to the service. You use the amount field to do this in your requests.

The service uses this field to calculate the tax and returns the following fields:

  • tax_amount: The amount of tax.
  • total_amount: The total amount including tax. This is the sum of the pre-tax amount (amount field) and the tax (tax_amount field).

For example, this request specifies an amount of 100 that does not include tax:

{
                "custom_id": "line_2",
                "amount": 100,
                "ship_from_address": {"country_code": "PL"},
                "product_class": "P",
                
                "description": "Goods #2",              
                "parcel_reference": "3897329872423",
                "carrier_id": "DHL",
        "product_cn_code": "8504 31 80 15",
                
    }]

This example shows the values returned by the service for this request. Note the tax amount is 10:

"transaction_lines": [
            {
                "description": "Smoked herrings",
                "reverse_charge": false,
                "amount": 100,
                "tax_rule_applied": "physical-tax",
                "taxes": [
                    {
                        "rate": 12,
                        "tax_name": "European VAT",
                        "rate_type": "Reduced",
                        "amount_fraction_taxable": 1,
                        "tax_base_amount": 100
                    }
                ],
                "tax_amount": 10,

The total amount is at the end of the JSON:

"total_amount": 110,

Tax Inclusive Pricing

If the prices that you list on your store include tax, you can use the total_amount field to include this in your requests.

The service returns the following fields:

  • amount: The amount excluding the tax.
  • tax_amount: The amount of tax.

For example, this request specifies a total amount of 100 that includes tax:

{
                "custom_id": "line_2",
                "total_amount": 100,
                "ship_from_address": {"country_code": "PL"},
                "product_class": "P",
                
                "description": "Goods #2",              
                "parcel_reference": "3897329872423",
                "carrier_id": "DHL",
        "product_cn_code": "8504 31 80 15",
        
    }]


If you need further help, contact support at https://www.vertexinc.com/en-gb/support-services/taxamo-customer-support.

Did this page help you?