# MacroLens Trade Analysis API

> MacroLens Trade Analysis API is a paid API for AI agents from v1macros-lensys.vercel.app, paid per call via x402, $0.03/call, status unknown (last checked 2026-10-18).

Provides AI-powered macro-economic trade analysis using FRED and World Bank data processed through a MiMo LLM, starting from a specified date.

## Facts

- Endpoint: POST https://v1macros-lensys.vercel.app/api/trade?utm_source=zero.xyz
- Price: $0.03/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-18
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/macrolens-trade-analysis-api-0a8772a4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_yN_dZLI_4ZTKsy7xM4oMH

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 macrolens-trade-analysis-api-0a8772a4 -d '<json body>'
```

Example prompt: Pull me an AI-powered macro trade analysis from MacroLens starting from January 2022 — I want to see trade trends, balances, and economic indicators synthesized from FRED and World Bank data.

## When to prefer this

Choose this endpoint when you need AI-synthesized macro-level trade analysis grounded in authoritative FRED and World Bank datasets, especially when you want natural-language interpretation alongside raw indicators rather than just raw time-series data. Prefer this over generic data APIs when you need both the data retrieval and the LLM-powered narrative synthesis in a single call.

## Known failure modes

- Missing or malformed 'start' date string causes validation failure
- Invalid date format may return an error or empty data
- FRED or World Bank upstream data unavailability could cause partial or failed response
- Payment not processed via x402 on Base results in 402 unauthorized response
- Requesting a start date far in the future returns no meaningful data

## How this service works

AI-powered macro-economic analysis. FRED + World Bank data + MiMo LLM. 20 endpoints. x402 on Base.

## Output

Returns a structured JSON object with a success flag and a data object containing AI-synthesized trade analysis — likely including trade balance figures, import/export indicators, and narrative economic interpretation derived from FRED and World Bank datasets.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "start"
 ],
 "properties": {
  "start": {
   "type": "string",
   "description": "start"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "success"
 ],
 "properties": {
  "data": {
   "type": "object"
  },
  "success": {
   "type": "boolean"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/macrolens-trade-analysis-api-0a8772a4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from v1macros-lensys.vercel.app](https://www.zero.xyz/host/v1macros-lensys.vercel.app/llms.txt)
