get-action-reactions
Retrieve reactions for a specific Trello action, including member and emoji details, to analyze engagement and interactions within your project management workflow.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| actionId | Yes | ID of the action | |
| emoji | No | Include emoji information for reactions | |
| member | No | Include member information for reactions |
Implementation Reference
- src/tools/actions.ts:191-233 (handler)Handler function that fetches and returns the reactions for a specific action using the Trello API.async ({ actionId, member, emoji }) => { try { if (!credentials.apiKey || !credentials.apiToken) { return { content: [ { type: 'text', text: 'Trello API credentials are not configured', }, ], isError: true, }; } const url = new URL(`https://api.trello.com/1/actions/${actionId}/reactions`); url.searchParams.append('key', credentials.apiKey); url.searchParams.append('token', credentials.apiToken); if (member !== undefined) url.searchParams.append('member', member.toString()); if (emoji !== undefined) url.searchParams.append('emoji', emoji.toString()); const response = await fetch(url.toString()); const data = await response.json(); return { content: [ { type: 'text', text: JSON.stringify(data), }, ], }; } catch (error) { return { content: [ { type: 'text', text: `Error getting action reactions: ${error}`, }, ], isError: true, }; } }
- src/tools/actions.ts:186-190 (schema)Input schema defining parameters for the get-action-reactions tool.{ actionId: z.string().describe('ID of the action'), member: z.boolean().optional().describe('Include member information for reactions'), emoji: z.boolean().optional().describe('Include emoji information for reactions'), },
- src/tools/actions.ts:185-234 (registration)Registration of the 'get-action-reactions' tool with schema and handler within registerActionsTools function.'get-action-reactions', { actionId: z.string().describe('ID of the action'), member: z.boolean().optional().describe('Include member information for reactions'), emoji: z.boolean().optional().describe('Include emoji information for reactions'), }, async ({ actionId, member, emoji }) => { try { if (!credentials.apiKey || !credentials.apiToken) { return { content: [ { type: 'text', text: 'Trello API credentials are not configured', }, ], isError: true, }; } const url = new URL(`https://api.trello.com/1/actions/${actionId}/reactions`); url.searchParams.append('key', credentials.apiKey); url.searchParams.append('token', credentials.apiToken); if (member !== undefined) url.searchParams.append('member', member.toString()); if (emoji !== undefined) url.searchParams.append('emoji', emoji.toString()); const response = await fetch(url.toString()); const data = await response.json(); return { content: [ { type: 'text', text: JSON.stringify(data), }, ], }; } catch (error) { return { content: [ { type: 'text', text: `Error getting action reactions: ${error}`, }, ], isError: true, }; } } );