OpenAI-compatible API
/v1Use it from anything that speaks the OpenAI chat format, including @ai-sdk/openai-compatible.
POST /v1/chat/completionschatGET /v1/modelsmodels- Streaming with
stream: true, SSE chunks in OpenAI formatSSE - Token usage in the last chunk with
include_usageusage
curl http://127.0.0.1:8787/v1/chat/completions \ -H "Authorization: Bearer $API_KEY" \ -H "Content-Type: application/json" \ -d '{"model":"gemini-3.8-flash", "reasoning_effort":"low", "messages":[{"role":"user", "content":"Say hello in one word."}]}'