Create a Tax Item

Please note there is a soft limit of 5 unique tax items per cart item at any one time.

Create a Tax Item

POST https://api.moltin.com/v2/carts/:cartID/items/:itemID/taxes

Headers

NameTypeDescription

Authorization

string

The Bearer token to grant access to the API

Request Body

NameTypeDescription

type

string

This represents the type of object being returned

name

string

The name of the tax item

jurisdiction

string

The relevant tax jurisdiction

code

string

A unique tax code in this jurisdiction

rate

float

The tax rate represented as a decimal (12.5% -> 0.125)

{
    "data": {
        "id": "003e2458-3415-4fd2-a10c-ed422bfac4bb",
        "type": "tax_item",
        "name": "Tax Name",
        "jurisdiction" : "UK",
        "code": "MYTAX01",
        "rate": 0.2
    }
}
curl -X POST https://api.moltin.com/v2/carts/:cartID/items/:itemID/taxes \
    -H "Content-Type: application/json" \
    -H "Authorization: Bearer XXXX" \
    -d $'{
        "data": {
            "type": "tax_item",
            "name": "Tax Name",
            "jurisdiction" : "UK",
            "code": "MYTAX01",
            "rate": 0.2
        }
    }'

Last updated