genmux API is now generally available. Read the docs →
genmux API

Blog

Cline and Roo Code with an OpenAI-compatible provider

5 min readWritten by genmux API Team


Cline and Roo Code are the two most used agent extensions for VS Code, and both have an "OpenAI Compatible" provider that takes a base URL, a key and a model id. That is the whole integration with genmux. This post lists the exact fields, which of the ten text models to put in them, when to switch on image support, and the two limits of emulated function calling you should know about before a long session.

The provider fields

Open the extension's settings (the gear icon in the Cline or Roo panel) and fill in:

FieldValue
API ProviderOpenAI Compatible
Base URLhttps://api.genmux.tech/v1
API Keyyour genmux key (nb_live_...)
Model IDdeepseek-v4-flash (or any model from the list below)
Supports streamingon
Supports imagesoff — on only for the vision models below
Supports computer use / browseroff

Both extensions call GET /v1/models on the base URL to offer a dropdown; genmux returns the standard {"object":"list","data":[…]} shape, so the ids appear there without typing. Roo Code also has context-window and max-output fields — leave them at the defaults; genmux clamps a too-large max_tokens to the model's own limit rather than failing the request.

There is no need for a custom header or a "legacy format" switch: the endpoint is the plain OpenAI chat-completions dialect, errors come in the OpenAI {"error":{…}} envelope, and a 401 shows up in the extension exactly as it would with an OpenAI key.

Which models to pick

Cline and Roo carry their own tool protocol inside the system prompt, and newer builds can switch to the API's native function calling. Either way, choose from the seven models where genmux's function calling is switched on — they are the ones measured on agent-style tasks:

ModelRole in the editorVisionPrice per 1M tokens (in / out)
deepseek-v4-flashDefault: fast, cheap, 1M context—$0.198 / $0.594
deepseek-v4-proPlan mode, large refactors—$0.594 / $1.782
deepseek-v3Budget option, 64K context—$0.198 / $0.594
qwen3-maxStrong generalist with screenshotsyes$1.08 / $5.40
qwen3-7-maxTop Qwen tier for hard tasksyes$2.25 / $6.75
doubao-seed-2-proReasoning plus vision, 256K contextyes$0.782 / $3.755
doubao-seed-2-codeCoding-tuned, UI from screenshotyes$0.782 / $3.755

Cline's Plan/Act split and Roo's modes both let you assign different models per mode. The pairing that works: deepseek-v4-pro for Plan (or Roo's Architect mode) and deepseek-v4-flash for Act (Code mode). Planning is a few long prompts; acting is dozens of short ones, and the cheap model does those fine.

qwen3-6-flash, doubao-seed-2-lite and doubao-seed-2-mini are chat-only: a request with tools returns 400 tools_unsupported, and they were not evaluated on agent tasks. Leave them for the chat sidebar.

Vision: screenshots into the task

When "supports images" is on, both extensions attach pasted or dragged screenshots as image_url content parts. Four of the tool models accept them: qwen3-max, qwen3-7-max, doubao-seed-2-pro and doubao-seed-2-code. A screenshot of a broken layout with "make the sidebar look like this" is a good use — doubao-seed-2-code is tuned for exactly that UI-from-image job, and Qwen3-Max reads error dialogs and charts reliably.

Two things to keep in mind. Images are billed as prompt tokens at a fixed rate per image on top of the text, so a session that pastes a screenshot on every turn costs noticeably more than one that pastes it once. And switching "supports images" on for a DeepSeek model does not fail loudly — the model simply cannot see the image and will say so, or worse, guess. Keep the toggle per model, not global.

The honest limits

  • It works on seven of ten models, and only those seven. The measured pass rates on 20 agent-style tasks: DeepSeek V4 Pro 20/20, V4 Flash 19/20, V3 19/20, Qwen3.7-Max 19/20, Qwen3-Max 19/20, Doubao Seed 2.0 Pro 19/20, Doubao Seed 2.0 Code 18/20. The full table and how it was measured are in the emulated function calling post.
  • tool_choice: required is advisory. When an extension insists on a tool call, a model can still answer in prose. In the eval, V3, Qwen3-Max and Doubao Code each did that once. In practice you see it as the agent explaining what it would do instead of doing it; a "go ahead" gets it moving. Pro and Flash did not do it at all.
  • One call per turn is the norm. Models rarely batch parallel calls, so a change across five files is five round trips. That is how the extensions already loop, so it is a latency observation, not a correctness one.
  • Tool definitions cost prompt tokens — about 40 per tool plus its schema. Cline's and Roo's tool sets add on the order of 1–2K tokens per request; the conversation history is a far bigger cost, which is why "start a new task" is the most effective cost control in either extension.

Reading the cost

Every request the extension makes is a genmux job. The extension shows its own token estimate; the actual charge is usage.cost on the response, and GET /v1/generations?capability=text.chat lists the day's calls with cost per call.

Getting started

Provider "OpenAI Compatible", https://api.genmux.tech/v1, a key, deepseek-v4-flash — and Cline or Roo Code is editing files through genmux. Every client in one place is the coding agents page; terminal-first setups are covered for OpenCode and aider; the chat endpoint reference, including tools and response_format, is in the docs.

About the author

Written by genmux API Team — genmux API.

More about us