Local setup
The avant CLI signs you in, fetches your workspace credentials and writes the config for your harness. Supported harnesses are Claude Code, Codex, OpenCode, Pi and Oh My Pi.
Install
Section titled “Install”macOS and Linux:
curl -fsSL https://avant.codes/install.sh | shWindows PowerShell:
irm https://avant.codes/install.ps1 | iexUpdate later with avant update.
Sign in
Section titled “Sign in”avant loginThis opens the dashboard in your browser. Credentials are stored in ~/.avant/credentials.json. If your email isn’t allowed yet, login fails with not_allowed. Ask an organization admin to invite you.
Pick the organization to work in:
avant org listavant org use <org-name-or-id>Connect a workspace
Section titled “Connect a workspace”avant workspace listavant workspace use <workspace-name-or-id>use gets you a credential for the workspace and configures the harnesses you choose. To skip the prompt, pass them:
avant workspace use my-team --harness claude-code,codexYou’re only offered harnesses that work with the workspace’s models:
| Harness | Needs | Works with |
|---|---|---|
| Claude Code | The Messages API (Claude models) | Anthropic, Google Vertex AI, AWS Bedrock, Azure AI Foundry |
| Codex | The Responses API | OpenAI, and AWS Bedrock or Azure models that list Responses |
| OpenCode, Pi, Oh My Pi | Messages or Chat Completions | Every provider except TypeSafe |
Each provider page has a table of models and the harnesses that can use them.
use also installs the workspace’s skills and connectors and writes its tool, command and path denies into the harness. See Policy.
Restart the harness afterwards.
Keys or tokens
Section titled “Keys or tokens”What use sets up depends on the workspace’s auth mode:
-
Workspace keys. The CLI generates your personal key and writes it into the harness config.
avant workspace generate-key <workspace>rotates it. The old key stops working right away. -
Short-lived tokens. No key is stored. Claude Code runs
avant tokenitself to get a fresh token:{ "apiKeyHelper": "avant token -w <workspace-id>" }Codex, OpenCode, Pi and Oh My Pi only read a fixed key, so they talk to a local relay on
127.0.0.1:4141that adds a fresh token to each request. Start it once and it runs at every login:Terminal window avant sync startavant syncalso checks every 5 minutes for workspace changes, such as allowed models or permissions, and re-applies them to the harnesses the workspace is active for. Pass--no-configto run only the relay.avant sync statusshows whether it runs and when each workspace last synced.avant sync stopstops it.
Connect with a key from the dashboard
Section titled “Connect with a key from the dashboard”If an admin gave you a key, or you generated one on the workspace’s Connect page:
avant workspace connect ws_<workspaceId>_<secret>Use a workspace without a harness
Section titled “Use a workspace without a harness”Point any Anthropic or OpenAI SDK at the proxy and use your key or token as the API key:
export ANTHROPIC_BASE_URL=https://proxy.avant.codesexport ANTHROPIC_API_KEY=ws_...
export OPENAI_BASE_URL=https://proxy.avant.codes/v1export OPENAI_API_KEY=ws_...The proxy accepts the credential as Authorization: Bearer, x-api-key or X-Workspace-Token. Which APIs a workspace serves depends on its upstream, and the Connect page lists them.
Switch, disconnect, sign out
Section titled “Switch, disconnect, sign out”| Command | Does |
|---|---|
avant workspace use <other> |
Points your harnesses at another workspace. |
avant workspace disconnect |
Removes Avant from your harness configs. The workspace stays cached. |
avant logout |
Clears all local credentials and unwires every harness. |