Skip to content

GET /api/v1/macro/indicator

Macro economic indicators.

Returns macro economic indicators such as CPI, PPI, GDP, and unemployment rate.

Request

GET /api/v1/macro/indicator

Headers

HeaderValue
F-API-KEYYour API key

Query Parameters

ParameterTypeRequiredFilterDescription
indicator_namestringNoexactIndicator name
periodstringNoexactPeriod (e.g. 2024-01)
sourcestringNoexactData source
limitintegerNoMax rows per page (default 100, max 1000)
offsetintegerNoRows to skip (default 0)
sortstringNoSort field (default period)
orderasc | descNoSort direction (default desc)

Example

Terminal window
curl -H "F-API-KEY: fk-xxxxx" \
"https://finance-api.xp-java.workers.dev/api/v1/macro/indicator?indicator_name=CPI&limit=12"

Response

{
"code": 0,
"message": "ok",
"data": [
{
"indicator_name": "CPI",
"period": "2024-12",
"value": 0.1,
"unit": "%",
"source": "stats",
"updated_at": "2025-01-10T00:00:00Z"
}
],
"meta": {
"total": 12,
"limit": 12,
"offset": 0,
"has_more": false
}
}