Skip to main content
Glama

zulip_add_reaction

Add emoji reactions to messages in Zulip workspaces using message IDs and emoji names to enhance communication and express responses visually.

Instructions

Add an emoji reaction to a message

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
message_idYesThe ID of the message to react to
emoji_nameYesEmoji name without colons

Implementation Reference

  • Switch case in CallToolRequest handler that executes the zulip_add_reaction tool by validating arguments and calling ZulipClient.addReaction method.
    case "zulip_add_reaction": {
      const args = request.params.arguments as unknown as AddReactionArgs;
      if (args.message_id === undefined || !args.emoji_name) {
        throw new Error(
          "Missing required arguments: message_id and emoji_name"
        );
      }
      const response = await zulipClient.addReaction(
        args.message_id,
        args.emoji_name
      );
      return {
        content: [{ type: "text", text: JSON.stringify(response) }],
      };
    }
  • Tool schema definition including name, description, and input schema for zulip_add_reaction.
    const addReactionTool: Tool = {
      name: "zulip_add_reaction",
      description: "Add an emoji reaction to a message",
      inputSchema: {
        type: "object",
        properties: {
          message_id: {
            type: "number",
            description: "The ID of the message to react to",
          },
          emoji_name: {
            type: "string",
            description: "Emoji name without colons",
          },
        },
        required: ["message_id", "emoji_name"],
      },
    };
  • ZulipClient method that performs the actual API call to add a reaction to a message.
    async addReaction(messageId: number, emojiName: string) {
      try {
        return await this.client.reactions.add({
          message_id: messageId,
          emoji_name: emojiName,
        });
      } catch (error) {
        console.error("Error adding reaction:", error);
        throw error;
      }
    }
  • TypeScript interface defining the input arguments for the zulip_add_reaction tool.
    interface AddReactionArgs {
      message_id: number;
      emoji_name: string;
  • index.ts:542-542 (registration)
    Inclusion of the zulip_add_reaction tool in the list of tools returned by ListToolsRequest handler.
    addReactionTool,
Behavior2/5

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

With no annotations provided, the description carries full burden but offers minimal behavioral insight. It states the action but doesn't disclose whether this requires specific permissions, if it's idempotent, what happens on duplicate reactions, or any rate limits. For a mutation tool with zero annotation coverage, this is inadequate.

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

Conciseness5/5

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

The description is a single, efficient sentence that directly states the tool's purpose without any wasted words. It's appropriately sized and front-loaded, making it easy to parse quickly.

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?

For a mutation tool with no annotations and no output schema, the description is insufficient. It doesn't explain what the tool returns, error conditions, or behavioral nuances. Given the complexity of adding reactions in a messaging system, more context about permissions, idempotency, or response format would be needed.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already fully documents both parameters. The description doesn't add any additional meaning about the parameters beyond what's in the schema, such as emoji format examples or message ID constraints. Baseline 3 is appropriate when the schema does all the work.

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

Purpose4/5

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

The description clearly states the action ('Add') and target ('emoji reaction to a message'), making the purpose immediately understandable. However, it doesn't distinguish this tool from potential sibling tools like 'zulip_post_message' or 'zulip_send_direct_message' in terms of interaction type, which prevents a perfect score.

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 about when to use this tool versus alternatives. The description doesn't mention prerequisites (like needing message access), appropriate contexts, or when other tools might be more suitable for different types of interactions.

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/Monadical-SAS/zulip-mcp'

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