Querying Desktop Networks in Batches
Function
Queries desktop VPCs, subnets, private IP addresses, EIPs, and security groups.
Debugging
You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.
Authorization Information
Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
- If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
workspace:desktops:listDesktopNetworks
List
desktop *
-
-
- vpc:vpcs:get
- vpc:subnets:get
- vpc:networks:get
- vpc:ports:get
- vpc:securityGroups:get
- eip:publicIps:list
URI
GET /v2/{project_id}/desktops/networks
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Project ID. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
desktop_ids |
No |
Array of strings |
Desktop IDs. The value ranges from 1 to 100. |
Request Parameters
None
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
networks |
Array of DesktopNetworkResult objects |
Desktop network information list. |
|
Parameter |
Type |
Description |
|---|---|---|
|
computer_name |
String |
Desktop name. |
|
computer_id |
String |
Desktop ID. |
|
computer_ip |
String |
Desktop IP address. |
|
network_infos |
Array of NetworkInfo objects |
Desktop network information. |
|
Parameter |
Type |
Description |
|---|---|---|
|
vpc_info |
Vpc object |
VPC information. |
|
subnet_info |
DesktopSubnet object |
Subnet information. |
|
port_info |
Port object |
Private IP address information. |
|
public_ip_info |
PublicIp object |
EIP information. |
|
security_groups |
Array of SecurityGroupInfo objects |
Security groups bound to the desktop. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
ID of the VPC where the desktop is located. |
|
name |
String |
Name of the VPC where the desktop is located. |
|
cidr |
String |
VPC CIDR block where the desktop is located. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
ID of the subnet where the desktop is located. |
|
name |
String |
Name of the subnet where the desktop is located. |
|
cidr |
String |
Subnet CIDR block where the desktop is located. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
Unique ID of the private IP address. |
|
ip_address |
String |
Private IP address. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
Unique ID of the EIP. |
|
public_ip_address |
String |
EIP. |
|
Parameter |
Type |
Description |
|---|---|---|
|
id |
String |
Security group ID. |
|
name |
String |
Security group name. |
Status code: 400
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code, which is returned upon failure. |
|
error_msg |
String |
Error message. |
|
error_detail |
String |
Error details. |
|
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Status code: 401
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code, which is returned upon failure. |
|
error_msg |
String |
Error message. |
|
error_detail |
String |
Error details. |
|
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Status code: 403
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code, which is returned upon failure. |
|
error_msg |
String |
Error message. |
|
error_detail |
String |
Error details. |
|
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Status code: 404
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code, which is returned upon failure. |
|
error_msg |
String |
Error message. |
|
error_detail |
String |
Error details. |
|
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Status code: 409
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code, which is returned upon failure. |
|
error_msg |
String |
Error message. |
|
error_detail |
String |
Error details. |
|
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Status code: 500
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code, which is returned upon failure. |
|
error_msg |
String |
Error message. |
|
error_detail |
String |
Error details. |
|
encoded_authorization_message |
String |
Encrypted detailed reason for rejection. You can call the API decode-authorization-message of STS to decrypt the reason. |
Example Requests
None
Example Responses
Status code: 200
Normal.
{
"networks" : [ {
"computer_name" : "string",
"computer_id" : "string",
"computer_ip" : "string",
"network_infos" : [ {
"vpc_info" : {
"id" : "string",
"name" : "string",
"cidr" : "string"
},
"subnet_info" : {
"id" : "string",
"name" : "string",
"cidr" : "string"
},
"port_info" : {
"id" : "string",
"ip_address" : "string"
},
"public_ip_info" : {
"id" : "string",
"public_ip_address" : "string"
},
"security_groups" : [ {
"id" : "string",
"name" : "string"
} ]
} ]
} ]
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Normal. |
|
400 |
The request cannot be understood by the server due to malformed syntax. |
|
401 |
Authentication failed. |
|
403 |
No operation permissions. |
|
404 |
No resources found. |
|
409 |
Operation conflict. |
|
500 |
An internal service error occurred. For details about the error code, see the error code description. |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot