Crie sua conta grátis e teste por 7 dias ( você não será cobrado no período de testes )

Criar Agendamento

Criar Agendamento

Criar Agendamento
PHP
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://api.robomensageiro.com.br/api/schedules',
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => '',
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 0,
  CURLOPT_FOLLOWLOCATION => true,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => 'POST',
  CURLOPT_POSTFIELDS =>'{
    "body":"Teste de Agendamento",
    "sendAt":"2023-12-17T22:00:00.000Z",
    "contactId":"24294",
    "userId":"34",
    "openTicket":"0",
    "queueId":"0",
    "whatsappId":"2",
    "repetir":"0", //0 = Não Repetir, 999 = Todo Dia (repetirTodo)
    "repetirTodo":"0", //0 = Não Repetir, 999 = Aniversário
    "quantasVezes":"0"
}',
  CURLOPT_HTTPHEADER => array(
    'Content-Type: application/json',
    'Authorization: Bearer tokenmeu'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;

Retorno com sucesso:

JSON
{
    "id": 57,
    "body": "Teste de Agendamento",
    "sendAt": "2023-12-17T22:00:00.000Z",
    "sentAt": null,
    "contactId": 24294,
    "ticketId": null,
    "userId": 34,
    "companyId": 1,
    "status": "PENDENTE",
    "geral": false,
    "queueId": 0,
    "whatsappId": 2,
    "mediaPath": null,
    "mediaName": null,
    "repetir": 0,
    "repetirTodo": 0,
    "quantasVezes": 0,
    "createdAt": "2023-12-17T14:34:07.751Z",
    "updatedAt": "2023-12-17T14:34:07.751Z"
}
Atendimento por WhatsAppAtendimento
WhatsApp