API V1:

Método padrão post texto

$url = “https://painel.zapsac.com/api/send/TOKEN”;
$handle = curl_init($url);
curl_setopt($handle, CURLOPT_POST, true);
curl_setopt($handle, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($handle, CURLOPT_RETURNTRANSFER,1);
curl_setopt($handle, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($handle, CURLOPT_POSTFIELDS, [
‘nome’ => ‘Teste’,
‘message’ => ‘teste envio’,
‘celular’ => ‘5516982553000’
]);
$dados = curl_exec($handle);
curl_close($handle);

Método padrão post doc

Voce tem que mudar de send para send-image e mais 2 parâmetros

curl_setopt($handle, CURLOPT_POSTFIELDS, [
‘nome’ => ‘Teste’,
‘message’ => ‘teste envio’,
‘celular’ => ‘5516982553000’,
‘file’ => ‘URL DO ARQUIVO AQUI’,
‘extensao’ => ‘.pdf’
]);

Envio de mídia (imagens) via get

https://painel.zapsac.com/api/send-image/SEU-TOKEN?celular=CELULAR-RECEBEDOR&message=MENSAGEM-FORMATO-ENCODER&file=CAMINHO-COMPLETO&extensao=TIPO-DE-EXTENSÃO

ex.:
https://painel.zapsac.com/api/send-image/0d0dd95128330040000a46a3b523a5e15b?celular=5531999357380&message=teste&file=https://fileswhats.nyc3.digitaloceanspaces.com/public/admin/sistema/1/chat/3103306/dzXGiLxi9jjoXQIyzU08jlNBBTj0z2MnUgKjixIx.pdf&extensao=pdf

Tornar o atendimento manual via get

https://painel.zapsac.com/api/send/SEU-TOKEN?celular=CELULAR-RECEBEDOR&message=Teste&manual=true

ex.:
https://painel.zapsac.com/api/send/0d0dd95128330040000a46a3b523a5e15b?celular=5531999357380&message=Teste&manual=true

Tornar o atendimento manual e jogar para um atendente especifico via get

https://painel.zapsac.com/api/send/SEU-TOKEN?celular=CELULAR-RECEBEDOR&message=Teste&manual=true&userEmail=EMAIL-DO-USUÁRIO

https://painel.zapsac.com/api/send/0d0dd95128330040000a46a3b523a5e15b?celular= 5531999357380&message=Tewste2&manual=true&userEmail=contato3@zapsac.com

Método de envio em PHP ou sistemas envio e recebimento de informações

$url = “https://simplechat.com.br/api/send/TOKEN”;
$handle = curl_init($url);
curl_setopt($handle, CURLOPT_POST, true); curl_setopt($handle, CURLOPT_SSL_VERIFYPEER, false); curl_setopt($handle, CURLOPT_RETURNTRANSFER,1); curl_setopt($handle, CURLOPT_FOLLOWLOCATION, true); curl_setopt($handle, CURLOPT_POSTFIELDS, [

‘nome’ => ‘Teste’,
‘message’ => ‘teste envio’, ‘celular’ => ‘5516982553000’

]);
$dados = curl_exec($handle); curl_close($handle);

Recebimento Webhook


$dados = $_POST;
$remetente = $dados[‘from’];
$destinatario = $dados[‘to’];
$mensagem = $dados[‘message’];

API V2:

Uso de cookies: Guardamos estatísticas de visitas para melhorar sua experiência de navegação. Ao continuar navegar você concorda com nossa política de privacidade.