主题
接口描述
获取 账单金额 详情 (受限于 GET 请求参数长度限制,如需单次 100 个节点以上的查询,推荐对接 批量查询接口)
请求路径
GET
/v1/ant/amount/details
请求参数
名称 | 类型 | 位置 | 必须 | 描述 |
---|---|---|---|---|
Authorization | string | header | 是 | 鉴权 token |
nodeIds | string | form | 是 | 节点 IDs,以英文逗号分隔。最大数量为100 |
day | string | form | 是 | 日期,格式:yyyymmdd。示例:20240305 |
返回值
名称 | 类型 | 描述 |
---|---|---|
details | map[string][]AmountDetail | 账单金额 信息,key 为 nodeId,value 为 账单金额信息 |
AmountDetail
名称 | 类型 | 描述 |
---|---|---|
measuredAmount | MeasuredAmount | 账单金额详情 |
MeasuredAmount
名称 | 类型 | 描述 |
---|---|---|
originalAmount | float | 原始金额。单位:元 |
slaDeduction | float | SLA扣减金额。单位:元 |
settleAmount | float | 最终金额。单位:元 |
isBilling | bool | false 已出账 true 出账中 出账中金额不可信 备注:25年3月20号会新增 |
请求示例
json
返回值示例
json
正常请求:
http code 200
{
"details": {
"nodeId1": {
"measuredAmount": {
"originalAmount": 100,
"slaDeduction": 0,
"settleAmount": 100,
"isBilling":false,
}
},
"nodeId2": {
"measuredAmount": {
"originalAmount": 100,
"slaDeduction": 100,
"settleAmount": 0,
"isBilling":false,
}
}
}
}
异常请求:
http code 4xx/5xx
{
"code": 4000001,
"desc": ""
}
错误码列表
错误码 | 描述 |
---|---|
401 | 鉴权失败 |
如接口返回错误码未列举,可在错误码总览中查找