API Basics
CloudAIKit provides OpenAI-compatible APIs and additionally supports Claude Messages, Google Gemini, Rerank, and Realtime. During development, first confirm that the target interface, model, and channel are compatible.
Basic Request
POST https://api.cloudaikit.com/v1/chat/completions
Authorization: Bearer sk-your-token
Content-Type: application/jsonThe request body must contain at least model and the input content. The chat interface uses messages, while the Responses interface uses input.
Common Paths
| Capability | Path |
|---|---|
| Model list | GET /v1/models |
| Chat completions | POST /v1/chat/completions |
| Responses | POST /v1/responses |
| Text completions | POST /v1/completions |
| Embeddings | POST /v1/embeddings |
| Image generation/editing | POST /v1/images/generations、POST /v1/images/edits |
| Audio | POST /v1/audio/transcriptions、/translations、/speech |
| Rerank | POST /v1/rerank |
| Realtime | GET /v1/realtime |
Streaming Responses
Chat Completions and Responses support streaming output through stream: true. The client needs to read the output using Server-Sent Events or the streaming iteration method provided by the corresponding SDK.
Compatibility Boundaries
OpenAI compatibility does not mean that all fields, models, and channels are completely identical. Some fields may be filtered or rewritten by the platform, or whether they are supported may be determined by the channel, such as reasoning parameters, service tiers, structured outputs, tool calls, image input, and audio input. For precise definitions, refer to the Reference.
