Status & Doctor
anyy status answers "what is this profile's current runtime state?"
anyy doctor answers "does the local Anyy setup look valid?"
Run status when you want a quick dashboard in the terminal. Run doctor when a command fails, after editing config, or before filing a bug report.
Which Command Should I Run?
| Need | Command |
|---|---|
| Confirm profile, home, role, timezone, and subsystem state | anyy status |
| Check whether the resident service is installed and reachable | anyy gateway status |
| Validate local files and configuration | anyy doctor |
| Validate a candidate config file | anyy doctor --config PATH |
| Inspect one channel's config and secret refs | anyy channels doctor CHANNEL |
| Script the result | Add --json to the command that supports it. |
Status Command
anyy status
Typical human output:
◆ Anyy status
Gateway running
Profile default
Default role default
Home /Users/you/.anyy
Timezone Asia/Shanghai (host)
◆ Subsystems
Gateway listener open
Cron configured
Heartbeat configured
Storage ok
MCP configured
Status resolves the selected profile, reads local configuration, checks the gateway socket when reachable, and summarizes subsystems. If the gateway is running, status uses runtime data for listener, timezone, role, MCP, and storage details where available.
Useful flags:
anyy status --home PATH
anyy status --socket PATH
anyy status --json
Use --json for scripts and dashboards.
Doctor Command
anyy doctor
Doctor produces a list of checks with ok, warn, fail, or info status. It
is intentionally concrete: filesystem, profile, config, timezone, gateway
listener config, channels, cron, heartbeat, MCP, and storage.
Useful flags:
anyy doctor --home PATH
anyy doctor --config PATH
anyy doctor --json
--config PATH is useful when validating a candidate config file before putting
it in the profile home.
Checks
Filesystem
Doctor verifies that the resolved Anyy home exists and is a directory. Status prints the same resolved home so you can catch profile or environment selection mistakes quickly.
Configuration
Doctor loads and validates config.yaml unless you pass --config PATH. Unknown
top-level YAML fields and invalid enum values fail validation instead of being
silently ignored.
For field defaults, see Configuration Reference.
Gateway
There are two related commands:
anyy gateway status
anyy status
gateway status is service-oriented: it reports whether the resident service is
installed, running, reachable, which service host owns it, the home path, socket,
and version mismatch warnings.
status is runtime-oriented: it reports whether the gateway RPC status endpoint
is reachable and folds gateway listener details into the subsystem summary.
Doctor reports the configured gateway listener posture. An open TCP listener is reported as informational because it may be intentional, but it deserves review.
Providers
The current CLI doctor validates provider configuration as part of config validation. It does not make a live model request to every provider. Provider runtime failures usually show up when a turn runs, in setup/model commands, or in gateway runtime diagnostics.
If a model call fails, check:
anyy status
anyy setup model
anyy doctor
Then inspect the provider entry in config.yaml and the referenced secret.
What doctor does not prove
Doctor is a local diagnostics command. A passing result does not guarantee that every external provider, platform API, MCP server, or channel destination will accept the next live request.
Use provider setup, channel live-smoke tests, or subsystem-specific probes when you need to test an external service.
Channels
anyy doctor includes configured channel readiness probes. For a single
channel, use the channel doctor because it has channel-specific checks:
anyy channels doctor telegram
anyy channels doctor telegram --json
Channel doctor verifies the config block, required secret references, enablement, and live-smoke readiness. It does not send a chat message as part of the normal doctor run.
Cron
Doctor includes cron status probes. Use the cron command for operational detail:
anyy cron list
Cron jobs run inside the resident gateway, so a valid cron config still needs a running gateway to execute scheduled work.
Heartbeat
Heartbeat status is available directly:
anyy heartbeat status
anyy heartbeat status --json
Use it when status or doctor reports a missing, stale, disabled, or degraded
heartbeat. The command reads local heartbeat state and does not call the model.
MCP
Doctor reports MCP config and runtime readiness. For operational detail, use:
anyy mcp status
anyy mcp list
anyy mcp probe SERVER_ID
anyy mcp logs SERVER_ID
If an MCP server is configured for lazy startup, a status check may show configuration readiness before the server process has been launched.
Storage
Doctor checks the state database and raw storage policy. Status summarizes storage and raw backlog information when available.
Useful maintenance commands:
anyy maintenance checkpoint-state
anyy maintenance compact-state
anyy maintenance prune-inactive-sessions
JSON Output
Both commands support JSON:
anyy status --json
anyy doctor --json
status --json emits one object. doctor --json emits an array of check
objects:
[
{
"name": "filesystem",
"status": "ok",
"detail": "/Users/you/.anyy"
}
]
Machine consumers should key on name and status, not on human wording in
detail.
Remediation
Use this order when something looks wrong:
-
Confirm you are checking the intended profile.
anyy profile listanyy status -
Validate local files and config.
anyy doctor -
Check the resident service separately.
anyy gateway statusanyy gateway restart -
Run the subsystem-specific command.
anyy channels doctor telegramanyy mcp statusanyy cron list -
If state maintenance is involved, create a backup first.
anyy backup create
For common failure modes, see Troubleshooting.