Skip to main content
GET
https://api.aisa.one/apis/v1
/
agentmail
/
inboxes
/
{inbox_id}
/
messages
List Messages
curl --request GET \
  --url https://api.aisa.one/apis/v1/agentmail/inboxes/{inbox_id}/messages \
  --header 'Authorization: Bearer <token>'
{
  "count": 123,
  "messages": [
    {
      "inbox_id": "<string>",
      "thread_id": "<string>",
      "message_id": "<string>",
      "labels": [
        "<string>"
      ],
      "timestamp": "2023-11-07T05:31:56Z",
      "from": "<string>",
      "to": [
        "<string>"
      ],
      "size": 123,
      "updated_at": "2023-11-07T05:31:56Z",
      "created_at": "2023-11-07T05:31:56Z",
      "cc": [
        "<string>"
      ],
      "bcc": [
        "<string>"
      ],
      "subject": "<string>",
      "preview": "<string>",
      "attachments": [
        {
          "attachment_id": "<string>",
          "size": 123,
          "filename": "<string>",
          "content_type": "<string>",
          "content_id": "<string>"
        }
      ],
      "in_reply_to": "<string>",
      "references": [
        "<string>"
      ],
      "headers": {}
    }
  ],
  "limit": 123,
  "next_page_token": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

Authorization
string
required

Bearer authentication

Path Parameters

inbox_id
string
required

The ID of the inbox.

Query Parameters

limit
integer

Limit of number of items returned.

page_token
string

Page token for pagination.

labels
string[]

Labels to filter by.

before
string<date-time>

Timestamp before which to filter by.

after
string<date-time>

Timestamp after which to filter by.

ascending
boolean

Sort in ascending temporal order.

include_spam
boolean

Include spam in results.

include_blocked
boolean

Include blocked in results.

include_unauthenticated
boolean

Include unauthenticated in results.

include_trash
boolean

Include trash in results.

Response

Response with status 200

count
integer
required

Number of items returned.

messages
MessageItem · object[]
required

Ordered by timestamp descending.

limit
integer

Limit of number of items returned.

next_page_token
string

Page token for pagination.