agent command provides functionality to create, manage, and run agents that analyze incidents and alerts, leveraging the infrastructure knowledge graph and LLM capabilities.
Usage
Commands
Subcommand: create
Creates a new agent configuration file based on available templates and opens it in your default editor.Usage
Options
Subcommand: delete
Deletes an existing agent.Usage
Subcommand: edit
Opens an existing agent configuration file in your default editor.Usage
Subcommand: list
Lists all available agents in your Unpage instance.Usage
Subcommand: quickstart
Launches an interactive wizard to quickly set up an incident response agent.Usage
Subcommand: route
Tests which agent would be selected to analyze a given payload based on your routing configuration.Usage
Subcommand: run
Executes an agent with a provided payload and displays the analysis.Usage
Options
Examples: Running an Agent with a Test Payload
Subcommand: schedule
Starts the agent scheduler daemon, which runs agents on a periodic schedule according to their cron expressions. This enables “background chores” like cost optimization reports, security audits, and other maintenance tasks that should run automatically on a schedule.Usage
Options
Configuring Scheduled Agents
To schedule an agent, add aschedule section to your agent YAML file with a cron expression:
Scheduled agents run with no input payload, so make sure your agent prompt specifies how to get any required inputs (e.g., via tool calls).
Cron Expression Format
Unpage supports multiple cron formats for maximum flexibility:Standard 5-field format (minute precision)
Extended 6-field format (second precision)
Cron Aliases
For convenience, you can use these aliases instead of full cron expressions:@hourly- Run every hour (equivalent to0 * * * *)@daily- Run daily at midnight (equivalent to0 0 * * *)@weekly- Run weekly on Sunday at midnight (equivalent to0 0 * * 0)@monthly- Run monthly on the 1st at midnight (equivalent to0 0 1 * *)@yearlyor@annually- Run yearly on January 1st at midnight (equivalent to0 0 1 1 *)
Examples
Standard 5-field patterns (minute precision)
Extended 6-field patterns (second precision)
Using aliases
Scheduler Functionality
When running, the scheduler:- Loads all agents from your profile that have a
scheduleconfiguration - Sets up cron jobs for each scheduled agent
- Runs agents automatically according to their schedules
- Logs the output of each agent run
Subcommand: serve
Starts the Unpage Agent server, which listens for incoming alerts and routes them to appropriate agents. This creates a webhook receiver that can process alerts from various systems (like PagerDuty) and intelligently selects the most appropriate agent to analyze them.Usage
Options
Server Functionality
When running, the agent server:- Exposes a
/webhookendpoint that receives alert payloads as JSON via POST requests - Automatically selects the most appropriate agent based on the incoming payload
- Processes the alert using the agent’s configuration and LLM capabilities
- Returns an analysis of the alert

