Headless CLI
The headless CLI runs a single prompt and exits — ideal for scripting, CI pipelines, and automation.
aether headless "Explain the main function in this project"| Flag | Type | Default | Description |
|---|---|---|---|
[PROMPT]... | positional | — | Prompt text (joined with spaces) |
-m, --model | string | — | Model spec (e.g., anthropic:claude-sonnet-4-5) |
-a, --agent | string | — | Named agent from settings.json |
-C, --cwd | path | . | Working directory |
--mcp-config | path | — | Path to MCP config file |
--system-prompt | string | — | Additional system prompt text |
--output | string | text | Output format: text, pretty, json |
-v, --verbose | flag | — | Verbose logging to stderr |
--events | string | — | Comma-separated event filter (e.g. tool_call,tool_result). Omit to emit all. |
Output formats
Section titled “Output formats”Plain text output — just the agent’s response.
aether headless --output text "What does this project do?"Formatted output with markdown rendering.
aether headless --output pretty "Summarize the README"Structured JSON output — useful for piping into other tools.
aether headless --output json "List all TODO comments" | jq '.response'Event filtering
Section titled “Event filtering”By default, headless mode emits all event types. Use --events to restrict output to specific event kinds:
aether headless --output json --events tool_call,tool_result "Refactor this module"Available event kinds:
| Event kind | Description |
|---|---|
text | Final text output |
thought | Extended thinking / reasoning |
tool_call | Tool invocation |
tool_result | Tool return value |
tool_error | Tool failure |
error | Agent-level error |
cancelled | Operation cancelled |
auto_continue | Agent auto-continuing |
model_switched | Model changed (alloying) |
tool_progress | Tool execution progress |
context_compaction_started | Compaction beginning |
context_compaction_result | Compaction completed |
context_usage | Token usage update |
context_cleared | Context was cleared |
Reading from stdin
Section titled “Reading from stdin”If no prompt is given and stdin is not a TTY, Aether reads the prompt from stdin:
echo "Explain this code" | aether headlesscat error.log | aether headless "What went wrong?"This is useful for piping file contents or command output into Aether.
Examples
Section titled “Examples”Quick question with a specific model
Section titled “Quick question with a specific model”aether headless -m anthropic:claude-sonnet-4-5 "What does the Config struct do?"Using a named agent
Section titled “Using a named agent”aether headless -a researcher "Find all API endpoints in this project"CI pipeline
Section titled “CI pipeline”aether headless \ -m anthropic:claude-haiku-4-5 \ --output json \ "Review the staged changes and list any issues" \ > review.jsonDifferent working directory
Section titled “Different working directory”aether headless -C /path/to/project "Summarize the architecture"Other subcommands
Section titled “Other subcommands”show-prompt
Section titled “show-prompt”Print the fully assembled system prompt (useful for debugging):
aether show-promptaether show-prompt --agent researcher| Flag | Type | Default | Description |
|---|---|---|---|
-C, --cwd | path | . | Working directory |
--mcp-config | path | — | Path to MCP config file (repeatable) |
--system-prompt | string | — | Additional system prompt text |
-a, --agent | string | — | Named agent to inspect |
agent new
Section titled “agent new”Initialize a new Aether project:
aether agent new [path]See Getting Started for details.
agent list
Section titled “agent list”List all agents in the project:
aether agent list [path]agent remove
Section titled “agent remove”Remove an agent from the project:
aether agent remove <name> [path]