Querying the Total Number of Resources of a User in a Cloud Vendor
Function
This API is used to query the total number of resources of a user in cloud vendors (like Alibaba Cloud, AWS, Azure, and Huawei Cloud Stack).
URI
GET /v1/multicloud-resources/count
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
vendor |
Yes |
String |
Definition Cloud vendor type. Constraints N/A Range AWS: Amazon Web Services
Default value N/A |
|
type |
No |
String |
Definition Resource type. Constraints N/A Range There are many resource types. Select a resource type based on the actual service. The common resource types are as follows:
Default value N/A |
|
resource_id_list |
No |
Array of strings |
Definition List of resource IDs selected by the user. Constraints N/A Range N/A Default value N/A |
|
name_list |
No |
Array of strings |
Definition Resource name. Constraints N/A Range List. For details, see Bare Metal Server (BMS). Default value N/A |
|
region_id_list |
No |
Array of strings |
Definition List of IDs of associated regions. Constraints N/A Range N/A Default value N/A |
Request Parameters
None
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
data |
Long |
Definition Number of cloud resources. Range The value range is 0 to 65,535. |
Status code: 400
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Definition Error code. Range The value is a string. It contains 8 to 36 characters. |
|
error_msg |
String |
Definition Error description. Range The value is a string. It contains 2 to 512 characters. |
Example Requests
Query the total number of resources of a user in a cloud vendor.
GET https://{Endpoint}/v1/multicloud-resources/count?vendor=ALI&type=ACS::ECS::Instance
Example Responses
Status code: 200
The total number of resources of the user in the cloud vendor is queried.
{
"data" : 2
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
The total number of resources of the user in the cloud vendor is queried. |
|
400 |
Failed to query the total number of resources of the user in the cloud vendor. |
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