# Fathom Macroeconomic Data API — Categories

> Fathom Macroeconomic Data API — Categories is a paid API for AI agents from fathom-opal.vercel.app, paid per call via x402, $0.04/call, status unknown (last checked 2026-09-14).

Retrieves the hierarchical category tree from FRED's macroeconomic data catalog, listing top-level or sub-categories of economic time series

## Facts

- Endpoint: POST https://fathom-opal.vercel.app/api/categories
- Price: $0.04/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/fathom-macroeconomic-data-api-categories-e5c1e1e7
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_nh7E7PrW24Y9tWsdzPcx_

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 fathom-macroeconomic-data-api-categories-e5c1e1e7 -d '<json body>'
```

Example prompt: Can you show me the top-level categories available in the FRED macroeconomic database so I can figure out which section covers inflation and interest rate data?

## When to prefer this

Use this endpoint when you need to browse or navigate the structure of the FRED macroeconomic data catalog before fetching specific time series data. Prefer it over a direct series search when the user wants to explore available data types hierarchically rather than querying a known series ID. Ideal for building category-aware data exploration flows.

## Known failure modes

- Invalid or non-existent categoryId returns an empty categories array or error
- Network timeouts on the Vercel-hosted service
- Payment authorization failure via x402 protocol blocks the request
- Malformed request body (e.g. categoryId as a number instead of string) may return a 400 error

## How this service works

Free macroeconomic data API powered by FRED. 816,000+ economic time series. GDP, inflation, unemployment, interest rates, and more.

## Output

Returns a JSON object with a source field (identifying the data provider), a category_id field (the queried category), and a categories array containing objects with names and IDs of categories at the requested level of the FRED hierarchy

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "categoryId": {
   "type": "string",
   "description": "Category ID (default: 0 for top-level)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "source"
 ],
 "properties": {
  "source": {
   "type": "string"
  },
  "categories": {
   "type": "array",
   "items": {
    "type": "object"
   }
  },
  "category_id": {
   "type": "string"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/fathom-macroeconomic-data-api-categories-e5c1e1e7/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from fathom-opal.vercel.app](https://www.zero.xyz/host/fathom-opal.vercel.app/llms.txt)
