Skip to main content

Agents

Each agent has its own idea of how a provider is configured, so alc translates one provider list into whatever the agent you are launching expects. This page is what it sets, agent by agent.

Every agent also runs on one codex login through the Codex bridge; alc --codex <agent> is the same command throughout, so it is not repeated below.

Claude Code

claudeinstall · accepts an Anthropic-compatible endpoint.

Claude Code gets a settings file (--settings) holding the endpoint, the model variables and the picker, and fetches its credential through apiKeyHelper from alc claude-credential; on Claude Code's own login the login answers and the file carries the endpoint and the model. See Background sessions. An Ollama profile gets more — see Local models.

alc claude
alc --openrouter claude

Codex CLI

codexinstall · accepts the OpenAI Responses API.

alc sets --model and, when configured, --config model_reasoning_effort=<level>. A non-Codex provider also gets a full model_providers.<id>.* override (base_url, wire_api=responses, requires_openai_auth=false) and, when it needs a key, env_key plus ALC_PROVIDER_API_KEY. An Ollama profile gets --oss --local-provider ollama instead.

Codex CLI is the one agent that never goes through the bridge: a codex-kind profile runs it directly on your native login.

alc codex
alc --openrouter codex

OpenCode

opencodeinstall · accepts any API-compatible provider.

alc sets an inline OPENCODE_CONFIG_CONTENT JSON variable, writing no file, naming the model as <provider-id>/<model>. The provider id is the kind name for Anthropic, OpenAI, OpenRouter and Ollama profiles, and alc-<profile> for every other kind.

A full provider.<id> object goes into the same JSON: always for Ollama, vLLM, custom and the newer presets; for the first four only when the base URL has been pointed away from that kind's default. options.apiKey appears only when the profile needs a key, so a default Ollama profile gets none.

alc opencode
alc --zai opencode

Pi

piinstall (npm install -g @earendil-works/pi-coding-agent) · accepts Anthropic, OpenAI or OpenAI-compatible.

alc merges an alc-<profile> entry into $PI_CODING_AGENT_DIR/models.json (default ~/.pi/agent/models.json) and passes --provider, --model and, with an effort configured, --thinking.

The merge is additive: alc only ever writes keys named alc-*, the write is atomic, and a models.json that fails to parse makes alc refuse rather than replace it. An anthropic profile with no stored key skips the merge entirely and launches with --provider anthropic, so Pi uses its own subscription login.

alc pi
alc --minimax pi

Copilot CLI

copilotinstall · accepts OpenAI- or Anthropic-compatible.

alc sets COPILOT_PROVIDER_TYPE, COPILOT_PROVIDER_BASE_URL, COPILOT_PROVIDER_API_KEY (skipped for keyless providers) and COPILOT_MODEL. Pure BYOK: no file is written and no GitHub Copilot login is needed.

alc copilot
alc --deepseek copilot

Goose

gooseinstall · accepts OpenAI- or Anthropic-compatible.

alc sets GOOSE_PROVIDER, GOOSE_MODEL, an optional GOOSE_FAST_MODEL, and the BYOK variables that provider needs: OPENROUTER_API_KEY, OLLAMA_HOST, ANTHROPIC_API_KEY (plus ANTHROPIC_HOST when it differs from goose's default), or the OPENAI_* set.

With no arguments of your own, alc appends goose's interactive session subcommand; pass your own and they are forwarded exactly as given.

alc goose
alc --groq goose

Qwen Code

qweninstall · accepts OpenAI-, Anthropic- or Gemini-compatible.

alc sets --auth-type <anthropic|openai|gemini> and --model, plus the matching environment: ANTHROPIC_*, GEMINI_API_KEY for the google kind, or OPENAI_*.

alc qwen
alc --xai qwen

Kimi Code CLI

kimiinstall · accepts OpenAI- or Anthropic-compatible.

alc reads your existing config (~/.kimi/config.toml, or ALC_KIMI_CONFIG), merges in providers.alc-<profile>, models.alc-<profile> and default_model, and writes the merged result to a new temp file (mode 0600) passed as --config-file. Your real config is never written to, and the temp file is deleted when Kimi exits, so the key touches disk only for the life of that process. Passing your own --config-file disables all of this.

alc kimi
alc --moonshot kimi

Binary overrides

Point any agent at a specific binary instead of resolving it from PATH:

AgentOverride env
Claude CodeALC_CLAUDE_BIN
Codex CLIALC_CODEX_BIN
OpenCodeALC_OPENCODE_BIN
PiALC_PI_BIN
Copilot CLIALC_COPILOT_BIN
GooseALC_GOOSE_BIN
Qwen CodeALC_QWEN_BIN
Kimi Code CLIALC_KIMI_BIN