List emails from the mailbox

GET {{baseUrl}}/emails/mailboxes/:email/messages?maxResults=<string>&pageToken=<string>&labelIds=<string>&q=<string>&includeSpamTrash=<boolean>

Lists the messages in the user's mailbox.

Scopes: mail:read

Rate Limit Label : MEDIUM

Not supported in Gov cluster

Request Params

| Key | Datatype | Required | Description | | maxResults | string | | Maximum number of messages to return. This field defaults to 50. The maximum allowed value for this field is 500. | | pageToken | string | | Page token to retrieve a specific page of results in the list. | | labelIds | string | | Only return messages with labels that match all of the specified label IDs in this query parameter. | | q | string | | Only return messages matching the specified elastic search query. | | includeSpamTrash | string | | Whether to include messages from SPAM and TRASH in the results. |

HEADERS

| Key | Datatype | Required | Description | | Accept | string | | |

RESPONSES

status: OK

{&quot;messages&quot;:[{&quot;id&quot;:&quot;\u003cstring\u003e&quot;,&quot;threadId&quot;:&quot;\u003cstring\u003e&quot;},{&quot;id&quot;:&quot;\u003cstring\u003e&quot;,&quot;threadId&quot;:&quot;\u003cstring\u003e&quot;}],&quot;nextPageToken&quot;:&quot;\u003cstring\u003e&quot;,&quot;resultSizeEstimate&quot;:&quot;\u003cinteger\u003e&quot;}