查询桌面连接状态列表 - ListDesktopsConnectStatus
功能介绍
查询桌面连接状态列表。
调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
授权信息
账号具备所有API的调用权限,如果使用账号下的IAM用户调用当前API,该IAM用户需具备调用API所需的权限。
- 如果使用角色与策略授权,具体权限要求请参见权限和授权项。
- 如果使用身份策略授权,当前API调用无需身份策略权限。
URI
GET /v2/{project_id}/connect-desktops
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
project_id | 是 | String | 项目ID。 |
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
user_names | 否 | Array of strings | 桌面所属用户,批量筛选,最多不超过100个用户。 |
connect_status | 否 | String | 桌面的连接状态。 |
offset | 否 | Integer | 从查询结果中的第几条数据开始返回,用于分页查询,取值范围0-2000,默认从0开始。 |
limit | 否 | Integer | 查询结果中想要返回的信息条目数量,用于分页查询,取值范围0-2000,默认值100。 |
请求参数
无
响应参数
状态码:200
参数 | 参数类型 | 描述 |
|---|---|---|
desktops | Array of ConnectDesktopsInfo objects | 桌面连接信息列表。 |
total_count | Integer | 桌面总数。 |
参数 | 参数类型 | 描述 |
|---|---|---|
desktop_id | String | 桌面id。 |
desktop_name | String | 桌面名称。 |
connect_status | String | 桌面的连接状态。 |
attach_users | Array of AttachUsersInfo objects | 桌面已分配的用户或用户组信息列表。 |
参数 | 参数类型 | 描述 |
|---|---|---|
id | String | 当type字段为USER时,填写用户id;当type字段为GROUP时,填写用户组id,后端服务会校验组id是否存在; |
name | String | 桌面分配对象的名称,当type类型USER时填写用户名字;当type类型GROUP时填写用户组名称。 |
user_group | String | 桌面用户所属的用户组。 |
type | String | 对象类型,可选值为: |
状态码:400
参数 | 参数类型 | 描述 |
|---|---|---|
error_code | String | 错误码,失败时返回。 |
error_msg | String | 错误描述。 |
error_detail | String | 错误详情。 |
encoded_authorization_message | String | 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 |
状态码:401
参数 | 参数类型 | 描述 |
|---|---|---|
error_code | String | 错误码,失败时返回。 |
error_msg | String | 错误描述。 |
error_detail | String | 错误详情。 |
encoded_authorization_message | String | 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 |
状态码:403
参数 | 参数类型 | 描述 |
|---|---|---|
error_code | String | 错误码,失败时返回。 |
error_msg | String | 错误描述。 |
error_detail | String | 错误详情。 |
encoded_authorization_message | String | 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 |
状态码:404
参数 | 参数类型 | 描述 |
|---|---|---|
error_code | String | 错误码,失败时返回。 |
error_msg | String | 错误描述。 |
error_detail | String | 错误详情。 |
encoded_authorization_message | String | 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 |
状态码:500
参数 | 参数类型 | 描述 |
|---|---|---|
error_code | String | 错误码,失败时返回。 |
error_msg | String | 错误描述。 |
error_detail | String | 错误详情。 |
encoded_authorization_message | String | 加密后的详细拒绝原因,用户可以自行调用STS服务的decode-authorization-message接口进行解密。 |
请求示例
GET /v2/0bec5db98280d2d02fd6c00c2de791ce/connect-desktops
响应示例
状态码:200
查询云桌面详情列表响应。
{
"desktops" : [ {
"desktop_id" : "string",
"desktop_name" : "string",
"connect_status" : "string",
"attach_users" : [ {
"id" : "string",
"name" : "string",
"user_group" : "string",
"type" : "USER"
} ]
} ],
"total_count" : 0
} 状态码
状态码 | 描述 |
|---|---|
200 | 查询云桌面详情列表响应。 |
400 | 由于包含语法错误,当前请求无法被服务器理解。 |
401 | 鉴权失败。 |
403 | 没有操作权限。 |
404 | 找不到资源。 |
500 | 服务内部错误,具体返回错误码请参见错误码说明。 |
错误码
请参见错误码。

