AI API Kit

API reference

Base URL https://api.aiapikit.com/v1. JSON in and out. Errors use {"error": {"type", "message"}}.

Management API

MethodPath
GET/v1/meCurrent workspace and plan
GET/v1/keysList keys (prefix and last 4 only)
POST/v1/keysCreate a key
POST/v1/keys/{id}/rotateRotate a key
DELETE/v1/keys/{id}Revoke a key
GET/v1/usage?from=&to=&group_by=modelToken usage and cost
GET/v1/projectsList projects
GET/v1/routesRouting rules
PUT/v1/routes/{alias}Create or replace a route
GET/v1/audit-logAudit log (Team and Scale)
POST/v1/webhooksRegister a webhook

Gateway

MethodPath
POSThttps://llm.aiapikit.com/v1/chat/completionsOpenAI format, streaming with "stream": true
POSThttps://llm.aiapikit.com/v1/messagesAnthropic format
GEThttps://llm.aiapikit.com/v1/modelsModels your key can use

Machine-readable: openapi.json

Internal endpoints (staff only)

Not covered by the SLA. Require a staff SSO session; requests with workspace keys are rejected.

GEThttps://aiapikit.com/internal/api/v1/tenantsAll workspaces with plan and spend
POSThttps://aiapikit.com/internal/api/v1/keys/{id}/impersonateShort-lived key acting as a workspace (support)
POSThttps://aiapikit.com/internal/api/v1/creditsGrant credits