Sazabi
CLI

sazabi automations

Command reference for sazabi automations.

sazabi automations — Manage scheduled automations. Subcommands: list, get, create, update, enable, disable, runs.

sazabi automations

Manage scheduled automations

sazabi automations <subcommand>
sazabi automations list  # List all automations
sazabi automations get <automation-id>  # Get one automation
sazabi automations create deploy-nightly --script health --cron-expression '0 3 * * *'  # Create from a DB-backed script by name
sazabi automations update <automation-id> --cron-expression '0 4 * * *'  # Change the schedule
sazabi automations enable <automation-id>  # Enable an automation
sazabi automations disable <automation-id>  # Disable an automation
sazabi automations runs list <automation-id>  # List runs for an automation
sazabi automations runs get <automation-id> <run-id>  # Get one run
sazabi automations runs logs <automation-id> <run-id>  # Get captured logs for a run

sazabi automations list

List automations in the active project

sazabi automations list [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
--searchstringNoFilter by automation name (case-insensitive)
--statusstringNoFilter by status: active or paused
--sourcestringNoFilter by source: sazabi_managed or custom
--healthstringNoFilter by health: healthy, failing, or never_run
--sortstringNoSort by: name, last_run, failures, or runs
--limitstringNoMaximum number of automations to return (default: 50, max: 100)
--cursorstringNoPagination cursor from previous response
sazabi automations list  # List all automations
sazabi automations list --status paused  # List paused automations

sazabi automations get

Get one automation by ID

sazabi automations get <automation-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
sazabi automations get <automation-id>  # Get one automation

sazabi automations create

Create an automation

sazabi automations create <name> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
--descriptionstringNoHuman-readable description (required for log-match automations)
--script-idstringNoProject script ID to run (cron automations)
--scriptstringNoProject script name to run (cron automations)
--expression-idstringNoLog-match expression ID to bind (creates a log-match investigation automation)
--cron-expressionstringNoCron schedule expression
--timezonestringNoIANA timezone for the schedule
--timeout-secondsstringNoRun timeout in seconds (1-3600)
--enabledbooleanNoCreate the automation enabled
sazabi automations create deploy-nightly --script health --cron-expression '0 3 * * *'  # Create from a DB-backed script by name
sazabi automations create deploy-nightly --script-id <script-id>  # Create by script ID
sazabi automations create "Investigate Plain tickets" --expression-id <uuid> --description "When a new Plain ticket is created, investigate …"  # Create a log-match investigation automation

sazabi automations update

Update an automation

sazabi automations update <automation-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
--namestringNoNew automation name
--descriptionstringNoNew human-readable description
--clear-descriptionbooleanNoClear the automation description
--cron-expressionstringNoNew cron schedule expression
--timezonestringNoNew IANA timezone for the schedule
--timeout-secondsstringNoNew run timeout in seconds (1-3600)
sazabi automations update <automation-id> --cron-expression '0 4 * * *'  # Change the schedule

sazabi automations enable

Enable an automation

sazabi automations enable <automation-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
sazabi automations enable <automation-id>  # Enable an automation

sazabi automations disable

Disable an automation

sazabi automations disable <automation-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
sazabi automations disable <automation-id>  # Disable an automation

sazabi automations runs

Inspect automation runs

sazabi automations runs <subcommand>
sazabi automations runs list <automation-id>  # List runs for an automation
sazabi automations runs get <automation-id> <run-id>  # Get one run
sazabi automations runs logs <automation-id> <run-id>  # Get captured logs for a run

sazabi automations runs list

List runs for an automation

sazabi automations runs list <automation-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
--statusstringNoFilter by run status: running, succeeded, failed, timed_out, or cancelled
--limitstringNoMaximum number of runs to return (default: 50, max: 100)
--cursorstringNoPagination cursor from previous response
sazabi automations runs list <automation-id>  # List runs for an automation
sazabi automations runs list <automation-id> --status failed  # List failed runs

sazabi automations runs get

Get one automation run by ID

sazabi automations runs get <automation-id> <run-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
sazabi automations runs get <automation-id> <run-id>  # Get one automation run

sazabi automations runs logs

Get the captured logs for an automation run

sazabi automations runs logs <automation-id> <run-id> [options]
FlagTypeRequiredDescription
--tokenstringNoOverride token
--api-base-urlstringNoOverride API base URL
--jsonbooleanNoOutput as JSON
--project-idstringNoOverride active project ID
sazabi automations runs logs <automation-id> <run-id>  # Get captured logs for a run