Skip to main content
GET
/
hts
/
{code}
Get HTS Code by Code
curl --request GET \
  --url https://htsapi.com/v1/hts/{code} \
  --header 'Authorization: Bearer <token>'
{
  "data": {
    "id": 123,
    "description": "<string>",
    "code": "<string>",
    "normalized_code": "<string>",
    "indent": 123,
    "chapter": "<string>",
    "heading": "<string>",
    "subheading": "<string>",
    "rates": {
      "general": "<string>",
      "special": "<string>",
      "other": "<string>"
    },
    "units": [
      "<string>"
    ],
    "footnotes": [
      {
        "marker": "<string>",
        "value": "<string>"
      }
    ],
    "hierarchy": [
      {
        "code": "<string>",
        "description": "<string>"
      }
    ],
    "children": [
      {
        "id": 123,
        "description": "<string>",
        "code": "<string>",
        "normalized_code": "<string>",
        "indent": 123,
        "chapter": "<string>",
        "heading": "<string>",
        "subheading": "<string>",
        "rates": {
          "general": "<string>",
          "special": "<string>",
          "other": "<string>"
        },
        "units": [
          "<string>"
        ],
        "footnotes": [
          {
            "marker": "<string>",
            "value": "<string>"
          }
        ]
      }
    ]
  }
}
Get a single HTS code with its full hierarchy and children. This endpoint is useful for exploring the code structure and understanding parent-child relationships.

Parameters

ParameterTypeRequiredDescription
codestringYesThe HTS code (e.g., ‘8517.12.00.50’)

Example Request

curl -X GET "https://htsapi.com/v1/hts/8517.12.00.50" \
  -H "Authorization: Bearer hts_your_api_key"

Example Response

{
  "data": {
    "id": 12345,
    "code": "8517.12.00.50",
    "normalized_code": "8517120050",
    "description": "Telephone sets, including telephones for cellular networks or for other wireless networks",
    "indent": 3,
    "chapter": "85",
    "heading": "8517",
    "subheading": "851712",
    "rates": {
      "general": "Free",
      "special": "Free (A+,AU,BH,CA...)",
      "other": "Free"
    },
    "units": ["No."],
    "footnotes": [],
    "hierarchy": [
      {
        "code": "85",
        "description": "Electrical machinery and equipment and parts thereof"
      },
      {
        "code": "8517",
        "description": "Telephone sets, including telephones for cellular networks or for other wireless networks"
      }
    ],
    "children": []
  }
}

Response Fields

  • hierarchy: Array of parent codes in order from chapter to immediate parent
  • children: Array of child codes (if any exist)
  • units: Measurement units for the code
  • footnotes: Footnotes and additional information

Use Cases

  • Explore code structure and relationships
  • Build hierarchical navigation UIs
  • Understand code context within the classification system
  • Get complete code details including rates and units

Authorizations

Authorization
string
header
required

API key as Bearer token. Format: Bearer hts_your_api_key

Path Parameters

code
string
required

The HTS code (e.g., '8517.12.00.50')

Response

HTS Code detail with hierarchy

data
object