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: false on every model. For ids that match gpt-5 through gpt-9 or the o-series, Continue posts to /responses by default. uttapen doesn't serve that path, so you get 404 — and yes, openai/gpt-5-mini matches.
  • 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 /. Without tool_use, Agent mode loses native tools; without image_input it won't send images.
  • The key: put UTTAPEN_API_KEY in ~/.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 contextLength to the model's real context, or lower; the numbers are on the model list.

Roles and cost

  - 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

ErrorCause in ContinueFix
404 not_founduseResponsesApi missing, so the call went to /responsesAdd useResponsesApi: false
404 model_not_foundmodel: doesn't match a real idCopy the id from /en/models (the 404 also lists the closest ids it guessed, in uttapen.suggestions)
401 invalid_api_keyThe .env file wasn't read, or the IDE wasn't restartedPut the value in ~/.continue/.env and restart the IDE
402 insufficient_balanceNo maxTokens, so the hold balloonedSet maxTokens and top up
429The key's rate limit, usually from frequent autocompleteUse a lighter autocomplete model, or raise the key's rate_limit_rpm (rate limits)
Tools don't work in Agent modeNo capabilities declaredAdd 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.

No API key yet?

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 →