- HTTP request
- Path parameters
- Query parameters
- Request body
- Response body
- Authorization scopes
- IAM Permissions
- AlertStatusCount
- AlertSeverityDistribution
- Try it!
Full name: projects.locations.instances.legacy.legacyCalculateAlertStats
Legacy endpoint for fetching alert stats (counts based on fields) for a given time range.
HTTP request
GET https://chronicle.googleapis.com/v1alpha/{instance}/legacy:legacyCalculateAlertStats
Path parameters
Parameters | |
---|---|
instance |
Required. Chronicle instance this request is sent to. Format: projects/{project}/locations/{location}/instances/{instance} |
Query parameters
Parameters | |
---|---|
timestampRange |
Required. Timerange to filter alerts by. Maximum allowed time range is 30 days. |
Request body
The request body must be empty.
Response body
Returns alerts stats over a given time range. NEXT TAG: 5
If successful, the response body contains data with the following structure:
JSON representation |
---|
{ "total_alerts": integer, "alert_status_count": { object ( |
Fields | |
---|---|
total_alerts |
Count of total number of alerts in the give time range. |
alert_status_count |
Count of alerts split on backstory.Status field. |
timestamp_range |
Time range used to fetch the stats. |
alert_severity_distribution |
Count of alerts in each severity category. |
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/cloud-platform
For more information, see the Authentication Overview.
IAM Permissions
Requires the following IAM permission on the instance
resource:
chronicle.legacies.legacyCalculateAlertStats
For more information, see the IAM documentation.
AlertStatusCount
Count of alerts split on backstory.Status field.
JSON representation |
---|
{ "open": integer, "closed": integer } |
Fields | |
---|---|
open |
Count of alerts in status NEW or OPEN or REVIEWED. |
closed |
Count of alerts in status CLOSED. |
AlertSeverityDistribution
Count of alerts in each severity category.
JSON representation |
---|
{ "severity_unset": integer, "info": integer, "low": integer, "medium": integer, "high": integer, "critical": integer } |
Fields | |
---|---|
severity_unset |
Count of alerts for which severity score is not set or set to zero. |
info |
Count of alerts for which severity score is in the range [1, 20). |
low |
Count of alerts for which severity score is in the range [20, 50). |
medium |
Count of alerts for which severity score is in the range [50, 80). |
high |
Count of alerts for which severity score is in the range [80, 90). |
critical |
Count of alerts for which severity score is in the range [90, 100]. |