Kilo Code, Cline and Roo Code are the most-used open-source AI coding agents for VS Code — and all three let you bring your own OpenAI-compatible API endpoint. That means you can run Claude inside your editor with a single sk-kunavo- key, at about 60% under Anthropic's list price on the mainline models. This guide is the three-field setup for each tool, which Claude model to pick per task, and what an agentic coding session actually costs.
Why these tools need an API key
Kilo Code, Cline and Roo Code don't bundle a model — every action (read a file, propose an edit, run a command, check the result) is an API call, billed per token. A chat subscription like Claude Pro does not cover this; the tools need direct API access. That's exactly the shape Kunavo serves: pay-as-you-go from a $5 top-up, one key for Claude, Gemini and GPT, and the balance never expires. Because agentic loops resend the growing task context on every step, the per-token rate is the single biggest lever on what a session costs — which is why the ~60% discount on claude-sonnet-4-6 compounds fast.
The three fields (all tools)
All three extensions share the same provider model — Kilo Code and Roo Code are forks in the Cline family — so the configuration is identical:
API Provider OpenAI Compatible
Base URL https://api.kunavo.com/v1
API Key sk-kunavo-... # create at kunavo.com/app/keys
Model ID claude-sonnet-4-6 # or claude-sonnet-5 / claude-haiku-4-5Get the key from the dashboard after signing up and topping up $5 — it's shown once, so store it right away. Full key management is covered in the Claude API key doc.
Kilo Code setup
- Install Kilo Code from the VS Code marketplace and open it from the sidebar.
- Open the extension settings (gear icon) and go to the Providers section.
- Set API Provider to OpenAI Compatible.
- Base URL:
https://api.kunavo.com/v1· API key: yoursk-kunavo-…key · Model:claude-sonnet-4-6. - Save, then ask it something small (“explain this file”) to confirm the wiring before letting it edit code.
Kilo Code supports per-mode model overrides (Architect / Code / Debug) — a good place to route planning to a stronger model and execution to a cheaper one.
Cline setup
- Install Cline and open its panel.
- Click the settings gear, and under API Provider choose OpenAI Compatible.
- Fill the same three values: base URL
https://api.kunavo.com/v1, your key, and the model IDclaude-sonnet-4-6. - If Cline asks for model metadata (context window, output cap), use the numbers from the model page.
Roo Code setup
Identical to the other two: Settings → Providers → API Provider → OpenAI Compatible, then base URL https://api.kunavo.com/v1, key, model ID. Roo Code's mode system (Code / Architect / Ask / Debug) also supports a different model per mode.
All three tools additionally ship a native Anthropic provider with a custom base-URL option. Pointing that at https://api.kunavo.com uses the native Messages API (/v1/messages) instead — useful because cache_control passes through untranslated and cached input bills at 10% of the input rate (see the prompt-caching doc). Either route works; the OpenAI-compatible one is the simplest to start with.
Which Claude model to pick
| Task | Model | Kunavo input / output (per 1M) |
|---|---|---|
| Everyday agentic coding (default) | claude-sonnet-4-6 | $1.20 / $6.00 |
| Near-Opus coding quality | claude-sonnet-5 | $2.10 / $10.50 |
| Hardest refactors and debugging | claude-opus-4-7 | $2.00 / $10.00 |
| Quick edits, commit messages, Q&A | claude-haiku-4-5 | $0.40 / $2.00 |
| Cheapest capable option | gemini-2-5-flash | $0.09 / $0.75 |
Because the model field is just a slug on the same endpoint, switching is a one-word change — no new key, no new provider config. Full rates for every model are in the Claude API pricing guide and on the pricing page.
What a session actually costs
Agentic tools are token-hungry by design: each step resends the system prompt, the task history and fresh file context. Realistic numbers at Kunavo rates:
| Unit | Tokens (input / output) | claude-sonnet-4-6 | At Anthropic list |
|---|---|---|---|
| One agentic step | 25,000 / 1,200 | $0.037 | $0.093 |
| A 20-step task | ~500k / ~24k | ~$0.74 | ~$1.86 |
| A heavy day (5 such tasks) | — | ~$3.72 | ~$9.30 |
The math, runnable:
# Kunavo Claude rates (USD per 1M tokens): (input, output)
RATES = {
"claude-haiku-4-5": (0.40, 2.00),
"claude-sonnet-4-6": (1.20, 6.00),
}
def step_cost(model, in_tokens, out_tokens):
i, o = RATES[model]
return in_tokens / 1_000_000 * i + out_tokens / 1_000_000 * o
# One agentic step: the tool resends the task context + file reads.
print(step_cost("claude-sonnet-4-6", 25_000, 1_200)) # -> $0.0372
# A realistic 20-step task (edit, run, fix, repeat):
print(20 * step_cost("claude-sonnet-4-6", 25_000, 1_200)) # -> ~$0.74Keeping the bill down
- Start new tasks instead of extending one forever. The tool resends the whole conversation each step, so a long-running task is quadratically expensive. Fresh task = fresh, small context.
- Route by mode. Kilo Code and Roo Code support a model per mode — Architect on
claude-sonnet-5, Code onclaude-sonnet-4-6, quick questions onclaude-haiku-4-5. - Use the native Anthropic route for caching. Cached input bills at 10% of the input rate — on a loop that resends a stable prefix every step, that's the biggest saving available (how it works).
- Watch per-key spend. Give the editor its own key with a spend limit in the dashboard, and check usage to see what a week of agentic coding really costs you.
FAQ
What base URL do I use?
https://api.kunavo.com/v1 with the OpenAI Compatible provider — in Kilo Code, Cline and Roo Code alike. For the native Anthropic provider, use https://api.kunavo.com (the SDK appends /v1/messages).
Can I use a Claude Pro / Max subscription?
No — chat subscriptions don't include API access, and these tools call the API directly. Pay-as-you-go from a $5 top-up is the right shape: no monthly fee when you don't code, and the balance never expires.
Which model should I set?
claude-sonnet-4-6 as the default; step up to claude-sonnet-5 or claude-opus-4-7 when a task defeats it, and down to claude-haiku-4-5 or gemini-2-5-flash for simple asks. Comparative positioning is in Claude vs GPT vs Gemini.
Is this different from using the OpenAI SDK?
Same mechanism: any OpenAI-compatible client works by changing base_url — the editor extensions just expose that as a settings field. The general pattern is covered in the OpenAI-compatible API guide.