文档中心 > 计费相关 > API 文档 > 账单管理相关接口 > 获取按付费模式汇总费用分布

获取按付费模式汇总费用分布

最近更新时间:2021-09-13 08:03:24

我的收藏

1. 接口描述

接口请求域名: billing.tencentcloudapi.com 。

获取按付费模式汇总费用分布

默认接口请求频率限制:20次/秒。

推荐使用 API Explorer
点击调试
API Explorer 提供了在线调用、签名验证、SDK 代码生成和快速检索接口等能力。您可查看每次调用的请求内容和返回结果以及自动生成 SDK 调用示例。

2. 输入参数

以下请求参数列表仅列出了接口请求参数和部分公共参数,完整公共参数列表见 公共请求参数

参数名称 必选 类型 描述
Action String 公共参数,本接口取值:DescribeBillSummaryByPayMode。
Version String 公共参数,本接口取值:2018-07-09。
Region String 公共参数,本接口不需要传递此参数。
BeginTime String 目前必须和EndTime相同月份,不支持跨月查询,且查询结果是整月数据,例如 BeginTime为2018-09,EndTime 为 2018-09,查询结果是 2018 年 9 月数据。
EndTime String 目前必须和BeginTime为相同月份,不支持跨月查询,且查询结果是整月数据,例如 BeginTime为2018-09,EndTime 为 2018-09,查询结果是 2018 年 9 月数据。
PayerUin String 查询账单数据的用户UIN

3. 输出参数

参数名称 类型 描述
Ready Integer 数据是否准备好,0未准备好,1准备好
SummaryOverview Array of PayModeSummaryOverviewItem 各付费模式花费分布详情
注意:此字段可能返回 null,表示取不到有效值。
RequestId String 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。

4. 示例

示例1 获取按付费模式汇总费用分布

输入示例

https://billing.tencentcloudapi.com/?Action=DescribeBillSummaryByPayMode
&BeginTime=2018-11
&EndTime=2018-11
&<公共请求参数>

输出示例

{
  "Response": {
    "Ready": 1,
    "SummaryOverview": [
      {
        "PayMode": "prePay",
        "PayModeName": "包年包月",
        "RealTotalCost": "0.00",
        "TotalCost": "-",
        "CashPayAmount": "0.00",
        "IncentivePayAmount": "0.00",
        "VoucherPayAmount": "0.00",
        "RealTotalCostRatio": "0.00",
        "Detail": [
          {
            "ActionType": "prepay_purchase",
            "ActionTypeName": "包年包月新购",
            "RealTotalCost": "0.00",
            "TotalCost": "-",
            "CashPayAmount": "0.00",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "0.00",
            "RealTotalCostRatio": "100.00",
            "BillMonth": "2021-01"
          }
        ]
      },
      {
        "PayMode": "postPay",
        "PayModeName": "按量计费",
        "RealTotalCost": "224.81",
        "TotalCost": "-",
        "CashPayAmount": "206.12",
        "IncentivePayAmount": "0.00",
        "VoucherPayAmount": "18.69",
        "RealTotalCostRatio": "100.00",
        "Detail": [
          {
            "ActionType": "recon_deduct",
            "ActionTypeName": "调账扣费",
            "RealTotalCost": "206.45",
            "TotalCost": "-",
            "CashPayAmount": "206.45",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "0.00",
            "RealTotalCostRatio": "87.39",
            "BillMonth": "2021-01"
          },
          {
            "ActionType": "postpay_deduct_s",
            "ActionTypeName": "竞价实例小时结",
            "RealTotalCost": "26.78",
            "TotalCost": "-",
            "CashPayAmount": "6.30",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "20.48",
            "RealTotalCostRatio": "11.34",
            "BillMonth": "2021-01"
          },
          {
            "ActionType": "billVirtualId",
            "ActionTypeName": "月度计费精度差异",
            "RealTotalCost": "2.98",
            "TotalCost": "-",
            "CashPayAmount": "0.70",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "2.28",
            "RealTotalCostRatio": "1.26",
            "BillMonth": "2021-01"
          },
          {
            "ActionType": "postpay_deduct_m",
            "ActionTypeName": "按量计费月结",
            "RealTotalCost": "0.02",
            "TotalCost": "-",
            "CashPayAmount": "0.00",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "0.02",
            "RealTotalCostRatio": "0.01",
            "BillMonth": "2021-01"
          },
          {
            "ActionType": "postpay_deduct_d",
            "ActionTypeName": "按量计费日结",
            "RealTotalCost": "0.00",
            "TotalCost": "-",
            "CashPayAmount": "0.00",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "0.00",
            "RealTotalCostRatio": "0.00",
            "BillMonth": "2021-01"
          },
          {
            "ActionType": "recon_increase",
            "ActionTypeName": "调账补偿",
            "RealTotalCost": "-2.00",
            "TotalCost": "-",
            "CashPayAmount": "-2.00",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "0.00",
            "RealTotalCostRatio": "0.00",
            "BillMonth": "2021-01"
          },
          {
            "ActionType": "recon_increase_d",
            "ActionTypeName": "优惠补偿",
            "RealTotalCost": "-9.42",
            "TotalCost": "-",
            "CashPayAmount": "-5.33",
            "IncentivePayAmount": "0.00",
            "VoucherPayAmount": "-4.09",
            "RealTotalCostRatio": "0.00",
            "BillMonth": "2021-01"
          }
        ]
      }
    ],
    "RequestId": "cbe90413-4027-4c7d-a6de-82bc57db396c"
  }
}

5. 开发者资源

腾讯云 API 平台

腾讯云 API 平台 是综合 API 文档、错误码、API Explorer 及 SDK 等资源的统一查询平台,方便您从同一入口查询及使用腾讯云提供的所有 API 服务。

API Inspector

用户可通过 API Inspector 查看控制台每一步操作关联的 API 调用情况,并自动生成各语言版本的 API 代码,也可前往 API Explorer 进行在线调试。

SDK

云 API 3.0 提供了配套的开发工具集(SDK),支持多种编程语言,能更方便的调用 API。

命令行工具

6. 错误码

以下仅列出了接口业务逻辑相关的错误码,其他错误码详见 公共错误码

错误码 描述
InternalError 内部错误。
InternalError.GatewayError 网关错误。
InvalidParameter 参数错误。
InvalidParameterValue 参数取值错误。
目录