Reviewed-by: Gladkov, Maksim <mgladkov@noreply.gitea.eco.tsi-dev.otc-service.com> Co-authored-by: wangdengke2 <wangdengke2@huawei.com> Co-committed-by: wangdengke2 <wangdengke2@huawei.com>
19 KiB
Querying Enterprise Project Quotas
Function
This API is used to query enterprise project quotas.
URI
GET https://{Endpoint}/v3/{project_id}/enterprise-projects/quotas
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
project_id |
Yes |
String |
Project ID of a tenant in a region. To obtain this value, see Obtaining a Project ID. |
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
enterprise_project_name |
No |
String |
Enterprise project name. Fuzzy search is supported. If this parameter is not specified, all enterprise project quotas are returned. |
offset |
No |
Integer |
Index offset.
|
limit |
No |
Integer |
Maximum records to be queried.
|
Request Parameters
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
X-Auth-Token |
Yes |
String |
User token |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
|---|---|---|
total_count |
Integer |
Total number of records |
quotas |
objects |
Enterprise project quotas. For details, see Table 5. |
Parameter |
Type |
Description |
|---|---|---|
enterprise_project_id |
String |
Enterprise project ID |
enterprise_project_name |
String |
Enterprise project name |
quota |
object |
Enterprise project quotas. For details, see Table 6. |
used |
object |
Enterprise project quota used. For details, see Table 7. |
Example Requests
- URI example
GET https://{Endpoint}/v3/0549b4a43100d4f32f51c01c2fe4acdb/enterprise-projects/quotas?enterprise_project_name=test&offset=1&limit=10
Example Responses
Status code: 200
Success.
{
"quotas" : [ {
"enterprise_project_id" : "c0348bb1-d09d-4ee2-8edd-53e496fe6b52",
"enterprise_project_name" : "test1",
"quota" : {
"instance" : 500,
"vcpus" : 1000,
"ram" : 2000
},
"used" : {
"instance" : 15,
"vcpus" : 88,
"ram" : 256
}
}, {
"enterprise_project_id" : "780a6b1f-58b8-4df6-a85e-326d052de704",
"enterprise_project_name" : "test2",
"quota" : {
"instance" : 500,
"vcpus" : 1000,
"ram" : 2000
},
"used" : {
"instance" : 36,
"vcpus" : 64,
"ram" : 192
}
} ],
"total_count" : 2
}
Status Codes
See Status Codes.
Error Codes
See Error Codes.