All Products
Search
Document Center

Identity as a Service:GetUser

Last Updated:Sep 10, 2024

Queries the information of an Employee Identity and Access Management (EIAM) account.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request syntax

GET /v2/{instanceId}/{applicationId}/users/{userId}

Request parameters

ParameterTypeRequiredDescriptionExample
AuthorizationstringYes

The authentication information. Format: Bearer ${access_token}. Example: Bearer ATxxxx.

Bearer AT8csE2seYxxxxxij
instanceIdstringYes

The instance ID.

idaas_ue2jvisn35ea5lmthk267xxxxx
applicationIdstringYes

The application ID.

app_mkv7rgt4d7i4u7zqtzev2mxxxx
userIdstringYes

The account ID.

user_d6sbsuumeta4h66ec3il7yxxxx

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

instanceIdstring

The instance ID.

idaas_ue2jvisn35ea5lmthk267xxxxx
organizationalUnitsarray<object>

The organizational units to which the account belongs.

object

The organizational unit.

organizationalUnitIdstring

The ID of the organizational unit.

ou_wovwffm62xifdziem7an7xxxxx
organizationalUnitNamestring

The name of the organizational unit.

name001
primaryboolean

Indicates whether the organizational unit is the primary organizational unit.

true
primaryOrganizationalUnitIdstring

The ID of the primary organizational unit of the account.

ou_wovwffm62xifdziem7an7xxxxx
customFieldsarray<object>

The extended fields of the account.

object
fieldNamestring

The name of the extended field.

xxxx
fieldValuestring

The value of the extended field. Field values are returned as strings regardless of the data types of the fields. For example, true or false is returned for a Boolean field.

userIdstring

The account ID.

user_d6sbsuumeta4h66ec3il7yxxxx
usernamestring

The username of the account.

name001
displayNamestring

The display name of the account.

display_name001
passwordSetboolean

Indicates whether the password is set.

true
phoneRegionstring

The country code of the mobile number. For example, the country code of China is 86 without 00 or +.

86
phoneNumberstring

The mobile number of the user who owns the account.

156xxxxxxx
phoneNumberVerifiedboolean

Indicates whether the mobile number has been verified. A value of true indicates that the mobile number has been verified by the user or has been set to the verified status by the administrator. A value of false indicates that the mobile number has not been verified.

true
emailstring

The email address of the user.

example@example.com
emailVerifiedboolean

Indicates whether the email address has been verified. A value of true indicates that the email address has been verified by the user or has been set to the verified status by the administrator. A value of false indicates that the email address has not been verified.

true
userExternalIdstring

The external ID of the account. The external ID can be used to map external data to the data of the account in EIAM of Identity as a Service (IDaaS). By default, the external ID is the account ID.

Note: For accounts with the same source type and source ID, each account has a unique external ID.

user_d6sbsuumeta4h66ec3il7yxxxx
userSourceTypestring

The source type of the account. Valid values:

  • build_in: The account was created in IDaaS.
  • ding_talk: The account was imported from DingTalk.
  • ad: The account was imported from Microsoft Active Directory (AD).
  • ldap: The account was imported from a Lightweight Directory Access Protocol (LDAP) service.
build_in
userSourceIdstring

The source ID of the account.

If the account was created in IDaaS, its source ID is the ID of the IDaaS instance. If the account was imported, its source ID is the enterprise ID in the source. For example, if the account was imported from DingTalk, its source ID is the corpId value of the enterprise in DingTalk.

idaas_ue2jvisn35ea5lmthk267xxxxx
statusstring

The status of the account. Valid values: enabled disabled

enabled
accountExpireTimelong

The time when the account expires. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1652085686179
registerTimelong

The time when the account was registered. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1652085686179
lockExpireTimelong

The time when the account lock expires. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1652085686179
createTimelong

The time when the account was created. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1652085686179
updateTimelong

The time when the account was last modified. This value is a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC.

1652085686179
descriptionstring

The description of the account.

Examples

Sample success responses

JSONformat

{
  "instanceId": "idaas_ue2jvisn35ea5lmthk267xxxxx",
  "organizationalUnits": [
    {
      "organizationalUnitId": "ou_wovwffm62xifdziem7an7xxxxx",
      "organizationalUnitName": "name001",
      "primary": true
    }
  ],
  "primaryOrganizationalUnitId": "ou_wovwffm62xifdziem7an7xxxxx",
  "customFields": [
    {
      "fieldName": "xxxx",
      "fieldValue": ""
    }
  ],
  "userId": "user_d6sbsuumeta4h66ec3il7yxxxx",
  "username": "name001",
  "displayName": "display_name001",
  "passwordSet": true,
  "phoneRegion": "86",
  "phoneNumber": "156xxxxxxx",
  "phoneNumberVerified": true,
  "email": "example@example.com",
  "emailVerified": true,
  "userExternalId": "user_d6sbsuumeta4h66ec3il7yxxxx",
  "userSourceType": "build_in",
  "userSourceId": "idaas_ue2jvisn35ea5lmthk267xxxxx",
  "status": "enabled",
  "accountExpireTime": 1652085686179,
  "registerTime": 1652085686179,
  "lockExpireTime": 1652085686179,
  "createTime": 1652085686179,
  "updateTime": 1652085686179,
  "description": "",
  "groups": [
    {
      "groupId": "group_ufdsasn35ea5lmthk267xxxxx",
      "groupName": "name_test",
      "description": "description_demo"
    }
  ]
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2023-10-24The internal configuration of the API is changed, but the call is not affectedView Change Details
2023-04-16The response structure of the API has changedView Change Details