Skip to content

wa calling query

GiuFLim edited this page Sep 22, 2025 · 8 revisions

查询calling的流水记录

使用此接口查询calling的流水记录。

接口

  • URL:https://api2.nxcloud.com/api/wa/calling/query
  • Method:POST
  • Content-Type:application/json
  • 需要鉴权:

鉴权机制

鉴权规则请参考地址:API接口调用约定

请求参数

header参数:

参数名 类型 必选 示例值 说明
accessKey String fme2na3kdi3ki 用户身份标识
ts String 1655710885431 当前请求的时间戳(单位是毫秒),牛信服务端允许用户端请求最大时间误差为60秒
bizType String 2 WhatsApp业务类型,取固定值“2”
action String mt WhatsApp业务操作,取固定值“mt”
sign String 6e9506557d1f289501d333ee2c365826 API入参参数签名,签名算法

body参数:

参数名 类型 必选 示例值 说明
appkey String pem28kje 应用appkey
business_phone String 86133xxx 商户的WhatsApp号码,需要带国码。如86158xxxx1795
call_id String call_id

请求示例1

{
    "appkey": "xxx",
    "business_phone": "xxx",
    "call_id": "outgoing:wacid.HBgNODYxMzc2MzMzOTA3MBUCABIYIDAyQ0JGREQyNkM1Qjg0ODI3NTU3Q0JBOEYwRUZEM0I3HBgMNjIyMTUwOTgwMzY2FQIAFTgA"
}

响应参数

参数名 类型 示例值 说明
code String 0
message String Success
data Object

data Object

参数名 类型 示例值 说明
app_id Integer 282 应用id
business_phone String 86133xxx 商户的WhatsApp号码,需要带国码。如86158xxxx1795
wabaId String 1 waba_id
calls Object[Array] calls信息

calls Object[Array]

参数名 类型 示例值 说明
call_id String xxx String
from String xxx 拨打方号码
to String xxx 接听方号码
costs Object 费用信息
start_time String 通话开始时间戳
end_time String 通话终止时间戳
record String 录音文件地址
call_duration Integer 20 通话时长/秒
fee_duration Integer 24 计费时长/秒
bill_type String 6+6 计费方式6+6
end_direction Integer 0 挂断方:0主叫, 1被叫,2服务器,3 未知
end_reason String Busy Here 终止原因

costs object

参数名 类型 示例值 说明
direction Integer 1 1-呼出 0-呼入
currency String USD 币种
price Double 0.33 币种对应的费用

响应结果1

{
    "code": 0,
    "message": "Success",
    "data": {
        "app_id": 282,
        "business_phone": "xxx",
        "wabaId": "xxx",
        "calls": [
            {
                "call_id": "outgoing:wacid.HBgNODYxMzc2MzMzOTA3MBUCABIYIDAyQ0JGREQyNkM1Qjg0ODI3NTU3Q0JBOEYwRUZEM0I3HBgMNjIyMTUwOTgwMzY2FQIAFTgA",
                "from": "xxx",
                "to": "xxx",
                "costs": [
                    {
                        "direction": 0,
                        "currency": "EUR",
                        "price": 0.080000
                    }
                ],
                "start_time": "1757915478",
                "end_time": "1757915509",
                "record": "https://hhd.xxx",
                "call_duration": 31,
                "fee_duration": 36,
                "bill_type": "6+6",
                "end_direction": 1,
                "end_reason": "NORMAL_CLEARING"
            }
        ]
    },
    "traceId": "0146fbd1aa46440fac0934bcc8343ca4"
}

响应结果2

{
    "code": 10014,
    "message": "Calling cdr not exist",
    "traceId": "7673af8320764892977efbb25e4077dc"
}

简介

短信

语音

云呼叫中心(NXLink)

云呼叫中心(AI自动外呼)

Flash Call

短链

邮件验证码

DID号码

通用

号码检测

WhatsApp

Viber

Zalo ZNS

Super Message API

隐私号(旧)

PNS

坐席(旧版)

AI Agent

Clone this wiki locally