Switch to a different thread (or clear the current thread). Clears the active stream, cancels all queued runs on the previous thread, fetches history for the new thread, and notifies the AnyStreamOptions.onThreadId | onThreadId callback.
switchThread(newThreadId: string | null)| Name | Type | Description |
|---|---|---|
newThreadId* | string | null | The thread ID to switch to, or |