startagent
A universal launcher for coding agents without vendor lock. Point Claude Code, Codex, OpenCode or Qwen Code at any Anthropic- or OpenAI-compatible provider: DeepSeek, Kimi/Moonshot, Z.ai GLM, MiniMax, or your own endpoint.
One Python file, standard library only, no build step. Your agent's own global config is never overwritten.
Why
A coding agent should not be tied to the vendor that happens to own your API
key. startagent keeps one small config per provider and launches the agent
with the right environment for that provider. Switching from DeepSeek to
Kimi is one command:
startagent --provider kimi
Requirements
- Python 3.11 or newer
- At least one agent CLI on
PATH:claude,codex,opencode,qwen - An API key from a supported provider
Install
The package is published as startagent-cli; the command it installs is
startagent.
Run without installing (needs uv):
uvx startagent-cli
Install as a command:
uv tool install startagent-cli
# or
pipx install startagent-cli
# or
pip install startagent-cli
From a clone (installs the local checkout into ~/.local/bin):
git clone https://github.com/easmith/startagent.git startagent
cd startagent
./install.sh # or: ./install.sh /custom/bin
Or copy startagent.py to any directory on your PATH as startagent and
make it executable:
cp startagent.py ~/.local/bin/startagent
chmod +x ~/.local/bin/startagent
Make sure ~/.local/bin is on your PATH.
Quick start
startagent
The first run asks for:
- the provider;
- the API key (hidden input; an existing
DEEPSEEK_API_KEYor~/.config/deepseek/api_keyis offered as a default); - the agent to run; if it is missing, the wizard offers to run its official installer right there;
- the main model, the fast model, and the reasoning effort;
- the last step: install
startagentitself to~/.local/bin/startagent. The command is shown before it runs;STARTAGENT_INSTALL_DIRchanges the target directory.
Later runs launch the saved configuration without asking anything.
Reconfigure with startagent --setup.
Commands
startagent run the saved agent
startagent --setup reconfigure
startagent --provider NAME switch provider and run
startagent --agent NAME switch agent and run
startagent claude|codex|opencode|qwen [args...]
startagent --check verify the key and endpoint (one-token request)
startagent --print print export lines for eval
startagent --list show the saved configuration
startagent <command> [args...] run any command with the provider environment
--print is useful if you want the environment in your current shell:
eval "$(startagent --print)"
The key is printed as $(cat ...), not in plain text.
Providers
| Provider | Anthropic endpoint | Default models |
|---|---|---|
| DeepSeek | https://api.deepseek.com/anthropic |
deepseek-flash[1m], deepseek-v4-pro[1m] |
| Kimi / Moonshot | https://api.moonshot.ai/anthropic |
kimi-k3[1m], kimi-k2.7-code |
| Z.ai GLM | https://api.z.ai/api/anthropic |
glm-5.3[1m], glm-5.3-flash |
| MiniMax | https://api.minimax.io/anthropic |
MiniMax-M3[1m], MiniMax-M3.1-Flash[1m] |
| Custom | your URL | your model IDs |
Every provider also has an OpenAI-compatible endpoint used by Qwen Code.
The [1m] suffix is a Claude Code convention for the 1M context window;
other agents receive the model ID without it.
Provider endpoints and model IDs change often. The wizard always offers a "custom model ID" option, and the "Custom" provider accepts any Anthropic-compatible base URL.
Agents
| Agent | How it is launched |
|---|---|
| Claude Code | ANTHROPIC_* environment variables |
| Codex | isolated CODEX_HOME with generated config.toml + models.json |
| OpenCode | isolated OPENCODE_CONFIG JSON, Anthropic provider override |
| Qwen Code | OPENAI_* environment variables |
If the selected agent is not installed, the wizard shows its official install command and asks before running it. Nothing is installed silently. Declining is fine: the config is still saved, and the wizard tells you the command to run later.
Codex is offered only for providers that expose the OpenAI Responses API
(DeepSeek and Z.ai GLM). The generated CODEX_HOME lives under
~/.config/startagent/agents/codex/<provider>/; your ~/.codex is not
modified. DeepSeek requires Codex 0.144 or newer.
Qwen Code is offered only when the provider has an OpenAI-compatible base URL.
Configuration
~/.config/startagent/
current.json provider and agent currently selected
deepseek.json provider settings (no secret)
deepseek.key API key, mode 600
agents/
codex/deepseek/ generated Codex config
opencode/deepseek/ generated OpenCode config
Override the config directory with STARTAGENT_CONFIG_DIR (useful for tests).
STARTAGENT_INSTALL_DIR changes where the wizard installs the script itself
(default: ~/.local/bin). The non-interactive equivalent is
./install.sh [directory].
Security
- API keys are stored in
<provider>.keywith mode600; the config directory is mode700. startagent --printnever prints the key itself.- No telemetry. The only network call is the provider you configured
(
--checksends a one-token request). - Agent configs are generated per provider, so switching providers does not touch the agent's global configuration.
Limitations
- Gemini CLI, GitHub Copilot CLI and Amazon Q Developer use their own protocols and are not supported.
- Kimi/Moonshot and MiniMax do not expose the OpenAI Responses API, so Codex is not offered for them.
- This is an unofficial launcher; provider APIs and model IDs may change.
Development
python3 startagent.py --version # run from the checkout
python3 -m unittest -v test_startagent.py
The tests use a temporary config directory and fake agent executables, so
they do not need API keys or installed agents. Real end-to-end checks are
manual: startagent --check, then launch each installed agent.
License
MIT. See LICENSE.
Metadata
Release files for startagent-cli 0.2.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| startagent_cli-0.2.3.tar.gz | 17.0 kB | Without provenance | Details for startagent_cli-0.2.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| startagent_cli-0.2.3-py3-none-any.whl | Python 3 | none | any | Details for startagent_cli-0.2.3-py3-none-any.whl |
Total release size: 32.0 kB
Release files / startagent_cli-0.2.3.tar.gz
| Download URL | startagent_cli-0.2.3.tar.gz |
|---|---|
| Size | 17.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
085a0057dfd8f7440e615eabd76f07f267332aa4363e4c37684a3c5bf9f9fb32
|
|
BLAKE2b-256 checksum How to use checksums |
faba1908f3b798a5996adf8a6c3ec3f70cd5999c8654f2805a06087ee4dd0195
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / startagent_cli-0.2.3-py3-none-any.whl
| Download URL | startagent_cli-0.2.3-py3-none-any.whl |
|---|---|
| Size | 15.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
cd3192c97aead9c7465c4a95a32376cdc057e21a5093aad10a6d973516840fa6
|
|
BLAKE2b-256 checksum How to use checksums |
f1ec8bd7d4c2aab8468a5075acb48b0404c13adeecd0c2591dc0b64830616e81
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.10.3 {"installer":{"name":"uv","version":"0.10.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for startagent-cli 0.2.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.