Skip to main content
Glama

add_reaction

React to a specific message in a Discord channel by specifying the channel ID, message ID, and emoji. Integrates directly with MCP for streamlined Discord interactions.

Instructions

Add a reaction to a message

Input Schema

NameRequiredDescriptionDefault
channel_idYesChannel containing the message
emojiYesEmoji to react with (Unicode or custom emoji ID)
message_idYesMessage to react to

Input Schema (JSON Schema)

{ "properties": { "channel_id": { "description": "Channel containing the message", "type": "string" }, "emoji": { "description": "Emoji to react with (Unicode or custom emoji ID)", "type": "string" }, "message_id": { "description": "Message to react to", "type": "string" } }, "required": [ "channel_id", "message_id", "emoji" ], "type": "object" }

Implementation Reference

  • Registration of the 'add_reaction' tool including its input schema definition in the list_tools() function.
    Tool( name="add_reaction", description="Add a reaction to a message", inputSchema={ "type": "object", "properties": { "channel_id": { "type": "string", "description": "Channel containing the message" }, "message_id": { "type": "string", "description": "Message to react to" }, "emoji": { "type": "string", "description": "Emoji to react with (Unicode or custom emoji ID)" } }, "required": ["channel_id", "message_id", "emoji"] } ),
  • The handler logic in call_tool() that executes the add_reaction tool: fetches channel and message, adds the specified emoji reaction, and returns a confirmation.
    elif name == "add_reaction": channel = await discord_client.fetch_channel(int(arguments["channel_id"])) message = await channel.fetch_message(int(arguments["message_id"])) await message.add_reaction(arguments["emoji"]) return [TextContent( type="text", text=f"Added reaction {arguments['emoji']} to message" )]

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/hanweg/mcp-discord'

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