Shipeasy
Bugs & Requests

Configure alerts

Turn an event into a metric, then raise a metric-threshold alert that files its own ticket when the metric crosses the line.

BetaOn this page · 6 min readUpdated · June 12, 2026Works with · Edge Worker · Cron

An alert rule watches one metric and fires when its value crosses a threshold over a window — "checkout errors > 50 in the last hour", "active users < 100 in the last 24h". When it fires, Shipeasy files a ticket into the same feedback queue as your bugs and error reports, so the thing you need to look at shows up where you already triage.

Alerts are evaluated server-side by a cron — there's no SDK call and nothing to poll. You only define the rule.

The event → metric → alert chain

An alert rule doesn't read raw events; it reads a metric. So a working alert is a three-link chain:

# 1. a metric over the event (DSL grammar: /shipeasy:metrics:grammar)
shipeasy metrics create checkout-errors \
  --event checkout_error --query 'count(checkout_error)'

# 2. a threshold rule on that metric
shipeasy alert-rules create "Checkout errors spiking" \
  --metric checkout-errors --comparator gt --threshold 50 --window 1 --severity danger

# 3. confirm it landed
shipeasy alert-rules list

The same three steps are available over MCP (exp_create_alert_rule) and as the /shipeasy:alerts:create skill, which surveys your project and proposes rules worth adding. The CLI command is shipeasy alert-rulesshipeasy alerts is the read-only view of what has already fired.

The rule fields

Field
Type
Description
namerequired
string
Human label (1–120 chars), shown on the rule and on every alert it raises.
metricrequired
metric id or name
The metric to watch. Immutable once set — to point a rule at a different metric, delete it and create a new one.
comparatorrequired
"gt" | "gte" | "lt" | "lte"
How the value is compared to the threshold: > ≥ < ≤.
thresholdrequired
number
The line the metric value is compared against.
window
integer (hours) ?
Lookback window in whole hours, 1–720 (30 days). Defaults to 24.
severity
"danger" | "warn" | "info" ?
Severity of the raised alert. Defaults to warn.
enabled
boolean ?
Whether the cron evaluates the rule. Defaults to true; pass --disabled to create it dormant.

Windows are whole hours. The minimum is 1 hour and there are no sub-hour windows — a "last 30 minutes" intent rounds up to 1h. Pick a window long enough that the metric is stable but short enough to catch the spike you care about.

How it fires

A cron evaluates every enabled rule on a roughly 10-minute cadence. For each rule it:

  1. Compiles the rule's metric into a query over the window [now − window hours, now] and reads the aggregated value from Analytics Engine.
  2. Compares that value to the threshold with the comparator. If it breaches, the rule raises an alert.
  3. When a previously-breaching rule comes back inside its threshold, the alert auto-resolves — no manual clearing.

Each rule is evaluated in isolation, so a misconfigured metric can't block the others.

What firing produces

A fired alert does three things at once:

When the metric recovers, the alert resolves and no new ticket is filed. If it breaches again after resolving, a fresh alert and ticket are raised.

Tuning a rule

Everything except the metric is editable in place — adjust the threshold, flip the comparator, widen the window, change severity, or toggle it off without recreating it:

shipeasy alert-rules update "Checkout errors spiking" \
  --threshold 80 --window 2 --severity warn
shipeasy alert-rules update "Checkout errors spiking" --enabled false

To repoint a rule at a different metric, delete it and create a new one — the metric is pinned for the rule's life because it fixes both what is measured and how it's aggregated.

Where to next

On this page