GetRemainder【获取用户配额剩余情况】¶
获取当前用户配套资源的剩余情况
Request Parameters
Parameter name | Type | Description | Required |
---|---|---|---|
action | String | API标识符 | Yes |
Response Elements
Name | Type | Description |
---|---|---|
message | String | 执行结果信息 |
code | Integer | HTTP Resonpe响应状态码 |
data | Dict | JSON 格式的配套资源剩余情况,每项参数可见下面 Data Item |
Data Item
Name | Type | Description |
---|---|---|
Remain_RAMSize | Integer | 内存剩余情况(GB) |
Remain_Instances | Integer | 可以新建的主机个数 |
Remain_FloatingIps | Integer | 可以申请的公网 IP个数 |
Remain_SecurityGroups | Integer | 可以新建的防火墙个数 |
Remain_Snapshots | Integer | 可以新建的镜像&快照个数 |
Remain_VolumeGigabytes | Integer | 可以新建的云硬盘大小(GB) |
Remain_Cores | Integer | 可以使用的CPU内核个数 |
Remain_Volumes | Integer | 可以新建的云硬盘个数 |
Example
Example Request:
Request Headers:
POST /api/ HTTP/1.1
Origin: https://console.plcloud.com
X-CSRFToken: 6An6xEuOJqW6dVDtlgzZr6FqgkSbJmqp
Content-Type: application/json
JSON Data:
{
"action": "GetRemainder"
}
Example Response:
{
"message": "Get usage successfully.",
"code": 200,
"data": {
"Remain_RAMSize": 48,
"Remain_Instances": 6,
"Remain_FloatingIps": 2,
"Remain_SecurityGroups": 11,
"Remain_Snapshots": 12,
"Remain_VolumeGigabytes": 1024,
"Remain_Cores": 24,
"Remain_Volumes": 12
}
}