Skip to main content

updateTaxRate

Requires permission products:tax:update.

Updates a tax rate. A code already used by another rate is refused. A rate cannot be deactivated while the catalog or the organization's defaults rely on it, or when it is the only live rate of a group in use. Needs the tax update permission.

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:

mutation UpdateTaxRate($input: UpdateTaxRateInput!) {
updateTaxRate(input: $input) {
id
code
postalCode
name
groupName
type
}
}

Variables:

{
"input": {
"id": "id"
}
}

Response:

{
"data": {
"updateTaxRate": {
"id": "id",
"code": "string",
"postalCode": "string",
"name": "string",
"groupName": "string",
"type": "string"
}
}
}
updateTaxRate(
input: UpdateTaxRateInput!
): TaxRate!

Arguments​

updateTaxRate.input ● UpdateTaxRateInput! non-null input​

The ID of the tax rate and the fields to change.

Type​

TaxRate object​

A tax rate.