Skip to content
TriedDocs
Account

Get alert

Read one alert rule by ID.

GEThttps://api.tried.com.au/alerts/{id}

Returns one alert rule with its settings, state and last value.

Request#

Field Type Required Description
id string Yes Alert ID, for example alert_3f9a1c7e2b8d4a6f0e1c5b92.

Example request#

curl https://api.tried.com.au/alerts/alert_3f9a1c7e2b8d4a6f0e1c5b92 \
  -H "Authorization: Bearer $TRIED_API_KEY"
const res = await fetch("https://api.tried.com.au/alerts/alert_3f9a1c7e2b8d4a6f0e1c5b92", {
  headers: { Authorization: `Bearer ${process.env.TRIED_API_KEY}` },
});
const alert = await res.json();
import os, requests

res = requests.get(
    "https://api.tried.com.au/alerts/alert_3f9a1c7e2b8d4a6f0e1c5b92",
    headers={"Authorization": f"Bearer {os.environ['TRIED_API_KEY']}"},
)
alert = res.json()

Response#

200 OK

{
  "alert_id": "alert_3f9a1c7e2b8d4a6f0e1c5b92",
  "name": "High p90 latency",
  "metric": "e2e_latency_p90",
  "threshold_type": "absolute",
  "comparator": ">",
  "threshold": 1500,
  "window_minutes": 60,
  "frequency_minutes": 5,
  "agent_ids": [
    "agent_4b7e2c9a1f3d5e8b0c6a2d1f"
  ],
  "emails": [
    "ops@example.com"
  ],
  "webhook_url": "https://example.com/hooks/alerts",
  "enabled": true,
  "state": "triggered",
  "last_value": 1720,
  "last_checked_timestamp": 1792398600000,
  "created_timestamp": 1792395000000
}
Field Type Description
alert_id string Alert ID, prefixed alert_.
state string ok or triggered. Changes only when the rule is evaluated (by the scheduler or Evaluate alert).
last_value number or null Value from the last evaluation. For a relative rule this is the percent change against the previous window. null until the first evaluation.
last_checked_timestamp integer or null Unix ms of the last evaluation.
created_timestamp integer Unix ms when the rule was created.

The other fields echo the rule settings. See Create alert for what each one means.

Errors#

Status When
401 Missing or invalid API key.
403 The key's IP allowlist or scopes reject the request. This route needs the analytics scope.
404 No alert with that ID in the workspace: Alert <id> not found.
429 Rate limit exceeded. See Rate limits.

See Errors for the body format.

Retell compatibility#

Retell's public API reference has no alerting endpoints, so this route has no Retell SDK equivalent.