Sovereign Customs Feeds: GACC (CN) · U.S. Census (US) · Eurostat (EU) + Modular Global Economy Ingestion
GlobalTradeData.org
Open Data Center · RESTful JSON API v1.0

Open Data API & Programmatic Integration Hub

The GlobalTradeData (GTD) Open Data Initiative provides standardized RESTful JSON endpoints for universities, quantitative research models, and macroeconomic analytics applications worldwide.

1. Standard RESTful JSON Endpoints

Parameters year and month are optional: they default to the latest period published by the requested reporter, which can differ (China 2026-09, United States 2026-08, European Union 2026-07). An unknown reporter returns HTTP 400.

Returns latest export, import, and trade balance aggregates across the Triad economies (CN, US, EU) alongside publication timestamps.

Query multidimensional export leaderboards. Supported query parameters: board (SCALE/GAINER/SURPLUS), scope (COMMODITY/PARTNER/SUBNATIONAL/GATEWAY), reporter (CN/US/EU/GLOBAL), year, and month.

GET /api/v1/industries/{slug}

Retrieve one reviewed industry topic: the published source line, its full monthly export value, quantity and estimated unit value series, and the stated measurement boundary.

GET /api/v1/partner/{iso2}

Retrieve bilateral foreign trade timeline, monthly outbound exports (FOB), inbound imports (CIF), and net balance time series.

Query export price indices (EPI), volume indices (EQI), and net barter terms of trade (TOT) series across reporting economies (CN, EU).

Python Client Example (Requests Snippet) Zero-Auth Open API
import requests

# 1. Fetch Top 10 China Export Commodities by Value
url = "https://globaltradedata.org/api/v1/rankings"
params = {
    "board": "SCALE",
    "scope": "COMMODITY",
    "reporter": "CN",
    "limit": 10
}
resp = requests.get(url, params=params)
data = resp.json()

for item in data['data']:
    print(f"#{item['rank_position']} {item['item_name_en']}: ${item['value_usd']:,.0f} USD (YoY: {item['yoy_growth']}%)")

China Data Endpoints

Beyond the rankings and partner feeds, the China data centre exposes its charts as JSON endpoints. Parameters are shown in the query string.

EndpointReturnsKey parameters
/api/v1/china/commodity-dataCommodity rows by tabtab=major|hs|sitc, year, month
/api/v1/china/commodity-timeseriesMonthly value/quantity seriescommodity = table 13/14 source name (e.g. 集成电路)
/api/v1/china/commodity-hs-timelineHS chapter timelinecommodity, year, month
/api/v1/china/commodity-sitc-timelineSITC timelinecommodity, year, month
/api/v1/china/commodity-modes-timelineCommodity x trade modecode = MODE_…, flow
/api/v1/china/partner-topTop partnerslimit, year, month
/api/v1/china/partner-timelinePartner timelinecodes (comma list, max 10), start, end

Full list: the routes above are backed by the same warehouse facts shown on the China pages.

Version & Attribution

API version: v1 (paths are stable; additive fields may appear).

Attribution: when you publish figures, cite GlobalTradeData and the original agency: GACC (China), U.S. Census Bureau (United States), Eurostat Comext (European Union). Do not present derived shares as official statistics.

2. Real-Time Query Architecture & Fair Use

GTD serves live aggregated metrics directly from our high-performance relational warehouse. Programmatic queries are subject to zero authentication and provide immediate JSON responses.

Response Protocol Strict RFC 8259 JSON UTF-8
application/json
Access No key required; no fixed quota is enforced
HTTP 200