Step 1: Retrieve Message Logs
Use the getMessageLog endpoint. This method supports filtering by hwid and allows you to specify a time range using date_from and date_to.
- Documentation: getMessageLog
-
Important Note on Sorting: When using the
limitparameter with this endpoint, the system retrieves the earliest messages within the specified date range first. If you need the most recent messages, you may need to adjust yourdate_fromparameter to a more recent timestamp.
Step 2: Retrieve Message Details
The getMessageLog response provides delivery status and metadata but does not include the full message content (title and body). To fetch the content, use the messages:list endpoint using the message codes obtained from the logs.
- Documentation: messages:list
-
Note: We recommend avoiding the legacy
getMessageDetailsendpoint, as it may not return data for older messages.
Alternative: Message Inbox
If your goal is to display a feed of past notifications directly within your mobile application (e.g., a "Notification Center"), we recommend using the Message Inbox feature. It is specifically designed for this purpose and handles storage and retrieval natively.
- Documentation: Message Inbox
Comments
0 comments
Please sign in to leave a comment.