---
title: "Applied tariff rates at HS 6-digit (UNCTAD TRAINS)"
method: GET
path: "/api/v1/wits/tariffs/hs6"
tags: ["Global Economy & Trade"]
---

# Applied tariff rates at HS 6-digit (UNCTAD TRAINS)

`GET /api/v1/wits/tariffs/hs6`

Preferential and Most-Favoured-Nation applied tariffs at HS 6-digit granularity from the UNCTAD TRAINS database redistributed by WITS. Returns applied rate, MFN/preferential split, min/max/average rates, nomenclature revision (H0-H5), and tariff line counts. Reporter + year + product are the minimum required parameters; the upstream rejects broad queries with HTTP 413. Country inputs accept either ISO3 alpha (USA) or M49 numeric (840); internal translation to M49 is performed automatically.

## Query parameters

- `reporter` string, required — Reporter country. ISO3 alpha or M49 numeric (e.g. `USA` or `840`).
- `year` integer, required — Observation year. TRAINS annual, typical lag 1-2 years.
- `product` string — HS 6-digit product code (digit string, e.g. `020110` for bovine carcasses) or `all` with narrow country/year.
- `partner` string — Partner country. M49 numeric, ISO3 alpha, or `000` / `WLD` for World aggregate.
- `datatype` string — Tariff data type: `reported` (published) or `aveestimated` (ad-valorem-equivalent estimated).

## Response `200`

TRAINS tariff observations at HS 6-digit with per-line breakdown.

- EnvelopeWitsTariffsHs6Payload
  - `data` WitsTariffsHs6Payload, required — TRAINS HS 6-digit tariff query result.
    - `reporter` string, required — Reporter code as supplied (normalised to M49 numeric internally).
    - `partner` string, required — Partner code (default `000` / World).
    - `product` string, required — HS 6-digit product code or `all`.
    - `year` string, required — Year supplied.
    - `datatype` string, required — Tariff data type requested (`reported` or `aveestimated`).
    - `count` integer, required — Number of observations returned.
    - `rows` WitsTariffRow[], required — Flat observation records.
      - `FREQ` string, nullable — SDMX frequency code (A = annual).
      - `REPORTER` string, nullable — Reporter country code (M49 numeric for TRAINS, ISO3 alpha for TradeStats).
      - `REPORTER_name` string, nullable — Reporter country name as published by WITS.
      - `PARTNER` string, nullable — Partner country code (`000`/`WLD` = World aggregate).
      - `PARTNER_name` string, nullable — Partner country name.
      - `PRODUCTCODE` string, nullable — HS 6-digit product code (TRAINS) or sector group like `Fuels` / `01-05_Animal` (TradeStats).
      - `PRODUCTCODE_name` string, nullable — Product name or sector label.
      - `DATATYPE` string, nullable — TRAINS data type: `Reported` (published) or `AveEstimated` (AVE estimated).
      - `DATATYPE_name` string, nullable — Readable data type description.
      - `INDICATOR` string, nullable — TradeStats-Tariff indicator code (e.g. `MFN-SMPL-AVRG`).
      - `INDICATOR_name` string, nullable — TradeStats-Tariff indicator name.
      - `TIME_PERIOD` string, nullable — Observation year (SDMX TIME_PERIOD).
      - `time_start` string, nullable — Observation start as returned by WITS (`YYYY-MM-DDTHH:MM:SS`).
      - `value` union — Numeric observation value. Tariff rate (%), trade value ($K), or indicator value.
        - number
        - string
      - `NOMENCODE` string, nullable — TRAINS nomenclature revision (H0-H5 for HS; S2 for SITC Rev 2).
      - `TARIFFTYPE` string, nullable — TRAINS tariff type: MFN or PREF (preferential).
      - `SUM_OF_RATES` string, nullable — TRAINS sum of tariff rates within the observation.
      - `MIN_RATE` string, nullable — TRAINS minimum tariff rate observed.
      - `MAX_RATE` string, nullable — TRAINS maximum tariff rate observed.
      - `TOTALNOOFLINES` string, nullable — TRAINS total number of tariff lines in scope.
      - `NBR_PREF_LINES` string, nullable — TRAINS number of preferential tariff lines.
      - `NBR_MFN_LINES` string, nullable — TRAINS number of MFN tariff lines.
      - `NBR_NA_LINES` string, nullable — TRAINS number of not-applicable tariff lines.
      - `OBS_VALUE_MEASURE` string, nullable — TRAINS value measure (e.g. `SimpleAverage`, `WeightedAverage`).
      - `DATASOURCE` string, nullable — Custodian datasource tag (e.g. `WITS-TRN`, `WITS-CMT`).
  - `meta` SugraMeta, required — Metadata attached to every /api/v1/* response envelope.
    - `endpoint` string, required — Requested endpoint path.
    - `data_time` string, required — ISO 8601 UTC timestamp of the source data, not of the request.
    - `response_time` string, required — ISO 8601 UTC timestamp when this response was produced.
    - `provider` string, required — API name and version.
    - `source` string, nullable — Identifier of the primary upstream source used for this response.
    - `attribution` string, nullable — Human-readable attribution mandated by an upstream source (e.g. a securities regulator or self-regulatory organization). Present only on responses whose source requires the owner and source to be clearly identified. Do not remove or alter it when using the response.
    - `fallback_used` boolean, nullable — True when the primary source failed and a fallback produced the data.
    - `fallback_chain` string[], nullable — Ordered list of sources attempted, in the order they were tried.
    - `cached` boolean, nullable — True when this response was served from the internal cache.
    - `stale` boolean, nullable — True when the cached response was returned after the upstream rate-limited or errored. Clients can use this to detect degraded data.

## Other responses

- `401` — Missing or invalid `x-api-key` header.
- `422` — Validation Error
- `429` — Daily rate limit exceeded. Check `X-RateLimit-Reset` for the next window.
- `503` — Upstream source is temporarily unavailable. Retry after a short delay.

---

[API](https://skmtc.net/sugra/apis/sugra-api.md) · [All operations](https://skmtc.net/sugra/apis/sugra-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/sugra/sugra-api/versions/4e2740743eb4/schema)
