Claude Code skill

The happyuptime-cli npm package ships a Claude Code skill file. Once installed, Claude Code (and any agent built on the Claude Agent SDK) understands every CLI command, knows your config-as-code schema, and can drive the API directly.

Install

1

Install the CLI

bash
npm install -g happyuptime-cli
2

Install the skill

bash
happy skill install

This copies happyuptime-cli.md to ~/.claude/skills/.

3

Authenticate

bash
happy login

Stores an API key in ~/.happyuptime/config.json. Claude Code calls happy directly, so any session inherits your auth.

What the skill teaches Claude

  • Full command tree (monitors, incidents, alerts, status, speed-test, config)
  • Every flag and output shape (--json is highlighted for chaining)
  • The happyuptime.yml config-as-code schema, with on-call layers and restrictions
  • Conventions: incident severity values, monitor types, region codes
  • Common workflows: "create monitor + status page component + alert rule" in one prompt

Example prompts

"Create an HTTP monitor for api.acme.com/health with 60s interval in us-east and eu-west, and add it to my Acme status page."

"Look at incidents from the last 24 hours, find any that opened during a deploy, and draft a postmortem for the worst one."

"Set up a 24/7 on-call rotation with three layers: Primary (weekly handoff Mondays 9 AM ET), Secondary (weekly handoff Mondays), and Manager (override layer for escalation only)."

Claude will translate each into the appropriate happy invocations or YAML edits.

Without the skill

If you don't install the skill, Claude Code can still drive happy — the CLI's --help output is comprehensive — but the skill saves discovery turns and reduces hallucination on flag names.

Other agent runtimes

The skill file is plain markdown. Anthropic's Agent SDK, Cursor's MCP integration, and any system that loads .md system prompts can use it directly:

bash
cat ~/.claude/skills/happyuptime-cli.md

Drop the contents into your agent's system prompt or skills directory.

Ask a question... ⌘I