# OEC Economic Complexity Trade Scraper (`parseforge/oec-economic-complexity-trade-scraper`) Actor

Scrape Observatory of Economic Complexity (OEC) bilateral trade flows: country, partner, product (HS code), year, export value, import value, and economic complexity index. Export international trade data to JSON, CSV, or Excel for economics research, supply chain, and market intel.

- **URL**: https://apify.com/parseforge/oec-economic-complexity-trade-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $22.00 / 1,000 result items

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

![ParseForge Banner](https://github.com/ParseForge/apify-assets/blob/ad35ccc13ddd068b9d6cba33f323962e39aed5b2/banner.jpg?raw=true)

## 📊 OEC Economic Complexity Trade Scraper

> 🚀 **Export international trade flows in seconds.** Pull bilateral trade data for **231 countries**, **5,000+ HS6 products**, across **1995-2024**, sourced from the Observatory of Economic Complexity (OEC) at MIT.

> 🕒 **Last updated:** 2026-05-23 · **📊 13 fields** per record · **🌍 231 countries** · **🛍️ 5,000+ HS6 products** · **📆 1995-2024 (BACI), 1962-2022 (SITC)**

The **OEC Economic Complexity Trade Scraper** queries the OEC public trade catalog (BACI HS6 and SITC4 product classifications) and returns **13 fields per record**, including reporter and partner country names and IDs, year, product ID, product name, product breakdown level, raw and formatted trade value in USD, cube name, and dataset annotation. The OEC is one of the most cited open trade-data references in academic and policy research.

The catalog covers **231 countries**, **5,000+ HS6 products** (Harmonized System 6-digit), the historical SITC4 classification back to 1962, and bilateral flows for any country pair. Trade values run from 1995 to 2024 under BACI HS6, with SITC available 1962 to 2022.

| 🎯 Target Audience | 💡 Primary Use Cases |
|---|---|
| Trade economists, supply-chain analysts, policy researchers, commodity traders, ESG analysts, journalists, sanctions compliance teams, M&A research | Bilateral flow analysis, supply-chain risk, comparative advantage models, sanctions impact, ESG product-origin audits, journalism investigations |

---

### 📋 What the OEC Economic Complexity Trade Scraper does

Five workflows in a single run:

- 🌍 **Country totals.** Pull total exports for one reporter country in one year. Set `productLevel: "none"`.
- 🤝 **Bilateral flows.** Specify both `reporter` and `partner` to get country-to-country trade values.
- 🛍️ **Product breakdown.** Switch `productLevel` to `hs4`, `hs6`, or `sitc4` to decompose flows by product.
- 🔍 **HS code filter.** Add a numeric HS4 or HS6 code (e.g. `8542` for integrated circuits) to scope to one product family.
- 📆 **Year selector.** Any year from 1995 to 2024 (BACI HS6) or 1962 to 2022 (SITC).

Each record carries the year, the canonical OEC country IDs and human names for both reporter and partner, the product ID and name, the breakdown level, the raw trade value in USD, a formatted display value, the cube name, and the OEC dataset annotation.

> 💡 **Why it matters:** international trade data is fragmented across UN Comtrade, BACI, ITC Trade Map, and national customs feeds. Each has its own format, codes, and refresh cycle. The OEC unifies the most-cited dataset into a single queryable surface, and this Actor exports it as ready-to-load CSV, Excel, or JSON without writing a single parser.

---

### 🎬 Full Demo

_🚧 Coming soon: a 3-minute walkthrough showing how to pull every U.S. integrated-circuit import in 2022 by partner country._

---

### ⚙️ Input

<table>
<thead>
<tr><th>Input</th><th>Type</th><th>Default</th><th>Behavior</th></tr>
</thead>
<tbody>
<tr><td>maxItems</td><td>integer</td><td>10</td><td>Records to return. Free plan caps at 10, paid plan at 1,000,000.</td></tr>
<tr><td>year</td><td>integer</td><td>2022</td><td>1995-2024 (BACI HS6) or 1962-2022 (SITC).</td></tr>
<tr><td>reporter</td><td>string</td><td>"nausa"</td><td>OEC country slug (e.g. nausa = United States, aschn = China).</td></tr>
<tr><td>partner</td><td>string</td><td>""</td><td>Optional partner country slug for bilateral flows.</td></tr>
<tr><td>productLevel</td><td>string</td><td>"none"</td><td>none, hs4, hs6, or sitc4.</td></tr>
<tr><td>hsCode</td><td>string</td><td>""</td><td>Optional numeric HS4 or HS6 code (e.g. 8542).</td></tr>
</tbody>
</table>

**Example: U.S. integrated-circuit imports from Taiwan in 2022, HS6 breakdown.**

```json
{
    "maxItems": 100,
    "year": 2022,
    "reporter": "astwn",
    "partner": "nausa",
    "productLevel": "hs6",
    "hsCode": "8542"
}
````

**Example: total Chinese exports for 2023.**

```json
{
    "maxItems": 1,
    "year": 2023,
    "reporter": "aschn",
    "productLevel": "none"
}
```

> ⚠️ **Good to Know:** trade values are reported in current USD as recorded in the underlying BACI or SITC dataset. The OEC harmonizes UN Comtrade source data, so values for the most recent year may be subject to revision as customs reports are finalized.

***

### 📊 Output

Each record contains **13 fields**. Download the dataset as CSV, Excel, JSON, or XML.

#### 🧾 Schema

| Field | Type | Example |
|---|---|---|
| 📆 `year` | number | `2022` |
| 🆔 `reporterId` | string | `"nausa"` |
| 🌍 `reporter` | string | `"United States"` |
| 🆔 `partnerId` | string | null | `"aschn"` |
| 🌐 `partner` | string | null | `"China"` |
| 🆔 `productId` | string | null | `"854231"` |
| 🛍️ `productName` | string | null | `"Processors and controllers"` |
| 📐 `productLevel` | string | `"hs6"` |
| 💵 `tradeValueUsd` | number | null | `47238159132` |
| 🏷️ `tradeValueUsdFormatted` | string | null | `"$47,238,159,132"` |
| 🧊 `cube` | string | `"trade_i_baci_a_92"` |
| 📚 `datasetName` | string | null | `"BACI HS6 (a.k.a. CEPII)"` |
| 🕒 `scrapedAt` | ISO 8601 | `"2026-05-23T00:00:00.000Z"` |

#### 📦 Sample records

<details>
<summary><strong>🇺🇸 U.S. total exports, 2022</strong></summary>

```json
{
    "year": 2022,
    "reporterId": "nausa",
    "reporter": "United States",
    "partnerId": null,
    "partner": null,
    "productId": null,
    "productName": null,
    "productLevel": "none",
    "tradeValueUsd": 1844892015423,
    "tradeValueUsdFormatted": "$1,844,892,015,423",
    "cube": "trade_i_baci_a_92",
    "datasetName": "BACI HS6 (a.k.a. CEPII)",
    "scrapedAt": "2026-05-23T00:00:00.000Z"
}
```

</details>

<details>
<summary><strong>🛍️ Integrated-circuit bilateral flow: Taiwan to U.S.</strong></summary>

```json
{
    "year": 2022,
    "reporterId": "astwn",
    "reporter": "Chinese Taipei",
    "partnerId": "nausa",
    "partner": "United States",
    "productId": "854231",
    "productName": "Processors and controllers",
    "productLevel": "hs6",
    "tradeValueUsd": 4729158132,
    "tradeValueUsdFormatted": "$4,729,158,132"
}
```

</details>

<details>
<summary><strong>🌍 Country totals: China exports, 2023</strong></summary>

```json
{
    "year": 2023,
    "reporterId": "aschn",
    "reporter": "China",
    "tradeValueUsd": 3380000000000,
    "tradeValueUsdFormatted": "$3,380,000,000,000",
    "productLevel": "none"
}
```

</details>

***

### ✨ Why choose this Actor

| | Capability |
|---|---|
| 🌍 | **Global coverage.** 231 reporter and partner countries with stable OEC slugs. |
| 🛍️ | **5,000+ HS6 products.** Full Harmonized System 6-digit breakdown, plus SITC4 for historical analysis. |
| 📆 | **30 years.** BACI HS6 from 1995 to 2024, SITC from 1962 to 2022. |
| 🤝 | **Bilateral or world totals.** Specify both countries for bilateral flows, or just the reporter for world exports. |
| 💵 | **USD values with formatting.** Both raw numeric and human-readable formatted string. |
| ⚡ | **Fast.** 100 trade flows in under 20 seconds. |
| 🚫 | **No authentication.** Public OEC catalog. No login or token required. |

> 📊 The trade data underneath every supply-chain strategy, sanctions analysis, and trade-policy decision should be queryable in one call, not stitched together from five sources.

***

### 📈 How it compares to alternatives

| Approach | Cost | Coverage | Refresh | Filters | Setup |
|---|---|---|---|---|---|
| **⭐ OEC Trade Scraper** *(this Actor)* | $5 free credit, then pay-per-use | **231 countries, 5k+ HS6** | **Live per run** | year, reporter, partner, product | ⚡ 2 min |
| UN Comtrade direct | Free tier limited | Same | Updated as reported | Many | 🐢 Auth, rate limits |
| ITC Trade Map | Subscription | Same | Periodic | Many | ⏳ Manual export |
| National customs CSVs | Free | One country each | Variable | None | 🕒 Days per country |

Pick this Actor when you want one harmonized trade-data surface across every country and product, without writing custom parsers per source.

***

### 🚀 How to use

1. 📝 **Sign up.** [Create a free account with $5 credit](https://console.apify.com/sign-up?fpr=vmoqkp) (takes 2 minutes).
2. 🌐 **Open the Actor.** Go to the OEC Economic Complexity Trade Scraper page on the Apify Store.
3. 🎯 **Set input.** Pick a `year`, `reporter`, optionally a `partner`, set the `productLevel`, and set `maxItems`.
4. 🚀 **Run it.** Click **Start** and let the Actor pull the trade flows.
5. 📥 **Download.** Grab your results in the **Dataset** tab as CSV, Excel, JSON, or XML.

> ⏱️ Total time from signup to a downloaded dataset: **3-5 minutes.** No coding required.

***

### 💼 Business use cases

<table>
<tr>
<td width="50%" valign="top">

#### 🚚 Supply Chain & Procurement

- Source-country concentration risk reports
- Alternate-supplier discovery by HS code
- Tariff-impact modelling on import baskets
- Lead-time and dependency dashboards

</td>
<td width="50%" valign="top">

#### 📊 Trade & Economic Analysis

- Comparative-advantage models by country
- Export-diversification scoring
- Economic-complexity rankings
- Trade-policy impact analysis

</td>
</tr>
<tr>
<td width="50%" valign="top">

#### 🛡️ Sanctions & Compliance

- Pre/post-sanctions trade-flow audits
- Product-origin verification
- Cross-border financial-flow proxies
- Russia, Iran, North Korea exposure analysis

</td>
<td width="50%" valign="top">

#### 🌱 ESG & Sustainability

- Carbon-footprint estimates by product origin
- Critical-mineral supply-chain mapping
- Deforestation-risk product audits
- Fair-trade and ethical-sourcing dashboards

</td>
</tr>
</table>

***

### 🔌 Automating OEC Trade Scraper

Control the scraper programmatically for scheduled runs and pipeline integrations:

- 🟢 **Node.js.** Install the `apify-client` NPM package.
- 🐍 **Python.** Use the `apify-client` PyPI package.
- 📚 See the [Apify API documentation](https://docs.apify.com/api/v2) for full details.

The [Apify Schedules feature](https://docs.apify.com/platform/schedules) lets you trigger this Actor on any cron interval. Annual refreshes are common for trade dashboards, with monthly pulls when partial-year data drops.

***

### 🌟 Beyond business use cases

Data like this powers more than commercial workflows. The same structured records support research, education, civic projects, and personal initiatives.

<table>
<tr>
<td width="50%">

#### 🎓 Research and academia

- International trade and development economics papers
- Reproducible datasets for political-economy research
- Coursework on globalization and comparative advantage
- Cross-country statistical learning exercises

</td>
<td width="50%">

#### 🎨 Personal and creative

- Data-visualization side projects on global trade
- Sankey diagrams of country-to-country flows
- Personal "world's most-traded product" dashboards
- Travel-blog content with country-economy context

</td>
</tr>
<tr>
<td width="50%">

#### 🤝 Non-profit and civic

- Investigative journalism on trade and sanctions
- Civic transparency around national trade dependencies
- Development-aid prioritization with trade data
- Fair-trade and ethical-sourcing campaigns

</td>
<td width="50%">

#### 🧪 Experimentation

- Train trade-flow forecasting models
- Build agent pipelines that answer trade questions
- Prototype supply-chain visualization dashboards
- Test economic-complexity hypotheses

</td>
</tr>
</table>

***

### 🤖 Ask an AI assistant about this scraper

Open a ready-to-send prompt about this ParseForge actor in the AI of your choice:

- 💬 [**ChatGPT**](https://chat.openai.com/?q=How%20do%20I%20use%20the%20OEC%20Economic%20Complexity%20Trade%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🧠 [**Claude**](https://claude.ai/new?q=How%20do%20I%20use%20the%20OEC%20Economic%20Complexity%20Trade%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🔍 [**Perplexity**](https://perplexity.ai/search?q=How%20do%20I%20use%20the%20OEC%20Economic%20Complexity%20Trade%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🅒 [**Copilot**](https://copilot.microsoft.com/?q=How%20do%20I%20use%20the%20OEC%20Economic%20Complexity%20Trade%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)

***

### ❓ Frequently Asked Questions

#### 🧩 How does it work?

Pick a year, a reporter country, optionally a partner country, and a product breakdown level. The Actor queries the OEC catalog and emits a clean structured record per trade flow.

#### 🌍 Which countries are supported?

231 countries identified by OEC slugs (e.g. `nausa` for United States, `aschn` for China, `eudeu` for Germany). The full list is in the input schema dropdown.

#### 📆 Which years are covered?

BACI HS6 covers 1995 to 2024. SITC4 covers 1962 to 2022 for longer historical analysis.

#### 🛍️ What product classifications are available?

HS4 (4-digit Harmonized System), HS6 (6-digit Harmonized System with 5,000+ products), and SITC4 (Standard International Trade Classification 4-digit). Use `none` for country totals without product breakdown.

#### 🔍 Can I filter to one product?

Yes. Set `productLevel` to `hs4` or `hs6` and add the numeric `hsCode` (e.g. `8542` for integrated circuits, `2709` for crude oil).

#### 🤝 How do bilateral flows work?

Set both `reporter` and `partner` to country slugs. The Actor returns trade flowing from reporter to partner for the given year and product level.

#### ⏰ Can I schedule regular runs?

Yes. Use Apify Schedules to refresh trade dashboards annually when new BACI data drops, or quarterly when partial-year revisions are released.

#### ⚖️ Is this data legal to use?

Yes. The OEC catalog is published for open use and built on top of UN Comtrade data, which is publicly available.

#### 💼 Can I use this commercially?

Yes. Supply-chain analytics, trade-policy consulting, ESG dashboards, and sanctions-compliance products are all valid commercial use cases.

#### 💳 Do I need a paid Apify plan?

No. The free Apify plan is enough for testing and small runs (10 records per run). A paid plan lifts the limit and gives you access to scheduling, higher concurrency, and larger datasets.

#### 🔁 What happens if a run fails partway?

Apify retries transient errors automatically. The Actor pages through results deterministically, so a re-run with the same input picks up cleanly.

#### 🆘 What if I need help?

Our support team is here to help. Contact us through the Apify platform or use the Tally form linked below.

***

### 🔌 Integrate with any app

OEC Trade Scraper connects to any cloud service via [Apify integrations](https://apify.com/integrations):

- [**Make**](https://docs.apify.com/platform/integrations/make) - Automate multi-step workflows
- [**Zapier**](https://docs.apify.com/platform/integrations/zapier) - Connect with 5,000+ apps
- [**Slack**](https://docs.apify.com/platform/integrations/slack) - Get run notifications in your channels
- [**Airbyte**](https://docs.apify.com/platform/integrations/airbyte) - Pipe trade data into your warehouse
- [**GitHub**](https://docs.apify.com/platform/integrations/github) - Trigger runs from repo commits
- [**Google Drive**](https://docs.apify.com/platform/integrations/drive) - Export datasets straight to Sheets

You can also use webhooks to fire downstream actions when a run finishes. Push a fresh trade-data refresh into your dashboard, or alert your team in Slack when bilateral flows shift.

***

### 🔗 Recommended Actors

- [**📈 Indexmundi Scraper**](https://apify.com/parseforge/indexmundi-scraper) - Global demographic and economic indicators
- [**📚 arXiv Scraper**](https://apify.com/parseforge/arxiv-scraper) - Open-access research papers
- [**🚢 ImportYeti Scraper**](https://apify.com/parseforge/importyeti-scraper) - U.S. import shipment records
- [**📨 IETF Datatracker Drafts Scraper**](https://apify.com/parseforge/ietf-datatracker-drafts-scraper) - Internet standards lifecycle
- [**🌐 Nominatim OSM Scraper**](https://apify.com/parseforge/nominatim-osm-scraper) - Geocode addresses via OpenStreetMap

> 💡 **Pro Tip:** browse the complete [ParseForge collection](https://apify.com/parseforge) for more reference-data scrapers.

***

**🆘 Need Help?** [**Open our contact form**](https://tally.so/r/BzdKgA) to request a new scraper, propose a custom data project, or report an issue.

***

> **⚠️ Disclaimer:** this Actor is an independent tool and is not affiliated with, endorsed by, or sponsored by the Observatory of Economic Complexity, MIT, or any of its contributors. All trademarks mentioned are the property of their respective owners. Only publicly available OEC trade data is collected.

# Actor input Schema

## `maxItems` (type: `integer`):

Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000

## `year` (type: `integer`):

Year of trade data (BACI HS6: 1995-2024; SITC: 1962-2022).

## `reporter` (type: `string`):

Country reporting the trade flow. Use OEC country slug.

## `partner` (type: `string`):

Optional partner country for bilateral flows. Leave blank for world totals.

## `productLevel` (type: `string`):

Aggregation depth for products. None returns country totals only.

## `hsCode` (type: `string`):

Optional HS4 or HS6 numeric code to filter results (e.g. 8542 for ICs). Leave blank for all.

## Actor input object example

```json
{
  "maxItems": 10,
  "year": 2022,
  "reporter": "nausa",
  "productLevel": "none"
}
```

# Actor output Schema

## `overview` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "maxItems": 10,
    "year": 2022,
    "reporter": "nausa",
    "partner": "",
    "productLevel": "none",
    "hsCode": ""
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/oec-economic-complexity-trade-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "maxItems": 10,
    "year": 2022,
    "reporter": "nausa",
    "partner": "",
    "productLevel": "none",
    "hsCode": "",
}

# Run the Actor and wait for it to finish
run = client.actor("parseforge/oec-economic-complexity-trade-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "maxItems": 10,
  "year": 2022,
  "reporter": "nausa",
  "partner": "",
  "productLevel": "none",
  "hsCode": ""
}' |
apify call parseforge/oec-economic-complexity-trade-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=parseforge/oec-economic-complexity-trade-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "OEC Economic Complexity Trade Scraper",
        "description": "Scrape Observatory of Economic Complexity (OEC) bilateral trade flows: country, partner, product (HS code), year, export value, import value, and economic complexity index. Export international trade data to JSON, CSV, or Excel for economics research, supply chain, and market intel.",
        "version": "1.0",
        "x-build-id": "x610mONerdGNBBTI1"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/parseforge~oec-economic-complexity-trade-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-parseforge-oec-economic-complexity-trade-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/parseforge~oec-economic-complexity-trade-scraper/runs": {
            "post": {
                "operationId": "runs-sync-parseforge-oec-economic-complexity-trade-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/parseforge~oec-economic-complexity-trade-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-parseforge-oec-economic-complexity-trade-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "maxItems": {
                        "title": "Max Items",
                        "minimum": 1,
                        "maximum": 1000000,
                        "type": "integer",
                        "description": "Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000"
                    },
                    "year": {
                        "title": "Year",
                        "minimum": 1962,
                        "maximum": 2024,
                        "type": "integer",
                        "description": "Year of trade data (BACI HS6: 1995-2024; SITC: 1962-2022)."
                    },
                    "reporter": {
                        "title": "Reporter (exporter country)",
                        "enum": [
                            "",
                            "afago",
                            "afbdi",
                            "afben",
                            "afbfa",
                            "afbwa",
                            "afcaf",
                            "afciv",
                            "afcmr",
                            "afcod",
                            "afcog",
                            "afcom",
                            "afcpv",
                            "afdji",
                            "afdza",
                            "afegy",
                            "aferi",
                            "afeth",
                            "afgab",
                            "afgha",
                            "afgin",
                            "afgmb",
                            "afgnb",
                            "afgnq",
                            "afken",
                            "aflbr",
                            "aflby",
                            "aflso",
                            "afmar",
                            "afmdg",
                            "afmli",
                            "afmoz",
                            "afmrt",
                            "afmus",
                            "afmwi",
                            "afmyt",
                            "afnam",
                            "afner",
                            "afnga",
                            "afrwa",
                            "afsdn",
                            "afsen",
                            "afshn",
                            "afsle",
                            "afsom",
                            "afssd",
                            "afstp",
                            "afswz",
                            "afsyc",
                            "aftcd",
                            "aftgo",
                            "aftun",
                            "aftza",
                            "afuga",
                            "afzaf",
                            "afzmb",
                            "afzwe",
                            "asafg",
                            "asare",
                            "asarm",
                            "asaze",
                            "asbgd",
                            "asbhr",
                            "asbrn",
                            "asbtn",
                            "ascck",
                            "aschn",
                            "ascxr",
                            "ascyp",
                            "asgeo",
                            "ashkg",
                            "asidn",
                            "asind",
                            "asiot",
                            "asirn",
                            "asirq",
                            "asisr",
                            "asjor",
                            "asjpn",
                            "askaz",
                            "askgz",
                            "askhm",
                            "askor",
                            "askwt",
                            "aslao",
                            "aslbn",
                            "aslka",
                            "asmac",
                            "asmdv",
                            "asmmr",
                            "asmng",
                            "asmys",
                            "asnpl",
                            "asomn",
                            "aspak",
                            "asphl",
                            "asprk",
                            "aspse",
                            "asqat",
                            "assau",
                            "assgp",
                            "assyr",
                            "astha",
                            "astjk",
                            "astkm",
                            "astls",
                            "astur",
                            "astwn",
                            "asuzb",
                            "asvnm",
                            "asyem",
                            "eualb",
                            "euand",
                            "euaut",
                            "eubel",
                            "eubgr",
                            "eubih",
                            "eublr",
                            "eublx",
                            "euche",
                            "eucze",
                            "eudeu",
                            "eudnk",
                            "euesp",
                            "euest",
                            "eufin",
                            "eufra",
                            "eugbr",
                            "eugib",
                            "eugrc",
                            "euhrv",
                            "euhun",
                            "euirl",
                            "euisl",
                            "euita",
                            "eultu",
                            "eulux",
                            "eulva",
                            "eumda",
                            "eumkd",
                            "eumlt",
                            "eumne",
                            "eunld",
                            "eunor",
                            "eupol",
                            "euprt",
                            "eurou",
                            "eurus",
                            "eusmr",
                            "eusrb",
                            "eusvk",
                            "eusvn",
                            "euswe",
                            "euukr",
                            "euyug",
                            "naabw",
                            "naaia",
                            "naant",
                            "naatg",
                            "nabes",
                            "nabhs",
                            "nablm",
                            "nablz",
                            "nabmu",
                            "nabrb",
                            "nacan",
                            "nacri",
                            "nacub",
                            "nacuw",
                            "nacym",
                            "nadma",
                            "nadom",
                            "nagrd",
                            "nagrl",
                            "nagtm",
                            "nahnd",
                            "nahti",
                            "najam",
                            "nakna",
                            "nalca",
                            "namaf",
                            "namex",
                            "namsr",
                            "nanic",
                            "napan",
                            "naslv",
                            "naspm",
                            "natca",
                            "natto",
                            "naumi",
                            "nausa",
                            "navct",
                            "navgb",
                            "ocasm",
                            "ocaus",
                            "occok",
                            "ocfji",
                            "ocfsm",
                            "ocgum",
                            "ockir",
                            "ocmhl",
                            "ocmnp",
                            "ocncl",
                            "ocnfk",
                            "ocniu",
                            "ocnru",
                            "ocnzl",
                            "ocpcn",
                            "ocplw",
                            "ocpng",
                            "ocpyf",
                            "ocslb",
                            "octkl",
                            "octon",
                            "octuv",
                            "ocvut",
                            "ocwlf",
                            "ocwsm",
                            "saarg",
                            "sabol",
                            "sabra",
                            "sachl",
                            "sacol",
                            "saecu",
                            "saflk",
                            "saguy",
                            "saper",
                            "sapry",
                            "sasur",
                            "saury",
                            "saven",
                            "xxatf"
                        ],
                        "type": "string",
                        "description": "Country reporting the trade flow. Use OEC country slug."
                    },
                    "partner": {
                        "title": "Partner (importer country)",
                        "enum": [
                            "",
                            "afago",
                            "afbdi",
                            "afben",
                            "afbfa",
                            "afbwa",
                            "afcaf",
                            "afciv",
                            "afcmr",
                            "afcod",
                            "afcog",
                            "afcom",
                            "afcpv",
                            "afdji",
                            "afdza",
                            "afegy",
                            "aferi",
                            "afeth",
                            "afgab",
                            "afgha",
                            "afgin",
                            "afgmb",
                            "afgnb",
                            "afgnq",
                            "afken",
                            "aflbr",
                            "aflby",
                            "aflso",
                            "afmar",
                            "afmdg",
                            "afmli",
                            "afmoz",
                            "afmrt",
                            "afmus",
                            "afmwi",
                            "afmyt",
                            "afnam",
                            "afner",
                            "afnga",
                            "afrwa",
                            "afsdn",
                            "afsen",
                            "afshn",
                            "afsle",
                            "afsom",
                            "afssd",
                            "afstp",
                            "afswz",
                            "afsyc",
                            "aftcd",
                            "aftgo",
                            "aftun",
                            "aftza",
                            "afuga",
                            "afzaf",
                            "afzmb",
                            "afzwe",
                            "asafg",
                            "asare",
                            "asarm",
                            "asaze",
                            "asbgd",
                            "asbhr",
                            "asbrn",
                            "asbtn",
                            "ascck",
                            "aschn",
                            "ascxr",
                            "ascyp",
                            "asgeo",
                            "ashkg",
                            "asidn",
                            "asind",
                            "asiot",
                            "asirn",
                            "asirq",
                            "asisr",
                            "asjor",
                            "asjpn",
                            "askaz",
                            "askgz",
                            "askhm",
                            "askor",
                            "askwt",
                            "aslao",
                            "aslbn",
                            "aslka",
                            "asmac",
                            "asmdv",
                            "asmmr",
                            "asmng",
                            "asmys",
                            "asnpl",
                            "asomn",
                            "aspak",
                            "asphl",
                            "asprk",
                            "aspse",
                            "asqat",
                            "assau",
                            "assgp",
                            "assyr",
                            "astha",
                            "astjk",
                            "astkm",
                            "astls",
                            "astur",
                            "astwn",
                            "asuzb",
                            "asvnm",
                            "asyem",
                            "eualb",
                            "euand",
                            "euaut",
                            "eubel",
                            "eubgr",
                            "eubih",
                            "eublr",
                            "eublx",
                            "euche",
                            "eucze",
                            "eudeu",
                            "eudnk",
                            "euesp",
                            "euest",
                            "eufin",
                            "eufra",
                            "eugbr",
                            "eugib",
                            "eugrc",
                            "euhrv",
                            "euhun",
                            "euirl",
                            "euisl",
                            "euita",
                            "eultu",
                            "eulux",
                            "eulva",
                            "eumda",
                            "eumkd",
                            "eumlt",
                            "eumne",
                            "eunld",
                            "eunor",
                            "eupol",
                            "euprt",
                            "eurou",
                            "eurus",
                            "eusmr",
                            "eusrb",
                            "eusvk",
                            "eusvn",
                            "euswe",
                            "euukr",
                            "euyug",
                            "naabw",
                            "naaia",
                            "naant",
                            "naatg",
                            "nabes",
                            "nabhs",
                            "nablm",
                            "nablz",
                            "nabmu",
                            "nabrb",
                            "nacan",
                            "nacri",
                            "nacub",
                            "nacuw",
                            "nacym",
                            "nadma",
                            "nadom",
                            "nagrd",
                            "nagrl",
                            "nagtm",
                            "nahnd",
                            "nahti",
                            "najam",
                            "nakna",
                            "nalca",
                            "namaf",
                            "namex",
                            "namsr",
                            "nanic",
                            "napan",
                            "naslv",
                            "naspm",
                            "natca",
                            "natto",
                            "naumi",
                            "nausa",
                            "navct",
                            "navgb",
                            "ocasm",
                            "ocaus",
                            "occok",
                            "ocfji",
                            "ocfsm",
                            "ocgum",
                            "ockir",
                            "ocmhl",
                            "ocmnp",
                            "ocncl",
                            "ocnfk",
                            "ocniu",
                            "ocnru",
                            "ocnzl",
                            "ocpcn",
                            "ocplw",
                            "ocpng",
                            "ocpyf",
                            "ocslb",
                            "octkl",
                            "octon",
                            "octuv",
                            "ocvut",
                            "ocwlf",
                            "ocwsm",
                            "saarg",
                            "sabol",
                            "sabra",
                            "sachl",
                            "sacol",
                            "saecu",
                            "saflk",
                            "saguy",
                            "saper",
                            "sapry",
                            "sasur",
                            "saury",
                            "saven",
                            "xxatf"
                        ],
                        "type": "string",
                        "description": "Optional partner country for bilateral flows. Leave blank for world totals."
                    },
                    "productLevel": {
                        "title": "Product breakdown",
                        "enum": [
                            "none",
                            "hs4",
                            "hs6",
                            "sitc4"
                        ],
                        "type": "string",
                        "description": "Aggregation depth for products. None returns country totals only."
                    },
                    "hsCode": {
                        "title": "HS code filter",
                        "type": "string",
                        "description": "Optional HS4 or HS6 numeric code to filter results (e.g. 8542 for ICs). Leave blank for all."
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
