UN Comtrade API for international bilateral trade data
Server has 4 tools with complete schemas and descriptions. Naming follows verb_noun pattern (get_*, comtrade_*). Descriptions are adequate (100-200 chars) but lack WHEN/WHY guidance. Parameters have types and descriptions, but lack enums for constrained values (flow, hs_code). No output schema documented. Error handling is minimal, API errors are caught but not actionable for LLM recovery. Missing idempotency hints and rate-limit guidance.
Get a reference list of common country ISO numeric codes used in UN Comtrade queries. No API call needed.
Get top traded commodities between two countries by trade value. Shows which product categories dominate bilateral trade.
Get top trading partners for a country by trade value. Useful for understanding a country's main trade relationships.
Get bilateral trade data between two countries from the UN Comtrade database. Returns trade value, quantity, partner, and commodity description for imports and/or exports.
No output schema documented. LLMs cannot predict response structure (fields, types, pagination). Clients must infer from examples or trial-and-error.
Parameter 'flow' accepts free-form strings ('M', 'X', 'M,X') without enum constraint. LLMs may hallucinate invalid values like 'import', 'export', 'both'.
Parameter 'hs_code' lacks format/pattern constraint. Description says '2/4/6 digit level' but no regex or length bounds enforced. LLMs may pass invalid codes.
Error handling returns raw API errors ('UN Comtrade API error: ...') without recovery guidance. LLM cannot determine if error is retryable, user-fixable, or fatal.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | D | 58 | 2026-07-28+ | v2 |
No pagination support visible. If results exceed API limit, LLM receives truncated data with no way to fetch next page. Large result sets risk context window exhaustion.