(30032) Message Sending Result
When the third-party application sends a message through the PBX API and the delivery status changes, this event notification will be triggered.
Report parameters
| Parameter | Type | Description |
|---|---|---|
| type | Integer | Event ID. |
| sn | String | PBX's serial number. |
| msg | Object <Msg_Info> | The detailed information. |
Msg_Info
| Parameter | Type | Description |
|---|---|---|
| session_id | Integer | The unique ID of the message session. |
| msg_id | Integer | The unique ID of the message. |
| delivery_status | Integer | Message delivery status.
|
| sender | Object<Sender_Info> | The information of the sender. |
| msg_type | Integer | The type of the message content.
|
| msg_body | String | Message content. |
| msg_files | String | The information of attached files, which is returned as a JSON-formatted string. The string represents an array of File_Info objects. For more details, see the File_Info table. |
| send_time | Integer | The Unix timestamp (in seconds) when the message was sent. |
| param | String | Additional message-related parameters, which is returned as a JSON-formatted string. |
| send_error | String | The type of error that occurred when sending a message.
|
| send_error_msg | String | The error message returned by third-party services when message sending fails. |
| tag | String | The tag assigned to the Facebook message, indicating its category or purpose.
|
| receive_time | Integer | The Unix timestamp (in seconds) when the message was received. |
| whatsapp_msg_param | String | Parameters to be inserted into the WhatsApp message template, provided as a JSON-formatted string. |
| msg_kind | Integer | The category of the message.
|
Sender_Info
| Parameter | Type | Description |
|---|---|---|
| user_id | Integer | The ID of the internal extension user in the session. |
| user_no | String | The identifier of the user in the session.
|
| user_type | Integer | User type.
|
| avatar | String | The ID of the user's avatar. |
| username | String | User name. |
File_Info
| Parameter | Type | Description |
|---|---|---|
| id | String | The ID of the file. |
| name | String | The name of the file. |
| uri | String | The URI for accessing the file. |
| type | String | File type. |
| size | Integer | File size (Unit: Byte). |
Report example
{
"type": 30032,
"sn": "3631A2124788",
"msg": {
"session_id": 3089,
"msg_id": 10325,
"delivery_status": 1,
"sender": {
"user_id": 0,
"user_no": "api",
"user_type": 9,
"avatar": "",
"username": "Third-Party Message Analytics Platform (Transmitted via API)"
},
"msg_type": 0,
"msg_body": "Your verification code is 846392. Please do not share this code with anyone.",
"msg_files": "",
"send_time": 1758594826,
"param": "",
"send_error": "",
"send_error_msg": "",
"tag": "",
"receive_time": 1758594826,
"whatsapp_msg_param": "",
"msg_kind": 0
}
}