Querying Tenant Quotas
Function
This API is used to query the maximum number of instances that a tenant can create, the number of created instances, and the maximum number of tags that can be created for each instance.
URI
GET /v2/{project_id}/quotas
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition Project ID. For details about how to obtain it, see Obtaining a Project ID. Constraints N/A Range N/A Default Value N/A |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| includeTagsQuota | No | String | Definition Whether a tag quota flag is included. Constraints N/A Range Default Value true |
| onlyQuota | No | String | Definition Queries quotas of a specified engine. Constraints N/A Range Default Value N/A |
Request Parameters
None
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| quotas | quotas object | Definition Quota information. Constraints N/A Range N/A Default Value N/A |
| Parameter | Type | Description |
|---|---|---|
| resources | Array of QuotaResourceEntity objects | Definition Quota list. Constraints N/A Range N/A Default Value N/A |
| Parameter | Type | Description |
|---|---|---|
| type | String | Definition Supports rabbitmqInstance, kafkaInstance, rocketmqInstance, and tags. Constraints N/A Range N/A Default Value N/A |
| quota | Integer | Definition The maximum number of instances that a tenant can create, or the maximum number of tags that can be created for each instance. Constraints N/A Range N/A Default Value N/A |
| used | Integer | Definition Number of created instances. Constraints N/A Range N/A Default Value N/A |
Example Requests
GET https://{endpoint}/v2/{project_id}/quotas?includeTagsQuota=false&onlyQuota=reliability Example Responses
Status code: 200
Successful
{
"quotas" : {
"resources" : [ {
"type" : "rabbitmqInstance",
"quota" : 100,
"used" : 3
}, {
"type" : "kafkaInstance",
"quota" : 100,
"used" : 17
}, {
"type" : "rocketmqInstance",
"quota" : 100,
"used" : 17
}, {
"type" : "tags",
"quota" : 20
} ]
}
} Status Codes
| Status Code | Description |
|---|---|
| 200 | Successful |
Error Codes
See Error Codes.
What is your overall rating for this page?
Thank 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