Verificar até 50 números de uma vez
curl --request POST \
--url https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch \
--header 'Content-Type: application/json' \
--data '
{
"phones": [
"5511988887777",
"5511900000000"
]
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({phones: ['5511988887777', '5511900000000']})
};
fetch('https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch"
payload = { "phones": ["5511988887777", "5511900000000"] }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'phones' => [
'5511988887777',
'5511900000000'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch"
payload := strings.NewReader("{\n \"phones\": [\n \"5511988887777\",\n \"5511900000000\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"data": [
{
"phone": "5511988887777",
"exists": true,
"canonical_phone": "5511988887777",
"jid": "5511988887777@s.whatsapp.net",
"lid": "987654321098765@lid"
},
{
"phone": "5511900000000",
"exists": false
}
]
}{
"error": {
"code": "instance_not_found",
"message": "Instance not found or invalid token"
}
}{
"error": {
"code": "subscription_required",
"message": "Active subscription required"
}
}{
"error": {
"code": "instance_not_connected",
"message": "Instance is not connected"
}
}Verificar até 50 números de uma vez
Cada telefone recebe seu próprio resultado, na mesma ordem enviada. Imediato: exige a instância conectada (caso contrário, 409 instance_not_connected).
POST
/
instances
/
{instance_id}
/
token
/
{token}
/
phone-exists-batch
Verificar até 50 números de uma vez
curl --request POST \
--url https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch \
--header 'Content-Type: application/json' \
--data '
{
"phones": [
"5511988887777",
"5511900000000"
]
}
'const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({phones: ['5511988887777', '5511900000000']})
};
fetch('https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch"
payload = { "phones": ["5511988887777", "5511900000000"] }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'phones' => [
'5511988887777',
'5511900000000'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.wabox.me/instances/{instance_id}/token/{token}/phone-exists-batch"
payload := strings.NewReader("{\n \"phones\": [\n \"5511988887777\",\n \"5511900000000\"\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"data": [
{
"phone": "5511988887777",
"exists": true,
"canonical_phone": "5511988887777",
"jid": "5511988887777@s.whatsapp.net",
"lid": "987654321098765@lid"
},
{
"phone": "5511900000000",
"exists": false
}
]
}{
"error": {
"code": "instance_not_found",
"message": "Instance not found or invalid token"
}
}{
"error": {
"code": "subscription_required",
"message": "Active subscription required"
}
}{
"error": {
"code": "instance_not_connected",
"message": "Instance is not connected"
}
}Path Parameters
Id da instância (dashboard › instância › Credenciais).
Token da instância. Trate como senha.
Body
application/json
Required array length:
1 - 50 elementsMinimum string length:
1Pattern:
^(\d{5,20}|\d+@lid|\d+(-\d+)?-group|\d+@g\.us|\d+@newsletter|\d+@broadcast|status@broadcast)$Response
Um resultado por telefone.