To integrate OMP tax rate API:
Lovat API uses the REST architecture. The API has predictable, resource-oriented URLs and uses HTTP response codes to indicate API errors. The API always responds in the JSON format, including cases of errors.
Authentication to the OMP API is performed via HTTP header basic authentication. Subscribers need to provide a token as the basic authentication value. If you’re new to Lovat, you’ll need to sign up for an account to get your API key. The API uses built-in HTTP features such as HTTP authentication and HTTP verbs, which can be interpreted by off-the-shelf HTTP clients. It also supports cross-origin resource sharing, allowing you to access it securely from a client web application.
Lovat API uses the following endpoint paths:
https://omp.vatcompliance.co/api/omp — OMP Feed API, OMP Tax rate API
sandbox.vatcompliance.co/api/omp
We recommend storing all merchant business location addresses in your system to pass in when calculating tax.
In addition to helping you calculate VAT for your merchants, we also make it very easy to help them file and remit their sales tax to the Tax authorities. Lovat’s transaction endpoints allow you to send completed order information to a merchant’s Lovat account. Simply include the merchant’s Lovat API token when posting, and those orders will show up in the merchant’s account with a return-ready report breaking out tax owed by jurisdiction. Merchants who choose to use Lovat will simply pay us based on the number of transactions we’re processing for them on a monthly basis.
The request type: POST
https://omp.vatcompliance.co/api/omp/tax_rate/{access_token}
JSON Params
Parameter |
Type |
Description |
Required |
merchant_id |
String |
Unique identifier of the merchant |
Required |
merchant_establishment_country_id |
String |
Merchant establishment country. Three-letter uppercase country code per ISO 3166-1 alpha-3 |
– |
merchant_vat_numbers |
– |
Tax number of merchant |
– |
transaction_id |
String |
Maximum 255 characters. |
True |
currency
|
String
|
Transaction currency. Three-letter currency code per ISO 4217. |
True |
transaction_datetime |
– |
Date and time of the transaction in accordance with ISO 8601 GMT |
Required |
transaction_sum |
Float |
Total amount of the order, excluding shipping |
Required |
delivery_fee |
Float |
Total amount of shipping for the order |
Required |
arrival_country
|
String
|
A country where the order shipped to. Three-letter uppercase country code per ISO 3166-1 alpha-3 |
Required |
arrival_zip |
String |
Required for US orders: Postal code where the order shipped to |
Optional |
arrival_state |
– |
For US, Canada, UK: Two-letter ISO state code where the order shipped to |
Optional |
departure_country |
String |
Three-letter ISO country code of the country where the order shipped from. All countries are specified as strings according to ISO 3166- 1 alpha-3 |
Required |
departure_zip |
String |
For US orders: Postal code where the order shipped from |
Optional |
departure_state |
String |
For US, Canada: Two-letter ISO state code where the order shipped from |
– |
service_code |
String |
Required for digitally supplied services. Tax categories of digital services |
Optional |
good_code |
String |
code of a good according to EU’s eight-digit coding system The Combined Nomenclature (CN) |
Optional |
vat_number_of_buyer |
String |
Tax number of buyer |
– |
buyer_name |
String |
|
Optional |
exemption_type |
String |
For US orders only |
Optional |
nexus_state |
String |
Merchant nexus states. Two-letter ISO state code where the merchant has nexus |
Optional |
sent over HTTPS,
use TLS 1.2 or higher, contain authentication parameters,
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' -d '{ "transaction_id": "ttt4565-85546", "merchant_id": "678345101", "merchant_establishment_country_id": "DEU", "merchant_VAT_numbers": "DE9875234", "transaction_datetime": "2022-01-09T08:27:22 +00:00", "transaction_sum": 43.04, "delivery_fee": 2.3, "currency": "EUR", "arrival_country" : "LVA", "good_code": "62160000", "departure_country" : "AUS", }' 'https://omp.vatcompliance.co/api/omp/tax_rate/6cec387781a94425b401206d1710801a { "transaction_id": "0099990100", "merchant_id": "678345101", "merchant_VAT_numbers": "GB9875234", "transaction_datetime": "2022-01-09T08:27:22 +00:00", "transaction_sum": 120.50, "delivery_fee": 2.3, "currency": "GBP", "arrival_country" : "DEU", "good_code": "62160000", "departure_country" : "GBR", }
List of supported HTTP errors:
200, 201, 204
No error
400 Bad Request
This often indicates a required parameter missing. Refer to the response body for details
401 Unauthorized
No valid API key provided
402 Request Failed
Request failed despite valid parameters
403 Forbidden
No permission. Refer to the response body for details
404 Not Found
The requested item doesn’t exist
409, 422
Invalid request parameters
412 Precondition Failed
The project has not been activated yet (used in the Get Token method)
415 Unsupported Media Type
‘Content-Type: application/json’ missing in HTTP header
500, 502, 503, 504 Server Errors
Something went wrong
All dates are specified as strings according to ISO 8601. You can specify date strings either in UTC (e.g., 2013-01-15T00:00:00Z), or indicating the UTC offset (e.g., 2013-01-15T00:00:00-08:00 for eight hours behind UTC). In the latter case, make sure to take into account the daylight saving time, if applicable.
We support the following countries around the world:
The US, EU countries, UK, Russia, Ukraine, Belarus, Norway, Canada, Australia, Japan.
Audio/visual content |
1 |
Live streaming |
2 |
Telephone services |
3 |
Internet telephone services |
4 |
Call management services |
5 |
Paging services |
6 |
Internet access |
7 |
Images |
8 |
Music |
9 |
Games |
10 |
E-newspapers |
11 |
Web hosting |
12 |
Distance maintenance of programmes |
13 |
Advertising space on a website |
14 |
E-books |
15 |
Licenses |
16 |
Dating |
17 |
Distance education |
18 |
Gambling |
19 |
We limit API requests to 1,000 per minute for OMP plans. Our Advanced and Enterprise plans include an increased limit of 5,000 per minute. You may have more calls than your monthly plan limit. Overage fees are charged separately if you exceed your plan limit during a next month.
For the US orders only types of exemption: wholesale, government, marketplace, other, non_exempt, or nill.