Skip to main content
Glama

get-message-read-receipts

Retrieve a list of users who have read a specific message in Zulip by providing the message ID, enabling tracking of message engagement and audience reach.

Instructions

Get list of users who have read a specific message.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
message_idYesUnique message ID to get read receipts for

Implementation Reference

  • MCP tool handler function that calls the Zulip client to fetch read receipts for a message and formats the response.
    async ({ message_id }) => { try { const result = await zulipClient.getMessageReadReceipts(message_id); return createSuccessResponse(JSON.stringify({ message_id, read_by_count: result.user_ids.length, user_ids: result.user_ids }, null, 2)); } catch (error) { return createErrorResponse(`Error getting read receipts: ${error instanceof Error ? error.message : 'Unknown error'}`); } }
  • Zod schema defining the input parameters for the tool (message_id: number).
    export const GetMessageReadReceiptsSchema = z.object({ message_id: z.number().describe("Unique message ID to get read receipts for") });
  • src/server.ts:621-637 (registration)
    Registration of the MCP tool using McpServer.tool(), including name, description, input schema, and handler function.
    server.tool( "get-message-read-receipts", "Get list of users who have read a specific message.", GetMessageReadReceiptsSchema.shape, async ({ message_id }) => { try { const result = await zulipClient.getMessageReadReceipts(message_id); return createSuccessResponse(JSON.stringify({ message_id, read_by_count: result.user_ids.length, user_ids: result.user_ids }, null, 2)); } catch (error) { return createErrorResponse(`Error getting read receipts: ${error instanceof Error ? error.message : 'Unknown error'}`); } } );
  • ZulipClient method that performs the actual API call to retrieve read receipts for a message.
    async getMessageReadReceipts(messageId: number): Promise<{ user_ids: number[] }> { const response = await this.client.get(`/messages/${messageId}/read_receipts`); return response.data; }

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/avisekrath/zulip-mcp-server'

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