Querying Quota Information
Function
This API is used to query quota information.
Calling Method
For details, see Calling APIs.
URI
GET /v5/{project_id}/billing/quotas
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
User project ID |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
enterprise_project_id |
No |
String |
Enterprise project ID. To query all enterprise projects, set this parameter to all_granted_eps. |
version |
No |
String |
HSS edition. Its value can be:
|
charging_mode |
No |
String |
Billing mode. Its value can be:
|
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
x-auth-token |
Yes |
String |
User token. It can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is a token. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
data_list |
Array of ResourceQuotasInfo objects |
Quota statistics list |
Parameter |
Type |
Description |
---|---|---|
version |
String |
HSS edition. Its value can be:
|
total_num |
Integer |
Total quotas |
used_num |
Integer |
Used quotas |
available_num |
Integer |
Total quotas |
available_resources_list |
Array of AvailableResourceIdsInfo objects |
Available resource list |
Example Requests
This API is used to query quotas of the basic edition in all enterprise projects.
GET https://{endpoint}/v5/{project_id}/billing/quotas?version=hss.version.basic&enterprise_project_id=all_granted_eps
Example Responses
Status code: 200
Quota statistics list
{ "data_list" : [ { "available_num" : 1, "available_resources_list" : [ { "current_time" : "2022-09-17T17:00:24Z", "resource_id" : "9ecb83a7-8b03-4e37-a26d-c3e90ca97eea", "shared_quota" : "shared" } ], "total_num" : 2, "used_num" : 1, "version" : "hss.version.basic" } ] }
Status Codes
Status Code |
Description |
---|---|
200 |
Quota statistics list |
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