Skip to Content

cmdop provider

Manage custom LLM providers. Bare cmdop provider opens an interactive TUI manager. Subcommands exist for scripts and CI.

Interactive manager

cmdop provider

Opens a TUI showing all configured providers, the active one, and lets you add / edit / delete / set-default / test connectivity.

The interactive manager is the default surface — running cmdop provider with no subcommand opens it (rather than showing help). For scripted use, use the explicit subcommands below.

Subcommands

cmdop provider add # interactive add cmdop provider list cmdop provider set <id> # activate a provider cmdop provider default # reset to SDKRouter default cmdop provider delete <id> cmdop provider test <id> # send a test prompt cmdop provider edit-key <id> # rotate the API key on an existing provider

Add a provider

cmdop provider add walks through:

  1. Provider name (label).
  2. Base URL (any OpenAI-compatible endpoint).
  3. API key.
  4. Default model.
  5. Optional: list of allowed models (defaults to “any”).

Common targets:

ProviderBase URL
Z.AIhttps://api.z.ai/v1
MiniMaxhttps://api.minimax.chat/v1
DeepSeekhttps://api.deepseek.com/v1
Ollama (local)http://localhost:11434/v1
OpenRouterhttps://openrouter.ai/api/v1
OpenAIhttps://api.openai.com/v1

List providers

cmdop provider list
ID NAME ACTIVE BASE URL DEFAULT MODEL sdkrouter SDKRouter * api.cmdop.com - ollama-local Ollama (local) http://localhost:11434 qwen2.5-coder:32b deepseek DeepSeek https://api.deepseek.com/v1 deepseek-chat

Set a provider as active

cmdop provider set ollama-local

When a custom provider is active, cmdop chat and cmdop run route completions through it. SDKRouter aliases (@code, @balanced) resolve to the provider’s default model. Search, vision, and CDN still go through SDKRouter regardless.

Reset to SDKRouter

cmdop provider default

Test connectivity

cmdop provider test ollama-local

Sends a small prompt and reports latency + response. Useful for diagnosing “is my Ollama up?” without firing up a full chat.

Edit the API key

If a provider’s key rotates, you don’t need to delete and re-add:

cmdop provider edit-key deepseek

Delete a provider

cmdop provider delete old-provider

TTY requirement

The interactive manager requires a TTY. In CI / non-interactive contexts use the explicit subcommands. Running cmdop provider over a pipe will fail loudly rather than silently dropping into help text.

Where providers are stored

~/.cmdop/providers.yaml (mode 0600). Same directory as tokens — don’t check it into git.

Last updated on