Usa i webhook per ricevere subito nel tuo sistema gli eventi dei messaggi.
Sono disponibili due tipi di webhook:
Configura questo webhook nelle impostazioni del dispositivo per ricevere aggiornamenti di stato senza interrogare l'API.
{
"sms_id": int,
"status_id": int,
"status_message": string,
"sendto": string,
"senttime": datetime,
"channel_id": int,
"device_id": int
}
Configura questo webhook per inoltrare i messaggi in arrivo al tuo CRM, helpdesk o backend.
Il payload include un campo "type" che indica se il messaggio in arrivo è un testo o un'immagine (ad es. da WhatsApp).
Inviato per gli SMS in arrivo e i messaggi di testo in arrivo da WhatsApp / WhatsApp Business / RCS.
{
"address": string,
"date": datetime,
"date_sent": datetime,
"body": string,
"internal_id": int,
"channel_id": int,
"sms_id": int,
"device_id": int,
"device_name": string,
"type": "text"
}
Inviato per le immagini in arrivo da WhatsApp / WhatsApp Business. L'immagine è già caricata sul nostro storage S3: il tuo backend deve solo salvare l'URL, senza scaricare e ricaricare il file.
{
"address": string,
"date": datetime,
"date_sent": datetime,
"body": "",
"internal_id": null,
"sim": int,
"sms_id": int,
"type": "img",
"img_url": "https://smsgateway24.s3.eu-central-1.amazonaws.com/..."
}
Note: