alerting_alerts
Creates, updates, deletes, gets or lists an alerting_alerts resource.
Overview​
| Name | alerting_alerts |
| Type | Resource |
| Id | ovh.cloud.alerting_alerts |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
alert_id | integer | Alert ID (wire: alertId) |
alert_date | string (date-time) | Send date (wire: alertDate) |
emails | array | Receivers of the alert |
Sent Alert to client
| Name | Datatype | Description |
|---|---|---|
alert_id | integer | Alert ID (wire: alertId) |
alert_date | string (date-time) | Send date (wire: alertDate) |
emails | array | Receivers of the alert |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | alert_id, id, service_name | Returns when the alert was sent and to which email addresses. | |
list | select | id, service_name | x_pagination_mode | Returns the IDs of the alerts already sent for this billing alert. |
Parameters​
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
alert_id | integer | Alert ID (wire: alertId) |
api_host | string | The OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}}) |
id | string (uuid) | Id |
service_name | string | The Public Cloud project ID. Resolved from OVH_CLOUD_PROJECT_SERVICE when set. |
x_pagination_mode | string | Sent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode) |
SELECT examples​
- get
- list
Returns when the alert was sent and to which email addresses.
SELECT
alert_id,
alert_date,
emails
FROM ovh.cloud.alerting_alerts
WHERE alert_id = '{{ alert_id }}' -- required
AND id = '{{ id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
;
Returns the IDs of the alerts already sent for this billing alert.
SELECT
alert_id,
alert_date,
emails
FROM ovh.cloud.alerting_alerts
WHERE id = '{{ id }}' -- required
AND service_name = '{{ service_name }}' -- required unless OVH_CLOUD_PROJECT_SERVICE is set
AND x_pagination_mode = '{{ x_pagination_mode }}'
;