获取单个资源扣费信息
基本信息
Action
GetLeaseInfo
Path
/iaas
Method
GET
请求参数
此接口除公共参数外,还包含以下参数。关于公共参数的更多信息,请参见前文内容。
| 参数名 | 类型 | 是否必须 | 描述 |
|---|---|---|---|
resource |
String |
是 |
资源 ID |
user |
String |
是 |
private |
verbose |
String |
否 |
区域 ID |
返回数据
此接口除公共返回参数外,还包含以下返回参数。关于公共返回参数的更多信息,请参见前文内容。
| 参数名 | 类型 | 是否必须 | 描述 |
|---|---|---|---|
lease_info |
Object |
否 |
租赁信息 |
lease_info.console_id |
String |
否 |
Console ID |
lease_info.contract |
Object |
否 |
合同信息 |
lease_info.contract.auto_renew |
Integer |
否 |
用户设置合同到期后的续费时长 |
lease_info.contract.charge_mode |
String |
否 |
计费模式 |
lease_info.contract.console_id |
String |
否 |
Console ID |
lease_info.contract.contract_id |
String |
否 |
合同 ID |
lease_info.contract.create_time |
String |
否 |
合同创建时间 |
lease_info.contract.discount |
Integer |
否 |
合同折扣 |
lease_info.contract.duration |
String |
否 |
合同周期 |
lease_info.contract.end_time |
String |
否 |
合同结束时间 |
lease_info.contract.long_resource_id |
String |
否 |
|
lease_info.contract.next_charge_mode |
String |
否 |
用户设置合同到期转换的计费模式 |
lease_info.contract.price |
String |
否 |
合同价格 |
lease_info.contract.price_info |
Object |
否 |
合同配置 |
lease_info.contract.product_id |
String |
否 |
合同使用的促销 ID |
lease_info.contract.resource_id |
String |
否 |
资源 ID |
lease_info.contract.start_time |
String |
否 |
合同开始时间 |
lease_info.contract.zone_id |
String |
否 |
区域 ID |
lease_info.group_id |
String |
否 |
|
lease_info.lease_time |
String |
否 |
租赁开始时间 |
lease_info.renewal |
String |
否 |
系统默认资源到期后的处理模式 |
lease_info.renewal_time |
String |
否 |
租赁到期时间 |
lease_info.resource_id |
String |
否 |
资源 ID |
lease_info.root_user_id |
String |
否 |
主用户 ID |
lease_info.status |
String |
否 |
租赁状态 |
lease_info.status_time |
String |
否 |
租赁状态变更时间 |
lease_info.unlease_time |
String |
否 |
解除租赁时间 |
lease_info.user_id |
String |
否 |
用户 ID |
lease_info.zone_id |
String |
否 |
区域 ID |
resource_id |
String |
否 |
资源 ID |
请求示例
{
"action": "GetLeaseInfo",
"resource": "cl-vmk7zt7d",
"zone": "pek3"
}
返回示例
{
"action": "GetLeaseInfoResponse",
"lease_info": {
"console_id": "qingcloud",
"contract": {
"auto_renew": null,
"charge_mode": "monthly",
"console_id": "qingcloud",
"contract_id": "ct-8rSs32LY",
"create_time": "2021-11-01T01:49:02Z",
"discount": 100,
"duration": "1 month",
"end_time": null,
"group_id": "2",
"long_resource_id": null,
"next_charge_mode": null,
"price": "726.864",
"price_info": {
"aid": "app-o1rl71en",
"avv": "public",
"cid": "cl-vmk7zt7d",
"md": {
"nd": [
{
"c": 2,
"cls": 202,
"cnt": 3,
"g": 0,
"gcls": 0,
"hpvr": "kvm",
"m": 4096,
"r": "replica",
"repl": 1,
"sc": 200,
"stor": 100
}
]
},
"pts": [
"cluster"
],
"stat": "active",
"zone": "pek3c"
},
"product_id": null,
"resource_id": "cl-vmk7zt7d",
"start_time": "2021-11-01T01:49:02Z",
"zone_id": "pek3"
},
"group_id": "2",
"lease_time": "2020-09-29T23:26:24Z",
"renewal": "auto",
"renewal_time": "2021-12-01T01:49:02Z",
"resource_id": "cl-vmk7zt7d",
"root_user_id": "usr-lKV1fd7l",
"status": "active",
"status_time": "2020-09-29T23:26:25Z",
"unlease_time": null,
"user_id": "usr-lKV1fd7l",
"zone_id": "pek3"
},
"resource_id": "cl-vmk7zt7d",
"ret_code": 0
}