All Products
Search
Document Center

Elastic Desktop Service:ListDirectoryUsers

Last Updated:Mar 17, 2026

If you use an Active Directory (AD) directory to connect to your enterprise AD, call this operation to retrieve user information from your enterprise AD.

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

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The region ID. To get a list of regions that WUYING Workspace supports, call DescribeRegions.

cn-hangzhou

Filter

string

No

The string for a fuzzy search. The operation returns all results that contain this string.

alice

DirectoryId

string

Yes

The AD directory ID.

cn-hangzhou+dir-jedbpr4sl9l37****

NextToken

string

No

The token used to start the next query. If this value is empty, no more results are available.

caeba0bbb2be03f84eb48b699f0a4883

MaxResults

integer

No

The number of entries to return on each page.

  • Maximum value: 100.

  • Default value: 10.

10

OUPath

string

No

The path of the organizational unit (OU) in the AD domain. You can call ListUserAdOrganizationUnits to obtain the OU path.

example.com/Domain Controllers

AssignedInfo

string

No

Note

This parameter is not publicly available. You can only set this parameter to 1 or leave it empty.

1

SortType

string

No

The sorting method.

Valid values:

  • asc :

    Lists users with assigned cloud desktops last.

  • desc :

    Lists users with assigned cloud desktops first.

asc

IncludeAssignedUser

boolean

No

Specifies whether to return only users who are assigned cloud desktops.

true

Response elements

Element

Type

Description

Example

object

The response object.

NextToken

string

The token that is used to start the next query. If this parameter is empty, all results have been returned.

caeba0bbb2be03f84eb48b699f0a4883

RequestId

string

The request ID.

1CBAFFAB-B697-4049-A9B1-67E1FC5F****

Users

array<object>

An array that consists of the users in the AD directory. If the AD directory contains only the Administrator and Guest users, an empty `Users` array is returned.

object

The user object.

EndUser

string

The username.

Alice

DisplayName

string

The display name.

Alice

AssignedDesktopNumber

integer

The number of assigned cloud desktops.

2

Email

string

The email address.

user@example.com

Phone

string

The mobile phone number.

130********

DisplayNameNew

string

UserPrincipalName

string

Examples

Success response

JSON format

{
  "NextToken": "caeba0bbb2be03f84eb48b699f0a4883",
  "RequestId": "1CBAFFAB-B697-4049-A9B1-67E1FC5F****",
  "Users": [
    {
      "EndUser": "Alice",
      "DisplayName": "Alice",
      "AssignedDesktopNumber": 2,
      "Email": "user@example.com",
      "Phone": "130********",
      "DisplayNameNew": "",
      "UserPrincipalName": ""
    }
  ]
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.