Zero
Connect Zero, the terminal coding agent, to AI/ML API through its built-in provider preset.
About
Zero is an AI coding agent for your local terminal. It inspects a repository, edits files, and runs commands, either through its TUI or non-interactively with zero exec for scripts and CI.
AI/ML API is a built-in, recommended provider preset in Zero — it ships upstream, so there is nothing to patch or build from source. Zero also offers guided onboarding: you can create an AI/ML API account, top it up, and get a key without leaving the terminal.
Quick start
When to use AI/ML API with Zero
AI/ML API works well with Zero when you want:
one key and one base URL for many model providers
to switch models without re-configuring the agent
to onboard from the terminal, without opening a dashboard first
Prerequisites
Before you start, make sure you have:
Zero installed (see github.com/Gitlawb/zero)
an AI/ML API key from aimlapi.com/app/keys — or use the guided onboarding below
a model ID from aimlapi.com/models
The base URL is:
Need a key first? Use API Key Management.
Set up AI/ML API in Zero
Option 1 — Provider setup command
The preset fills in the base URL and default model. --set-active makes AI/ML API the provider Zero uses for the next session.
Option 2 — Setup wizard
Run zero and follow the setup wizard, or run it directly:
AI/ML API is listed as aimlapi.com and sorts to the top of the picker as a recommended provider.
Option 3 — Environment variable
Export the key before running setup and Zero picks it up automatically:
Guided onboarding
If you have no key yet, the onboarding flow in the TUI takes an email, creates an AI/ML API account, lets you choose a top-up amount, opens checkout in the browser, and saves the issued key into your Zero provider profile.
Model selection
Use exact AI/ML API model IDs. List what is available:
Good starting models
anthropic/claude-sonnet-5— the preset default, strong for codingopenai/gpt-5-5— strong general usegoogle/gemini-3-7-flash— lower latency and lower cost
For the full catalog, use All Model IDs.
Config checklist
Make sure these values are set:
API key variable:
AIMLAPI_API_KEYprovider ID:
aimlapi(shown as aimlapi.com)base URL:
https://api.aimlapi.com/v1(built in, no manual config needed)model ID: exact AI/ML API chat model ID
Troubleshooting
Links
All Model IDs
Last updated
Was this helpful?