BroadRouter
Get started

Use Kilo Code with BroadNet Inference (OpenAI Compatible provider)

Updated

In Kilo Code, open Settings, go to Providers and click Custom provider. Choose Provider API OpenAI Compatible, set Base URL to https://inference.broadnet.ai/v1, paste your BroadNet key, and add a model ID such as broadnet/glm-5.3 by hand. In kilo.json, use npm @ai-sdk/openai-compatible with options.baseURL and set limit.context and limit.output.

Kilo Code is an open-source coding agent for VS Code and the terminal. Any provider with an OpenAI Chat Completions API can be added as a custom provider. BroadNet Inference serves that format at https://inference.broadnet.ai/v1. BroadRouter is BroadNet’s own site; this guide follows Kilo’s provider docs as they read on 15 November 2026.

Setup in VS Code

  1. Get a key. Create a pay-as-you-go key in the BroadNet console, or use an unlimited plan key.

  2. Open Settings (gear icon) and go to the Providers tab.

  3. Scroll to the bottom and click Custom provider.

  4. Fill in the dialog:

    Field Value
    Provider ID broadnet
    Display name BroadNet Inference
    Provider API OpenAI Compatible
    Base URL https://inference.broadnet.ai/v1
    API key your BroadNet key
    Models add broadnet/glm-5.3 by hand (see below)
  5. Click Submit. The model appears in the model picker.

  6. Test it. Start a task such as “explain this file”. If it answers, the connection works.

Kilo tries to fill the model list from the endpoint’s /v1/models. BroadNet’s docs describe that endpoint as catalogue metadata for monitors, and when we checked it on 15 November 2026 it listed only the two transcription models. Type the chat model IDs yourself, and don’t pick the transcription models.

Setup in kilo.json (CLI, or for limits and tool flags)

Kilo’s dialog doesn’t set token limits or tool calling. Its docs point to the config file for that: ~/.config/kilo/kilo.json, or ./kilo.json in a project.

{
  "$schema": "https://app.kilo.ai/config.json",
  "model": "broadnet/glm-5.3",
  "provider": {
    "broadnet": {
      "npm": "@ai-sdk/openai-compatible",
      "env": ["BROADNET_API_KEY"],
      "options": {
        "baseURL": "https://inference.broadnet.ai/v1"
      },
      "models": {
        "glm-5.3": {
          "id": "broadnet/glm-5.3",
          "name": "GLM 5.3",
          "tool_call": true,
          "reasoning": true,
          "limit": { "context": 1048576, "output": 16000 }
        },
        "qwen3.8-27b": {
          "id": "broadnet/qwen3.8-27b",
          "name": "Qwen3.8 27B",
          "tool_call": true,
          "reasoning": true,
          "modalities": { "input": ["text", "image"], "output": ["text"] },
          "limit": { "context": 262144, "output": 16000 }
        },
        "deepseek-v4.1-flash": {
          "id": "broadnet/deepseek-v4.1-flash",
          "name": "DeepSeek V4.1 Flash",
          "reasoning": true,
          "limit": { "context": 1048576, "output": 16000 }
        }
      }
    }
  }
}
export BROADNET_API_KEY='your-broadnet-key'
  • The top-level model value, broadnet/glm-5.3, is the provider name plus the map key (glm-5.3), not the BroadNet ID. The id field is the model ID Kilo sends to BroadNet. Kilo’s docs say id defaults to the map key, so set it whenever the key isn’t the full BroadNet ID, as with the short keys here.
  • Always set limit.context and limit.output. For a custom model with no catalogue match, Kilo’s docs say both resolve to 0, which disables automatic context management. The output value of 16,000 is our suggestion; it leaves room for reasoning.
  • tool_call is left off DeepSeek V4.1 Flash on purpose: BroadNet’s docs don’t list tool calling for it. Add it after you have tested it.

Which model to pick

Task Model Notes
Agent coding with tools GLM 5.3 Tools and structured output listed; 1M context
Screenshots, Arabic Qwen3.8 27B Tools and images; 262K context
Long sessions, flat price DeepSeek V4.1 Flash Unlimited plans; tools not listed by BroadNet

Try the unlimited plan on a Meteor hour ($1) before a Full Moon month ($60).

Troubleshooting

  • “Invalid API Key” or 401. Paste the key again. Check that the key has allowance left, and that BROADNET_API_KEY is set in the process that runs Kilo.
  • “Model Not Found”. Check the ID matches BroadNet’s exactly, with the broadnet/ prefix. Paid models need a top-up; the $5 credit covers only broadnet/gemma-4-26b-a4b and the two Transcribe models.
  • Empty answer or “response may be incomplete”. Kilo warns when a reasoning model spends the whole output on reasoning. Raise limit.output. Why answers come back empty.
  • 429. A pay-as-you-go key allows 30 requests a minute and 4 in flight. See errors and retries.
  • Parallel subagents on a plan key wait or fail. A plan session runs one request at a time, so give each parallel subagent its own session.
  • Connection errors. The Base URL must end in /v1. If your key has an IP allow-list, add your machine’s address.

Questions

Why doesn't Kilo Code list BroadNet's chat models after I enter the Base URL?

Kilo fetches models from the endpoint's /v1/models list. When we checked on 15 November 2026, BroadNet's public /v1/models listed only its two transcription models, so add the chat model IDs by hand.

What should limit.context be for BroadNet models?

1048576 for GLM 5.3 and DeepSeek V4.1 Flash, 262144 for Qwen3.8 27B and 32768 for BroadNet Gemma 4 VL 26B. Kilo's docs say a missing limit resolves to 0 for custom models, which turns off automatic context management.

Can I use Kilo Code on the BroadNet unlimited plan?

Yes. The plans cover DeepSeek V4.1 Flash, ID broadnet/deepseek-v4.1-flash. Use the plan key as the API key. BroadNet's docs don't list tool calling for that model, so test an agent task first.

Should I pick OpenAI Compatible or OpenAI Responses as the Provider API?

OpenAI Compatible. BroadNet serves chat completions at /v1/chat/completions and does not list the Responses API.

Read as MarkdownAsk ChatGPTAsk ClaudeAsk Perplexity