Vai al contenuto
GET /v1/cpi

Latest Spanish CPI and inflation

Provalo dal vivo

10 chiamate gratuite al giorno — senza registrazione, senza chiave API. Passa dal gateway oanor.

Intestazioni personalizzate (facoltative)
api.oanor.com/spain-stats-api

Funziona. Prendi una chiave API e usala nel tuo progetto.

Ottieni una chiave API

Frammenti di codice

curl "https://api.oanor.com/spain-stats-api/v1/cpi" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/spain-stats-api/v1/cpi", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/spain-stats-api/v1/cpi");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/spain-stats-api/v1/cpi",
    headers={"x-oanor-key": "oanor_test_..."}
)

Risposta di esempio

Una risposta reale di questo endpoint, acquisita dall'ultimo health check.

{
    "data": {
        "base": "2021 = 100",
        "table": "50902",
        "latest": {
            "year": 2025,
            "month": 12,
            "date_iso": "2025-11-30",
            "index_value": 119.942,
            "change_annual_pct": 2.9,
            "change_monthly_pct": 0.3
        },
        "series": [
            {
                "year": 2025,
                "month": 12,
                "date_iso": "2025-11-30",
                "index_value": 119.942,
                "change_annual_pct": 2.9,
                "change_monthly_pct": 0.3
            },
            {
                "year": 2025,
                "month": 11,
                "date_iso": "2025-10-31",
                "index_value": 119.532,
                "change_annual_pct": 3,
                "change_monthly_pct": 0.2
            },
            {
                "year": 2025,
                "month": 10,
                "date_iso": "2025-09-30",
                "index_value": 119.301,
                "change_annual_pct": 3.1,
                "change_monthly_pct": 0.7
            },
            {
                "year": 2025,
                "month": 9,
                "date_iso": "2025-08-31",
                "index_value": 118.485,
                "change_annual_pct": 3,
                "change_monthly_pct": -0.3
            },
            {
                "year": 2025,
                "month": 8,
                "date_iso": "2025-07-31",
                "index_value": 118.824,
                "change_annual_pct": 2.7,
                "change_monthly_pct": 0
            },
            {
                "year": 2025,
                "month": 7,
                "date_iso": "2025-06-30",
                "index_value": 118.777,
                "change_annual_pct": 2.7,
                "change_monthly_pct": -0.1
            },
            {
                "year": 2025,
                "month": 6,
                "date_iso": "2025-05-31",
                "index_value": 118.867,
                "change_annual_pct": 2.3,
                "change_monthly_pct": 0.7
            },
            {
                "year": 2025,
                "month": 5,
                "date_iso": "2025-04-30",
                "index_value": 118.077,
                "change_annual_pct": 2,
                "change_monthly_pct": 0.1
            },
            {
                "year": 2025,
                "month": 4,
                "date_iso": "2025-03-31",
                "index_value": 117.997,
                "change_annual_pct": 2.2,
                "change_monthly_pct": 0.6
            },
            {
                "year": 2025,
                "month": 3,
                "date_iso": "2025-02-28",
                "index_value": 117.26,
                "change_annual_pct": 2.3,
                "change_monthly_pct": 0.1
            },
            {
                "year": 2025,
                "month": 2,
                "date_iso": "2025-01-31",
                "index_value": 117.1
…