get-threads
Retrieve recent conversation threads from a Liveblocks room to track discussions and manage collaborative workflows.
Instructions
Get recent Liveblocks threads
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| roomId | Yes | ||
| query | No |
Implementation Reference
- src/server.ts:252-256 (handler)Handler function that calls the Liveblocks getThreads API via callLiveblocksApi to retrieve threads for a given room.async ({ roomId, query }, extra) => { return await callLiveblocksApi( getLiveblocks().getThreads({ roomId, query }, { signal: extra.signal }) ); }
- src/server.ts:233-251 (schema)Zod schema defining input parameters: required roomId and optional query with resolved flag and metadata filters.{ roomId: z.string(), query: z .object({ resolved: z.boolean().optional(), metadata: z .record( z.string(), z.union([ z.string(), z.object({ startsWith: z.string(), }), ]) ) .optional(), }) .optional(), },
- src/server.ts:230-257 (registration)Registers the 'get-threads' tool with the MCP server, including description, input schema, and handler function.server.tool( "get-threads", `Get recent Liveblocks threads`, { roomId: z.string(), query: z .object({ resolved: z.boolean().optional(), metadata: z .record( z.string(), z.union([ z.string(), z.object({ startsWith: z.string(), }), ]) ) .optional(), }) .optional(), }, async ({ roomId, query }, extra) => { return await callLiveblocksApi( getLiveblocks().getThreads({ roomId, query }, { signal: extra.signal }) ); } );