Nebul Docs

GitHub Copilot Chat

Add Nebul models to GitHub Copilot Chat in VS Code with the Custom Endpoint provider.

GitHub Copilot Chat is the chat experience built into VS Code. Its Custom Endpoint provider connects any OpenAI-, Responses-, or Anthropic-compatible API, so you can put Nebul models into the Copilot model picker and use them for chat and agent sessions with your own API key.

Prerequisites

Add Nebul as a custom endpoint

  1. Open the model picker in the Chat view and select the gear icon (Manage Language Models), or run Chat: Manage Language Models from the Command Palette.
  2. Select Add Models, then select Custom Endpoint from the provider list.
  3. Enter a group name, such as Nebul. This is the label shown in the model picker.
  4. Enter a display name and your Nebul API key. The key is stored in VS Code's secret storage.
  5. Select the API type: Chat Completions, Responses, or Messages. Any of the three works with Nebul; Chat Completions is the usual choice.
  6. VS Code opens a chatLanguageModels.json file. Replace its contents with your model entry and save:
[
  {
    "name": "Nebul",
    "vendor": "customendpoint",
    "apiKey": "${input:nebulApiKey}",
    "apiType": "chat-completions",
    "models": [
      {
        "id": "zai-org/GLM-5.3",
        "name": "GLM 5.3",
        "url": "https://api.inference.nebul.io/v1/chat/completions",
        "toolCalling": true,
        "maxInputTokens": 1048576,
        "maxOutputTokens": 16384
      }
    ]
  }
]

Field notes:

  • vendor must be customendpoint.
  • apiType sets the protocol: chat-completions, responses, or messages. For the Anthropic-style Messages API, use https://api.inference.nebul.io/v1/messages as the model URL; VS Code then authenticates with an x-api-key header, which Nebul accepts. See Messages API.
  • The url should be the full endpoint URL, including the API path, as shown. If you omit the path, VS Code inserts /v1 and the path for the model's API type.
  • toolCalling: true is required for the model to appear in agent mode. Pick a model with supports_function_calling in the catalog.
  • maxInputTokens and maxOutputTokens come from /v1/model/info. You can set contextWindow instead of maxInputTokens, and VS Code derives it.

If the model does not appear in the picker immediately, restart VS Code.

Community extension alternative

The OAI Compatible Provider for Copilot extension offers the same idea with per-model settings in settings.json instead of chatLanguageModels.json, including per-model base URLs and request parameters.

Run it

Open the Chat view, pick the Nebul model from the model picker, and send a message. Requests go from VS Code directly to api.inference.nebul.io with your key. Usage appears under the API key's project in AI Studio.

Agent mode needs the model's tool calling, which is why toolCalling: true matters above. For tool-calling request shapes, see Function Calling & Tools.

Troubleshooting

  • Model missing from the picker: restart VS Code, and confirm toolCalling: true on the model entry. Models without tool calling are hidden from agents.
  • 401 responses: the stored API key is wrong or revoked. Update it in the Language Models editor with the gear icon next to the provider.
  • 404 responses: check the model url. It must be https://api.inference.nebul.io/v1/chat/completions (or the /v1/messages equivalent for the Messages API type).
  • Model not found: use the exact model ID from the Model Catalog. Only models enabled for your project work.
  • Copilot Business or Enterprise policies: an administrator can disable bring-your-own-key. If Custom Endpoint is missing, ask your admin to allow the Bring Your Own Language Model Key in VS Code policy.

Data and telemetry

With a custom endpoint, chat requests go to Nebul, not to GitHub's model providers. Some features still require a GitHub account and work as usual: inline suggestions, semantic search, and anything built on embeddings.

VS Code itself sends telemetry to Microsoft unless you turn it off. In settings.json:

{
  "telemetry.telemetryLevel": "off"
}

For how Nebul treats the requests it receives, see Privacy & Security.

On this page