GitHub Copilot
GitHub Copilot Chat in VS Code can use models from your own provider, a feature GitHub calls bring your own key. This guide adds Entrim as a Custom Endpoint so Entrim models show up in the Copilot Chat model picker.
Models you add this way work without a Copilot plan or a GitHub sign-in. Inline suggestions still come from Copilot's own models and need a GitHub account.
Prerequisites
To follow this guide, you need:
- An Entrim account with Model API credits
- An Entrim API key
- VS Code, updated to the latest version, with GitHub Copilot Chat
Set up VS Code
1. Open the language models editor
Open the Chat view, open the model picker and select Manage Language Models (the gear icon). You can also run Chat: Manage Language Models from the Command Palette.
2. Add Entrim as a custom endpoint
Select Add Models, then Custom Endpoint, and answer the prompts:
- For the group name, enter
Entrim. The model picker lists your Entrim models under this name. - Enter a display name and paste your Entrim API key.
- For the API type, choose Chat Completions.
3. Add the model
VS Code then opens chatLanguageModels.json. Make the Entrim entry look like this and save the file:
[
{
"name": "Entrim",
"vendor": "customendpoint",
"apiKey": "${input:entrimApiKey}",
"apiType": "chat-completions",
"models": [
{
"id": "zai-org/GLM-5.3-Flash",
"name": "GLM-5.3-Flash",
"url": "https://api.entrim.ai/v1/chat/completions",
"toolCalling": true,
"vision": true,
"thinking": true,
"supportsReasoningEffort": ["low", "medium", "high"],
"reasoningEffortFormat": "chat-completions",
"maxInputTokens": 1048576,
"maxOutputTokens": 131072
}
]
}
]
If VS Code already filled in apiKey from the key you entered, keep its value. An ${input:...} value like the one above makes VS Code ask for the key and store it securely, so the key never sits in the file.
| Field | Meaning |
|---|---|
url | The full chat completions endpoint, including /chat/completions |
toolCalling | The model can call tools. Copilot needs this to use the model in agent mode. |
vision | The model accepts images |
thinking, supportsReasoningEffort | The model reasons before it answers and accepts reasoning_effort |
maxInputTokens, maxOutputTokens | The model's limits, from max_input_tokens and max_output_tokens in GET /v1/models |
4. Pick the model
In the Chat view, open the model picker and choose GLM-5.3-Flash under Entrim. You can use it in ask mode and, because toolCalling is on, in agent mode.
Troubleshooting
| Problem | Fix |
|---|---|
| The model isn't in the picker | Check that chatLanguageModels.json is saved and valid JSON, and that the entry uses "vendor": "customendpoint". |
401 errors | The API key is missing or invalid. Open Manage Language Models and enter the key again. |
404 errors | url must be the full endpoint, https://api.entrim.ai/v1/chat/completions. |
400 "Invalid model name" | id doesn't match an Entrim model ID. Compare it with GET /v1/models, including upper and lower case. |