你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
适用于企业客户的报告 API - 余额和摘要
注意
2024 年 5 月 1 日,Azure 企业报告 API 将停用。 任何剩余的企业报告 API 都将停止响应请求。 在此之前,客户需要过渡到使用 Microsoft 成本管理 API。 要了解详细信息,请参阅从 Azure 企业报告迁移到 Microsoft 成本管理 API 概述。
余额和摘要 API 提供了关于余额、新购买、Azure 市场服务费用、调整和超额费用信息的每月摘要。
请求
需要添加的常见标头属性在企业客户的报告 API 概述一文中指定。 如果未指定计费周期,则返回当前计费周期的数据。
方法 | 请求 URI |
---|---|
GET | https://consumption.azure.com/v3/enrollments/{enrollmentNumber}/balancesummary |
GET | https://consumption.azure.com/v3/enrollments/{enrollmentNumber}/billingPeriods/{billingPeriod}/balancesummary |
注意
若要使用以前版本的 API,请将 v3 替换为上述 URL 中的 v2。 如果使用 v2,则某些字段不可用。
响应
{
"id": "enrollments/100/billingperiods/201507/balancesummaries",
"billingPeriodId": 201507,
"currencyCode": "USD",
"beginningBalance": 0,
"endingBalance": 1.1,
"newPurchases": 1,
"adjustments": 1.1,
"utilized": 1.1,
"serviceOverage": 1,
"chargesBilledSeparately": 1,
"totalOverage": 1,
"totalUsage": 1.1,
"azureMarketplaceServiceCharges": 1,
"newPurchasesDetails": [
{
"name": "",
"value": 1
}
],
"adjustmentDetails": [
{
"name": "Promo Credit",
"value": 1.1
},
{
"name": "SIE Credit",
"value": 1.0
}
]
}
响应属性定义
属性名称 | 类型 | 说明 |
---|---|---|
id | 字符串 | 特定计费周期和注册的唯一 ID |
billingPeriodId | 字符串 | 计费周期 ID |
currencyCode | string | 货币代码 |
beginningBalance | Decimal | 计费周期的起始余额 |
endingBalance | Decimal | 计费周期的期末余额(对于开放期,此余额将每日更新) |
newPurchases | Decimal | 新购买总量 |
调整 | Decimal | 调整总金额 |
已用量 | Decimal | 承诺使用总量 |
serviceOverage | Decimal | Azure 服务超额 |
chargesBilledSeparately | Decimal | 单独计费收费 |
totalOverage | Decimal | serviceOverage + chargesBilledSeparately |
totalUsage | Decimal | Azure 服务承诺 + 总超额 |
azureMarketplaceServiceCharges | Decimal | Azure 市场的总费用 |
newPurchasesDetails | 名称值对的 JSON 字符串数组 | 新购买列表 |
adjustmentDetails | 名称值对的 JSON 字符串数组 | 调整列表(促销贷方、SIE 贷方等) |