border.bot
Esc
  • Loading…
↑ ↓ to move↵ to openEsc to close
Docs menu

API reference

Every border.bot REST endpoint for HS code classification, landed cost, origin and compliance, with parameters, responses and curl examples.

Base URL https://api.border.bot, version 1.14.0. Machine-readable: OpenAPI 3.1. Try requests in the interactive reference, or import every endpoint into Postman: download the Postman collection (set clientId and clientSecret from an API client, and Postman fetches the token).

Classify products to HS/HTS codes and calculate duties, taxes, fees and landed cost for cross-border parcels.

Versions: This is v1, the current version. Within a version, changes are only additive (new endpoints, new optional fields, new enum values). Breaking changes ship as a new version; every version and its dates: https://api.border.bot/versions

Authentication: create an API client in the dashboard (Developers → API clients) and keep its client id and secret on your server. Trade them for an access token with POST https://api.border.bot/oauth2/token (form fields grant_type=client_credentials, client_id, client_secret); the token lasts expires_in seconds (an hour). Send it as Authorization: Bearer <access_token>, and fetch a new one shortly before it expires or after a 401.

Credits: billable requests use prepaid credits (see GET /v1/pricing). Prices are set server-side; failed requests are refunded automatically. Every response includes X-Request-Id (a UUID; quote it to support) and API-Version; billable responses include X-Credits-Charged and X-Credits-Remaining.

Retries: send an Idempotency-Key header on POST requests; repeating it returns the original result without charging again.

Rate limits: 120 requests per 60 seconds per API client, and per IP address for public endpoints. Responses carry the IETF RateLimit-Policy header ("key";q=120;w=60 with a client, "ip";q=120;w=60 without). Over the limit you get 429 rate_limited with RateLimit: "key";r=0;t=60 and Retry-After in seconds; wait that long before retrying.

Errors: { "error": { "code", "message", "details"? } } with a stable code (e.g. 402 insufficient_credits, 429 rate_limited).

MCP: use border.bot from Claude, ChatGPT, Codex, Cursor, VS Code and other MCP clients at https://mcp.border.bot/mcp (OAuth, no API client). Setup guides: https://border.bot/mcp

Classification#

HS/HTS codes.

Landed cost#

Duties, taxes and fees.

Products#

Product pages and country of origin.

Compliance#

Restricted goods, agency filings and agency product codes.

Account#

Your workspace, credits and usage.

Reference#

Public reference data (no key needed).

Origin#

Shipping documents#

Bulk#

Catalogue#