> For the complete documentation index, see [llms.txt](https://docs.innopaas.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.innopaas.com/api-reference/api-reference-en/whatsapp-business-api/webhook/chatroom-inbound-and-outbound-message-events.md). Agents can also search and read this documentation through its [MCP server](https://docs.innopaas.com/~gitbook/mcp).

# Chatroom inbound and outbound message events

Chatroom inbound and outbound messages are only for event listening in the chatroom,**chat\_mt\_message\_notify (chatroom downstream message reception), chat\_mo\_message\_notify (chatroom upstream message reception)**

| Field          | Data type | Required | Description                                                          |
| -------------- | --------- | -------- | -------------------------------------------------------------------- |
| wabaId         | String    | Yes      | Waba Id                                                              |
| from           | String    | Yes      | Enterprise Sender                                                    |
| to             | String    | Yes      | User's WhatsApp number                                               |
| messageType    | String    | Yes      | Message type                                                         |
| context        | Object    | Yes      | Message content                                                      |
| wamid          | String    | No       | Mete message ID                                                      |
| conversationId | String    | No       | Session ID (InnoPaaS chatroom session ID)                            |
| uid            | String    | No       | User-defined ID                                                      |
| sendTime       | String    | Yes      | Send time, UTC, for example: 2026-07-09T09:11:23.405Z                |
| sendTimestamp  | String    | Yes      | Send timestamp, accurate to milliseconds, for example: 1783588283405 |
| id             | String    | Yes      | Message Id                                                           |
| agent          | json      | No       | Agent account information                                            |
| assignee       | json      | No       | Assigned account information                                         |

agent parameters

| Field     | Data type | Required | Description   |
| --------- | --------- | -------- | ------------- |
| userEmail | String    | Yes      | Account email |
| userId    | String    | Yes      | Account ID    |
| userName  | String    | Yes      | Account name  |

assignee parameters

| Field        | Data type | Required | Description                                            |
| ------------ | --------- | -------- | ------------------------------------------------------ |
| userEmail    | String    | Yes      | Account email                                          |
| userId       | String    | Yes      | Account ID                                             |
| userName     | String    | Yes      | Account name                                           |
| assigneeType | Int       | Yes      | 0: customer service, 1: Bot customer service, 2: Agent |

**chat\_mt\_message\_notify example**

```json
{
    "id": "b5e984b3-21b2-42a9-b08b-72e5a4096ac6",
    "type": "chat_mt_message_notify",
    "eventTime": "2023-02-22T12:00:00.000Z",
    "body": {
        "agent": {
            "userEmail": "test01@253.com",
            "userId": "2038624",
            "userName": "test"
        },
        "assignee": {
            "assigneeType": 0,
            "userEmail": "innopaas@253.com",
            "userId": "2040160",
            "userName": "innopaas"
        },
        "wabaId": "WHATSAPP_BUSINESS_ACCOUNT_ID",
        "from": "wamid.BgNODYxN...",
        "id": "059862baa7994b1bb0***a15990667ebeb8",
        "to": "PHONE-NUMBER",
        "messageType": "text",
        "context": {
            "to_user_id": "SL.1838476520903277",
            "from": "86178****8556",
            "id": "wamid.HBgTU0wuMTgzODQ3NjUyMDkwMzI3NxUUABEYFDJBMzREQkI3NDREMDVBQTM3QTM3AA==",
            "text": {
                "previewUrl": true,
                "body": "Have you ever imported phone accessories from China before?",
                "type": "text"
            },
            "to": "2327***13292",
            "type": "text",
            "timestamp": 1793606952000
        },
        "wamid": "wamid.BgNODYxN...",
        "conversationId": "12312312312312",
        "uid": "123123123123123213123",
        "sendTime": "2026-07-09T09:11:23.405Z",
        "sendTimestamp": "1783588283405"
    }
}
```

**chat\_mo\_message\_notify example**

```json
{
    "id": "b5e984b3-21b2-42a9-b08b-72e5a4096ac6",
    "type": "chat_mo_message_notify",
    "eventTime": "2023-02-22T12:00:00.000Z",
    "body": {
        "wabaId": "WHATSAPP_BUSINESS_ACCOUNT_ID",
        "from": "wamid.BgNODYxN...",
        "id": "9bbd248f7e8049cb8e680a589ad71231",
        "to": "PHONE-NUMBER",
        "messageType": "text",
        "assignee": {
            "assigneeType": 0,
            "userEmail": "innopaas@253.com",
            "userId": "2040160",
            "userName": "innopaas"
        },
        "context": {
            "from": "923****04081",
            "id": "wamid.HBgMOTIzMDY0NjA0MDgxFQIAEhggQUM0QjY3NzM3RkE1MkRCNERBODYwQjQ5NEIzMDRDNTAA",
            "text": {
                "previewUrl": true,
                "body": "Hi",
                "type": "text"
            },
            "type": "text",
            "from_user_id": "PK.2084349368861389",
            "timestamp": 1793607152000
        },
        "wamid": "wamid.BgNODYxN...",
        "conversationId": "12312312312312",
        "uid": "123123123123123213123",
        "sendTime": "2026-07-09T09:11:23.405Z",
        "sendTimestamp": "1783588283405"
    }
}
```
