remove_reaction
Delete an emoji reaction from a Slack message by specifying the channel, message timestamp, and emoji name.
Instructions
Remove an emoji reaction from a message
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| channel | Yes | Channel ID | |
| timestamp | Yes | Message timestamp | |
| name | Yes | Emoji name (without colons) |
Implementation Reference
- src/tools/reactions.ts:23-40 (handler)The core handler function for the 'remove_reaction' tool. It validates input using removeReactionSchema, calls the Slack API to remove the reaction, and returns a success response.export async function removeReaction(client: SlackClientWrapper, args: unknown) { const params = removeReactionSchema.parse(args); return await client.safeCall(async () => { await client.getClient().reactions.remove({ channel: params.channel, timestamp: params.timestamp, name: params.name, }); return { ok: true, channel: params.channel, timestamp: params.timestamp, reaction: params.name, }; }); }
- src/utils/validators.ts:101-105 (schema)Zod schema for validating the input parameters of the remove_reaction tool: channel ID, message timestamp, and emoji name.export const removeReactionSchema = z.object({ channel: channelIdSchema, timestamp: timestampSchema, name: emojiSchema, });
- src/index.ts:374-395 (registration)Tool registration metadata including name, description, and input schema definition used in list_tools response.{ name: 'remove_reaction', description: 'Remove an emoji reaction from a message', inputSchema: { type: 'object', properties: { channel: { type: 'string', description: 'Channel ID', }, timestamp: { type: 'string', description: 'Message timestamp', }, name: { type: 'string', description: 'Emoji name (without colons)', }, }, required: ['channel', 'timestamp', 'name'], }, },
- src/index.ts:438-438 (registration)Handler function registration in the toolHandlers map, binding 'remove_reaction' to the implementation in reactionTools.remove_reaction: (args) => reactionTools.removeReaction(slackClient, args),