Method: projects.alertPolicies.list

Lists the existing alerting policies for the project.

HTTP request

GET https://monitoring.googleapis.com/v3/{name}/alertPolicies

Path parameters

Parameters
name

string

The project whose alert policies are to be listed. The format is

projects/[PROJECT_ID]

Note that this field names the parent container in which the alerting policies to be listed are stored. To retrieve a single alerting policy by name, use the alertPolicies.get operation, instead.

Authorization requires the following Google IAM permission on the specified resource name:

  • monitoring.alertPolicies.list

Query parameters

Parameters
filter

string

If provided, this field specifies the criteria that must be met by alert policies to be included in the response.

For more details, see sorting and filtering.

orderBy

string

A comma-separated list of fields by which to sort the result. Supports the same set of field references as the filter field. Entries can be prefixed with a minus sign to sort by the field in descending order.

For more details, see sorting and filtering.

pageSize

number

The maximum number of results to return in a single response.

pageToken

string

If this field is not empty then it must contain the nextPageToken value returned by a previous call to this method. Using this field causes the method to return more results from the previous method call.

Request body

The request body must be empty.

Response body

If successful, the response body contains data with the following structure:

The protocol for the alertPolicies.list response.

JSON representation
{
  "alertPolicies": [
    {
      object(AlertPolicy)
    }
  ],
  "nextPageToken": string
}
Fields
alertPolicies[]

object(AlertPolicy)

The returned alert policies.

nextPageToken

string

If there might be more results than were returned, then this field is set to a non-empty value. To see the additional results, use that value as pageToken in the next call to this method.

Authorization Scopes

Requires one of the following OAuth scopes:

  • https://www.googleapis.com/auth/cloud-platform
  • https://www.googleapis.com/auth/monitoring
  • https://www.googleapis.com/auth/monitoring.read

For more information, see the Authentication Overview.

Try it!

Was this page helpful? Let us know how we did:

Send feedback about...

Stackdriver Monitoring