OAuth clients provide you client credentials as per the OAuth standard. They can be managed by Dynatrace administrators and are used to set up integrations between Dynatrace and external systems or to automate account management.
You can only access your client secret once upon creation. You can't reveal it afterward.
After you create the OAuth2 client, request the bearer token from the Dynatrace SSO system via an API call.
POST |
|
Content type |
|
Provide the following parameters in the request body. Be sure to URL-encode all values!
Parameter | Value |
---|---|
grant_type |
|
client_id |
|
client_secret |
|
scope | A list of required scopes separated by a whitespace, for example You can assign multiple scopes to a single token, or you can generate several tokens, each with different access levels and use them accordingly—check your organization's security policies for the best practice. |
resource |
|
The response of the request contains the bearer token.
To authenticate a call, attach the token to the Authorization HTTP header preceding the Bearer realm.
--header 'Authorization: Bearer abcdefjhij1234567890'
The following example shows the authentication.
curl --request GET \--url https://api.dynatrace.com/iam/v1/accounts/2b794097-8ad2-4b32-b923-0131da2eeddf/users \--header 'Authorization: Bearer abcdefjhij1234567890' \