Tax calculation
Supports the following calculation operations for prices:
Net to gross values
Gross to net values
Gross values in one country to gross values in another country
Note: This endpoint calculates net and gross values for prices based on existing tax configurations. To use this endpoint, you need to create tax configurations first.
To calculate gross values beetween countries, you need to create tax configurations for both countries.
Authorizations
Path parameters
tenantstring · min: 3 · max: 16RequiredPattern:
Your Emporix tenant's name.
Note: The tenant should always be written in lowercase.
^[a-z][a-z0-9]+$
Body
commandUuidstringOptional
Calculation command's unique identifier.
Note: This field is optional. If not specified, the commandUuid
will be generated by the server.
Responses
200
The request was successful. The calculated value is returned.
application/json
400
Request was syntactically incorrect. Details will be provided in the response payload.
application/json
401
Given request is unauthorized - the authorization token is invalid or has expired. Details will be provided in the response payload.
application/json
403
Given authorization scopes are not sufficient and do not match scopes required by the endpoint.
application/json
500
Internal Service Error occurred.
application/json
put
PUT /tax/{tenant}/taxes/calculation-commands HTTP/1.1
Host: api.emporix.io
Authorization: Bearer YOUR_OAUTH2_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 110
{
"input": {
"targetLocation": {
"countryCode": "DE"
},
"targetTaxClass": "STANDARD",
"includesTax": false,
"price": 1.59
}
}
{
"commandUuid": "cb0d5627-08ef-4de9-a676-a254a4311261",
"input": {
"targetCountry": "DE",
"targetTaxClass": "STANDARD",
"includesTax": false,
"price": 1.59
},
"output": {
"netPrice": 1.59,
"grossPrice": 1.8921,
"targetTaxRate": 19
}
}
Was this helpful?