Querying Tenant Quotas
Function
This API is used to query the quotas of all resources for a specified tenant, including used quotas.
URI
GET /v1/{project_id}/cloudservers/limits
| Parameter | Mandatory | Description |
|---|---|---|
| project_id | Yes | Specifies the project ID. For details about how to obtain the ID, see Obtaining a Project ID. |
Request
None
Response
| Parameter | Type | Description |
|---|---|---|
| absolute | Object | Specifies tenant quotas. For details, see Table 3. |
| Parameter | Type | Description |
|---|---|---|
| maxTotalInstances | Integer | Specifies the maximum number of ECSs you can use. |
| maxTotalCores | Integer | Specifies the maximum number of CPU cores you can use. |
| maxTotalRAMSize | Integer | Specifies the maximum memory space (MB) you can use. |
| maxTotalSpotInstances | Integer | Specifies the maximum number of spot ECSs that can be requested. |
| maxTotalSpotCores | Integer | Specifies the maximum number of vCPUs of spot ECSs that can be requested. |
| maxTotalSpotRAMSize | Integer | Specifies the maximum memory capacity, in the unit of MB, of a spot ECS. |
| maxTotalKeypairs | Integer | Specifies the maximum number of SSH key pairs you can use. |
| maxServerMeta | Integer | Specifies the maximum length of the metadata you can use. |
| maxPersonality | Integer | Specifies the maximum number of files that can be injected. |
| maxPersonalitySize | Integer | Specifies the maximum size (byte) of the file to be injected. |
| maxServerGroups | Integer | Specifies the maximum number of server groups. |
| maxServerGroupMembers | Integer | Specifies the maximum number of ECSs in an ECS group. |
| totalServerGroupsUsed | Integer | Specifies the number of used server groups. |
| maxSecurityGroups | Integer | Specifies the maximum number of security groups you can use. NOTE: The quota complies with the VPC quota limit. |
| maxSecurityGroupRules | Integer | Specifies the maximum number of security group rules that you can configure in a security group. NOTE: The quota complies with the VPC quota limit. |
| maxTotalFloatingIps | Integer | Specifies the maximum number of floating IP addresses you can use. |
| maxImageMeta | Integer | Specifies the maximum length of the image metadata. |
| totalInstancesUsed | Integer | Specifies the number of used ECSs. |
| totalCoresUsed | Integer | Specifies the number of the used CPU cores. |
| totalRAMUsed | Integer | Specifies the used memory size (MB). |
| totalSpotInstancesUsed | Integer | Specifies the number of used spot ECSs. |
| totalSpotCoresUsed | Integer | Specifies the number of used vCPUs of a spot ECS. |
| totalSpotRAMUsed | Integer | Specifies the used memory capacity, in the unit of MB, of a spot ECS. |
| totalSecurityGroupsUsed | Integer | Specifies the number of used security groups. |
| totalFloatingIpsUsed | Integer | Specifies the number of used floating IP addresses. |
| limit_by_flavor | Array of objects | This parameter is not used, and the returned value is []. |
Example Request
GET https://{endpoint}/v1/{project_id}/cloudservers/limits Example Response
{
"absolute": {
"maxServerMeta": 128,
"maxPersonality": 5,
"maxImageMeta": 128,
"maxPersonalitySize": 10240,
"maxSecurityGroupRules": 20,
"maxTotalKeypairs": -1,
"totalRAMUsed": 75776,
"totalInstancesUsed": 21,
"maxSecurityGroups": 10,
"totalFloatingIpsUsed": 0,
"maxTotalCores": 20480,
"totalSecurityGroupsUsed": 1,
"maxTotalFloatingIps": 10,
"maxTotalInstances": 2048,
"totalCoresUsed": 40,
"maxTotalRAMSize": 25165824,
"maxTotalSpotInstances": 20,
"maxTotalSpotCores": 320,
"maxTotalSpotRAMSize": 655360,
"totalSpotInstancesUsed": 0,
"totalSpotCoresUsed": 0,
"totalSpotRAMUsed": 0,
"limit_by_flavor": [],
"maxServerGroups": 10,
"maxServerGroupMembers": 16,
"totalServerGroupsUsed": 2
}
} Returned Values
Error Codes
Last Article: Tenant Quota Management
Next Article: Task Status Management
Did this article solve your problem?
Thank you for your score!Your feedback would help us improve the website.