Skip to main content

taxRatesByLocation

Requires an authenticated session.

Returns the active tax rates for a place, taking the most specific match that exists: country with state, city and postal code, then each shorter combination, down to the country alone. Default rates come first.

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

query TaxRatesByLocation($country: String!) {
taxRatesByLocation(country: $country) {
id
code
postalCode
name
groupName
type
}
}

Variables:

{
"country": "string"
}

Response:

{
"data": {
"taxRatesByLocation": [
{
"id": "id",
"code": "string",
"postalCode": "string",
"name": "string",
"groupName": "string",
"type": "string"
}
]
}
}
taxRatesByLocation(
city: String
country: String!
postalCode: String
state: String
): [TaxRate!]!

Arguments​

taxRatesByLocation.city ● String scalar​

The city. Omit it to match at a broader level.

taxRatesByLocation.country ● String! non-null scalar​

The country the tax applies in.

taxRatesByLocation.postalCode ● String scalar​

The postal code. Omit it to match at a broader level.

taxRatesByLocation.state ● String scalar​

The state or region. Omit it to match at a broader level.

Type​

TaxRate object​

A tax rate.