# BeLive AI Hub > One OpenAI-compatible API over many model providers: chat completions, streaming, tool calling, > embeddings, image and video generation, with OpenRouter-compatible model discovery. Not Tencent > Cloud AI Hub, which is a different product. Data-plane base URL: https://tokenhub-api.belive.sg/api/v1. Every page below is plain Markdown. ## Docs - [Quickstart](https://aihub.belive.sg/docs/markdown/quickstart): Get started with AI Hub. - [Authentication](https://aihub.belive.sg/docs/markdown/auth): Inference requests use a Bearer token: your workspace API key. The model catalogue, docs and read-only MCP server are public. - [Models](https://aihub.belive.sg/docs/markdown/models): GET`/v1/models` returns the live catalogue, including pricing, so you can build model pickers without hardcoding. - [Endpoint index](https://aihub.belive.sg/docs/markdown/endpoints): Find the guide, authentication, protocol and recovery instructions for each customer data-plane operation. ## API reference - [Chat completions](https://aihub.belive.sg/docs/markdown/chat): POST`/api/v1/chat/completions` is the primary endpoint, and `/v1/chat/completions` is the same endpoint under the prefix most SDKs append for you. OpenAI-compatible request and response shapes. - [Thinking and max_tokens](https://aihub.belive.sg/docs/markdown/thinking): A thinking (reasoning) model spends tokens on reasoning before it answers. This page lists which models think, the fields that switch or steer it, how `max_tokens` covers reasoning and answer together, what is held before the call and what is billed, and how reasoning streams. - [Tool calling](https://aihub.belive.sg/docs/markdown/tools): Let models call your functions. Works on every model tagged **tools** in the catalogue, with the OpenAI tools format. - [Streaming](https://aihub.belive.sg/docs/markdown/streaming): Set `"stream": true` and tokens arrive as server-sent events, using the same wire format as OpenAI. - [Errors](https://aihub.belive.sg/docs/markdown/errors): Errors use the envelope of the protocol you call. Branch on its stable error fields; never parse the human-readable `message`. - [Responses](https://aihub.belive.sg/docs/markdown/responses): Use the stateless OpenAI Responses compatibility endpoint with supported text, images and function tools. - [Messages](https://aihub.belive.sg/docs/markdown/messages): Call the Anthropic Messages compatibility route with text, images and client-side tools. - [Structured outputs](https://aihub.belive.sg/docs/markdown/structured-outputs): Request a JSON object or a JSON schema on routes that support response_format. ## Capabilities - [Embeddings](https://aihub.belive.sg/docs/markdown/embeddings): POST`/api/v1/embeddings` turns text and supported media into vectors for search and retrieval, with the OpenAI request and response shapes. - [Image generation](https://aihub.belive.sg/docs/markdown/images): POST`/api/v1/images/generations` creates an image from a prompt with the OpenAI request shape. The call is synchronous: the image is in the response. - [Video generation](https://aihub.belive.sg/docs/markdown/video): POST`/api/v1/videos` starts a video generation job. Jobs are asynchronous: submit, poll until the job completes, then download the video. - [Capabilities](https://aihub.belive.sg/docs/markdown/capabilities): Ready-made endpoints for text, image, speech and video tasks — translation, OCR, receipts, transcription, background removal, virtual try-on and more — on the same key. - [Provider routing](https://aihub.belive.sg/docs/markdown/routing): When a model is served by more than one provider, the `provider` object chooses which of them may serve a request, and in what order. - [Prompt caching](https://aihub.belive.sg/docs/markdown/prompt-caching): Use provider-supported prompt caching and read cache usage without assuming a universal cache control. - [Reranking](https://aihub.belive.sg/docs/markdown/reranking): Rank text documents against a query with a catalogue-listed rerank model. - [Audio output](https://aihub.belive.sg/docs/markdown/audio-api): Create speech or submit a music generation job using a model advertised in your environment. ## Multimodal - [Multimodal inputs](https://aihub.belive.sg/docs/markdown/multimodal): Send images, audio, PDFs and video to compatible models through Chat Completions. - [Image understanding](https://aihub.belive.sg/docs/markdown/image-understanding): Send an image with a question using the image_url content part. - [Audio inputs](https://aihub.belive.sg/docs/markdown/audio-inputs): Use input_audio to ask a compatible model about an MP3 or WAV recording. - [PDFs](https://aihub.belive.sg/docs/markdown/pdfs): Read a PDF through a model route that advertises native file input. - [Video understanding](https://aihub.belive.sg/docs/markdown/video-understanding): Analyze a short video in chat, or use an asynchronous job for longer video work. ## Platform - [Management API](https://aihub.belive.sg/docs/markdown/management): The management API is the control plane this console talks to: workspaces, inference keys, usage and activity. A **management key** lets a script or an agent platform call it without a browser session. - [Webhooks](https://aihub.belive.sg/docs/markdown/webhooks): When a video, audio or capability job finishes, AI Hub posts a signed event to your URL, so you do not have to poll. Polling still works. - [Workspaces & governance](https://aihub.belive.sg/docs/markdown/workspaces): Understand workspace ownership, key restrictions and the signed-in settings behind governance controls. ## Guides - [Rate limits & caps](https://aihub.belive.sg/docs/markdown/limits): Each key can carry a monthly USD spend cap and its own rate limits. A key has none of them unless you set them. - [Cost](https://aihub.belive.sg/docs/markdown/billing): Billing is live: each request is charged against your organization's credit balance, which you read on the console's Billing page (an inference API key cannot read it), and a request the balance cannot cover is refused with `402 insufficient_credits`. Cost is computed per request and shown in your Activity and Analytics views. - [Use AI Hub with Qwen Code](https://aihub.belive.sg/docs/markdown/qwen-code): [Qwen Code](https://github.com/QwenLM/qwen-code) is an open-source coding agent for the terminal. It runs on AI Hub through its OpenAI-compatible protocol: set the base URL and your API key, and pick any catalogue model. - [Use AI Hub with Hermes Agent](https://aihub.belive.sg/docs/markdown/hermes-agent): Configure Hermes Agent with a named AI Hub custom provider, choose a primary model with fallbacks, then add image and video understanding, image and video generation, and speech. - [Use AI Hub with OpenClaw](https://aihub.belive.sg/docs/markdown/openclaw): Set up OpenClaw with AI Hub as a custom Chat Completions provider, choose a primary model with fallbacks, then add image and video understanding, image and video generation, and speech. - [Use AI Hub with OpenCode](https://aihub.belive.sg/docs/markdown/opencode): Connect OpenCode to AI Hub with a custom provider and the OpenAI-compatible Chat Completions adapter. - [Claude Code and AI Hub](https://aihub.belive.sg/docs/markdown/claude-code): Point Claude Code at AI Hub through its Anthropic Messages API and use any catalogue model. - [Claude Desktop and AI Hub](https://aihub.belive.sg/docs/markdown/claude-desktop): Connect Claude Desktop to AI Hub's Messages API: where the setting lives, the base URL and the model IDs. - [Codex CLI and AI Hub](https://aihub.belive.sg/docs/markdown/codex-cli): Connect Codex CLI to AI Hub as a custom provider over the Responses API. - [Codex Desktop and AI Hub](https://aihub.belive.sg/docs/markdown/codex-desktop): Connect Codex Desktop to AI Hub's Responses API: configuration file, credential delivery and model IDs. ## Cookbook - [Cookbook](https://aihub.belive.sg/docs/markdown/cookbook): Complete, runnable recipes for building on AI Hub, from a first request to a coding agent. - [First request](https://aihub.belive.sg/docs/markdown/first-request): Find an exact model id and send one chat completion, in curl, Python or TypeScript. - [Terminal chat](https://aihub.belive.sg/docs/markdown/terminal-chat): A streaming chat in the terminal that keeps history and treats every incomplete answer as an error. - [Browser chat with Next.js](https://aihub.belive.sg/docs/markdown/browser-chat): A small Next.js chat app: the page streams the answer, and the key never leaves your server. - [A function-tool loop](https://aihub.belive.sg/docs/markdown/function-tools): Let a model call one function in your program, with validated arguments and a hard stop. - [Migrate an OpenAI-compatible client](https://aihub.belive.sg/docs/markdown/migrate-openai): Move code that already uses an OpenAI-compatible client to AI Hub by changing its settings, not its logic. - [Coding agents](https://aihub.belive.sg/docs/markdown/coding-agents): Which AI Hub route each coding agent uses, with links to its configuration guide. - [AI Hub MCP server](https://aihub.belive.sg/docs/markdown/tokenhub-mcp): Connect an assistant to AI Hub's MCP server for live docs and model catalogue tools. - [AI Hub Skills](https://aihub.belive.sg/docs/markdown/integration-skill): AI Hub Skills: portable guidance and complete examples for integrating AI Hub with coding agents. ## API reference - [Public data-plane OpenAPI](https://aihub.belive.sg/docs/openapi/data-plane.yaml): selected public operations; account, management and staff APIs excluded ## Agent tools - [MCP server](https://aihub.belive.sg/mcp): read-only search_docs, get_doc, list_models and get_model over Streamable HTTP; no key - [Integration skill 1.2.3](https://aihub.belive.sg/skills/tokenhub-integration/1.2.3.zip): SKILL.md, references and the cookbook examples - [Model catalogue](https://tokenhub-api.belive.sg/api/v1/models?output_modalities=all): public JSON, no key