跳转到内容

实时WhatsApp检测

实时检查输入的全局号码是否是WhatsApp帐户。

代码示例:

curl --location --request POST 'https://api.checknumber.ai/v1/realtime/whatsapp' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--header 'X-API-Key: AbcdEfgh' \
--data-urlencode 'number=628138800001&country=ID'

已注册WhatsApp的输入号码的响应

{
"status": "OK",
"message": {
"number": "+628138800001",
"whatsapp": "yes"
},
"pricingStrategy": "PAY",
"transactionId": "tphxc6te38gpcoyk8hkvwc"
}

未注册WhatsApp的输入号码的响应

{
"status": "OK",
"message": {
"number": "+628138800001",
"whatsapp": "no"
},
"pricingStrategy": "PAY",
"transactionId": "tphxc6te38gpcoyk8hkvwc"
}

HTTP请求

POST https://api.checknumber.ai/v1/realtime/whatsapp

请求参数

参数描述
numberstring,电话号码
countrystring国家缩写。巴西:BR,墨西哥:MX,尼日利亚:NG,印度:IN。
callbackoptionalstring,回调URL。强烈建议使用回调URL

响应格式

字段描述
status状态码
messagenumber:电话号码
whatsapp:结论

状态码

状态描述
OKchargemessage包含结果
FAILfree,无效查询
INVALID_INPUTfree,无效输入
RETRY_LATERfree,服务器错误,请稍后重试