Skip to main content
GET
/
threads
/
{threadId}
JavaScript
import AIInbx from 'aiinbx';

const client = new AIInbx({
  apiKey: 'My API Key',
});

const thread = await client.threads.retrieve('threadId');

console.log(thread.id);
{
  "id": "<string>",
  "createdAt": "<string>",
  "subject": "<string>",
  "emails": [
    {
      "id": "<string>",
      "createdAt": "<string>",
      "messageId": "<string>",
      "inReplyToId": "<string>",
      "references": [
        "<string>"
      ],
      "subject": "<string>",
      "text": "<string>",
      "html": "<string>",
      "strippedText": "<string>",
      "strippedHtml": "<string>",
      "snippet": "<string>",
      "fromName": "<string>",
      "fromAddress": "<string>",
      "toAddresses": [
        "<string>"
      ],
      "ccAddresses": [
        "<string>"
      ],
      "bccAddresses": [
        "<string>"
      ],
      "replyToAddresses": [
        "<string>"
      ],
      "sentAt": "<string>",
      "receivedAt": "<string>",
      "direction": "INBOUND",
      "status": "DRAFT",
      "threadId": "<string>",
      "attachments": [
        {
          "id": "<string>",
          "createdAt": "<string>",
          "fileName": "<string>",
          "contentType": "<string>",
          "sizeInBytes": 123,
          "cid": "<string>",
          "disposition": "<string>",
          "signedUrl": "<string>",
          "expiresAt": "<string>"
        }
      ]
    }
  ]
}

Authorizations

Authorization
string
header
required

API Key authentication using Bearer token

Path Parameters

threadId
string
required

The unique identifier of the thread

Response

Successful response

id
string
required
createdAt
string
required
subject
string | null
required
emails
object[]
required