> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tokenlab.sh/llms.txt
> Use this file to discover all available pages before exploring further.

# Introduction

> Access hundreds of AI models through a unified API

## What Is TokenLab?

TokenLab is an AI API aggregation platform that gives you unified access to **hundreds of AI models** from providers such as OpenAI, Anthropic, Google, DeepSeek, Moonshot, MiniMax, and more.

<CardGroup cols={2}>
  <Card title="Native + Compatible" icon="plug">
    Use native Anthropic/Gemini routes when provider behavior matters, or OpenAI-compatible `/v1` routes for existing OpenAI-style tools.
  </Card>

  <Card title="Native Formats" icon="shuffle">
    Call OpenAI, Anthropic, Gemini, and Responses-style endpoints from one platform.
  </Card>

  <Card title="Pay As You Go" icon="coins">
    No subscriptions. Only pay for what you actually use.
  </Card>

  <Card title="High Availability" icon="shield-check">
    Smart routing, failover, and multi-channel support improve reliability.
  </Card>
</CardGroup>

## Supported Capabilities

The public catalog changes over time. Use `/v1/models`, `recommended_for`, or the Models page for exact current availability; the examples below use current public model IDs.

| Capability                 | Description                                                            | Example models                                                           |
| -------------------------- | ---------------------------------------------------------------------- | ------------------------------------------------------------------------ |
| Chat & Reasoning           | Text generation, planning, tools                                       | `gpt-5.4`, `claude-sonnet-4-6`, `deepseek-r1`                            |
| Vision & Multimodal        | Image understanding and multimodal chat                                | `gpt-4o`, `claude-sonnet-4-6`, `gemini-3.5-flash`                        |
| Image Generation & Editing | Text-to-image and image editing                                        | `gpt-image-2`, `flux-pro`, `qwen-image-plus`                             |
| Video Generation           | Text-to-video, image-to-video, reference video, and motion control     | `veo3.1`, `wan-2.7`, `kling-3.0-video`, `happyhorse-1.0`                 |
| Audio & Realtime WebSocket | TTS, transcription, audio translation, and realtime WebSocket sessions | `gpt-4o-mini-tts`, `whisper-1`, `gpt-realtime`                           |
| Embeddings & Rerank        | Text vectorization and reranking                                       | `text-embedding-3-small`, `qwen3-vl-rerank`                              |
| Translation                | Text translation and WebSocket speech translation workflows            | `doubao-seed-translation`, `gpt-realtime-translate`                      |
| Music & 3D                 | Music and 3D asset generation                                          | `suno-music`, `tripo-h3.1`                                               |
| Worlds                     | World generation, status polling, and media asset workflows            | Use `/v1/worlds/generations` and the Models API for current availability |

## Choose the Request Format

Start with the route that matches the behavior you need. Use native Anthropic/Gemini routes for provider-native features; use OpenAI-compatible `/v1/chat/completions` when migrating existing OpenAI-style chat code.

<CodeGroup>
  ```bash cURL theme={null}
  curl https://api.tokenlab.sh/v1/chat/completions \
    -H "Authorization: Bearer sk-your-api-key" \
    -H "Content-Type: application/json" \
    -d '{
      "model": "gpt-5.4",
      "messages": [
        {"role": "user", "content": "Explain what TokenLab does in one sentence."}
      ]
    }'
  ```

  ```python Python theme={null}
  from openai import OpenAI

  client = OpenAI(
      api_key="sk-your-api-key",
      base_url="https://api.tokenlab.sh/v1"
  )

  response = client.chat.completions.create(
      model="gpt-5.4",
      messages=[{"role": "user", "content": "Explain what TokenLab does in one sentence."}]
  )

  print(response.choices[0].message.content)
  ```

  ```javascript JavaScript theme={null}
  import OpenAI from 'openai';

  const client = new OpenAI({
    apiKey: 'sk-your-api-key',
    baseURL: 'https://api.tokenlab.sh/v1'
  });

  const response = await client.chat.completions.create({
    model: 'gpt-5.4',
    messages: [{ role: 'user', content: 'Explain what TokenLab does in one sentence.' }],
  });

  console.log(response.choices[0].message.content);
  ```

  <Note>
    Use `POST /v1/responses` only when you explicitly need Responses-specific behavior. It is not the default compatibility path across all models.
  </Note>
</CodeGroup>

## Key Features

<CardGroup cols={2}>
  <Card title="Multiple API Formats" icon="layers" href="/guides/api-formats">
    Use OpenAI, Anthropic, Gemini, or Responses-native formats with one account.
  </Card>

  <Card title="Agent-First Errors" icon="wand-magic-sparkles" href="/guides/agent-first-api">
    Structured hints help coding agents self-correct faster.
  </Card>

  <Card title="Integration Coverage" icon="toolbox" href="/guides/ide-sdk-compatibility">
    Connect IDEs, SDKs, frameworks, and chat apps with fewer provider-specific changes.
  </Card>
</CardGroup>

## Next Steps

<CardGroup cols={2}>
  <Card title="Quickstart" icon="rocket" href="/quickstart">
    Get your first request working in a couple of minutes.
  </Card>

  <Card title="API Reference" icon="book" href="/api-reference/introduction">
    Explore the endpoint-by-endpoint reference.
  </Card>

  <Card title="Integrations" icon="puzzle-piece" href="/integrations/openai-sdk">
    Start with SDK, IDE, and app integrations.
  </Card>

  <Card title="Models" icon="robot" href="https://tokenlab.sh/en/models">
    Browse current model availability and pricing.
  </Card>
</CardGroup>
