Docs / REST API
REST API
The same data as the MCP tools, over plain HTTPS with an
API key from the app, passed as a bearer token
or an x-api-key header - for curl, scripts, and jobs. Rate
limits are on the shared reference page; errors are
below.
GET /v1/pressure/latest
The newest closed UTC day's reading on the 0-5 scale. The in-progress day is never served here.
Query
dataset- slug from /v1/datasets; defaults tomacro.
Responses cache for five minutes; a repeated call inside that window costs nothing new.
$ curl https://api.pressureatlas.com/v1/pressure/latest \
-H "Authorization: Bearer pa_your_key"
{
"date": "2026-08-19",
"pressure": "3.2",
"label": "building",
"dataset": "macro",
"dataset_name": "Macro (Global)"
}
GET /v1/pressure/recent
The most recent 5 closed days of readings - the same tape as the public feed, counted against your account's daily budget.
Query
dataset- defaults tomacro.date_start,date_end-YYYY-MM-DD, validated and accepted; every account currently receives the fixed recent window, and the response carries a note when dates were passed.
$ curl "https://api.pressureatlas.com/v1/pressure/recent?date_start=2026-08-13" \
-H "Authorization: Bearer pa_your_key"
{
"dataset": "macro",
"window": { "start": "2026-08-15", "end": "2026-08-19" },
"notes": [
"Your access includes the most recent 5 days of pressure; the requested window was ignored."
],
"readings": [
{ "date": "2026-08-15", "pressure": "2.6", "label": "equilibrium" },
{ "date": "2026-08-16", "pressure": "2.9", "label": "equilibrium" },
{ "date": "2026-08-17", "pressure": "3.1", "label": "building" },
{ "date": "2026-08-18", "pressure": "3.4", "label": "building" },
{ "date": "2026-08-19", "pressure": "3.2", "label": "building" }
]
}
GET /v1/metrics/:slug/latest
Every metric in the catalog other than Pressure is read here, by its slug
from /v1/datasets (the catalog names the path
for each row under read_with). The reading is on that metric's
own scale and the value field is named after the metric.
Also
/v1/metrics/:slug/recent- daily readings for a window;date_start,date_endas for /v1/pressure/recent./v1/metrics/:slug/export- the full history asformat=csvorformat=json, on accounts with export.
When the metric carries an explanation, the latest reading includes it as plain text.
{
"date": "2026-08-19",
"drift": "6.20",
"label": "mid",
"dataset": "drift",
"dataset_name": "Drift",
"explanation": "Smoothed over two weeks."
}
GET /v1/datasets
The catalog with your access per dataset. The full catalog is
always visible. Each row names the path that serves it
(read_with) and carries the metric's explanation when one is
set.
{
"datasets": [
{
"slug": "macro",
"name": "Macro (Global)",
"description": "Pressure: a daily measurement ...",
"read_with": "/v1/pressure",
"history_start": "2021-04-01",
"your_access": "the most recent 5 days of pressure",
"export": false
}
]
}
Errors
REST errors are standard HTTP with one JSON body shape.
| Status | Code | When |
|---|---|---|
| 401 | unauthorized | Missing, invalid, or revoked key. |
| 400 | invalid_request, invalid_window | Bad date format, start after end, window before history. |
| 403 | not_available | A dataset or feature outside your account's access. |
| 404 | unknown_dataset, wrong_route | Slug not in the catalog; or the slug exists but is served by the other path (the message names it). |
| 429 | rate_limited | Per-minute or daily budget spent; Retry-After is set. |
| 503 | upstream_unavailable, data_pending | The data source is unavailable, or the newest day is still preparing. |
{
"error": {
"code": "rate_limited",
"message": "You've used the 200 calls included today. The counter resets at midnight UTC."
}
}