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

# Connect Cline to Token Factory

> Configure Corvex Token Factory as an OpenAI Compatible provider in the Cline extension.

Corvex Token Factory connects to Cline through its **OpenAI Compatible** API
provider. Point the provider at the Token Factory Chat Completions endpoint, paste
your API key, and enter a model ID from the catalog. Cline sends OpenAI-shaped
requests with tool definitions, which both Token Factory models accept.

## Prerequisites

* A Token Factory API key. See [Authentication](/getting-started/authentication).
* [Cline](https://docs.cline.bot/) installed in VS Code, Cursor, JetBrains, or
  another supported IDE.
* A model ID from the [Token Factory catalog](/models/overview).

<Steps>
  <Step title="Choose your own API key">
    On first launch, Cline shows an onboarding screen titled **How will you
    use Cline?**. Select **Bring my own API key** and then **Continue**. The
    settings (gear) icon is inactive until onboarding is complete.

    If Cline is already configured, open the Cline panel, select the settings
    (gear) icon, and go to **API Configuration**.
  </Step>

  <Step title="Enter the Token Factory endpoint, key, and model">
    | Field    | Value                                                     |
    | -------- | --------------------------------------------------------- |
    | Base URL | `https://api.tokenfactory.corvex.cloud/v1`                |
    | API Key  | your `sk-corvex-...` key                                  |
    | Model ID | `zai-org/GLM-5.3` or `deepseek-ai/DeepSeek-V4-Flash-0731` |

    Enter the model ID exactly as the catalog lists it, including the
    `namespace/` prefix. Do not add a `corvex/` prefix.
  </Step>

  <Step title="Set the model limits">
    Cline does not read context limits from the endpoint and defaults to a
    128,000-token window. Expand **Model Configuration** and set the values for
    the model you selected.

    | Model                                | Context Window Size | Max Output Tokens |
    | ------------------------------------ | ------------------- | ----------------- |
    | `zai-org/GLM-5.3`                    | `393216`            | `32000`           |
    | `deepseek-ai/DeepSeek-V4-Flash-0731` | `1048576`           | `32000`           |

    **Supports Images** is checked by default; clear it, because neither model
    accepts image input. Leave **Enable R1 messages format** off. The Max
    Output Tokens value is a per-response budget; keep it well below the
    context window so there is room for input and tool results. The price
    fields only affect Cline's local cost display; the published rates are on
    the [Pricing](/pricing) page.
  </Step>

  <Step title="Verify the connection">
    Return to the chat, confirm the context bar shows the configured window
    (for example `393.2k`), and start a task in **Act** mode that reads a file
    in your repository. A completed tool call confirms the endpoint, key, and
    model ID.
  </Step>
</Steps>

## Compatibility notes

* **Model IDs.** Use the exact `id` from `GET /v1/models`. IDs are
  case-sensitive. See [Models](/models/overview).
* **Context length.** If a long task exceeds the model's window, the gateway
  returns `context_length_exceeded`. Start a new task or shorten the context. See
  [Errors](/reference/errors#context_length_exceeded-400).
* **Reasoning.** Both models reason before answering; Cline shows the
  reasoning under **Thinking**. Reasoning tokens count toward the Max Output
  Tokens value you configured. The **Reasoning Effort** setting is sent with
  the request; Token Factory applies the model's default reasoning behavior.

## Related documentation

* [Use the OpenAI SDK](/integrations/openai-drop-in) — the same endpoint from
  Python or TypeScript.
* [Connect Kilo Code](/integrations/kilo-code) — the same provider settings in
  a related extension.
* [Errors](/reference/errors) — authentication, rate-limit, and validation
  responses.
