OpenCode guides

Install OpenCode on Windows and connect it to UAI: an 8-step visual guide

Download OpenCode Desktop, add UAI as a custom OpenAI-compatible provider, and complete a working test chat in eight illustrated steps.

  • Custom endpoint
  • OpenCode Desktop
  • UAI API Key
  • Windows setup
On this page
  1. Before you start
  2. 1. Download OpenCode from the official site
  3. 2. Launch OpenCode and check the current model
  4. 3. Review the available models
  5. 4. Open the provider connection flow
  6. 5. Choose a custom OpenAI-compatible provider
  7. 6. Enter the provider name and Base URL
  8. 7. Enter the API key and model IDs
  9. 8. Save and select a UAI model
  10. A practical Luna and Sol workflow
  11. Troubleshooting
  12. Final check

Who this is for

Use this guide if you are setting up OpenCode Desktop on Windows for the first time and want to call models through a UAI API key. The eight screenshots take you from installation to a working test chat.

Before you start

Prepare a Windows computer and a UAI account with an API key. The UAI Base URL for OpenCode is:

https://uai99.com/v1

Create a separate key for OpenCode when possible. Separate keys make usage tracking, limits and revocation easier. These screenshots were captured from the August 2026 desktop interface; if a later release moves a control, look for the equivalent Model, Provider or Custom OpenAI-compatible provider entry.

1. Download OpenCode from the official site

Open the official OpenCode download page and choose the installer for your system. This guide uses the Windows x64 desktop build. Double-click the installer after it downloads.

Download OpenCode Desktop for Windows

Avoid installers from untrusted mirrors. The official page also offers macOS, Linux and terminal builds, although their installation flow may differ from these screenshots.

2. Launch OpenCode and check the current model

OpenCode starts on a new conversation. The active model appears near the bottom of the window. Click the small arrow beside its name to open the model picker.

Check the active OpenCode model

3. Review the available models

The picker lists models currently offered by OpenCode and models from connected providers. Any Free badges in the screenshot reflect the service at the time of capture; model names, quotas and eligibility can change.

Review the OpenCode model list

You can use an available model to explore the interface. Continue with the next step to use your own UAI balance and model access.

4. Open the provider connection flow

At the bottom of the model picker, select the entry for connecting more models. Depending on the release, it may be labelled Connect providers or Add provider.

Open the OpenCode provider settings

5. Choose a custom OpenAI-compatible provider

Select Custom OpenAI-compatible provider. UAI exposes an OpenAI-compatible API, so do not choose the OpenAI account sign-in flow or paste a UAI key into another vendor's dedicated form.

Choose a custom OpenAI-compatible provider

6. Enter the provider name and Base URL

Use these values:

  • Provider ID: uai99
  • Display name: UAI99
  • Base URL: https://uai99.com/v1

Enter the UAI99 provider and Base URL

Keep /v1 at the end. Using only https://uai99.com may send the client to the website instead of the OpenAI-compatible API.

7. Enter the API key and model IDs

Scroll down and paste the key created in your UAI account into the API key field. The current custom-provider screen requires model IDs to be added manually, and each ID must exactly match the UAI model list.

A practical starting pair is:

gpt-5.6-luna
gpt-5.6-sol

Enter the UAI API key and model IDs

Use gpt-5.6-luna for clear, repetitive work where speed and cost matter, and gpt-5.6-sol for planning, harder reasoning and high-value decisions. Availability still depends on your UAI key permissions, group, balance and upstream account status. Add other exact model IDs here when needed.

8. Save and select a UAI model

Submit the provider settings, return to a new conversation, open the model picker under UAI99, and choose one of the models you added. The screenshot shows a successful gpt-5.6-luna selection.

Select the newly added UAI model

Send a short test such as “Which model are you using?” before starting a larger task.

A practical Luna and Sol workflow

  • Start with Luna for routine edits, research organisation and clearly specified execution.
  • Switch to Sol for architecture, difficult debugging and decisions that require comparing trade-offs.
  • The selected model controls the upstream route, while one UAI key still shares its account balance and limits.
  • Start a fresh conversation for a new task so unrelated history does not keep increasing context usage.

Troubleshooting

  • Connection fails: confirm the URL uses HTTPS and ends in /v1.
  • Model not found: verify the complete model ID, including case and hyphens.
  • Balance, limit or 403 error: check the UAI balance, key status, group, model permission and upstream availability.
  • A new model is missing: the custom provider does not automatically populate every UAI model; return to the provider settings and add its ID manually.
  • A key was exposed: delete it in UAI and create a replacement. Never post a full key in chat, screenshots or public support tickets.

Final check

You should now see a UAI99 provider in OpenCode, select one of your manually added models, and complete a test chat. The OpenCode interface and built-in model list will evolve, but the UAI setup still comes down to three values: https://uai99.com/v1, a dedicated API key, and an exact model ID.


Originally published on UAI. This edition is formatted for uagents.net.