Providers & routing

Connect a subscription

Use your Claude Pro or Max, ChatGPT, Kimi Code or Grok plan through OpenLLM by signing in to the vendor's own CLI on a device that runs the daemon.

Use the coding subscription you already pay for as a model source. The daemon on your device runs each request through the vendor's official CLI login. OpenLLM's servers never receive the token. Available on every plan. You need at least one device running the daemon. See Devices.

SubscriptionProvider idPlan you needSign-in methods
Claude Codeclaude_codeClaude Pro or Maxbrowser (default), device
CodexchatgptA ChatGPT subscriptionbrowser (default), device
Kimi Codekimi_codeA Kimi Code coding plandevice only
GrokgrokSuperGrok or X Premium+browser (default), device

Models use the provider id as their prefix, for example claude_code/claude-opus-5-5 or grok/grok-4.7. To list the ones you can use, call GET https://www.openllm.sh/v1/models.

Before you begin

  • Install OpenLLM and start the daemon on the device. See Install.

  • Install the vendor's CLI on the same device. The OpenLLM installer installs any missing ones in the background. To install one yourself, use the vendor's installer:

    curl -fsSL https://claude.ai/install.sh | bash             # Claude Code
    curl -fsSL https://chatgpt.com/codex/install.sh | bash     # Codex
    curl -fsSL https://code.kimi.com/kimi-code/install.sh | bash  # Kimi Code
    curl -fsSL https://x.ai/cli/install.sh | bash              # Grok

The daemon signs in inside its own folder under ~/.openllm/cli/<provider>/. It doesn't use or change the login in your own ~/.claude, ~/.codex, ~/.kimi-code, or ~/.grok. You sign in once more for OpenLLM, even if the CLI is already signed in on your machine.

Sign in from the app

  1. Open Providers and select the Subscriptions tab.
  2. If you have more than one device, select the device that should hold the login.
  3. Check the banner above the list. Sign-ins open a browser window here means the sign-in page opens on that device. Sign-ins give you a code to enter here means you get a link and a code to use from any browser. To switch, select Change.
  4. Select Connect on the subscription's row.
  5. In the Sign in to … dialog, select Open … sign-in and approve access on the vendor's page. Depending on the vendor, you then enter the code shown in the dialog on that page, or paste the code the page shows you into the dialog and select Submit.
  6. Wait for the dialog to confirm the sign-in. The row then shows your usage.

If the row says Not installed, install the vendor's CLI on that device. The row updates once the daemon detects it.

Sign in from the CLI

Run these on the device. They talk to the local daemon, not to OpenLLM's servers.

  1. Start the sign-in:

    openllm auth login claude_code

    Add --method device to get a link and code instead of a browser window. Kimi Code only supports --method device.

  2. Approve access on the vendor's page.

  3. If the vendor shows you a code to paste back, which Claude Code does with --method device, copy it and pipe it in with the flow id from the login output. The command reads the code from a pipe only, never from an argument or an interactive terminal. On macOS:

    pbpaste | openllm auth submit-code claude_code --flow-id <id>
  4. Confirm the sign-in:

    openllm auth status claude_code

Other commands: openllm auth providers lists each provider's sign-in methods, openllm auth usage shows cached usage, openllm auth refresh fetches it again, and openllm auth cancel <provider> stops a pending sign-in. Add --json for machine-readable output.

Sign out

  • In the app: select the connected subscription's row to open its usage, select Log out, then confirm.
  • In the CLI: run openllm auth logout <provider>.

This signs the daemon out of that vendor on this device only. Your OpenLLM account stays signed in.

Usage and limits

Each row shows how much of your tightest usage window you've used. Select the row to see every window and when it resets. To fetch fresh numbers, select the refresh button on the tab.

When a subscription hits its limit, the request moves to the next model in the chain. OpenLLM cools the model down for 3 minutes. While the vendor reports a window as used up, the daemon skips that subscription until the window resets. If the subscription is the last model in the chain, you get the vendor's own limit error. To keep working through a limit, add an API-key or included model after the subscription. See Fallback chains.

Check that it works

  1. Run openllm auth status and confirm the provider is signed in.

  2. Send a request to the daemon with one of the provider's models:

    curl http://127.0.0.1:8787/v1/chat/completions \
      -H "Content-Type: application/json" \
      -d '{"model": "claude_code/claude-opus-5-5", "messages": [{"role": "user", "content": "Hi"}]}'
  3. Check that the x-openllm-resolved-model response header names the subscription model.

From the hosted gateway, a subscription model only runs when it comes first in the chain and one of your devices is online. See Which source serves a request.

Common problems

MessageCauseFix
Not signed in on this device. Connect to sign in again.The device has no login for this vendor.Select Connect, or run openllm auth login <provider>.
The vendor client isn't available on this device. Install it, then try Connect again.The vendor's CLI isn't installed.Install it with the vendor's installer above.
This client needs a runtime the daemon can't find (often Node.js for an npm install). Install the native client, then try again.The CLI was installed through npm and its runtime is missing.Install the vendor's native build instead.
Couldn't unlock the secure store for this sign-in. Try Connect again.The daemon couldn't open the system keychain.Select Connect again.
Couldn't read the local credential store for this sign-in. Try Connect again.The CLI's credential file couldn't be read.Select Connect again.
The daemon couldn't confirm this sign-in in time. Try Connect again.The check after sign-in timed out.Select Connect again.
The daemon couldn't confirm this sign-in. Try Connect again.The check after sign-in failed.Select Connect again.
Local daemon stopped, unreachable, or timed out.openllm auth couldn't reach the daemon.Run openllm start, then retry.
403 subscription_requires_daemonThe chain has only subscription models and no online device can serve them.Start the daemon on a signed-in device, or add an API-key model to the chain. See Errors.

For other problems, see Troubleshooting.

Last updated on

On this page