> ## Documentation Index
> Fetch the complete documentation index at: https://traddal.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Block a code

> Exclude an HS code from your classification results.

Requires the `classify:read` scope.

<ParamField body="hs_code" type="string" required>
  The code to block (2–13 chars, digits and dots; dots are stripped on
  storage).
</ParamField>

<ParamField body="destination_country" type="string" required>
  ISO alpha-2 destination the block applies to (or `GLOBAL`).
</ParamField>

<ParamField body="reason" type="string">
  Why the code is blocked (up to 1000 chars) — shown in the dashboard.
</ParamField>

<ResponseField name="entry" type="object | null">
  The created entry (`id`, `hs_code`, `country_code`, `reason`,
  `created_at`), or `null` when the code was already blocked.
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://{partner}.mytraddal.com/admin/api/v1/classify/blocklist \
    -H 'Content-Type: application/json' \
    -H 'Authorization: Bearer {access_token}' \
    -d '{
      "hs_code": "4202.92.3131",
      "destination_country": "US",
      "reason": "Ruled out by our broker"
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json 201 theme={null}
  {
    "success": true,
    "message": "Code blocked",
    "entry": {
      "id": 41,
      "hs_code": "4202923131",
      "country_code": "US",
      "reason": "Ruled out by our broker",
      "created_at": "2026-07-30T10:15:02.000Z"
    }
  }
  ```
</ResponseExample>
