OpenCode setup

OpenCode, powered by one API

Point OpenCode at unlimitedai.sh and switch between 29 frontier models without juggling separate provider accounts. OpenCode talks to /v1/chat/completions.

Copy-ready setup

One-liner
UAI_API_KEY='sk-xx' OPENCODE_CONFIG_CONTENT='{"provider":{"uai":{"npm":"@ai-sdk/openai-compatible","name":"unlimitedai.sh","options":{"baseURL":"https://api.unlimitedai.sh/v1","apiKey":"{env:UAI_API_KEY}"},"models":{"z-ai/glm-5.3":{}}}}}' opencode -m 'uai/z-ai/glm-5.3'

Step by step

  • →Install: npm i -g opencode-ai
  • →Paste the one-liner
  • →Switch models with -m 'uai/MODEL_ID'

Which model to pick

  • →Heavy refactors and planning: anthropic/claude-opus-5 or openai/gpt-6-luna
  • →Fast everyday edits: deepseek/deepseek-v4.1-flash or z-ai/glm-5.3-flash
  • →Long context reading: moonshotai/kimi-k3 or qwen/qwen3.8-max
  • →All 29 Models plan only: anthropic/claude-opus-5.5, openai/gpt-6.1-sol, openai/gpt-6-astra and more

Questions

Does OpenCode need a special plugin?
No. OpenCode supports custom API endpoints natively; you only change the base URL, key and model ID.
Where do I get my API key?
Your key is delivered after you buy any plan — 28 days or a 24-hour pass.