List alert rules
GET
/api/v1/alerts/rules
const url = 'https://example.com/api/v1/alerts/rules';const options = {method: 'GET', headers: {Authorization: '<Authorization>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/v1/alerts/rules \ --header 'Authorization: <Authorization>'Returns alert rule rows, optionally filtered by environment.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”env
integer
Environment ID; omit to list all
Responses
Section titled “Responses”OK
Media typeapplication/json
Array<object>
object
channel_ids
Array<integer>
cooldown_minutes
integer
created_at
string
enabled
boolean
environment_id
integer
id
integer
info
string
match_field
string
match_type
string
match_value
string
name
string
node_uuid
string
source
string
status_severity
string
updated_at
string
Examplegenerated
[ { "channel_ids": [ 1 ], "cooldown_minutes": 1, "created_at": "example", "enabled": true, "environment_id": 1, "id": 1, "info": "example", "match_field": "example", "match_type": "example", "match_value": "example", "name": "example", "node_uuid": "example", "source": "example", "status_severity": "example", "updated_at": "example" }]Unauthorized
Media typeapplication/json
object
code
string
error
string
Examplegenerated
{ "code": "example", "error": "example"}Forbidden
Media typeapplication/json
object
code
string
error
string
Examplegenerated
{ "code": "example", "error": "example"}Alerts disabled
Media typeapplication/json
object
code
string
error
string
Examplegenerated
{ "code": "example", "error": "example"}