curl -s -X POST "https://api.impulselabs.ai/api/api-keys" \
-H "Authorization: Bearer <your-dashboard-session-token>" \
-H "Content-Type: application/json" \
-d '{ "name": "production" }'
import requests
resp = requests.post(
"https://api.impulselabs.ai/api/api-keys",
headers={"Authorization": "Bearer <dashboard-token>"},
json={"name": "production"},
)
data = resp.json()
print(data["key"]) # Save this — shown once only
const resp = await fetch("https://api.impulselabs.ai/api/api-keys", {
method: "POST",
headers: {
Authorization: "Bearer <dashboard-token>",
"Content-Type": "application/json",
},
body: JSON.stringify({ name: "production" }),
});
const { key } = await resp.json();
console.log(key); // imp_a1b2c3...
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "production",
"key": "imp_a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2",
"key_prefix": "imp_a1b2",
"created_at": "2026-02-19T12:00:00.000Z"
}
{
"error": "Invalid body",
"details": {
"fieldErrors": { "name": ["String must contain at least 1 character(s)"] }
}
}
{
"error": "Upgrade required",
"message": "API keys are available on Pro plans and above. Upgrade at /billing."
}
API Keys
Create API Key
Create a new API key for the authenticated user. The raw key is returned once and cannot be retrieved again.
POST
/
api
/
api-keys
curl -s -X POST "https://api.impulselabs.ai/api/api-keys" \
-H "Authorization: Bearer <your-dashboard-session-token>" \
-H "Content-Type: application/json" \
-d '{ "name": "production" }'
import requests
resp = requests.post(
"https://api.impulselabs.ai/api/api-keys",
headers={"Authorization": "Bearer <dashboard-token>"},
json={"name": "production"},
)
data = resp.json()
print(data["key"]) # Save this — shown once only
const resp = await fetch("https://api.impulselabs.ai/api/api-keys", {
method: "POST",
headers: {
Authorization: "Bearer <dashboard-token>",
"Content-Type": "application/json",
},
body: JSON.stringify({ name: "production" }),
});
const { key } = await resp.json();
console.log(key); // imp_a1b2c3...
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "production",
"key": "imp_a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2",
"key_prefix": "imp_a1b2",
"created_at": "2026-02-19T12:00:00.000Z"
}
{
"error": "Invalid body",
"details": {
"fieldErrors": { "name": ["String must contain at least 1 character(s)"] }
}
}
{
"error": "Upgrade required",
"message": "API keys are available on Pro plans and above. Upgrade at /billing."
}
This endpoint uses your dashboard session (Auth0 JWT), not an API key.
Request body
string
required
A human-readable label for the key. Max 128 characters. Example:
production, ci-pipeline.Response
string
Unique identifier for the key (UUID). Use this when revoking.
string
The label you provided.
string
The raw API key — shown only once. Starts with
imp_.string
First 8 characters of the key. Safe to store and use in logs to identify which key made a request.
string
ISO 8601 timestamp.
curl -s -X POST "https://api.impulselabs.ai/api/api-keys" \
-H "Authorization: Bearer <your-dashboard-session-token>" \
-H "Content-Type: application/json" \
-d '{ "name": "production" }'
import requests
resp = requests.post(
"https://api.impulselabs.ai/api/api-keys",
headers={"Authorization": "Bearer <dashboard-token>"},
json={"name": "production"},
)
data = resp.json()
print(data["key"]) # Save this — shown once only
const resp = await fetch("https://api.impulselabs.ai/api/api-keys", {
method: "POST",
headers: {
Authorization: "Bearer <dashboard-token>",
"Content-Type": "application/json",
},
body: JSON.stringify({ name: "production" }),
});
const { key } = await resp.json();
console.log(key); // imp_a1b2c3...
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"name": "production",
"key": "imp_a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2",
"key_prefix": "imp_a1b2",
"created_at": "2026-02-19T12:00:00.000Z"
}
{
"error": "Invalid body",
"details": {
"fieldErrors": { "name": ["String must contain at least 1 character(s)"] }
}
}
{
"error": "Upgrade required",
"message": "API keys are available on Pro plans and above. Upgrade at /billing."
}