User management API - GET user groups

Gets the information about user's group membership.

The request produces an application/json payload.

GET

https://api.dynatrace.com/iam/v1/accounts/{accountUuid}/users/{email}

Authentication

To execute this request, you need the Allow read access for identity resources (users and groups) (account-idm-read) scope assigned to your token. To learn how to obtain and use it, see OAuth clients.

Parameters

Parameter
Type
Description
In
Required
accountUuid
string

The ID of the required account.

You can find the UUID on the Account Management > Identity & access management > OAuth clients page, during creation of an OAuth client.

path
required
email
string

The email address of the required user.

path
required

Response

Response codes

Code
Type
Description
200

Success. The response contains the groups of the user.

Response body objects

The GroupUserDto object

Element
Type
Description
uid
string

The UUID of the user.

email
string

The email address of the user.

name
string

The first name of the user.

surname
string

The last name of the user.

userStatus
string

The status of this user in Dynatrace:

  • ACTIVE: The user is active.
  • INACTIVE: The user is deactivated and cannot sign in to Dynatrace.
  • PENDING: The user received an invitation, but hasn't completed sign-up yet.
  • DELETED: The user was deleted and cannot sign in to Dynatrace anymore.
  • ECUSTOMS_MANUALLY_BLOCKED: The user is blocked due to to a trade and export compliance violation.
  • ACTIVE
  • INACTIVE
  • PENDING
  • DELETED
  • ECUSTOMS_MANUALLY_BLOCKED
emergencyContact
boolean

The user is (true) or is not (false) an emergency contact for the account.

groups

A list of groups of which the user is a member.

The AccountGroupDto object

Element
Type
Description
groupName
string

The name of the user group.

uuid
string

The UUID of the user group.

owner
string

The type of the group. LOCAL, SCIM, SAML and DCS corresponds to the identity provider from which the group originates. ALL_USERS is a special case of LOCAL group. It means that group is always assigned to all users in the account.

  • LOCAL
  • SCIM
  • SAML
  • DCS
  • ALL_USERS
accountUUID
string

The UUID of the Dynatrace account.

accountName
string

The name of the Dynatrace account.

description
string

A short description of the group.

createdAt
string

The date and time of the group creation in 2021-05-01T15:11:00Z format.

updatedAt
string

The date and time of the most recent modification to the group in 2021-05-01T15:11:00Z format.

Response body JSON model

{
"uid": "string",
"email": "string",
"name": "string",
"surname": "string",
"userStatus": "ACTIVE",
"emergencyContact": true,
"groups": [
{
"groupName": "string",
"uuid": "string",
"owner": "LOCAL",
"accountUUID": "string",
"accountName": "string",
"description": "string",
"createdAt": "string",
"updatedAt": "string"
}
]
}

Example

In this example, the reuqest gets the group membership of the user with the john.smith@company.com email address. The result is truncated to three entries.

Curl

curl --request GET \
--url 'https://api.dynatrace.com/iam/v1/accounts/2b794097-8ad2-4b32-b923-0131da2eeddf/users/john.smith@company.com' \
--header 'Authorization: Bearer abcdefjhij1234567890'

Request URL

https://api.dynatrace.com/iam/v1/accounts/2b794097-8ad2-4b32-b923-0131da2eeddf/users/john.smith@company.com

Response body

{
"uid": "a5f4a0df-ca5a-47c6-a7c1-d2ac95cf1550",
"email": "john.smith@company.com",
"groups": [
{
"groupName": "Confidential data admin",
"uuid": "541802b0-623c-4193-8728-036ed01d4eb4",
"owner": "LOCAL",
"description": null,
"hidden": false,
"accountUUID": "2b794097-8ad2-4b32-b923-0131da2eeddf",
"accountName": "Dynatrace",
"createdAt": "2020-03-11T03:01:01Z",
"updatedAt": "2020-03-11T03:01:01Z"
},
{
"groupName": "Monitoring viewer",
"uuid": "7a1d224d-0ebc-4318-ab1e-64b217b7c156",
"owner": "LOCAL",
"description": null,
"hidden": false,
"accountUUID": "2b794097-8ad2-4b32-b923-0131da2eeddf",
"accountName": "Dynatrace",
"createdAt": "2020-03-11T03:01:01Z",
"updatedAt": "2020-03-11T03:01:01Z"
},
{
"groupName": "Monitoring admin",
"uuid": "f335c6ae-f046-48ad-a0a2-49bb8fdca07b",
"owner": "LOCAL",
"description": null,
"hidden": false,
"accountUUID": "2b794097-8ad2-4b32-b923-0131da2eeddf",
"accountName": "Dynatrace",
"createdAt": "2020-03-11T03:01:01Z",
"updatedAt": "2020-03-11T03:01:01Z"
},
{
"groupName": "Account manager",
"uuid": "56d56aba-c12f-44c1-a0ba-42eba3e3ff84",
"owner": "LOCAL",
"description": null,
"hidden": false,
"accountUUID": "2b794097-8ad2-4b32-b923-0131da2eeddf",
"accountName": "Dynatrace",
"createdAt": "2020-03-11T03:01:01Z",
"updatedAt": "2020-03-11T03:01:01Z"
}
],
"emergencyContact": false,
"userStatus": "ACTIVE"
}

Response code

200