What you need
- A provider account and an API key (a few providers, like a local Ollama server, work without one).
- For self-hosted or account-scoped providers (Azure OpenAI, Ollama, and similar), the base URL of your endpoint.
Three ways to set up
1. Guided terminal setup
monad init --no-input (or -y) seeds the home directory without prompting, for
scripted setups.
2. Explicit CLI commands
The CLI splits the surface into three nouns:provider, credential, and model.
All of them accept the global --json flag for machine-readable output.
Add or update a provider (the JSON shape is id, label, type, optional baseUrl
and extra):
3. Web UI
Runmonad on a fresh install and the browser opens the same setup flow. Afterwards,
Studio → Models and providers (/studio/models) adds providers, manages each
provider’s credentials, browses its models, and edits model profiles. See
the web UI.
Model profiles and the default model
A model profile is a named recipe that maps roles to concrete models:chat is the
required default route, and optional routes cover fast, vision, image, video,
speech, transcription, embedding, and memory. A profile can also carry
generation params and fallback targets. The fixed default profile is used whenever a
request does not name one.
Where things are stored
- Providers, their credentials, and profiles live in
agents.jsonunder Monad’s config directory. Provider credentials are native settings and do not use Agent Runtime Credentials or${secret:...}references. - Secrets never come back out either.
monad credential listshows only a masked token preview, andmonad credential addechoes just the new credential id. - The user is responsible for protecting the native settings file. The daemon and settings APIs continue to redact secrets from responses and logs.
Provider-specific notes
- Azure OpenAI requires a base URL for your resource
(
https://{resource}.openai.azure.com/openai/v1), and the model id is your Azure deployment name. - Amazon Bedrock requires an AWS region (prompted as an extra field) and a bearer
API key (
ABSK…). - Neither Azure nor Bedrock exposes a standard model-listing route, so when the connection test returns no models, the wizard falls back to manual model-id entry — type the model or deployment id yourself.
- Ollama and similar local servers treat the API key as optional; just point the base URL at your server.
Custom providers
A provider that is not in the catalog can still be added as a third-party atom pack: drop a module that exports aModelProvider into ~/.monad/atoms/providers/ and the daemon
picks it up without a restart. See
model-providers.md for the contract.
For contributors
When developing Monad itself, copy.env.example to .env.local and set
OPENROUTER_API_KEY; the dev environment seeds it as a working credential so live
runs work out of the box. This is a dev-only path — release builds configure
providers only through the flows above. See
CONTRIBUTING.md.