• /
  • Log in
  • Free account

REST API calls for alerts

Our REST API (v2) allows you to configure settings for alerts. The API Explorer also includes the curl request format, available parameters, potential response status codes, and JSON response structure for each of the available API calls. You can also create alert conditions in the UI.

Important

For infrastructure alerting, see REST API for infrastructure monitoring alerts.

Available data and functions via API

REST API functions

Comments

View account data

In general, any role can use a user key or REST API key with GET > List functions to view alerts data. The account Owner and Admins may use their API key.

List output will be paginated. Available functions include:

Maintain account data

You may have an Owner or Admin role in your account and a user key or have a custom role that grants permissions to manage Alerts and a user key in order to use any maintenance function, including POST > Create, PUT > Add, PUT > Update, and DELETE.

Conditions excluded from the REST API

These types of conditions do not have available endpoints in the API:

  • APM: Web transaction percentiles, conditions targeting labels, and baselines
  • NRQL: Baselines

Alert policies

These API functions include links to the API Explorer, where you can create, delete, or list policies.

Important

If your account hosts data in the EU data center, ensure you're using the proper API endpoints for EU region accounts.

Notification channels

These API functions include links to the API Explorer, where you can create, delete, or list Alerts notification channels.

Important

If your account hosts data in the EU data center, ensure you are using the proper API endpoints for EU region accounts.

Conditions for APM, browser, mobile

These API functions include links to the API Explorer, where you can create, update, delete, or list policy conditions. These calls are for conditions with these types of entities:

  • APM: Apps and key transactions
  • Browser: Apps and key transactions
  • Mobile: Mobile apps

Exception: The following APM conditions are not available from this API endpoint:

  • Conditions targeting labels (dynamic targeting)
  • Web transaction percentile conditions
  • Baseline conditions

Important

The API Explorer provides information about other types of conditions using separate endpoints, including external services (APM and mobile), and synthetic monitoring. Consider all types of alert conditions when searching or updating. If your account hosts data in the EU data center, ensure you are using the proper API endpoints for EU region accounts.

Conditions for NRQL

These API functions include links to the API Explorer, where you can create, update, delete, or list NRQL conditions for your policies.

Exception: NRQL baseline conditions are not available from this endpoint.

Important

If your account hosts data in the EU data center, ensure you are using the proper API endpoints for EU region accounts.

Conditions for external services

These API functions include links to the API Explorer, where you can create, update, delete, or list policy conditions. These calls are for conditions for external services. The API calls can be used with APM and mobile monitoring apps.

Important

If your account hosts data in the EU data center, ensure you are using the proper API endpoints for EU region accounts.

Conditions for Synthetic monitoring

These API functions include links to the API Explorer, where you can create, update, delete, or list conditions for your alert policies. The API calls can be used with Synthetic monitoring.

Alert activity: Events, violations, incidents

These API functions include links to the API Explorer, where you can view information about events, violations, and incidents for your alert policies.

Important

If your account hosts data in the EU data center, ensure you are using the proper API endpoints for EU region accounts.

Alert entity conditions

These API functions include links to the API Explorer, where you can list, add and remove entities in the conditions for your alert policies.

Important

If your account hosts data in the EU data center, ensure you are using the proper API endpoints for EU region accounts.

For more help

If you need more help, check out these support and learning resources:

Create issueEdit page
Copyright © 2021 New Relic Inc.