Use VS Code chat with the Bokyaa router
Bokyaa team ·
VS Code chat can use a custom endpoint as a language model. The Bokyaa router serves the OpenAI Chat Completions format, so it can be that endpoint.
Before you start
- In the Bokyaa app, open Router and add at least one provider connection.
- Create a router key. Router keys need a plan that includes them; see the pricing page. The key is shown once, so copy it then.
Add the endpoint
Open the Command Palette and run Chat: Manage Language Models, choose Add Models, then Custom Endpoint. VS Code opens chatLanguageModels.json. Add:
[
{
"name": "Bokyaa router",
"vendor": "customendpoint",
"apiKey": "${input:bokyaaRouterKey}",
"apiType": "chat-completions",
"models": [
{
"id": "auto",
"name": "Bokyaa auto",
"url": "https://api.bokyaa.com/v1/chat/completions",
"toolCalling": true,
"vision": false,
"maxInputTokens": 128000,
"maxOutputTokens": 16000
}
]
}
]
VS Code asks for the key (sk-bky-...) when it resolves the input variable, so the key stays out of the file. Set maxInputTokens and maxOutputTokens to the limits of the model you route to. The model name auto lets the router choose.
Source
code.visualstudio.com/docs/copilot/customization/language-models, the custom endpoint section, read 2026-11-08. Tools change; if a step no longer matches, follow the tool's own page.