alert-as-code

alert-as-code is a skill for Claude Code, Codex from makifbaysal/tasktrooper. It costs 61 tokens per session (893 once invoked), scanned A, original, Apache-2.0.

A guide to keeping monitoring alerts in repository files or infrastructure configuration and sending them to TaskTrooper. It covers Prometheus rules, Google Cloud Monitoring policies, and Datadog monitors.

In plain words
What is it for?
Use it to create alert rules in code or Terraform, configure their conditions and routing, and send firing or resolved alerts to TaskTrooper.
Why use it?
It provides a defined path from a monitoring rule to an incident, while keeping alert-ingest tokens out of source code.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to create alert rules in code or Terraform, configure their conditions and routing, and send firing or resolved alerts to TaskTrooper.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/makifbaysal/tasktrooper/alert-as-code
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add makifbaysal/tasktrooper --skill alert-as-code
Clone the repo
git clone --depth 1 https://github.com/makifbaysal/tasktrooper

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for alert-as-code

README.md
[![agentmods](https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/alert-as-code/github.svg)](https://agentmods.dev/skills/makifbaysal/tasktrooper/alert-as-code)
Your own site
<a href="https://agentmods.dev/skills/makifbaysal/tasktrooper/alert-as-code"><img src="https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/alert-as-code/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for alert-as-code

Your own site · 80×15
<a href="https://agentmods.dev/skills/makifbaysal/tasktrooper/alert-as-code"><img src="https://agentmods.dev/badge/skills/makifbaysal/tasktrooper/alert-as-code.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 61 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 893 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00061 $0.00893
Opus 5.5 $0.00024 $0.00357
Sonnet 5.5 $0.00012 $0.00179
Haiku 4.5 $0.00006 $0.00089

Measured 1mo ago against content hash e78da3c5b65e, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

alert-as-code scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

catalog/agents/release-engineer/skills/alert-as-code/SKILL.md · 46 lines

How it starts

The opening of the file, as written. The whole thing — 46 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Alerts as code

TaskTrooper's own alert rules (propose_alert_rule) need nothing in the repository. Use this skill only when the team's alerting lives in code already, or the signal is only readable by the monitoring system itself. The alert must land here as an incident: every rule below notifies TaskTrooper's alert ingest URL, POST <server>/v1/alerts/ingest/<token>, which accepts Alertmanager, Sentry, Google Cloud Monitoring and a generic {title, severity, env, detail, fingerprint, resolved} JSON. A person creates the token under the repository's alert tokens; it is a secret — it goes in the monitoring system's secret store, never in the repository.

Prometheus (prometheus-operator)

apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
  name: checkout-api
spec:
  groups:
    - name: checkout-api.golden
      rules:
        - alert: CheckoutApiHighErrorRatio
          expr: |
            sum(rate(http_server_request_duration_seconds_count{service_name="checkout-api",http_response_status_code=~"5.."}[5m]))
              / sum(rate(http_server_request_duration_seconds_count{service_name="checkout-api"}[5m])) > 0.02
          for: 5m
          labels: { severity: high }
          annotations:
            summary: checkout-api error ratio above 2%

Alertmanager routes it with a webhook_configs receiver whose url is the ingest URL (from a secret file: url_file), send_resolved: true so recovery resolves the incident.

Google Cloud Monitoring (Terraform)

A google_monitoring_notification_channel of type = "webhook_tokenauth" with labels = { url = var.tasktrooper_ingest_url }, and a google_monitoring_alert_policy whose conditions.condition_threshold filters the service's metric (resource.type = "cloud_run_revision" AND resource.labels.service_name = "checkout-api"), with duration = "300s" and notification_channels naming that channel. Cloud Monitoring's incident payload is understood as is, opened and closed.

Read the full file on GitHub · 46 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 46 lines · 61 tokens per session scan A e78da3c5b65e

Subscribe to this mod's changes

alert-as-code is a skill published in the GitHub repository makifbaysal/tasktrooper (123 stars, last pushed today), licensed Apache-2.0. It adds 61 tokens to every session and 893 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-10-18.

Related

alert-as-code compared with skills from other repositories

alert-as-code next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
alert-as-codemakifbaysal/tasktrooperSkill123todayApache-2.0A61Claude Code, Codex
paperclip-create-agentpaperclipai/paperclipSkill118kyesterdayMITA44Claude Code, Codex
agent-topology-optimizerruvnet/rufloSkill83ktodayMITA21Claude Code
ramppaperclipai/paperclipSkill118kyesterdayMITA35Claude Code, Codex
paperclip-task-bridgepaperclipai/paperclipSkill118kyesterdayMITA27Claude Code, Codex
github-pr-workflowpaperclipai/paperclipSkill118kyesterdayMITA39Claude Code, Codex
agent-v3-memory-specialistruvnet/rufloSkill83ktodayMITA25Claude Code