{"uid":"cap_e1MEhSzj6yoaQLy60_WxU","slug":"un-comtrade-preview-trade-data-api-df804a4f","name":"UN Comtrade Preview Trade Data API","description":"UN Comtrade public preview trade data (keyless). POST {reporterCode,period,partnerCode,cmdCode,flowCode} (+ optional typeCode/freqCode/clCode/maxRecords). Unpaid empty → 402; after settle empty/invalid → 400 charged:false. New trade vertical; no catalog adjacency.","url":"https://x402-v2-mint-un-comtrade-preview.vercel.app/v1/un-comtrade-preview?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"clCode":{"type":"string","maxLength":8},"period":{"type":["string","integer"]},"cmdCode":{"type":"string","maxLength":32},"flowCode":{"type":"string","maxLength":8},"freqCode":{"type":"string","maxLength":8},"typeCode":{"type":"string","maxLength":8},"maxRecords":{"type":["integer","string"]},"request_id":{"type":"string"},"partnerCode":{"type":["string","integer"]},"reporterCode":{"type":["string","integer"]}}},"responseSchema":{"type":"json","example":{"ok":true,"skill":"un-comtrade-preview","charged":true,"summary":"ok"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02015","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.02015/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02015","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02015","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_H0Ei_G4-_WHOwvpiyTVgJ","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02015","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Fetches UN Comtrade international trade statistics (imports/exports) by reporter, partner, commodity, and period via a pay-per-call x402 endpoint.","exampleAgentPrompt":"Pull UN Comtrade trade data for reporter country 842 (USA) importing commodity 0901 (coffee) from partner 076 (Brazil) for period 2023, using monthly frequency.","exampleUseCases":[{"title":"Bilateral export analysis by commodity","prompt":"Get me UN Comtrade data showing Germany's exports of automotive parts (HS code 8708) to the United States for 2022 — use annual frequency and reporter code 276, partner 842."},{"title":"Import monitoring for policy research","prompt":"I need the UN Comtrade import figures for China (reporter 156) buying crude oil (commodity code 2709) from Saudi Arabia (partner 682) for the year 2023."},{"title":"Trade balance research across commodities","prompt":"Fetch UN Comtrade data for Japan (reporter 392) exporting electronics — commodity code 8542 — to South Korea (partner 410) for period 2022, limit to 50 records."}],"resultDescription":"Returns a JSON object with ok (boolean), skill name, charged (boolean indicating whether the payment settled and data was returned), and a summary field. On success, trade flow records matching the query parameters are included. A 402 is returned if payment hasn't been made; a 400 with charged:false is returned if parameters are invalid post-payment.","failureModes":["402 Unpaid: request made without valid x402 payment — no data returned","400 with charged:false: payment settled but query parameters were empty or invalid","Invalid reporterCode or partnerCode returns no matching records","Unsupported cmdCode or flowCode values result in empty result sets","Period format mismatch (e.g. wrong year/month format) may yield empty data"],"whenToPreferThis":"Choose this endpoint when you need keyless (no UN Comtrade API key required), pay-per-call access to UN Comtrade international trade statistics. Ideal for agents that need occasional trade flow lookups without managing API credentials. Best when querying specific reporter-partner-commodity-period combinations rather than bulk downloads.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-18T00:52:03.208Z","isFirstParty":false,"canonicalSlug":"un-comtrade-preview-trade-data-api-df804a4f"}