Skip to main content
PATCH
/
v4
/
threads
/
{thread_id}
Python
import os
from scale_gp import SGPClient

client = SGPClient(
    api_key=os.environ.get("SGP_API_KEY"),  # This is the default and can be omitted
)
chat_thread = client.chat_threads.update(
    thread_id="thread_id",
)
print(chat_thread.id)
{
  "id": "<string>",
  "title": "<string>",
  "application_variant_id": "<string>",
  "account_id": "<string>",
  "created_by_user_id": "<string>",
  "created_by_identity_type": "user",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "thread_metadata": {},
  "archived_at": "2023-11-07T05:31:56Z"
}

Authorizations

x-api-key
string
header
required

Headers

x-selected-account-id
string | null

Path Parameters

thread_id
string
required

Body

application/json
title
string

The title of the chat thread.

archived_at
string

Date when the chat thread is archived, or None to un-archive.

thread_metadata
Thread Metadata · object

The metadata associated with the thread

Response

Successful Response

id
string
required
title
string
required
application_variant_id
string
required
account_id
string
required

The ID of the account that owns the given entity.

created_by_user_id
string
required

The user who originally created the entity.

created_by_identity_type
enum<string>
required

The type of identity that created the entity.

Available options:
user,
service_account
created_at
string<date-time>
required

The date and time when the entity was created in ISO format.

updated_at
string<date-time>
required

The date and time when the entity was last updated in ISO format.

thread_metadata
Thread Metadata · object
archived_at
string<date-time>

The date and time when the entity was archived in ISO format.