Void with a Custom OpenAI-Compatible Endpoint
Void is an open-source editor forked from VS Code, built around the idea that you bring your own model. Connecting a gateway is one provider and one URL, but the URL is shared by three separate callers and each one can be pointed at a different model — so a half-finished setup looks like a working one.
**Add the provider as OpenAI Compatible, not OpenAI.** The picker offers both, and OpenAI is the one that hardcodes api.openai.com. Picking it gives you a working-looking form with no field that will ever reach your gateway.
https://aicomp.ai/v1).
Create one free →
This page covers the one field that matters, the three model roles behind it, and why autocomplete is the caller that decides what this setup costs per month.
The two fields
Settings → Models / AI Providers → Add Provider → OpenAI Compatible
| Field | Value |
|---|---|
| Base URL | https://gw.example.com/v1 |
| API Key | sk-your-gateway-key |
{
"provider": "openai-compatible",
"baseUrl": "https://gw.example.com/v1",
"apiKey": "sk-your-gateway-key"
}
Base URL is a root. Void appends the operation path itself, so the value stops at the version path your gateway serves under. Adding /chat/completions produces a doubled path and a 404; adding a trailing slash produces a double slash and the same 404.
The awkward part is that Void does not send a request when you save. There is no "test connection" result, no green tick, no error. Silence on save means nothing either way — the only real verification is typing in the editor and seeing whether autocomplete fires. That makes a mistyped URL feel like a permissions problem or a broken install, because nothing points at the URL.
One provider, three model slots
| Role | Trigger | What it sends |
|---|---|---|
| Autocomplete | Tab | the code around your cursor, continuously |
| Inline edit | Ctrl/Cmd+K | the selection plus your instruction |
| Chat | Ctrl/Cmd+L | what you dragged or @-referenced, plus history |
This is the part most setups miss. Adding a provider gives you a Base URL; it does not assign a model to any role. You then add the model in the Models section and select it — added-but-not-selected models sit in the list doing nothing.
The failure is quiet and specific: chat works, autocomplete does not. Nothing is wrong with the URL or the key, because chat is using both successfully. The empty slot is all that is missing.
Because the three roles are independent, they do not have to share a model — and that is the cost lever here. Autocomplete runs far more often than anything else in the editor and its answer is a few tokens. Chat runs rarely and its answer may be a whole file. Putting a fast, cheap model on autocomplete and a stronger one on chat is the single change that moves this page's monthly number the most, and it is a per-role setting rather than a per-provider one.
Why autocomplete dominates the bill
Inline edit and chat happen when you ask for them. Autocomplete happens whenever you pause, and each request carries the surrounding file so the model has something to complete from. The response is short; the request is not, and the request is the one you pay for.
That inverts the usual intuition about coding tools. In an agent that writes files — Claude Code or OpenCode — the output column is the expensive one because the model is producing files. In an editor where the model is completing a line you already started, the output is tens of tokens and the input is a chunk of your file, sent continuously.
A day of work on this page's workload is 260k input and 40k output tokens — 5.2M input and 0.8M output across 20 working days. At that ratio the input rate decides the month, and the model you put on the autocomplete slot matters more than the one you put on chat. Compare output vs input pricing before picking, and see cheapest models by workload shape for how a small-output workload reorders the table.
| Model | Gateway rate in / out per 1M tokens | One day | 20 days |
|---|---|---|---|
| gpt-5.6-sol | $2.5 / $15.00 | $1.25 | $25.00 |
| claude-sonnet-4-6 | $1.5 / $7.5 | $0.69 | $13.80 |
| deepseek-v4-flash | $0.22 / $0.66 | $0.08 | $1.67 |
| kimi-k3 | $1.5 / $7.5 | $0.69 | $13.80 |
| qwen3.8-max | $1.00 / $3.00 | $0.38 | $7.60 |
One day = 260k input + 40k output on this page's workload. 20 days = 5.2M input and 0.8M output. Rates checked 2026-10-12 — gateway rates move with upstream promotions, so verify the current number in your dashboard before committing to a budget.
Verifying the route
- Choose OpenAI Compatible, not OpenAI, in the provider picker.
- Fill Base URL with the version root — no trailing slash, no operation path.
- Add the model in the Models section, then select it. Adding alone leaves the slot empty.
- Assign a model to each of the three roles. An empty autocomplete slot fails silently while chat works.
- Type in a file and wait. Saving does not test; only a real request does.
- Put the cheap model on autocomplete. It is the high-frequency caller.
FAQ
FAQ
Chat works but autocomplete does nothing. Why?
The autocomplete role has no model assigned. It is a separate slot from chat — add the model and select it under that role.
Why does nothing happen when I save the provider?
Void does not probe the endpoint on save. There is no test request, so no message means nothing at all. Trigger autocomplete or send a chat message to find out whether it works.
Should Base URL include /v1?
Yes, if your gateway mounts its OpenAI-compatible API under /v1. Void appends the operation path, so the value should stop at the version root.
Can I use a different model for autocomplete than for chat?
Yes, and you should. Autocomplete is high-frequency with a tiny response; chat is low-frequency with a long one. The two roles want different rate shapes.
I picked the OpenAI provider and my key is rejected. Is the key wrong?
Probably not. The OpenAI provider points at api.openai.com, where a gateway key is genuinely invalid. Switch the provider type to OpenAI Compatible.
Is this cheaper than running a local model?
It depends on your volume. A local model removes the per-token cost and adds hardware and latency, and autocomplete is the most latency-sensitive caller in the editor — that is usually the deciding factor, not the price.
Related
- Cursor with a custom endpoint — the commercial editor Void is often compared to
- Windsurf with a custom endpoint — same three-role split, different settings layout
- Zed with a custom endpoint — another bring-your-own-model editor
- Base URL not working — the trailing-slash and doubled-path failures
- Output vs input pricing — which side your workload sits on
- Tools that take one endpoint — the full matrix