Messages API allows you to get and create messages on behalf of your customers or agents.
Here's the example response for the Messages API methods:
{
"id": 9577656,
"agent": {
"id": 4188,
"name": "Sam"
},
"type": "message",
"text": "Can you can a can as a canner can can a can?",
"read": false,
"createdAt": "1594139170.913",
"updatedAt": "1594291329.303",
"edited": false,
"broadcastType": null,
"chat": 5215261,
"from": "agent"
}
Below you can find details on each of the Message Object fields.
Field | Type | Description |
id | Integer | Unique id of the message provided by HelpCrunch |
agent | Object | If the message was sent from agent, this object will contain id and name of that agent |
type | String | "tech" - system message (e.g. about status update) "email" - email message "knowledgeBase" - link to Knowledge Base article "message" - regular message "private" - private note (agents only) |
text | String | Text of the message |
read | Boolean | true - message was read. false - message has not been read |
createdAt | Date (UNIX timestamp) | Date and time the message was created |
updatedAt | Date (UNIX timestamp) | Date and time the message was updated |
edited | Boolean | true - message was edited. false - message was not edited |
broadcastType | String | "trigger" - proactive chat "auto chat" - targeted chat auto message "auto email" - email auto message "manual chat" - manual chat message "manual email" - manual email message Read more about Auto and manual messages |
chat | Integer | Unique id of the chat provided by HelpCrunch |
from | String | "agent" or "customer". Who sent the message. |
If you have any questions regarding the REST API, feel free to chat us any time.
👩💻 Happy Coding! 👨💻