Skip to main content
Glama
liveblocks

Liveblocks

Official
by liveblocks

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
NameRequiredDescriptionDefault
roomIdYes
queryNo

Implementation Reference

  • 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 })
      );
    }
  • 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 })
        );
      }
    );
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It only states the action ('Get recent Liveblocks threads') without explaining what 'recent' entails (e.g., time frame, pagination), whether it's read-only, what permissions are needed, or how errors are handled. This leaves significant gaps for a tool with parameters.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with no wasted words. It's front-loaded with the core action, though it could be more structured by including key details like parameter context or usage scenarios.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity (2 parameters with nested objects, 0% schema coverage, no output schema, and no annotations), the description is incomplete. It doesn't explain the return format, error handling, or how parameters interact, making it inadequate for effective tool invocation in this context.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 0% description coverage, so the description must compensate. It mentions 'recent' but doesn't explain how this relates to the parameters (roomId and query with resolved/metadata). No additional meaning is provided for the parameters, leaving their purpose and usage unclear beyond the schema structure.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states the tool's purpose as 'Get recent Liveblocks threads', which provides a clear verb ('Get') and resource ('Liveblocks threads'). However, it lacks specificity about what 'recent' means and doesn't differentiate from sibling tools like 'get-thread' (singular) or 'get-thread-participants', leaving ambiguity about scope.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives. The description doesn't mention when to choose 'get-threads' over 'get-thread' (singular) or other related tools like 'get-thread-subscriptions', nor does it specify prerequisites or context for usage.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/liveblocks/liveblocks-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server