fields=kapso(...)
selector on list endpoints. The SDK also ships helpers so you can include the full set with one line.
Helpers
kapso(default)
, kapso(*)
, or kapso(all)
map to the same default set. Use kapso()
to omit Kapso fields.
Message fields
Field | Description |
---|---|
direction | Inbound or outbound based on the business number. |
status | Server-side message status when available. |
processing_status | Internal processing status when available. |
phone_number | Business phone number for the message. |
has_media | True when a media blob is attached. |
media_data | URL, filename, content type, and byte size for stored media. |
media_url | Direct URL to the attached media. Inbound: immediate. Outbound: appears shortly after send. |
whatsapp_conversation_id | Internal conversation identifier. |
contact_name | Display name when known. |
message_type_data | Per-type hints such as caption, sticker info, or location values. |
flow_response | Parsed Flows response JSON. |
flow_token | Token from a Flows response when present. |
flow_name | Name from a Flows response when present. |
order_text | Optional note from order messages. |
Conversation fields
Use these withfields=kapso(...)
on GET /{phone_number_id}/conversations
.
Field | Description |
---|---|
contact_name | Display name for the contact linked to the conversation. |
messages_count | Total number of stored messages in the conversation. |
last_message_id | WAMID of the most recent message in the conversation. |
last_message_type | Type of the most recent message (for example text, image, reaction). |
last_message_timestamp | ISO 8601 timestamp of the most recent message. |
last_message_text | Text or caption preview when available (may be empty for non-text types). |
last_inbound_at | ISO 8601 timestamp of the most recent inbound message. |
last_outbound_at | ISO 8601 timestamp of the most recent outbound message. |
Examples
All Kapso fields:Webhooks
The SDK includes a normalization helper for Meta webhooks. It returns the same structure as history queries and setskapso.direction
. SMB echoes are tagged with kapso.source = "smb_message_echo"
. Other webhook fields are available under events.raw.<fieldName>
.