Webhooks
WhatsApp End of Session
Sends an HTTP notification to your endpoint when a WhatsApp conversation with one of your agents closes: after the idle wait without messages, a few minutes after the agent ends the chat, or when a template you sent gets no reply. See WhatsApp conversations for when each one happens.
Configuration
This event uses the agent's end-of-call webhook field, the same address that receives End of Call for calls (Instructions tab, For developer section; see General). For an agent that answers WhatsApp, every conversation that closes is sent there, including the ones that close with no reply from the contact.
Delivery
- Method:
POST - Content-Type:
application/json - Authorization: none. The request has no
Authorizationheader. - Retries: none. The request is sent once.
Payload
startedAtstringmessagesarrayanalysis.summarystringanalysis.structuredDataobjectanalysis.successEvaluationbooleanfalse when the contact never wrote.Message details
Each item in messages has:
role:userfor the contact,assistantfor the agent (including the templates you sent)message: the text of the message
Responding to events
Return any HTTP 2xx status code to acknowledge receipt. Response body is ignored.
Any other response, or a network error, counts as a failed delivery. The event is not sent again, and the session card in the dashboard's Messages inbox shows Webhook failed.