Skip to main content
The devhelm CLI is a full-featured command-line tool for managing monitors, incidents, alert channels, and deploying config-as-code. Install it via npm and authenticate with an API token.

Install

npm install -g devhelm
Verify the installation:
devhelm --version

Authentication

The CLI resolves your API token from (in priority order):
  1. --api-token flag on any command
  2. DEVHELM_API_TOKEN environment variable
  3. Saved context in ~/.devhelm/contexts.json
# Option A: environment variable (recommended for CI)
export DEVHELM_API_TOKEN=dh_live_xxxxxxxx

# Option B: interactive login (saves to contexts.json)
devhelm auth login

Command reference

The CLI has 15 resource topics with full CRUD operations. Every command supports --output json for machine-readable output.

Config as Code

CommandDescription
devhelm validate <file>Validate config file syntax offline
devhelm plan -f <file>Preview changes without applying
devhelm deploy -f <file>Apply config changes
devhelm deploy --dry-run -f <file>Simulate deploy without applying
devhelm deploy force-unlockRelease a stuck deploy lock

Monitors

CommandDescription
devhelm monitors listList all monitors
devhelm monitors get <id>Get monitor details
devhelm monitors createCreate a monitor
devhelm monitors update <id>Update a monitor
devhelm monitors delete <id>Delete a monitor
devhelm monitors pause <id>Pause a monitor
devhelm monitors resume <id>Resume a paused monitor
devhelm monitors test <id>Run an on-demand check

Incidents

CommandDescription
devhelm incidents listList incidents
devhelm incidents get <id>Get incident details
devhelm incidents createCreate a manual incident
devhelm incidents resolve <id>Resolve an incident

Alert channels

CommandDescription
devhelm alert-channels listList alert channels
devhelm alert-channels get <id>Get channel details
devhelm alert-channels createCreate an alert channel
devhelm alert-channels update <id>Update a channel
devhelm alert-channels delete <id>Delete a channel
devhelm alert-channels test <id>Send a test notification

Other resources

TopicCommands
notification-policieslist, get, create, update, delete
tagslist, get, create, update, delete
environmentslist, get, create, update, delete
secretslist, set, delete
webhookslist, get, create, update, delete, test
resource-groupslist, get, create, update, delete
api-keyslist, create, delete
maintenance-windowslist, get, create, update, delete
status-dataservices, incidents, dependencies

Status and auth

CommandDescription
devhelm statusShow current monitor status overview
devhelm auth loginInteractive login
devhelm auth logoutClear saved credentials
devhelm auth tokenDisplay the current token
devhelm auth contextManage auth contexts

Global flags

FlagDescription
--api-tokenAPI token (overrides env var and saved context)
--api-urlAPI base URL (default: https://api.devhelm.io)
--output, -oOutput format: table, json, yaml
--no-colorDisable colored output
--verboseEnable debug logging
--helpShow help for any command

Exit codes

CodeMeaning
0Success
1Validation or command failure
2Authentication failure
10Changes pending (with --detailed-exitcode on deploy dry-run)

Getting help

Every command supports --help:
devhelm monitors create --help
devhelm deploy --help