• /
  • EnglishEspañol日本語한국어Português
  • 로그인지금 시작하기

Synthetics REST API

Use the synthetics REST API to create and manage synthetic monitors.

Before you start

중요

On October 22, 2024, we will end of life the containerized private minion (CPM) and legacy synthetics runtime versions. As of August 26, 2024, you can no longer create new monitors using legacy synthetics runtime versions. The Synthetics REST API only supports monitor creation using legacy synthetics runtime versions. Please use NerdGraph APIs to manage your synthetic monitors using our latest runtimes to avoid degradation.

Our synthetics REST API is one way to manage your synthetic monitors via API but the recommended way is using our NerdGraph API.

Permissions

To use the synthetics REST API, you must have synthetics-related permissions, and a .

You can use NRQL queries to analyze past changes made via the API.

Monitor types in API

These are the monitor types and how they're referred to in in the Synthetics REST API:

Monitor type

API name

Ping

SIMPLE

Simple browser

BROWSER

Scripted browser

SCRIPT_BROWSER

API test

SCRIPT_API

Use the API

To use the synthetic monitoring REST API, you must have the ability to manage synthetics monitors and use a user key (the REST API key won't work).

This API can be used for all synthetic monitors. (Additional API methods for scripted browser and API test monitors are also available to update the script associated with those monitors.) All synthetic monitoring data is available via the API. API examples show curl commands.

For US-based accounts, use the following endpoint:

https://synthetics.newrelic.com/synthetics/api

For EU-based accounts, use the following endpoint:

https://synthetics.eu.newrelic.com/synthetics/api

주의

The synthetic monitoring REST API limits an account's rate of requests to three requests per second. Requests made in excess of this threshold will return a 429 response code.

Script API for scripted browser and API test monitors

In addition to the general API, there are several API methods for the scripted browsers (SCRIPT_BROWSER) and API test browsers (SCRIPT_API). These examples show curl commands.

Scripted browser example

Here is an example of using New Relic's REST API and the bash script to create a scripted browser monitor.

Copyright © 2024 New Relic Inc.

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.