CLI
CLI overview
The planned agenetix CLI for command-line MCP server management, tool editing, and agent configuration.
The
agenetixCLI is planned but not yet available. This page describes the intended design so you can plan your workflows.
The agenetix CLI will be a single binary covering everything available in the dashboard and API. It supports both interactive humans (OAuth login) and headless automation (service account tokens).
Authentication#
Two auth modes, matching tools like gh, gcloud, and stripe:
flowchart LR
Interactive["Interactive\nagenetix auth login"] --> PKCE["OAuth 2.1 PKCE\nBrowser flow"]
PKCE --> Keychain["OS keychain storage"]
Headless["Headless\nService account token"] --> ClientCreds["OAuth 2.0\nClient Credentials"]
ClientCreds --> Env["AGENETIX_TOKEN env var"]Token resolution order: --token flag, AGENETIX_TOKEN env var, keychain entry, error.
Profiles#
Named profiles for multi-environment workflows:
# ~/.config/agenetix/config.toml
[profile.default]
endpoint = "https://api.agenetix.com"
org = "org_abc123"
[profile.staging]
endpoint = "https://staging.agenetix.com"
org = "org_staging"Override per command with AGENETIX_PROFILE, AGENETIX_ENDPOINT, AGENETIX_ORG.
Key workflows#
| Workflow | Command |
|---|---|
| Generate from OpenAPI | agenetix mcp generate --openapi <spec> |
| Connect existing MCP | agenetix mcp connect --url <url> |
| Edit tool rules | agenetix tool patch <server> <tool> --when-to-use "..." |
| Refresh OpenAPI | agenetix mcp refresh-openapi <server> --dry-run |
| Create agent | agenetix agent create --name "Support Agent" |
| Interactive chat | agenetix agent chat <agent-id> |
Output modes#
All commands accept --output table|json|yaml and --quiet. Default is human-friendly table.
See Command reference for the full specification.
