Run Cline on Stav
Point the Cline coding agent at Stav with one command — and keep its traffic on EU compute.
Cline is an open-source coding agent from Cline Bot Inc. It runs as a CLI and as a VS Code extension, edits files, runs commands and uses tools. Its "OpenAI Compatible" provider talks to any OpenAI-style API, so it runs on Stav with configuration only.
Point it at Stav and every agent turn is billed to your Stav credits, shows up in your request log, and follows your workspace policy. Pick an EU-served model and the work runs on EU compute.
Tested with the Cline CLI 3.0.70 on the Chat Completions API. The VS Code extension uses the same provider code and the same three settings, but was not tested in this run.
Before you start
- A Stav API key. See Authentication.
- Cline installed:
npm install -g clinefor the CLI, or the Cline extension from the VS Code marketplace.
Set it up
CLI
One command registers Stav as the provider, with your key and a model:
cline auth openai-compatible \
-k sk_stav_live_... \
-m zai-org/glm-5-2/scaleway-generative-apis \
-b https://api.stav.ai/v1
Cline saves it to ~/.cline/data/settings/providers.json. Check it with:
cline --json "Reply with exactly: STAV OK" | grep run_result
- Keep
/v1in the base URL. Cline adds/chat/completionsitself and does not add/v1. -mis remembered.cline -m <model> "task"switches the model for that run and saves it as the provider's model. Pass-magain to switch back, or runcline authagain.- Reasoning level.
cline --thinking high "task"sendsreasoning_effort: high. Without the flag Cline sends none and the provider's default applies.
VS Code extension
In the Cline settings panel:
| Field | Value |
|---|---|
| API Provider | OpenAI Compatible |
| Base URL | https://api.stav.ai/v1 |
| API Key | sk_stav_live_... |
| Model ID | zai-org/glm-5-2/scaleway-generative-apis |
Under Model Configuration, set the context window to the value on the model's catalogue page. Cline does not know Stav's model ids and assumes 128,000 tokens when you leave it empty, so it compacts your conversation at the wrong point on a larger model.
Pick a model
| You send | What happens |
|---|---|
creator/model/provider, e.g. zai-org/glm-5-2/scaleway-generative-apis | One Provider Endpoint, here in Paris. Use this to know where the work runs |
creator/model, e.g. mistral-ai/mistral-large-4 | Stav picks one of the model's Provider Endpoints. Without a region policy that can be outside the EU |
auto | Your default Router picks a model per request |
@your-workspace/router | A named Router you set up in Your workspace → Connect → Routers |
anthropic/…, openai/…, xai/… | Works, and is forwarded to that US provider. Stav adds governance, not EU compute |
To keep everything in the EU, set Compute region to EU only in Your workspace → Govern → Key policies → Reach. That applies to every request from every key, including auto and models you name. See Enforce a sovereignty floor.
Cline's model picker (/models in the CLI) lists the ids from Stav's /v1/models. Any id you type works too, including auto and @your-workspace/router.
What works
| Feature | Status |
|---|---|
| Chat, streaming | Works |
| Tool calls (file edits, shell, the full agent loop) | Works |
auto and named Routers | Work |
Reasoning level (--thinking) | Works on models that reason. On a model that cannot, Stav leaves the field out and names it in the X-Stav-Dropped-Params header. The request is answered as usual |
| OpenAI GPT-5.6 models with tools and a reasoning level | Work. Stav sends them to OpenAI's Responses API, where tools and reasoning go together. Sent to OpenAI directly, Cline gets a 400 for this combination |
| Claude and GPT models | Work, forwarded to the US provider |
Traffic that does not go through Stav
Cline sends its own usage telemetry to Cline's servers. That is Cline's traffic, not your model traffic. See Cline's documentation for how to turn it off.
Troubleshooting
| You see | Do this |
|---|---|
404 on every request | The base URL must end in /v1: https://api.stav.ai/v1 |
Invalid or revoked API key. | Check the key. Run cline auth openai-compatible -k <key> -m <model> -b https://api.stav.ai/v1 again |
| Cline runs on a model you did not expect | -m from an earlier run was saved. Pass -m again, or run cline auth again |
| Cline compacts the conversation early | Set the context window in the extension's Model Configuration to the value on the model's catalogue page |
| A request ran outside the EU | Pin the endpoint (creator/model/provider) or set Compute region in Your workspace → Govern → Key policies → Reach |
More error codes: Errors.
Check it worked
Open Your workspace → Monitor → Request log. Each agent turn is one row, with the model, Inference Provider, country and cost. See Request log and prompt capture.