appSetCustomerTaxExemption
Requires permission customers:customer:update.
Record a customer's tax exemption from an installed app, through the customer record. It replaces the exemption the customer has; a flagged customer needs a certificate number. Needs write_customer_tax_exemption.
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:
- GraphQL
- cURL
mutation AppSetCustomerTaxExemption($input: AppSetCustomerTaxExemptionInput!) {
appSetCustomerTaxExemption(input: $input) {
id
code
registrationNumber
name
displayName
legalName
addresses {
id
postalCode
contactName
type
createdAt
city
}
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "mutation AppSetCustomerTaxExemption($input: AppSetCustomerTaxExemptionInput!) {\n appSetCustomerTaxExemption(input: $input) {\n id\n code\n registrationNumber\n name\n displayName\n legalName\n addresses {\n id\n postalCode\n contactName\n type\n createdAt\n city\n }\n }\n}",
"variables": {
"input": {
"customerId": "id",
"taxExemption": {
"taxExempt": true
}
}
}
}
EOF
Variables:
{
"input": {
"customerId": "id",
"taxExemption": {
"taxExempt": true
}
}
}
Response:
{
"data": {
"appSetCustomerTaxExemption": {
"id": "id",
"code": "string",
"registrationNumber": "string",
"name": "string",
"displayName": "string",
"legalName": "string",
"addresses": [
{
"id": "id",
"postalCode": "string",
"contactName": "string",
"type": "string",
"createdAt": "2025-01-15T00:00:00Z",
"city": "string"
}
]
}
}
}
appSetCustomerTaxExemption(
input: AppSetCustomerTaxExemptionInput!
): Partner!
Arguments
appSetCustomerTaxExemption.input ● AppSetCustomerTaxExemptionInput! non-null input
The customer and the exemption.
Type
Partner object
A partner: the one master record for customers and vendors, with its roles, addresses, contacts and account details.