[UPDATE] API with new endpoints

Hi,

We’ve updated the API documentation to include a number of new endpoints:

  1. GeographicalAreas
    For listing the country and country groups used by the tariff, which will be needed after EU Exit.

  2. SearchReferences
    The data behind the A-Z browsing on the trade tariff.

  3. Added more data in the commodity code response, so that the duty expression is exposed by each component part (previously it was one string) so that the values can be extracted.

  4. Clarified that the search quota filters for status use underscore no spaces.

Let me know if you have any issues or need more data in the TARIFF API for your use case.

Many thanks,

Matthew Ford
Technical Director @ Bit Zesty

Hi Matt
Thanks for this, it should be really great.

https://www.trade-tariff.service.gov.uk/api/v2/commodities/0207141000 is a complex commodity.

Could you please clarify what “duty_expression_abbreviation” means please? The duty is 102.4 EUR per 100kg. It’s not a percentage. So I am confused by this:

{
“id”: “2049690-01”,
“type”: “measure_component”,
“attributes”: {
“duty_expression_id”: “01”,
“duty_amount”: 102.4,
“monetary_unit_code”: “EUR”,
“monetary_unit_abbreviation”: null,
“measurement_unit_code”: “DTN”,
“duty_expression_description”: “% or amount”,
"duty_expression_abbreviation": "%"
}

Also, I cannot find a computer-readable node that breaks down the additional duty that is expressed as subtracting 30% of the CIF price. For example, the human-readable expression is “90.045 EUR / 100 kg - 30.00 %” which you return as
<span title='90.045 EUR'>90.045</span> EUR / <abbr title='Hectokilogram'>100 kg</abbr> - <span title='30.0 '>30.00</span> %

But where is the breakdown so that we can see 90.045 and 30.00 in their own fields please?

Thanks

Hi Daniel,

Unfortunately, the TARIC schema overloads the IDs of duty expressions, in order to determine the ID 01 could be an amount or a % and this is only determined by the presence of a monetary unit. The abbreviation is the duty_expression_description in its abbreviated form, however, as I mentioned above in this particular case it’s not used as there is a currency value present.

The code we use to generate the description is here: https://github.com/bitzesty/trade-tariff-backend/blob/master/app/formatters/duty_expression_formatter.rb#L39-L103 which might help with how the description is built, up.

Each measure can have many components, and each one would have a duty expression, to get the full description you need to concatenate all the components.

Let me know if you have any other questions.