# MacroLens Trade Analysis API

> MacroLens Trade Analysis API is a paid API for AI agents from mascronlens.vercel.app, paid per call via x402, $0.4/call, status unknown (last checked 2026-09-15).

Analyzes international trade data using FRED and World Bank datasets, enhanced with AI-powered macro-economic insights via MiMo LLM

## Facts

- Endpoint: POST https://mascronlens.vercel.app/api/trade
- Price: $0.4/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/macrolens-trade-analysis-api-457dbf5e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_5pUhoNclbH363RGSZqxT6

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-457dbf5e -d '<json body>'
```

Example prompt: Can you pull me a MacroLens AI trade analysis starting from January 2020 and give me the key macro-economic takeaways on global trade flows and balances?

## When to prefer this

Choose this endpoint when you need AI-synthesized macro-economic trade analysis combining authoritative FRED and World Bank data — particularly useful for investors, researchers, or analysts who want LLM-interpreted trade insights rather than raw data. Prefer over generic economic APIs when you want the MiMo LLM layer to contextualize and explain trade trends.

## Known failure modes

- Missing required 'start' parameter returns validation error
- Invalid date format in 'start' field causes parsing failure
- FRED or World Bank upstream data unavailable leads to partial or failed response
- Payment not received or insufficient USDC balance blocks access with 402 response
- Date range too far in the past may have limited data coverage

## How this service works

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

## Output

A JSON object with a success boolean and a data object containing AI-interpreted trade metrics and macro-economic insights drawn from FRED and World Bank trade datasets for the specified period

## 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-457dbf5e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from mascronlens.vercel.app](https://www.zero.xyz/host/mascronlens.vercel.app/llms.txt)
