CLI (uptimyctl)
Manage incidents, maintenance windows, healthchecks, and workspace configuration from the command line.
Overview
uptimyctl is a command-line tool for managing your upti.my workspace. It provides full CRUD access to incidents, maintenance windows, healthchecks, and applications. It also supports exporting and importing your workspace configuration for infrastructure-as-code workflows.
Source code and releases are available at github.com/uptimy/uptimyctl.
Installation
Install uptimyctl using one of the following methods.
Quick Install (curl)
curl -sSL https://raw.githubusercontent.com/uptimy/uptimyctl/main/install.sh | bashGo Install
go install github.com/uptimy/uptimyctl@latestBuild from Source
git clone https://github.com/uptimy/uptimyctl.git
cd uptimyctl
go build -o uptimyctl .Authentication
uptimyctl supports three ways to provide your API key, listed in order of precedence.
| Method | Details |
|---|---|
| Flag | --api-key YOUR_KEY on any command |
| Environment variable | UPTIMYCTL_API_KEY=YOUR_KEY |
| Config file | ~/.config/uptimyctl/config.yaml (created by uptimyctl auth login) |
uptimyctl auth loginCommands Reference
Applications
uptimyctl applications list
uptimyctl applications get <uuid>Healthchecks
uptimyctl healthchecks list
uptimyctl healthchecks get <uuid>
uptimyctl healthchecks trigger <uuid>Incidents
uptimyctl incidents list
uptimyctl incidents get <uuid>
uptimyctl incidents create --title "API outage" --severity critical --public
uptimyctl incidents update <uuid> --status investigating
uptimyctl incidents add-update <uuid> --message "Root cause identified"
uptimyctl incidents resolve <uuid>
uptimyctl incidents statsMaintenance Windows
uptimyctl maintenances list
uptimyctl maintenances create --name "DB migration" --start "2026-03-01T02:00:00Z" --end "2026-03-01T04:00:00Z"
uptimyctl maintenances resolve <uuid>
uptimyctl maintenances delete <uuid>Schedulers (Regions)
uptimyctl schedulers list
uptimyctl schedulers get <uuid>Export & Import
Export your entire workspace configuration to a JSON file and import it into another workspace. This is useful for promoting configuration from staging to production or for backup purposes.
uptimyctl export -f config.json
uptimyctl import config.jsonOutput Formats
By default, uptimyctl outputs results in a human-readable table format. Use -o json for machine-readable JSON output.
uptimyctl incidents list -o jsonCI/CD Integration
Use uptimyctl in your deployment pipelines to create maintenance windows before deploys and resolve them afterward. This suppresses false alerts during expected downtime.
- name: Start maintenance window
run: |
uptimyctl maintenances create \
--name "Deploy ${{ github.sha }}" \
--start "$(date -u +%Y-%m-%dT%H:%M:%SZ)" \
--end "$(date -u -d '+30 minutes' +%Y-%m-%dT%H:%M:%SZ)"
env:
UPTIMYCTL_API_KEY: ${{ secrets.UPTIMYCTL_API_KEY }}
- name: Deploy application
run: ./deploy.sh
- name: Resolve maintenance window
run: uptimyctl maintenances resolve ${{ steps.maintenance.outputs.id }}
env:
UPTIMYCTL_API_KEY: ${{ secrets.UPTIMYCTL_API_KEY }}💡 Config Management
Use uptimyctl export and uptimyctl import for Terraform-style config management. Export from production, review changes, and import into staging or new workspaces.
Configuration
The config file is stored at ~/.config/uptimyctl/config.yaml and is created automatically by uptimyctl auth login. Environment variables and flags override config file values.
api_key: your-api-key-here
api_url: https://api.upti.my
output: table