webchat.message.sent webhook event is triggered whenever the AI or a human agent
sends a message in a webchat session. This can be used to track outgoing communication
and monitor agent activity.
Payload
AI Example
Human Agent Example
Properties
| Property | Type | Description |
|---|---|---|
event | string | The webhook event type (webchat.message.sent). |
data.sessionId | string | The unique identifier for the webchat session. |
data.orgId | string | The Apten organization ID that owns the session. |
data.profile | string | The name of the webchat profile that handled the session. |
data.origin | string | The URL of the page where the webchat widget was opened. Only included if set. |
data.messageId | string | The unique identifier for the message. |
data.content | string | The content of the message sent to the visitor. |
data.sentBy | string | Who sent the message: ai or human. |
data.agentUserId | string | The Apten user ID of the human agent who sent the message. Only included when sentBy is human. |
data.createdAt | string | The ISO 8601 timestamp when the message was sent. |
timestamp | string | The ISO 8601 timestamp when the webhook was sent. |

