Skip to content

CLI Reference

heartbit [run|chat|serve|daemon|submit|status|approve|result] <args>
heartbit <task> # shorthand for 'run'

When invoked without a subcommand, heartbit <task> is treated as heartbit run <task>.

Execute a task in standalone mode and exit.

Terminal window
heartbit run "Analyze the Rust ecosystem"
heartbit "Analyze the Rust ecosystem" # equivalent shorthand

Without --config, the CLI builds a single AgentRunner with all 14 built-in tools and reads configuration from environment variables. With --config, it loads the TOML file and builds an Orchestrator (or a direct AgentRunner when only one agent is defined).

Interactive multi-turn REPL. Default max turns: 200.

Terminal window
heartbit chat
heartbit chat --config heartbit.toml

Start a Restate HTTP worker for durable execution. Requires the restate feature flag.

Terminal window
heartbit serve --config heartbit.toml

Run the Kafka-backed daemon with HTTP API, cron scheduling, WebSocket, SSE, and optional Telegram bot. Requires the daemon feature flag.

Terminal window
heartbit daemon --config daemon.toml

Submit a task for durable execution via Restate. Returns a workflow ID.

Terminal window
heartbit submit "Write a report" --config heartbit.toml

Query the status of a durable workflow by its ID.

Terminal window
heartbit status wf_abc123 --config heartbit.toml

Send an approval signal to a durable workflow waiting for human-in-the-loop confirmation.

Terminal window
heartbit approve wf_abc123 --config heartbit.toml

Get the completed result of a durable workflow.

Terminal window
heartbit result wf_abc123 --config heartbit.toml
FlagDescription
--config <path>Path to a heartbit.toml configuration file. When omitted, the CLI uses environment variables for configuration.
--observability <level>Observability verbosity: production, analysis, or debug.
FlagAvailable onDescription
--approverun, chat, submitEnable human-in-the-loop approval. The CLI prompts before each tool execution round. Denied tools receive error results so the LLM can adjust and retry.
-v, --verboserun, chat, daemonEmit structured AgentEvent payloads as JSON to stderr. Useful for debugging and observability.
--bind <addr>serve, daemonAddress to bind the HTTP server (serve default: 0.0.0.0:9080).
--restate-url <url>submit, status, approve, resultRestate ingress URL (overrides config; defaults to http://localhost:8080).
Terminal window
# Standalone with env vars only
export ANTHROPIC_API_KEY=sk-...
heartbit "Summarize this project"
# With config file and approval
heartbit run "Deploy to staging" --config heartbit.toml --approve
# Interactive chat with verbose events
heartbit chat --config heartbit.toml -v
# Durable execution workflow
heartbit serve --config heartbit.toml &
heartbit submit "Generate quarterly report" --config heartbit.toml
# => wf_abc123
heartbit status wf_abc123 --config heartbit.toml
heartbit result wf_abc123 --config heartbit.toml