# DataNexusAI Trade Data API

> DataNexusAI Trade Data API is a paid API for AI agents from api.datanexusai.org, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-02).

Retrieves international trade flow data (imports/exports) by reporter country, partner, product code, and date range.

## Facts

- Endpoint: GET https://api.datanexusai.org/api/v1/trade?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/datanexusai-trade-data-api-6d29a844
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_Y2H7g_oD-KiYMyGwrVrhQ

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability datanexusai-trade-data-api-6d29a844
```

Example prompt: Can you pull Bulgaria's wheat import data from WORLD as the partner, for product code 1001, covering 2020 to 2023, showing imports only?

## When to prefer this

Choose this endpoint when you need structured international trade flow data (imports or exports) queryable by country, product code, and date range. Ideal for trade analytics, economic research, market intelligence, and commodity flow analysis. This endpoint uses x402 micropayments (USDC) making it suitable for pay-per-query agent workflows without subscription overhead.

## Known failure modes

- Missing required 'type' or 'method' fields returns a 400 validation error
- Invalid or unrecognized product code returns empty results or an error
- Invalid reporter country code returns no matching records
- Date range with unsupported format may return an error or empty response
- Payment failure (insufficient USDC balance) returns HTTP 402 with x402 payment challenge
- Exceeded pagination offset beyond available records returns empty result set

## How this service works

Public data API for SEBRA payments, PTP road accidents, Hearthstone cards, EU agri-food prices, and trade/market analytics. Paid data endpoints use x402 (USDC micropayments). Docs and discovery endpoints are free.

Machine-readable discovery: `https://api.datanexusai.org/openapi.json`, `https://api.datanexusai.org/llms.txt`, `https://api.datanexusai.org/.well-known/x402`.

Human docs: `/docs` and `/api/`.

## Output

Returns a list of trade records matching the query filters, including reporter country, partner, product code, trade flow direction (import/export), time period, and associated trade volumes or values. Supports pagination via limit and offset parameters.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "flow": {
       "type": "string",
       "description": "1/2 or import/export."
      },
      "limit": {
       "type": "integer"
      },
      "offset": {
       "type": "integer"
      },
      "date_to": {
       "type": "string",
       "description": "End period."
      },
      "partner": {
       "type": "string",
       "description": "Partner (often WORLD)."
      },
      "product": {
       "type": "string",
       "example": "1001",
       "description": "Product code (or commodity=)."
      },
      "reporter": {
       "type": "string",
       "example": "BG",
       "description": "Reporter country (or country=)."
      },
      "date_from": {
       "type": "string",
       "example": "2020",
       "description": "Start period."
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/datanexusai-trade-data-api-6d29a844/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.datanexusai.org](https://www.zero.xyz/host/api.datanexusai.org/llms.txt)
