curl --request POST \
--url https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"category": "food"
}
'import requests
url = "https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi"
payload = { "category": "food" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({category: 'food'})
};
fetch('https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'category' => 'food'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi"
payload := strings.NewReader("{\n \"category\": \"food\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"category\": \"food\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"category\": \"food\"\n}"
response = http.request(request)
puts response.read_bodyBls cpi
A direct inflation lookup by category; for other CPI items or percent changes use bls_series_search on survey cu and bls_series.
curl --request POST \
--url https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"category": "food"
}
'import requests
url = "https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi"
payload = { "category": "food" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({category: 'food'})
};
fetch('https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'category' => 'food'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi"
payload := strings.NewReader("{\n \"category\": \"food\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"category\": \"food\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"category\": \"food\"\n}"
response = http.request(request)
puts response.read_bodyRequest contract
- Method and path: POST /apis/v1/bls/economic-statistics/bls-cpi
- Availability: enabled
- Request URL template:
https://api.aisa.one/apis/v1/bls/economic-statistics/bls-cpi
{
"operationId": "bls.economic-statistics.bls-cpi",
"method": "POST",
"path": "/apis/v1/bls/economic-statistics/bls-cpi",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"examples": {
"provider": {
"summary": "Official provider example; checked against AIsa request constraints",
"value": {
"category": "food",
"end_year": 2026,
"start_year": 2025
}
}
},
"schema": {
"additionalProperties": true,
"properties": {
"area_code": {
"default": "0000",
"description": "BLS CPI area code: 0000 U.S. city average, 0100 Northeast, 0200 Midwest, 0300 South, 0400 West, S49A Los Angeles, S12A New York, S23A Chicago, S37B Houston, S49B San Francisco. Pattern: ^[A-Za-z0-9]{4}$.\n\nProvider reference: default \"0000\".",
"type": "string",
"x-alexandria-option-metadata": {
"in": "body"
}
},
"category": {
"description": "CPI-U expenditure category.\n\nProvider reference: allowed values [\"all_items\", \"core\", \"food\", \"food_at_home\", \"food_away_from_home\", \"energy\", \"gasoline\", \"electricity\", \"utility_gas\", \"housing\", \"shelter\", \"rent\", \"owners_equivalent_rent\", \"apparel\", \"transportation\", \"new_vehicles\", \"used_cars_and_trucks\", \"airline_fares\", \"medical_care\", \"medical_care_services\", \"recreation\", \"education_and_communication\", \"other_goods_and_services\", \"services\", \"commodities\"].",
"type": "string"
},
"end_year": {
"description": "end_year\n\nProvider reference: minimum 1900; maximum 2100.",
"type": "number",
"x-alexandria-option-metadata": {
"in": "body",
"max": 2100,
"min": 1900
}
},
"seasonally_adjusted": {
"description": "Seasonally adjusted (CUSR) instead of unadjusted (CUUR). Only available for area_code 0000.",
"type": "boolean",
"x-alexandria-option-metadata": {
"in": "body"
}
},
"start_year": {
"description": "start_year\n\nProvider reference: minimum 1900; maximum 2100.",
"type": "number",
"x-alexandria-option-metadata": {
"in": "body",
"max": 2100,
"min": 1900
}
}
},
"required": [
"category"
],
"type": "object"
}
}
},
"required": true
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
Cost and request rules
Usage-based pricing. Default request estimate: $0.0005 USD. The final charge depends on actual usage. Your account price may differ; use a request quote where supported.Authorizations
Body
CPI-U expenditure category.
Provider reference: allowed values ["all_items", "core", "food", "food_at_home", "food_away_from_home", "energy", "gasoline", "electricity", "utility_gas", "housing", "shelter", "rent", "owners_equivalent_rent", "apparel", "transportation", "new_vehicles", "used_cars_and_trucks", "airline_fares", "medical_care", "medical_care_services", "recreation", "education_and_communication", "other_goods_and_services", "services", "commodities"].
Response
Consumer Price Index for All Urban Consumers (CPI-U) for one expenditure category (all_items, core, food, energy, gasoline, shelter, rent, apparel, medical_care, ...) and area (U.S. city average by default), over an optional year window of at most 10 years (the latest 3 years when omitted). Returns the index observations with the resolved BLS series id (CUUR/CUSR + area + item).
The response contains the tool result directly.
| Documented field | Provider type | Description |
|---|---|---|
area_code | string | |
category | string | |
count | number | |
exists | boolean | |
first_date | string | |
item_code | string | |
item_name | string | |
last_date | string | |
latest | object | |
messages | string[] | |
observations | object[] | |
observed_at_ms | number | |
seasonally_adjusted | boolean | |
series_id | string | |
source_url | string | |
units | string |
These are the provider's documented fields. Field requiredness, nullability and nested object structures are specified only where the descriptions explicitly say so.