Thread

@Serializable
data class Thread(val id: ThreadId, val createdAt: Int, val metadata: Map<String, String>)

Represents a thread that contains messages.

Constructors

Link copied to clipboard
constructor(id: ThreadId, createdAt: Int, metadata: Map<String, String>)

Properties

Link copied to clipboard

The Unix timestamp (in seconds) for when the thread was created.

Link copied to clipboard

The identifier of the thread, which can be referenced in API endpoints.

Link copied to clipboard

A map representing a set of key-value pairs that can be attached to the thread. This can be useful for storing additional information about the thread in a structured format. Keys can be a maximum of 64 characters long, and values can be a maximum of 512 characters long.