get_todolists
Retrieve all todo lists for a specific project using the project ID. Simplify project management by accessing organized task lists from Basecamp 3.
Instructions
Get todo lists for a project
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| project_id | Yes | The project ID |
Implementation Reference
- src/lib/basecamp-client.ts:92-103 (handler)Core implementation that fetches todo lists from Basecamp API: gets project, finds todoset, queries API.async getTodoLists(projectId: string): Promise<TodoList[]> { // First get the project to find the todoset const project = await this.getProject(projectId); const todoset = project.dock.find(item => item.name === 'todoset'); if (!todoset) { throw new Error(`No todoset found for project ${projectId}`); } const response = await this.client.get(`/buckets/${projectId}/todosets/${todoset.id}/todolists.json`); return response.data; }
- src/index.ts:579-591 (handler)MCP CallToolRequest handler case: invokes BasecampClient.getTodoLists and returns formatted JSON response.case 'get_todolists': { const todolists = await client.getTodoLists(typedArgs.project_id); return { content: [{ type: 'text', text: JSON.stringify({ status: 'success', todolists, count: todolists.length }, null, 2) }] }; }
- src/index.ts:153-162 (registration)Tool registration in ListToolsRequestHandler: defines name, description, and input schema (requires project_id).name: 'get_todolists', description: 'Get todo lists for a project', inputSchema: { type: 'object', properties: { project_id: { type: 'string', description: 'The project ID' }, }, required: ['project_id'], }, },
- src/index.ts:155-162 (schema)Input schema definition for the get_todolists tool.inputSchema: { type: 'object', properties: { project_id: { type: 'string', description: 'The project ID' }, }, required: ['project_id'], }, },