You can call this operation to query the details of cloud desktops.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer automatically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes DescribeDesktops

The operation that you want to perform. Set the value to DescribeDesktops.

RegionId String Yes cn-hangzhou

The ID of the region.

DesktopStatus String No Running

The status of the cloud desktop. Valid values:

  • Pending
  • Starting
  • Running
  • Stopping
  • Stopped
  • Expired
  • Deleted
MaxResults Integer No 10

The number of entries to return on each page.

Valid values: 1 to 100.

Default value: 10.

NextToken String No caeba0bbb2be03f84eb48b699f0a4883

The token used to start the next query. If the value of this parameter is empty, all results are returned.

DesktopName String No testDesktopName

The name of the cloud desktop.

DirectoryId String No cn-hangzhou+dir-jedbpr4sl9l37****

The ID of the directory.

PolicyGroupId String No system-all-enabled-policy

The ID of the policy.

DesktopId.N RepeatList No ecd-gx2x1dhsmucyy****

The ID of cloud desktop N. You can specify one or more cloud desktop IDs. Valid values of N: 1 to 100.

EndUserId.N RepeatList No 123456789

The ID of user N who is authorized to use the cloud desktop. You can specify one or more user IDs. Valid values of N: 1 to 100.

Note Only one user can use the desktop at a time.

Response parameters

Parameter Type Example Description
Desktops Array of Desktop

Details of the cloud desktops.

ChargeType String PostPaid

The billing method of the cloud desktop. Valid values:

  • PostPaid: pay-as-you-go
  • PrePaid: subscription
ConnectionStatus String Disconnected

The connection status of the user. Valid values:

  • Connected
  • Disconnected
  • Unknown
Cpu Integer 2

The number of CPUs of the cloud desktop.

CreationTime String 2020-11-06T08:28Z

The time when the cloud desktop was created.

DataDiskCategory String null
Note This parameter is in invitational preview and not available.
DataDiskSize String null
Note This parameter is in invitational preview and not available.
DesktopId String ecd-gx2x1dhsmucyy****

The ID of the cloud desktop.

DesktopName String testDesktopName

The name of the cloud desktop.

DesktopStatus String Running

The status of the cloud desktop.

DesktopType String ecd.basic.large

The specification of the cloud desktop.

DirectoryId String cn-hangzhou+dir-jedbpr4sl9l37****

The ID of the directory.

Disks Array of Disk

Details of the disks.

DiskId String d-jedbpr4sl9l37****

The ID of the disk.

DiskSize Integer 80

The size of the disk. Unit: GiB.

DiskType String system

The type of the disk. Valid values:

  • system: system disk
  • data: data disk
EndUserIds List 123456789

The IDs of users who are authorized to log on to the cloud desktop.

ExpiredTime String 2099-12-31T15:59Z

The time when the cloud desktop expires. This parameter has a value only when the billing method of the cloud desktop is subscription.

ImageId String m-4zfb6zj728hhr****

The ID of the image.

Memory Long 4096

The size of the memory. Unit: MiB.

NetworkInterfaceId Long 123456

The ID of the secondary NIC created by Elastic Cloud Desktop for the RAM or AD user. You are not authorized to modify this parameter.

PolicyGroupId String system-all-enabled-policy

The ID of the policy.

SystemDiskCategory String null
Note This parameter is in invitational preview and not available.
SystemDiskSize Integer 0
Note This parameter is in invitational preview and not available.
NextToken String caeba0bbb2be03f84eb48b699f0a4883

The token used to start the next query. If the value of this parameter is empty, all results are returned.

RequestId String 484256DA-D816-44D2-9D86-B6EE4D5BA78C

The ID of the request.

Examples

Sample requests

https://ecd.cn-hangzhou.aliyuncs.com/?Action=DescribeDesktops
&MaxResults=10
&DesktopId.1=ecd-gx2x1dhsmucyy****
&<Common request parameters>

Sample success responses

XML format

<DescribeDesktopsResponse>
      <RequestId>484256DA-D816-44D2-9D86-B6EE4D5BA78C</RequestId>
      <NextToken>caeba0bbb2be03f84eb48b699f0a4883</NextToken>
      <Desktops>
            <PolicyGroupId>system-all-enabled-policy</PolicyGroupId>
            <Memory>4096</Memory>
            <DesktopName>testDesktopName</DesktopName>
            <DesktopId>ecd-gx2x1dhsmucyy****</DesktopId>
            <Cpu>2</Cpu>
            <EndUserIds>123456789</EndUserIds>
            <NetworkInterfaceId>123456</NetworkInterfaceId>
            <DesktopStatus>Running</DesktopStatus>
            <DirectoryId>cn-hangzhou+dir-akchwgcm706le****</DirectoryId>
            <DesktopType>ecd.basic.large</DesktopType>
            <ChargeType>PostPaid</ChargeType>
            <ExpiredTime>2099-12-31T15:59Z</ExpiredTime>
            <CreationTime>2020-11-06T08:28Z</CreationTime>
            <ImageId>m-4zfb6zj728hhr****</ImageId>
            <Disks>
                  <DiskId>d-jedbpr4sl9l37****</DiskId>
                  <DiskSize>80</DiskSize>
                  <DiskType>system</DiskType>
            </Disks>
            <ConnectionStatus>Disconnected</ConnectionStatus>
      </Desktops>
</DescribeDesktopsResponse>

JSON format

{
    "RequestId":"484256DA-D816-44D2-9D86-B6EE4D5BA78C",
    "NextToken":"caeba0bbb2be03f84eb48b699f0a4883",
    "Desktops":[
        {
            "PolicyGroupId":"system-all-enabled-policy",
            "Memory":"4096",
            "DesktopName":"testDesktopName",
            "DesktopId":"ecd-gx2x1dhsmucyy****",
            "Cpu":"2",
            "EndUserIds":[
                "123456789"
            ],
            "NetworkInterfaceId":"123456",
            "DesktopStatus":"Running",
            "DirectoryId":"cn-hangzhou+dir-akchwgcm706le****",
            "DesktopType":"ecd.basic.large",
            "ChargeType":"PostPaid",
            "ExpiredTime":"2099-12-31T15:59Z",
            "CreationTime":"2020-11-06T08:28Z",
            "ImageId":"m-4zfb6zj728hhr****",
            "Disks":{
                    "DiskId": "d-jedbpr4sl9l37****",
                    "DiskSize": "80",
                    "DiskType": "system"
                },
            "ConnectionStatus":"Disconnected"
        }
    ]
}

Error codes

For a list of error codes, visit the API Error Center.