Just as with validations, at VatZen we have a concept of 2 price types: Hot and Cold.
Cold prices works in fire-and-forget way. Meaning that you simply call our endpoint and we return you the data, which is never stored afterwards.
Hot prices endpoint is different from the cold one in the way that all the requests you make has id's assigned and stored in our DB. And you can always fetch this prices (fetch them all of fetch by id). For example, you can create them on the server side and then retrieve on the client.
Cold validations are performed via price
endpoint, end hot validation use prices
CRUD endpoints. You can get more details below.
Base of our prices endpoints is the Price
entity, which is returned from all pricing-related endpoints. You can find the description of the Pricing
entity below:
Field | Type | Example | Description |
|
|
| Uniq id assigned only for hot price calculations. You can use this id to retrieve the price info later. |
|
|
| Object, which represents the calculation results. |
|
|
| Total amount in cents, including VAT. |
|
|
| Total amount in cents, excluding VAT. |
|
|
| VAT amount in cents. |
|
|
| Category used for calculating the vat rate. |
|
|
| VAT Value in percents |
|
|
| Information about the country, which was the target for your calculations |
|
|
| 2 symbol ISO country code |
|
|
| English name of the country |
|
|
| Local name of the country, defaults to English |
|
|
| Identifies if the requested country a member state or not |
{"success": true,"amount": {"total_excl_vat": 10000,"total_incl_vat": 10500,"vat_amount": 500},"requested": {"amount": 10000,"vat_included": false},"category": "audiobook","vat_rate": 5,"country": {"code": "DE","name": "Germany","local_name": "Germany","member_state": true}}
{"success": true,"id": "ab123ba","amount": {"total_excl_vat": 10000,"total_incl_vat": 10500,"vat_amount": 500},"requested": {"amount": 10000,"vat_included": false},"category": "audiobook","vat_rate": 5,"country": {"code": "DE","name": "Germany","local_name": "Germany","member_state": true}}
{"success": true,"id": "ab123ba","amount": {"total_excl_vat": 10000,"total_incl_vat": 10500,"vat_amount": 500},"requested": {"amount": 10000,"vat_included": false},"category": "audiobook","vat_rate": 5,"country": {"code": "DE","name": "Germany","local_name": "Germany","member_state": true}}
{"success": true,"pagination": {"has_more": true,"total_count": 10},"prices": [{"id": "ab123ba","amount": {"total_excl_vat": 10000,"total_incl_vat": 10500,"vat_amount": 500},"requested": {"amount": 10000,"vat_included": false},"category": "audiobook","vat_rate": 5,"country": {"code": "DE","name": "Germany","local_name": "Germany","member_state": true}},// ...]}