Reviewed-by: Drobnak, David <david.drobnak@t-systems.com> Co-authored-by: Hasko, Vladimir <vladimir.hasko@t-systems.com> Co-committed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com>
21 KiB
Querying Enterprise Project Resource Quotas of a Tenant
Function
This API is used to obtain the resource quotas of a specified enterprise project. Before calling this API:
- Learn how to authorize and authenticate it.
- Obtain the required region and endpoint.
URI
- URI format
- Example
GET https://gaussdb-mysql.eu-de.otc.t-systems.com/mysql/v3/619d3e78f61b4be68bc5aa0b59edcf7b/quotas
- Parameter description
Table 1 Parameter description Name
Mandatory
Description
project_id
Yes
Project ID of a tenant in a region.
To obtain this value, see Obtaining a Project ID.
offset
No
Index offset. If offset is set to N, the resource query starts from the N+1 piece of data. The value is 0 by default, indicating that the query starts from the first piece of data. The value cannot be a negative number.
limit
No
Number of records to be queried. The default value is 10. The value must be a positive integer. The minimum value is 1 and the maximum value is 100.
enterprise_project_name
No
Enterprise project name.
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
User token. |
X-Language |
No |
String |
Language. |
Content-Type |
Yes |
String |
MIME type of the request body. You are advised to use the default value application/json. For APIs used to upload objects or images, the value can vary depending on the flow type. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
quota_list |
Array of quota objects |
Quota information list. |
total_count |
Integer |
Number of quota records. |
Parameter |
Type |
Description |
---|---|---|
enterprise_project_id |
String |
Enterprise project ID. |
enterprise_project_name |
String |
Enterprise project name. |
instance_quota |
Integer |
Quota of the DB instance quantity. |
vcpus_quota |
Integer |
Quota of vCPUs. |
ram_quota |
Integer |
Memory quota in GB. |
availability_instance_quota |
Integer |
Remaining quota of DB instances. |
availability_vcpus_quota |
Integer |
Remaining quota of vCPUs. |
availability_ram_quota |
Integer |
Remaining memory quota. |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code. |
error_msg |
String |
Error message. |
Status code: 500
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code. |
error_msg |
String |
Error message. |
Example Request
GET https://gaussdb-mysql.eu-de.otc.t-systems.com/mysql/v3/619d3e78f61b4be68bc5aa0b59edcf7b/quotas
Example Response
Status code: 200
Success.
{ "quota_list" : [ { "enterprise_project_id" : "0", "enterprise_project_name" : "default", "instance_quota" : 20, "vcpus_quota" : 20, "ram_quota" : 40, "availability_instance_quota" : 1, "availability_vcpus_quota" : 4, "availability_ram_quota" : 8 } ] }
Status Code
For details, see Status Codes.
Error Code
For details, see Error Codes.