get-lists
Retrieve all lists from a specific Trello board to organize and manage tasks efficiently. Simplify project tracking by accessing board data directly through the Advanced Trello MCP Server.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| boardId | Yes | ID of the Trello board to get lists from |
Implementation Reference
- src/tools/lists.ts:16-41 (handler)Handler function that fetches lists from the specified Trello board via API and returns JSON data or error.async ({ boardId }) => { try { const response = await fetch( `https://api.trello.com/1/boards/${boardId}/lists?key=${credentials.apiKey}&token=${credentials.apiToken}` ); const data = await response.json(); return { content: [ { type: 'text', text: JSON.stringify(data), }, ], }; } catch (error) { return { content: [ { type: 'text', text: `Error getting lists: ${error}`, }, ], isError: true, }; } }
- src/tools/lists.ts:13-15 (schema)Input schema using Zod: requires boardId as string with description.{ boardId: z.string().describe('ID of the Trello board to get lists from'), },
- src/tools/lists.ts:12-42 (registration)Registration of the 'get-lists' tool with server.tool, including name, schema, and handler.'get-lists', { boardId: z.string().describe('ID of the Trello board to get lists from'), }, async ({ boardId }) => { try { const response = await fetch( `https://api.trello.com/1/boards/${boardId}/lists?key=${credentials.apiKey}&token=${credentials.apiToken}` ); const data = await response.json(); return { content: [ { type: 'text', text: JSON.stringify(data), }, ], }; } catch (error) { return { content: [ { type: 'text', text: `Error getting lists: ${error}`, }, ], isError: true, }; } } );
- src/index.ts:89-89 (registration)Top-level call to registerListsTools function, which includes the 'get-lists' tool registration.registerListsTools(server, credentials);
- src/index.ts:7-7 (registration)Import of the registerListsTools function used to register the lists tools including 'get-lists'.import { registerListsTools } from './tools/lists.js';