Skip to main content
POST
Create an application alert

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

application_id
string<uuid>
required

Body

application/json

A create or a full update of one application alert. No other key is accepted.

name
string
required

The alert's name on the application page. Under Alerts the alert is named "Application · Environment · name".

Required string length: 1 - 100
environment_id
string<uuid>
required

One of the application's environments.

condition
ApplicationAlertCondition · object
required

The one condition an application alert has: it fires when the metric reads above threshold for hold_minutes in a row. The metrics are the ones the application's charts draw for the environment.

send_to
string<uuid>[]
required

The ids of the organisation's places to send alerts to (its alert integrations). They are linked, never changed.

Required array length: 1 - 5 elements
severity
enum<string>

warning when a create leaves it out; an update that leaves it out keeps the stored one.

Available options:
critical,
warning,
info

Response

The created alert

One alert of an application's list: an own alert, which these routes made and may change, or an organisation alert rule that watches the environment, which is changed under Alerts.

alert_id
string<uuid>
required
rule_id
string<uuid>
required
name
string
required

The name the person gave an own alert; the alert's name for any other.

own
boolean
required
environment_id
string<uuid> | null
required

The environment an application alert watches; null for an organisation rule.

says
string
required

An own alert's condition in one sentence; the rule's name for any other.

condition
ApplicationAlertCondition · object | null
required

The one condition an application alert has: it fires when the metric reads above threshold for hold_minutes in a row. The metrics are the ones the application's charts draw for the environment.

severity
string
required
send_to
ApplicationAlertDestination · object[]
required
enabled
boolean
required

True when the alert and its rule are both on.

last_firing
ApplicationAlertFiring · object | null
required

An alert's last firing the caller may read. An organisation rule's is its last on one of the environment's clusters.

evaluated_at
string<date-time> | null
required

When the evaluator last evaluated the rule; null before its first run and while a held rule never was evaluated.

evaluation
enum<string>
required

ok: the rule was read on its last run. unknown: the evaluator holds it unread (the metric store did not answer or lacks the metric, or the environment's installations cannot be resolved). not_evaluated: no run recorded a state yet.

Available options:
ok,
unknown,
not_evaluated
unknown_reason
string | null
required

Why the evaluator holds the rule, only while evaluation is unknown. no_installations: nothing of the application runs on the environment, or only on a stopped cluster. application_not_found or environment_not_found: what the alert watched is gone; the evaluator then closes the alert's open firing with a resolution_note, since nothing can report it resolved. Any other value names a read that failed or a metric the store lacks.