curl --request POST \
--url https://api.enviaai.app/v1/contacts/check \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"instanceId": "<string>",
"phones": [
{}
]
}
'{
"success": true,
"data": [
{
"phone": "5511999999999",
"exists": true,
"jid": "[email protected]"
},
{
"phone": "5511988888888",
"exists": true,
"jid": "[email protected]"
},
{
"phone": "5511977777777",
"exists": false,
"jid": null
}
]
}
Verifique se números estão no WhatsApp
curl --request POST \
--url https://api.enviaai.app/v1/contacts/check \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"instanceId": "<string>",
"phones": [
{}
]
}
'{
"success": true,
"data": [
{
"phone": "5511999999999",
"exists": true,
"jid": "[email protected]"
},
{
"phone": "5511988888888",
"exists": true,
"jid": "[email protected]"
},
{
"phone": "5511977777777",
"exists": false,
"jid": null
}
]
}
const result = await client.contacts.check({
instanceId: 'inst_abc123',
phones: [
'5511999999999',
'5511988888888',
'5511977777777'
]
});
result.data.forEach(({ phone, exists }) => {
console.log(`${phone}: ${exists ? '✓ WhatsApp' : '✗ Não encontrado'}`);
});
{
"success": true,
"data": [
{
"phone": "5511999999999",
"exists": true,
"jid": "[email protected]"
},
{
"phone": "5511988888888",
"exists": true,
"jid": "[email protected]"
},
{
"phone": "5511977777777",
"exists": false,
"jid": null
}
]
}