category_idinteger
The id for a category. integer, default: 0 (root category)
Valor predeterminado: 0
https://api.sandbase.ai/v1/api/fred/categorycategory from FRED. Returns the official FRED API response unchanged.
Su salida aparecerá aquí
Complete las entradas y luego haga clic en Ejecutar.
Returns the name and parent of one FRED category. It takes an optional category_id, and the default 0 returns the root category.
parent_id from a known category.category_id exists before you request its child categories or series.curl -X POST "https://api.sandbase.ai/v1/api/fred/category" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"file_type": "json"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
category_id | integer | No | The id for a category. integer, default: 0 (root category) |
file_type | string | No | Response format. Only json is supported. |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"categories": [
{
"id": 0,
"name": "Categories",
"parent_id": 0
}
]
}
| Field | Meaning |
|---|---|
categories[] | List of matching categories. It holds one item for the requested category_id. |
categories[].id | Numeric id of the category. The root category has id 0. |
categories[].name | Display name of the category. The root category is named Categories. |
categories[].parent_id | Id of the parent category. The root category shows 0 as its own parent. |
category_id or send 0 to get the root category.file_type accepts only json.$0.00001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
Empiece a construir
Endpoint de la API de la plataforma con autenticación unificada y seguimiento de uso.
curl -X POST "https://api.sandbase.ai/v1/api/fred/category" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"file_type": "json",
"category_id": 0
}'Configure su clave de API de SandBase en el entorno de su servidor. Las solicitudes usan autenticación Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Conserve su clave en el servidor. No la exponga en código del navegador.
category_idintegerThe id for a category. integer, default: 0 (root category)
Valor predeterminado: 0
file_typestringResponse format. Only json is supported.
Valor predeterminado: "json"
Valores posibles: json
Respuesta de ejemplo guardada para esta API; no se realiza ninguna solicitud en vivo al verla.
No se ha publicado ninguna respuesta guardada. Ejecute la API en Playground para inspeccionar su respuesta.
Explorar más
| API | Precio | Respuesta |
|---|---|---|
FRED categoryEsta API FRED | $0.00001 por llamada | JSON |
FRED | $0.00001 por llamada | JSON |
FRED | $0.00001 por llamada | JSON |
FRED | $0.00001 por llamada | JSON |
FRED | $0.00001 por llamada | JSON |
FRED | $0.00001 por llamada | JSON |
Preguntas
Envía una solicitud POST a https://api.sandbase.ai/v1/api/fred/category con tu clave API de SandBase en el encabezado Authorization (Bearer) y los parámetros como un cuerpo JSON. También puedes probarlo en el Playground de esta página sin escribir código.
$0.00001 por llamada, facturado desde tu saldo de SandBase. Solo se te cobra por las llamadas que haces; no hay suscripción.
No se requieren parámetros. Opcionales: category_id (integer) y file_type (una de json). La tabla de Parámetros y el Playground de esta página enumeran todos los campos.
Una respuesta JSON devuelta en la misma solicitud HTTP (sincrónica). El README de esta página incluye una respuesta de ejemplo.
No. FRED category funciona a través de SandBase, así que una sola clave API de SandBase cubre este endpoint y todas las demás APIs y modelos del catálogo. No necesitas solicitar acceso a la API de FRED por separado.