/
Check all messages

Check all messages

URL: /services/rest/user/allMessages

Works for POST and application/x-www-form-urlencoded parameters, or GET and query parameters


This method queries the capped collection of messages so has limited history to query


When querying from the next 100 messages set the since parameter to the newestMessageTimestamp value of the last response.

namedescriptionexample valuevalidation rules
usernameUsername of registered user1234321@resellerCannot be null or empty, cannot contain spaces, user must exist
passwordPasswordpasswordCannot be null or empty, must match user's password
sinceEpoch, number of seconds since 1st Jan 1970 GMT1364545939Required, must be an integer number

Response in JSON:

{
    "newestMessageTimestamp": 1366624802,
    "hasMoreMessages": false,
    "incomingMessages": [
        {
            "documentId": "51750a01e4b0d1406c9c5fdb",
            "text": " ggghhh",
            "timestamp": 1366624769,
            "from": "61555879987",
            "recipient": "61500079987",
            "originDocumentId": "517509fee4b0b1be3f128ef5"
        }
    ],
    "outgoingMessages": [
        {
            "documentId": "517509fee4b0b1be3f128ef5",
            "text": "Reply> ggghhh",
            "timestamp": 1366624766,
            "recipient": "61555879987"
        },
        {
            "documentId": "51750a22e4b0b1be3f128ef6",
            "text": "Hello mommy",
            "timestamp": 1366624802,
            "recipient": "61255588885"
        }
    ],
    "status": 0
}

Response parameters

namedescription

newestMessageTimestamp

timestamp of the newest returned message
hasMoreMessagestrue if there are more messages to retrieve from server, false otherwise
status0 if everything is OK, error code otherwise
incomingMessageslist of received messages
outgoingMessageslist of sent messages

Parameters of single incoming message

namedescription
fromnumber of message sender
recipientnumber of message recipient
documentIdmessage ID
originDocumentIdID of the message this message is reply for
timestamptimestamp of the message
textmessage text

Parameters of single outgoing message

namedescription
documentIdmessage ID
textmessage text
timestamptimestamp when message was sent
recipientnumber the message was sent to

Possible statuses

0, 1, 2, 3, 200, 220, 9999 

Status codes and their meaning: User and Reseller REST API Response Status Codes

Related content

Get Unread Final Statuses
Get Unread Final Statuses
More like this
Message Status Query and Status Codes
Message Status Query and Status Codes
More like this
Send Single Message
Send Single Message
Read with this
Check messages
Check messages
More like this
MMS Summary
MMS Summary
More like this