Message Inbox API

getInboxMessages

post
https://cp.pushwoosh.com/json/1.3
/getInboxMessages
/getInboxMessages
Example Request
Request:
{
"request":
{
"application" : "XXXXX-XXXXX", // required, Pushwoosh app code
"userId" : "user_name_1", // required, user ID registered in Pushwoosh
"device_type" : 1 // optional, for device types refer to /registerDevice
}
}
Response:
{
"status_code": 200,
"status_message": "OK",
"response": {
"messages": [
{
"inbox_id": "6249b3be0f19a7.16973228",
"order": "1636321268891501", // message id
"rt": "1651330109", // timestamp - expiry date
"send_date": "1649008809", // send data
"title": "Title",
"text": "Message",
"action_type": 1, // 1 - link, 2 - rich media
"action_params": "{}", // push payload as json string
"image": "", // image
"status": 1, // 1 - delivered, 2 - read, 3 - open, 4 - deleted
"hash": "7t" // hash for stats
}],
"new_inbox": 1 // number of unread messages
}
}

inboxStatus

post
https://cp.pushwoosh.com/json/1.3
/inboxStatus
/inboxStatus
Example
Request:
{
"request": {
"application" :"XXXXX-XXXXX", // required, Pushwoosh application code
"inbox_code": "874393934032909", // required, "order" parameter of /getInboxMessages request
"hash" : "1C", // optional
"userId" : "some_user", // required
"status" : 2, // required, status to set: 1-delivered, 2-read, 3-opened, 4-deleted (by a user)
"device_type" : 3 // optional
}
}
Response:
{
"status_code": 200,
"status_message": "OK",
"response": null
}