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

# Integrations overview

> Connect third-party tools such as Claude Code, Codex, Cursor and Gemini CLI to DreamTo: which protocol to pick, what Base URL to enter, and how to write model IDs.

DreamTo serves the native OpenAI, Anthropic and Gemini protocols side by side. Most AI coding tools and chat clients can use DreamTo models after you change three things: the API address, the API Key and the model ID.

## Before you start

**1. Create an API Key**

Sign in to the [DreamTo console](https://www.dreamto.ai/console) and create a key on the **API Keys** page. It looks like `sk-xxxx`. We recommend a separate key per tool so you can track usage and disable each one independently.

**2. Find the model ID**

In the [Model Marketplace](https://www.dreamto.ai/models), find the model you want and copy its **model ID** (not its display name). You can also list the models available to your key with `GET /v1/models`:

```bash theme={null}
curl https://api.dreamto.ai/v1/models \
  -H "Authorization: Bearer $DREAMTO_API_KEY"
```

**3. Pick the protocol and address for your tool**

Use the table below to fill in the Base URL in your tool. Detailed steps for each tool are in the left navigation.

## Protocols and Base URLs

| Protocol | Models | Base URL to enter in the tool | Address the tool ends up calling |
| - | - | - | - |
| OpenAI Chat Completions | GPT, DeepSeek, Kimi, GLM, Grok, etc. | `https://api.dreamto.ai/v1` | `POST /v1/chat/completions` |
| OpenAI Responses | GPT family | `https://api.dreamto.ai/v1` | `POST /v1/responses` |
| Anthropic Messages | Claude family | `https://api.dreamto.ai` (most tools: no `/v1`) | `POST /v1/messages` |
| Gemini generateContent | Gemini family | `https://api.dreamto.ai` (no `/v1beta`) | `POST /v1beta/models/{model}:generateContent` |

> [!NOTE]
>
> Whether to include `/v1` depends on what the tool appends to the address. OpenAI-style tools usually append only `/chat/completions` or `/responses`, so include `/v1`. The official Anthropic and Gemini SDKs append `/v1/messages` and `/v1beta/models/...` themselves, so enter only the domain. Each tool page states which form to use.

For authentication, every protocol accepts `Authorization: Bearer <API Key>`. The `x-api-key` header sent by Anthropic clients and the `x-goog-api-key` header or `?key=` parameter sent by Gemini clients also work. See [Authentication](https://docs.dreamto.ai/en/authentication.md).

## Tools

> [card] [Claude Code](https://docs.dreamto.ai/en/integrations/claude-code.md)
>
> Anthropic's command-line coding assistant, connected via `ANTHROPIC_BASE_URL`.

> [card] [Codex CLI](https://docs.dreamto.ai/en/integrations/codex.md)
>
> OpenAI's command-line coding assistant; add a custom provider in `config.toml`.

> [card] [Gemini CLI](https://docs.dreamto.ai/en/integrations/gemini-cli.md)
>
> Google's command-line assistant, connected via `GOOGLE_GEMINI_BASE_URL`.

> [card] [Cursor](https://docs.dreamto.ai/en/integrations/cursor.md)
>
> AI code editor; override the OpenAI Base URL and use custom models.

> [card] [CC Switch](https://docs.dreamto.ai/en/integrations/cc-switch.md)
>
> Desktop config switcher that manages providers for Claude Code, Codex and Gemini CLI in one place.

> [card] [OpenCode](https://docs.dreamto.ai/en/integrations/opencode.md)
>
> Open-source terminal coding assistant; add a provider in `opencode.json`.

> [card] [OpenClaw](https://docs.dreamto.ai/en/integrations/openclaw.md)
>
> Open-source personal AI assistant; configure it under `models.providers` in `openclaw.json`.

> [card] [Hermes Agent](https://docs.dreamto.ai/en/integrations/hermes.md)
>
> Open-source agent from Nous Research; configure a custom endpoint in `~/.hermes/config.yaml`.

> [card] [Cline / Roo Code](https://docs.dreamto.ai/en/integrations/cline.md)
>
> VS Code coding agent extensions; choose the OpenAI Compatible provider.

> [card] [Continue](https://docs.dreamto.ai/en/integrations/continue.md)
>
> VS Code / JetBrains extension; set `apiBase` in `config.yaml`.

> [card] [TRAE](https://docs.dreamto.ai/en/integrations/trae.md)
>
> AI-native IDE; add a custom model under Settings → Models.

> [card] [WorkBuddy](https://docs.dreamto.ai/en/integrations/workbuddy.md)
>
> Desktop office agent; add a custom model in the model picker.

> [card] [Cherry Studio](https://docs.dreamto.ai/en/integrations/cherry-studio.md)
>
> Desktop AI client; add a custom provider under Model Services.

> [card] [LobeChat / NextChat](https://docs.dreamto.ai/en/integrations/lobechat-nextchat.md)
>
> Open-source web chat apps; just change the OpenAI API address.

> [card] [SDK quickstart](https://docs.dreamto.ai/en/integrations/sdks.md)
>
> Minimal examples for the official OpenAI, Anthropic and Google GenAI SDKs (Python, Node.js, cURL).

## FAQ

> [accordion] 401 Unauthorized
>
> The API Key is missing, wrong or deleted. Check that the key was copied in full with no leading or trailing spaces or quotes. Some tools read an environment variable of the same name first (such as `OPENAI_API_KEY` or `ANTHROPIC_API_KEY`); make sure an old value isn't overriding your setting.

> [accordion] 404 or "model not found"
>
> There are usually two causes. Either the Base URL is wrong and the request hits a path that doesn't exist (for example an extra or missing `/v1`, giving `/v1/v1/chat/completions`), or the model ID is a display name or misspelled. Copy the exact model ID from the Model Marketplace.

> [accordion] Protocol mismatch
>
> Call each model through a protocol it supports: Claude uses Anthropic Messages, Gemini uses generateContent, and GPT can use Chat Completions or Responses. Putting a Claude model ID into an "OpenAI compatible" config, or a Gemini model ID into an Anthropic config, may fail or lose features.

> [accordion] Streaming stalls or breaks
>
> All four DreamTo protocols support streaming. If the tool stops midway, first check whether a local proxy or corporate gateway is buffering the SSE response, then raise the tool's request timeout (such as `API_TIMEOUT_MS` for Claude Code).

> [accordion] What to provide when troubleshooting
>
> Every response carries an `X-Request-Id` header. When contacting support, include that value, the request time and the model ID. **Do not send your API Key.** See [Errors](https://docs.dreamto.ai/en/errors.md) for the error format.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.