Skip to content

Integrating Roo Code ​

A powerful VS Code AI coding extension — an enhanced fork of Cline with multi-mode switching and custom modes. It connects to Calgine Tokens via the OpenAI-compatible API.

Roo Code (formerly Roo Cline) is an enhanced VS Code AI coding extension based on Cline, adding multi-mode switching (Code / Architect / Ask / Debug), finer-grained permission control, and custom modes.

Prerequisites ​

  1. Sign up at the Calgine Tokens Console.
  2. Go to Workspace → API Tokens, click "Add Token", and copy the API Key after creation (starts with sk-).
SettingValue
Base URLhttps://api.calgine.com.cn/v1
API KeyThe API token you created in the console

Installation ​

Search for Roo Code in the VS Code Marketplace and install it, or visit VS Code Marketplace.

Configuration Steps ​

  1. Open Roo Code settings: after installation, click the Roo Code icon in the VS Code activity bar to open the panel, then click the Settings (gear icon) in the top-right corner.
  2. Add an API Provider: click Add API Configuration (or edit an existing one):
    • API Provider: select OpenAI Compatible
    • Base URL: https://api.calgine.com.cn/v1
    • API Key: your Calgine Tokens API Key (sk-your-token)
    • Model: a model name, e.g., gpt-4o
  3. Click Save to save the configuration.
  4. (Optional) Configure an Anthropic model: to use Claude models, add another provider:
    • API Provider: select Anthropic
    • Base URL: https://api.calgine.com.cn/anthropic
    • API Key: your Calgine Tokens API Key
    • Model: claude-opus-4-5-20251101

Verify the Setup ​

In the Roo Code panel, switch to Ask mode and ask any question (e.g., "what is the entry file of this project?"). A normal response means the setup is complete.

Built-in Modes ​

Roo Code provides four built-in modes that you can switch between at any time:

ModeDescription
CodeDefault mode with full file read/write and command execution permissions
ArchitectRead-only; ideal for planning and architecture discussions without modifying code
AskQ&A mode focused on answering questions without executing actions
DebugDebug mode focused on locating and fixing issues

Each mode can use its own model, for example:

  • Code / Debug modes: claude-opus-4-5-20251101 (higher capability)
  • Ask / Architect modes: gpt-4o-mini (faster, lower cost)

Key Differences from Cline ​

FeatureClineRoo Code
Multi-mode switching—✓
Custom modes—✓
Per-mode model configuration—✓
Basic agent features✓✓
File read/write & command execution✓✓

Tip

Roo Code and Cline are highly similar in features and configuration. Existing Cline users can migrate directly — the setup is identical.

Next Steps ​

  • Cline: A lighter-weight VS Code AI coding extension
  • Providers & Routing: Configure official direct connections for a more stable experience