Skip to main content
PATCH
/
threads
/
{threadId}
JavaScript
import Nuntly from '@nuntly/sdk';

const client = new Nuntly({
  apiKey: process.env['NUNTLY_API_KEY'], // This is the default and can be omitted
});

const thread = await client.threads.update('thr_01kabn43yqyxn2bx4ve84mczd3');

console.log(thread.id);
{
  "data": {
    "id": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Bearer HTTP authentication. Allowed headers Authorization: Bearer <API_KEY>

Path Parameters

threadId
string
required

The id of the thread

Example:

"thr_01kabn43yqyxn2bx4ve84mczd3"

Body

application/json

Thread read status, spam flag, or agent assignment.

isRead
boolean

Mark the thread as read or unread.

isSpam
boolean

Mark the thread as spam or not spam.

agentId
string | null

The AI agent identifier.

Response

Successful response.

data
object
required