Skip to content
//UN Comtrade Trade Data Scraper example\\

Japan coffee imports from three origins, monthly

Japan's monthly imports of green coffee (HS 090111) from Brazil, Viet Nam and Colombia in 2024.

Updated November 13, 2026

What this example returns

The dataset’s “Trade records” view shows 13 columns: Reporter, Partner, Flow, Period, HS code, Product, Value (USD), Net weight (kg), Quantity, Unit, Level, Parent HS code, and Source. See every output field.

What each setting does

The input this example runs UN Comtrade Trade Data Scraper with. “Try this input” opens it in the console, where you can run it as-is or change any field first.

Reporting countries reporters

Japan

Countries whose customs statistics to read: a name (Indonesia), an ISO code (IDN) or a UN M49 code (360). Each country is read on its own. Exports are what this country reports sending abroad; imports what it reports receiving.

HS codes hsCodes

090111

Products as Harmonized System codes: 2 digits (chapter, e.g. 08 fruit and nuts), 4 digits (heading, e.g. 0810 other fresh fruit) or 6 digits (subheading, e.g. 081090). TOTAL = all goods. A national tariff line of 8 or more digits (e.g. Indonesia's 08109091, salak) reads that line from the country's tariff-line data.

Trade flow flows

M

Which direction of trade to read. Choose several to get them in one run.

Default: X → this example uses M

Year from yearFrom

2024

First year to read. Empty = five years back.

Year to yearTo

2024

Last year to read. Empty = the current year.

Annual or monthly figures frequency

Monthly

Annual: one row per year. Monthly: one row per month (countries publish monthly figures sooner than annual ones).

Default: Annual → this example uses Monthly

Partner countries partners

Brazil, Viet Nam, Colombia

Only these destination or origin countries (names, ISO codes or M49 codes). Empty = every partner country.

Include the World total row includeWorld

No

Also save the partner 'World' row: the country's total for the product across all partners.

Default: Yes → this example uses No

.json
{
  "reporters": [
    "Japan"
  ],
  "hsCodes": [
    "090111"
  ],
  "flows": [
    "M"
  ],
  "yearFrom": 2024,
  "yearTo": 2024,
  "frequency": "monthly",
  "partners": [
    "Brazil",
    "Viet Nam",
    "Colombia"
  ],
  "includeWorld": false
}

What it costs

You pay for the events the actor reports, such as each result or page it produces. Platform usage is included in the event prices: compute, proxies, browser and storage cost nothing extra.

  • Trade record$0.0017One saved trade row: one reporting country, partner, flow, period and product code with value, net weight and quantity.

Full pricing

Other ways to run UN Comtrade Trade Data Scraper

All examples of UN Comtrade Trade Data Scraper

About UN Comtrade Trade Data Scraper

Export and import statistics from UN Comtrade by reporting country, partner country, HS code and year or month: trade value in US dollars, net weight in kg, quantity, HS subheadings and national tariff lines. No login or key needed.

Price:
$1.70 / 1,000 results
Developer:
Querystone
Category:
Business

UN Comtrade Trade Data Scraper pageOutput fieldsPricing

Related actors

//From the blog\\

Latest articles

All articles

The internet is full of data.
Start owning yours.

Scrape.ly gives you the infrastructure, the tooling, and the team to extract, process, and operationalize web data at any scale. Setup takes minutes.

No credit card. No setup calls.