All Products
Search
Document Center

Data Management:GetUser

Last Updated:Oct 19, 2026

Retrieves the information of a specific user.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

dms:GetUser

get

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

Tid

integer

No

The tenant ID. You can call the GetUserActiveTenant operation to obtain the value of this parameter.

3***

Uid

string

No

The user UID. You can view your UID by clicking the profile picture in the upper-right corner of the DMS console.

22973492647626****

UserId

string

No

The user ID. You can call the ListUsers operation to obtain the value of this parameter.

51****

Response elements

Element

Type

Description

Example

object

User

object

The user information.

State

string

The user state. Valid values:

  • NORMAL: normal

  • DISABLE: disabled

  • DELETE: deleted

NORMAL

CurResultCount

integer

The number of queried rows on the current day.

28

UserId

string

The user ID.

51****

LastLoginTime

string

The time when the user last logged on to the console.

2021-11-08 11:26:21

MaxResultCount

integer

The maximum number of queried rows on the current day.

10000

ParentUid

integer

The UID of the Alibaba Cloud account.

Note

A single Alibaba Cloud account UID can contain multiple RAM user UIDs.

140692647406****

RoleIdList

object

RoleIds

array

The list of role IDs.

integer

The role IDs. Valid values:

  • 1: regular user

  • 2: DBA

  • 3: administrator

  • 4: security administrator

  • 6: structure read-only user

1

RoleNameList

object

RoleNames

array

The list of role names.

string

The role names. Valid values:

  • USER: regular user

  • DBA: DBA

  • ADMIN: administrator

  • SECURITY_ADMIN: security administrator

  • STRUCT_READ_ONLY: structure read-only user

USER

NickName

string

The nickname of the user.

User_NickName

MaxExecuteCount

integer

The maximum number of queries on the current day.

2000

CurExecuteCount

integer

The number of queries on the current day.

3

Mobile

string

The mobile phone number of the user.

Note
  • If you have configured a mobile phone number in the Notification settings by clicking the profile picture in the upper-right corner of the console, this parameter is returned.

  • If you have not configured a mobile phone number, this parameter is not returned.

1389223****

Uid

string

The UID of the target user.

22275482072787****

Email

string

The email address used to receive message notifications.

Note
  • If you have configured an email address in the Notification settings by clicking the profile picture in the upper-right corner of the console, this parameter is returned.

  • If you have not configured an email address, this parameter is not returned.

Uesr_email

DingRobot

string

The DingTalk chatbot used to receive message notifications.

Note
  • If you have configured a DingTalk chatbot in the Notification settings by clicking the profile picture in the upper-right corner of the console, this parameter is returned.

  • If you have not configured a DingTalk chatbot, this parameter is not returned.

https://XXX.dingtalk.com/robot/send?access_token=***

Webhook

string

The webhook used to receive message notifications.

Note
  • If you have configured a webhook, the system sends message notifications to the specified URL when notifications are generated in DMS.

  • If you have not configured a webhook, this parameter is not returned.

http://dms-XXX.aliyun.com:8***

SignatureMethod

string

The signature method for the webhook. Valid values:

  • NONE: no signature

  • HMAC_SHA1: HMAC_SHA1

NONE

NotificationMode

string

The notification methods. Multiple values may be returned. Valid values:

  • SMS: text message

  • EMAIL: email

  • DINGDING: DingTalk

  • DINGROBOT: DingTalk chatbot

  • WEBHOOK: webhook

EMAIL

RequestId

string

The request ID.

804BB128-CAFA-5DD0-BA1E-43DDE488****

ErrorCode

string

The error code.

UnknownError

ErrorMessage

string

The error message.

Unknown server error

Success

boolean

Specifies whether the request is successful. Valid values:

  • true: The request is successful.

  • false: The request fails.

true

Examples

Success response

JSON format

{
  "User": {
    "State": "NORMAL",
    "CurResultCount": 28,
    "UserId": "51****",
    "LastLoginTime": "2021-11-08 11:26:21",
    "MaxResultCount": 10000,
    "ParentUid": 0,
    "RoleIdList": {
      "RoleIds": [
        1
      ]
    },
    "RoleNameList": {
      "RoleNames": [
        "USER"
      ]
    },
    "NickName": "User_NickName",
    "MaxExecuteCount": 2000,
    "CurExecuteCount": 3,
    "Mobile": "1389223****",
    "Uid": "22275482072787****",
    "Email": "Uesr_email",
    "DingRobot": "https://XXX.dingtalk.com/robot/send?access_token=***",
    "Webhook": "http://dms-XXX.aliyun.com:8***",
    "SignatureMethod": "NONE",
    "NotificationMode": "EMAIL"
  },
  "RequestId": "804BB128-CAFA-5DD0-BA1E-43DDE488****",
  "ErrorCode": "UnknownError",
  "ErrorMessage": "Unknown server error",
  "Success": true
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.