Continue: config.yaml setup and turning off the Responses API
Set up Continue for uttapen in config.yaml: provider openai with apiBase, useResponsesApi false, explicit maxTokens, and chat and autocomplete roles.
Updated: 23 Sep 2026
Continue is a VS Code and JetBrains extension that reaches uttapen through provider: openai with a custom apiBase. Active development stopped in mid-2026 and the repository is read-only, but version 2 still works; this page was checked against its docs and source.
config.yaml
In ~/.continue/config.yaml:
name: uttapen
version: 0.0.1
schema: v1
models:
- name: Claude Sonnet 5
provider: openai
model: anthropic/claude-sonnet-5
apiBase: https://api.uttapen.ir/v1
apiKey: ${{ secrets.UTTAPEN_API_KEY }}
useResponsesApi: false
capabilities: [tool_use, image_input]
roles: [chat, edit, apply]
defaultCompletionOptions:
contextLength: 200000
maxTokens: 8192
- name: Qwen3 Coder (autocomplete)
provider: openai
model: qwen/qwen3-coder
apiBase: https://api.uttapen.ir/v1
apiKey: ${{ secrets.UTTAPEN_API_KEY }}
useResponsesApi: false
roles: [autocomplete]
defaultCompletionOptions:
maxTokens: 256
Things that bite if you skip them:
- Put
useResponsesApi: falseon every model. For ids that matchgpt-5throughgpt-9or the o-series, Continue posts to/responsesby default. uttapen doesn't serve that path, so you get404— and yes,openai/gpt-5-minimatches. - Always write
maxTokens. Without it Continue guesses from its own model table; for GPT-5-family names that guess can be 100,000 tokens, and uttapen reserves the cost of that ceiling before sending (pricing), locking up your balance for nothing. For names it doesn't recognise Continue's own default is 4096, which is too small for long edits. - Declare
capabilities. Continue infers tool support from the model name and doesn't recognise ids containing/. Withouttool_use, Agent mode loses native tools; withoutimage_inputit won't send images. - The key: put
UTTAPEN_API_KEYin~/.continue/.env(or the project's.continue/.env). The IDE extensions cannot read shell environment variables, so restart the IDE after creating the file. - Set
contextLengthto the model's real context, or lower; the numbers are on the model list.
Roles and cost
chat,editandapplygo to the main model:anthropic/claude-sonnet-5oropenai/gpt-5for quality,deepseek/deepseek-v3.2andqwen/qwen3-coderfor cheaper work.autocompleteuses the/v1/completionspath and fires as you type. Give it a cheap model and a smallmaxTokenssuch as256, or this one role will dominate your spend.- Session titles reuse the chat model with
maxTokens: 16, so they cost almost nothing. embed: for codebase indexing and@codebasesearch, use a model from the embeddings category; you pay for input tokens only.openai/text-embedding-3-smallis cheap and good enough; if your code comments and docs are mostly Persian, also tryqwen/qwen3-embedding-8borbaai/bge-m3. A chat model id in this role gets400 invalid_request.
- name: Text Embedding 3 Small
provider: openai
model: openai/text-embedding-3-small
apiBase: https://api.uttapen.ir/v1
apiKey: ${{ secrets.UTTAPEN_API_KEY }}
roles: [embed]
Checking that it works
Open the Continue panel, select the uttapen model and ask something short, then look for the request in Dashboard → Usage. If nothing arrives, test the key directly:
curl https://api.uttapen.ir/v1/chat/completions \
-H "Authorization: Bearer $UTTAPEN_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"openai/gpt-5-mini","max_tokens":20,"messages":[{"role":"user","content":"ping"}]}'
Troubleshooting
| Error | Cause in Continue | Fix |
|---|---|---|
404 not_found | useResponsesApi missing, so the call went to /responses | Add useResponsesApi: false |
404 model_not_found | model: doesn't match a real id | Copy the id from /en/models (the 404 also lists the closest ids it guessed, in uttapen.suggestions) |
401 invalid_api_key | The .env file wasn't read, or the IDE wasn't restarted | Put the value in ~/.continue/.env and restart the IDE |
402 insufficient_balance | No maxTokens, so the hold ballooned | Set maxTokens and top up |
429 | The key's rate limit, usually from frequent autocomplete | Use a lighter autocomplete model, or raise the key's rate_limit_rpm (rate limits) |
| Tools don't work in Agent mode | No capabilities declared | Add capabilities: [tool_use] |
If your available balance is under the cost of the full maxTokens, uttapen doesn't refuse the call: it trims the ceiling to what the balance covers (floor 1,024 tokens), returns the granted number in the X-Uttapen-Max-Tokens header, and the reply may end with finish_reason: "length". 402 appears only when even that floor is unaffordable.
Other tools are in integrations; error codes are in errors.
Sign up with a phone number, top up your wallet from 100,000 toman and create a key. Free models work without a top-up — up to 50 requests a day. Create an API key →