Definitions

Definitions are used to configure alerts on how to observe a metric.

Data model

created_atstringTime when the definition was created (RFC3339). Read-only.
descriptionstringAdditional text that is included in the alert notification.
dimensionsobjectMore filters depending on the source type.
evaluation_strategyobjectCriteria on how to alert.
idstringA unique identifier for a definition. Read-only.
integration_idsarrayList of integrations used to notify when alert fires. Refer to Notification Service.
metricstringThe metric name to alert on for a specific source: domains, origins or stats.
namestringThe name of the alert definition.
objectstringThe resource type. Read-only. [Default definition]
service_idstringThe service on which the definition will alert on.
sourcestringThe source where the metric comes from.
updated_atstringTime when the definition was last updated (RFC3339). Read-only.

Domain derived metrics

In addition to the metrics provided by Domain Inspector, when choosing "domains" as a source, the following metric can also be used.

origin_offload_bytesnumberThe number of bytes offloaded to the edge.
status_404_ratenumberFraction of responses with 404 codes delivered. If there are no responses, this value will be 0.
status_4xx_excl_404_ratenumberFraction of responses with non-404 4xx codes delivered. If there are no responses, this value will be 0.
status_4xx_ratenumberFraction of responses with 4xx codes delivered from domain. If there are no responses, this value will be 0.
status_5xx_ratenumberFraction of responses with 5xx codes delivered from domain. If there are no responses, this value will be 0.
status_gte_400_ratenumberFraction of responses with 4xx or 5xx codes delivered from domain. If there are no responses, this value will be 0.
status_lt_500_ratenumberFraction of responses with non-5xx codes delivered from domain. If there are no responses, this value will be 0.

Origin derived metrics

In addition to the metrics provided by Origin Inspector, when choosing "origins" as a source, the following metric can also be used.

all_bandwidthintegerThe amount of bandwidth from your origin.
all_status_404_ratenumberFraction of all responses with 404 codes delivered (Compute, WAF, and VCL). If there are no responses, this value will be 0.
all_status_4xx_excl_404_ratenumberFraction of all responses with non-404 4xx codes delivered (Compute, WAF, and VCL). If there are no responses, this value will be 0.
all_status_4xx_ratenumberFraction of all responses with 4xx codes delivered (Compute, WAF, and VCL). If there are no responses, this value will be 0.
all_status_5xx_ratenumberFraction of all responses with 5xx codes delivered (Compute, WAF, and VCL). If there are no responses, this value will be 0.
all_status_gte_400_ratenumberFraction of all responses with 4xx or 5xx codes delivered (Compute, WAF, and VCL). If there are no responses, this value will be 0.
all_status_lt_500_ratenumberFraction of all responses with non-5xx codes delivered (Compute, WAF, and VCL). If there are no responses, this value will be 0.

Evaluation strategy data model

Criteria on how to alert.

ignore_belownumberThreshold for the denominator value used in evaluations that calculate a rate or ratio. Usually used to filter out noise.
periodstringThe length of time to evaluate whether the conditions have been met. The data is polled every minute. Required.
thresholdnumberThreshold used to alert. Required.
typestringType of strategy to use to evaluate. Required.

Stats derived metrics

In addition to the metrics provided by Historical Stats, when choosing "stats" as a source, the following metric can also be used.

all_status_4xx_ratenumberFraction of all responses with 4xx codes delivered (Compute and VCL). If there are no responses, this value will be 0.
all_status_5xx_ratenumberFraction of all responses with 5xx codes delivered (Compute and VCL). If there are no responses, this value will be 0.
all_status_gte_400_ratenumberFraction of all responses with 4xx or 5xx codes delivered (Compute and VCL). If there are no responses, this value will be 0.
all_status_lt_500_ratenumberFraction of all responses with non-5xx codes delivered (Compute and VCL). If there are no responses, this value will be 0.
status_404_ratenumberFraction of VCL responses with 404 codes delivered. If there are no responses, this value will be 0.
status_4xx_excl_404_ratenumberFraction of VCL responses with non-404 4xx codes delivered. If there are no responses, this value will be 0.
status_4xx_ratenumberFraction of VCL responses with 4xx codes delivered. If there are no responses, this value will be 0.
status_5xx_ratenumberFraction of VCL responses with 5xx codes delivered. If there are no responses, this value will be 0.
status_gte_400_ratenumberFraction of VCL responses with 4xx or 5xx codes delivered. If there are no responses, this value will be 0.
status_lt_500_ratenumberFraction of VCL responses with non-5xx codes delivered. If there are no responses, this value will be 0.

Endpoints

List definitions

GET/alerts/definitions

Create definition

POST/alerts/definitions

Read definition

GET/alerts/definitions/definition_id

Update definition

PUT/alerts/definitions/definition_id

Delete definition

DELETE/alerts/definitions/definition_id