tai is the single command-line entrypoint for operating a server from the
terminal. It groups every surface — tools, presets, agents, connectors, keys,
schedules, and more — under one command tree. The per-group pages in this
section render from the live command tree, so their usage and options never
drift from the code.
tai --help, or tai <command> --help, for the same tree these pages
document.
Command groups
serve
Boot a server locally.
tools
Inspect and manage registered tools.
agents
Inspect and manage agents.
presets
Manage versioned tool presets.
connectors
Manage OAuth connectors.
plugins
Browse the marketplace and install plugins.
keys
Mint and manage API keys.
config
Inspect the resolved configuration.
doctor
Diagnose the local environment.
Global options
These flags apply to every command:There is no
--api-key VALUE flag: a key on the command line leaks through
ps and shell history. Supply the key through the environment, the config
file, --api-key-stdin, or the interactive prompt.Server URL resolution
tai resolves the server it talks to in this order, first match wins:
1
The --server flag
An explicit
--server URL on the command line.2
The TAI_SERVER_URL environment variable
Set it to point a shell session at a server.
3
The config file
The
server_url key in config.toml.4
The local default
http://127.0.0.1:8000 — the port is tai42-cli’s own default, which the
skeleton’s serve settings import, so tai serve and this default always
agree.API-key resolution
The API key resolves in this order, first match wins:1
--api-key-stdin
Read one line from stdin — the way to pass a key from a secret store.
2
The TAI_API_KEY environment variable
Set it for a shell session.
3
The config file
The
api_key key in config.toml.4
An interactive prompt
A hidden prompt, as a last resort.
Config file
tai reads a TOML config file at $XDG_CONFIG_HOME/tai/config.toml, or
~/.config/tai/config.toml when XDG_CONFIG_HOME is unset. It recognizes two
keys:
Local vs remote commands
The command ships in two packages.tai42-cli provides the tai command itself
and the remote groups — thin clients over the HTTP API — so pip install tai42-cli
operates a running server from anywhere. The local commands are added by
tai42-skeleton, which contributes them to the same tree when it is installed
alongside.
Most commands call the server’s HTTP API and so resolve a
server URL and an API key. A few run locally and never contact a server —
tai serve boots one, tai openapi emits the API spec offline, tai version
and tai doctor inspect the local environment, and tai completion installs
shell completion.
