Skip to content

GET Alerts History.

GET
/api/data/namespaces/{namespace}/alerts/history
curl --request GET \
--url https://example-corp.console.ves.volterra.io/api/v1/api/production/us-east-1/namespaces/default/api/data/namespaces/example/alerts/history \
--header 'Authorization: <Authorization>'

GET the history of alert notifications sent to the end-user between the start_time and end_time that matches the filter specified in the request.

Examples of this operation.

namespace
required
string

Namespace namespace to scope the listing of alerts. For “system” namespace, all alerts for the tenant will be returned.

filter
string

HighDiskUsage”, severity=“critical”}” List of matchers to filter alert by. Syntax for filter := {[]} := <label_name>“<label_value>” <label_name> := string All alerts have the following default labels: “alertname”, “identifier”, “group”, “severity” <label_value> := string := [”=”|”!=”|”=”|”!”] = : Select labels that are exactly equal to the provided string != : Select labels that are not equal to the provided string. When more than one matcher is specified in the filter, then alerts matching ALL the matchers will be returned.

Optional: If not specified, then all the alerts for the tenant and namespace specified in the request will be returned.

start_time
string

Fetch alerts whose timestamp >= start_time format: unix_timestamp|RFC 3339

Optional: If not specified, then the start_time will be evaluated to end_time-10m If end_time is not specified, then the start_time will be evaluated to -10m.

end_time
string

Fetch alerts whose timestamp <= end_time format: unix_timestamp|RFC 3339

Optional: If not specified, then the end_time will be evaluated to start_time+10m If start_time is not specified, then the end_time will be evaluated to

A successful response.

Media typeapplication/json
Alerts History Response

Response message for AlertsHistoryRequest/AlertsHistoryScrollRequest.

object
alerts
alerts

List of alerts that matched the filter. Contains no more than 500 alerts per response.

Array<string>
scroll_id
scroll_id

Long Base-64 encoded string which can be used to retrieve next batch of alert messages using the scroll request. Empty scroll_id indicates no more messages to scroll (EOF). Note: scroll_id is valid only for 2 minutes. I.e., If one intend to retrieve next batch of the result, then the scroll request should be sent within 2 minutes upon receiving the response.

string
<= 1024 characters
total_hits
total hits

Total number of alerts that matched the query.

string format: uint64
<= 1024 characters
Examplegenerated
{
"alerts": [
"example"
],
"scroll_id": "example",
"total_hits": "example"
}

Returned when operation is not authorized.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when there is no permission to access resource.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when resource is not found.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when operation on resource is conflicting with current value.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when operation has been rejected as it is happening too frequently.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when server encountered an error in processing API.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when service is unavailable temporarily.

Media typeapplication/json
string format: string
Examplegenerated
example

Returned when server timed out processing request.

Media typeapplication/json
string format: string
Examplegenerated
example