• Home
  • Dynatrace API
  • Configuration
  • Remote environments
  • GET a remote environment

Remote environments API - GET a remote environment configuration

Gets the properties of the specified remote environment configuration.

The request produces an application/json payload.

GETManagedDynatrace for Governmenthttps://{your-domain}/e/{your-environment-id}/api/config/v1/remoteEnvironments/{id}
SaaShttps://{your-environment-id}.live.dynatrace.com/api/config/v1/remoteEnvironments/{id}
Environment ActiveGatehttps://{your-activegate-domain}/e/{your-environment-id}/api/config/v1/remoteEnvironments/{id}

Authentication

To execute this request, you need an access token with ReadConfig scope.

To learn how to obtain and use it, see Tokens and authentication.

Parameters

ParameterTypeDescriptionInRequired
idstring

The ID of the required configuration.

pathrequired

Response

Response codes

CodeTypeDescription
200RemoteEnvironmentConfigDto

Success

Response body objects

The RemoteEnvironmentConfigDto object

ElementTypeDescription
networkScopestring

The network scope of the remote environment:

  • EXTERNAL: The remote environment is located in an another network.
  • INTERNAL: The remote environment is located in the same network.
  • CLUSTER: The remote environment is located in the same cluster.

Dynatrace SaaS can only use EXTERNAL.

If not set, EXTERNAL is used.

The element can hold these values
  • CLUSTER
  • EXTERNAL
  • INTERNAL
displayNamestring

The display name of the remote environment.

idstring

The ID of the configuration.

uristring

The URI of the remote environment.

tokenstring

The API token granting access to the remote environment.

The token must have the Fetch data from a remote environment (RestRequestForwarding) scope.

For security reasons, GET requests return this field as null.

Response body JSON model

json
{ "networkScope": "EXTERNAL", "displayName": "string", "id": "string", "uri": "string", "token": "string" }

Example

In this example, the request inquires about the properties of the Production North remote environment, which has the ID b597955c-4706-40f6-b188-212faba25e1f.

The API token is passed in the Authorization header.

Curl

bash
curl -X GET \ https://mySampleEnv.live.dynatrace.com/api/config/v1/remoteEnvironments/b597955c-4706-40f6-b188-212faba25e1f \ -H 'Accept: application/json; charset=utf-8' \ -H 'Authorization: Api-Token dt0c01.abc123.abcdefjhij1234567890'

Request URL

plaintext
https://mySampleEnv.live.dynatrace.com/api/config/v1/remoteEnvironments/b597955c-4706-40f6-b188-212faba25e1f

Response body

json
{ "id": "b597955c-4706-40f6-b188-212faba25e1f", "displayName": "Production North", "uri": "https://prodNorth.live.dynatrace.com", "token": null, "networkScope": "EXTERNAL" }

Response code

200