Input & Output
The message data object provided to downstream nodes after the Chat Trigger activates, including sender identity, message content, and media.
Normalized Across All Channels
Although each messaging platform has its own payload format, BizFirstAI normalizes all incoming messages into a consistent output structure. Your downstream nodes use the same expression syntax regardless of whether the message came from Slack, WhatsApp, Teams, or SMS. Platform-specific raw data is available in the
raw_payload key for advanced use cases.
Output Ports
| Port Name | When Triggered | Description |
|---|---|---|
main |
When a message arrives that passes the keyword filter (if configured) | Primary output port. Carries the normalized message data object with sender information, message content, channel metadata, and any media attachments. |
Output Data
| Key | Type | Description |
|---|---|---|
sender_id |
String | The platform-specific unique identifier of the message sender. For Slack: the Slack user ID (e.g., U0123ABC456). For WhatsApp/SMS: the sender's phone number in E.164 format (e.g., +15551234567). For Teams: the Azure Active Directory object ID. |
sender_name |
String | The display name of the sender as known to the platform. For Slack and Teams, this is the user's display name from their profile. For WhatsApp, it is the contact name saved in the Business account, or "Unknown" if not saved. For SMS, it is the phone number. |
message_text |
String | The full text content of the incoming message. For Slack, formatting characters (bold, code) are stripped to plain text. For WhatsApp and SMS, this is the raw message body. Empty string if the message was media-only. |
channel |
String | The channel_type value that received the message. One of: slack, whatsapp, teams, sms. Useful when one downstream workflow serves multiple chat channels with conditional branching. |
channel_id |
String | The specific channel, conversation, or number the message was received on. Mirrors the channel_id configured in the node. Use when the workflow needs to reply to a specific channel or group conversation. |
thread_id |
String | The thread or conversation ID to reply within. For Slack, this is the thread_ts of the parent message. For WhatsApp, it is the conversation ID. For Teams, it is the conversation ID. For SMS, it is the sender's phone number (SMS has no threading). Pass this to the reply node to keep the response within the same conversation thread. |
timestamp |
ISO 8601 String | UTC timestamp of when the message was sent by the user. Note this may differ from the trigger execution time if there was queue latency. Example: 2024-06-15T11:23:45.000Z. |
media |
Array of Objects | List of media attachments included in the message. Each item contains type (image, video, document, audio), url (download URL), mime_type, and filename. Empty array if no media was attached. Available for WhatsApp and SMS channels; Slack attachments are included as file objects. |
execution_id |
String | Unique identifier for this workflow execution. Use in auto-reply messages and audit logs. |
raw_payload |
Object | The original, unprocessed event payload received from the messaging platform. Contains all platform-specific fields not captured in the normalized output. Use for advanced integrations that need platform-specific metadata. |
Data Flow Example
Below is the output object produced when a customer sends a WhatsApp message to a customer support number, with the keyword "order status" matching the filter.
{
"sender_id": "+15551234567",
"sender_name": "Jane Doe",
"message_text": "Hi, I need to check the order status for ORD-20240615-0042",
"channel": "whatsapp",
"channel_id": "+14155550100",
"thread_id": "wamid.HBgNMTU1NTEyMzQ1NjcVAgARGBI2MDRFMTE4QTBBQUUYNW==",
"timestamp": "2024-06-15T11:23:45.000Z",
"media": [],
"execution_id": "exec_chat_3Pm8kRt5NwYx",
"raw_payload": {
"object": "whatsapp_business_account",
"entry": [{
"id": "WHATSAPP_BUSINESS_ACCOUNT_ID",
"changes": [{
"field": "messages",
"value": {
"messaging_product": "whatsapp",
"messages": [{
"from": "15551234567",
"id": "wamid.HBgN...",
"timestamp": "1718450625",
"type": "text",
"text": { "body": "Hi, I need to check the order status for ORD-20240615-0042" }
}]
}
}]
}]
}
}
Accessing Message Data in Downstream Nodes
| Expression | Returns |
|---|---|
{{ $trigger.sender_name }} | "Jane Doe" |
{{ $trigger.sender_id }} | "+15551234567" |
{{ $trigger.message_text }} | "Hi, I need to check the order status for ORD-20240615-0042" |
{{ $trigger.channel }} | "whatsapp" |
{{ $trigger.thread_id }} | The WhatsApp conversation ID for threading replies |
{{ $trigger.timestamp }} | "2024-06-15T11:23:45.000Z" |
{{ $trigger.media[0].url }} | URL of the first media attachment (if any) |
sender_name Availability Varies by Channel
On SMS and WhatsApp,
sender_name is only populated if the sender's number is saved as a contact in the Business account. For unknown numbers, it defaults to the phone number string. Always code defensively: {{ $trigger.sender_name || $trigger.sender_id }}.