接口名
QueryAccountBill
描述
查询用户某个账期内的消费,并以资源所有者的维度进行汇总。注:
- 由实例账单汇总,一般存在一天延迟。
- 暂时不包括阿里通信和万网产品。
请求参数
名称 | 类型 | 是否必填 | 说明 |
---|---|---|---|
Action | String | 是 | 要执行的操作,取值:QueryAccountBill |
BillingCycle | String | 是 | 账期,YYYY-MM。样例:2018-07 |
PageNum | String | 否 | 页码,默认值为1 |
PageSize | String | 否 | 每页数量,默认值20,最大值:300 |
OwnerID | String | 否 | 指定资源所有者的阿里云账号ID |
IsGroupByProduct | Boolean | 否 | 是否增加产品Code汇总,默认false, 仅以OwnerId汇总 |
Product code | String | 否 | 按照product code筛选订单,仅当IsGroupByProduct为true生效 |
返回参数
名称 | 类型 | 说明 |
---|---|---|
BillingCycle | String | 账期,格式:YYYY-MM |
AccountID | String | 账号ID |
AccountName | String | 账号 |
TotalCount | String | 总记录数 |
PageNum | String | 页码 |
PageSize | String | 每页数量 |
Items | Item | 账单详情 |
Item:
名称 | 类型 | 说明 |
---|---|---|
OwnerID | String | 子账号的阿里云Id) |
OwnerName | String | 子账号名称 |
CostUnit | String | 财务单元 |
ProductCode | String | 产品code,仅当IsGroupByProduct为true时返回 |
ProductName | String | 产品名称,仅当IsGroupByProduct为true时返回 |
SubscriptionType | String | 产品订阅类型,预付费:Subscription,后付费:PayAsYouGo,仅当IsGroupByProduct为true时返回 |
PretaxGrossAmount | Double | 原始金额 |
InvoiceDiscount | Double | 优惠金额 |
DeductedByCoupons | Double | 优惠券抵扣 |
PretaxAmount | Double | 应付金额 |
DeductedByCashCoupons | Double | 代金券抵扣(仅中国站) |
DeductedByPrepaidCard | Double | 储值卡抵扣(仅中国站) |
PaymentAmount | Double | 现金支付(仅中国站) |
OutstandingAmount | Double | 未结清金额或信用结算金额(普通用户的欠费, 或者信用客户信用额度消耗,仅中国站) |
Currency | String | 币种 CNY/USD/JPY |
请求示例
&Action=QueryAccountBill
&BillingCycle=2019-09
&其他公共参数
返回示例
{
"Data": {
"Items": {
"Item": [
{
"PaymentAmount": 0,
"OutstandingAmount": 0,
"DeductedByPrepaidCard": 0,
"DeductedByCashCoupons": 0,
"PretaxAmount": 0,
"CostUnit": "未分配",
"OwnerID": "1369168081849304",
"Currency": "CNY",
"DeductedByCoupons": 0,
"PretaxGrossAmount": 0,
"OwnerName": "aligzncloudtest2",
"InvoiceDiscount": 0
},
{
"PaymentAmount": 0,
"OutstandingAmount": 0,
"DeductedByPrepaidCard": 0,
"DeductedByCashCoupons": 0,
"PretaxAmount": 0,
"CostUnit": "财务单元1",
"OwnerID": "1369168081849304",
"Currency": "CNY",
"DeductedByCoupons": 0,
"PretaxGrossAmount": 0,
"OwnerName": "aligzncloudtest2",
"InvoiceDiscount": 0
}
]
},
"TotalCount": 2,
"BillingCycle": "2019-09",
"AccountID": "1369168081849304",
"PageSize": 100,
"AccountName": "aligzncloudtest2",
"PageNum": 1
},
"Message": "Successful!",
"RequestId": "A522988D-706B-4C2A-AEDA-7CF686FD8505",
"Success": true,
"Code": "Success"
}
原创文章,作者:网友投稿,如若转载,请注明出处:https://www.cloudads.cn/archives/33922.html