Querying Tenant Resource Details
Function
Queries the details of resources allocated to a common tenant.
Calling Method
For details, see Calling APIs.
Authorization Information
Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions. For details about the required permissions, see Permissions Policies and Supported Actions.
URI
GET /v1/{project_id}/tenants/resource/assignrecourd
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
project_id |
Yes |
String |
Project ID. For details about how to obtain the project ID, see Obtaining a Project ID. |
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
limit |
No |
Integer |
Number of items displayed on each page. Value range: 1~100 Default value: 10 |
|
offset |
No |
Integer |
Offset where the query starts. Value range: 0~2147483647 Default value: 0 |
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
X-Auth-Token |
No |
String |
User token. This parameter is mandatory when token authentication is used. You can obtain the token by calling the IAM API used to obtain a user token. Value of X-Subject-Token in the response header. |
Response Parameters
Status code: 200
|
Parameter |
Type |
Description |
|---|---|---|
|
X-Request-Id |
String |
Request ID. |
|
Parameter |
Type |
Description |
|---|---|---|
|
customer_project_id |
String |
Tenant ID. |
|
customer_name |
String |
Name of the associated tenant. |
|
region_id |
String |
AZ of the tenant. |
|
resource_count |
Integer |
Total number of records in the allocation table, which is used for pagination. Value range: 0~2147483647 |
|
resources |
Array of AllocateSpResourceInfo objects |
Resources allocated to the tenant. |
|
resources_overview |
Array of AllocateSpResourceSummaryInfo objects |
Summary of resources allocated to the tenant. |
|
Parameter |
Type |
Description |
|---|---|---|
|
assignment_record_id |
String |
Resource allocation record ID. |
|
resource_spec_code |
String |
Resource specification code. |
|
charging_mode |
String |
Resource billing type. |
|
resource_num |
Double |
Resource quantity. Value range: 0~2147483647 |
|
resource_used_num |
Double |
Number of used resources. Value range: 0~2147483647 |
|
resource_allocate_time |
Long |
Resource allocation time (UTC time), which is a Unix time. The value is accurate to seconds. Value range: 0~2147483647 |
|
resource_expire_time |
Long |
Resource expiration time (UTC time), which is a Unix time. The value is accurate to seconds. Value range: 0~2147483647 |
|
Parameter |
Type |
Description |
|---|---|---|
|
resource_spec_code |
String |
Resource specification code. |
|
resource_num |
Double |
Resource quantity. Value range: 0~2147483647 |
|
resource_used_num |
Double |
Number of used resources. Value range: 0~2147483647 |
|
resource_remind_quota |
Double |
Remaining resources in TMS. Value range: 0~2147483647 |
Status code: 400
|
Parameter |
Type |
Description |
|---|---|---|
|
error_code |
String |
Error code. |
|
error_msg |
String |
Error description. |
Example Requests
None
Example Responses
Status code: 400
Parameters error, including the error code and its description.
{
"error_code" : "MSS.00000003",
"error_msg" : "Invalid parameter"
}
Status Codes
|
Status Code |
Description |
|---|---|
|
200 |
Succeeded. |
|
400 |
Parameters error, including the error code and its description. |
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