Memory.getThreadById()
The .getThreadById() method retrieves a specific thread by its ID.
Usage exampleUsage example的直接链接
await memory?.getThreadById({ threadId: 'thread-123' })
ParametersParameters的直接链接
threadId:
string
The ID of the thread to be retrieved.
ReturnsReturns的直接链接
thread:
Promise<StorageThreadType | null>
A promise that resolves to the thread associated with the given ID, or null if not found.
RelatedRelated的直接链接
- Memory Class Reference
- Getting Started with Memory (Covers threads concept)
- createThread
- listThreads