things_get_list
Retrieve all to-dos from a specific Things 3 list by name, such as inbox, today, or upcoming, with optional result limits.
Instructions
Get all to-dos from a specific list by name
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| list | Yes | ||
| max_results | No | Limit number of results returned (defaults to all if not specified) |
Implementation Reference
- src/tools/get.ts:109-143 (handler)The execute method handles the 'things_get_list' tool by mapping the requested list name to an AppleScript filename and then executing it.
async execute(toolName: string, params: GetParams): Promise<string> { let scriptName: string; // Handle the get_list tool separately if (toolName === 'things_get_list') { const listParams = params as z.infer<typeof GetListByNameSchema>; scriptName = this.listNameToScript[listParams.list]; if (!scriptName) { throw new Error(`Unknown list: ${listParams.list}`); } } else { scriptName = this.scriptMap[toolName]; if (!scriptName) { throw new Error(`Unknown tool: ${toolName}`); } } let scriptArgs: string[] = []; const options = { maxResults: (params as any).max_results }; // Handle specific tools that need arguments if (toolName === 'things_get_project') { const projectParams = params as z.infer<typeof GetProjectSchema>; scriptArgs = [projectParams.project_id]; } else if (toolName === 'things_get_area') { const areaParams = params as z.infer<typeof GetAreaSchema>; scriptArgs = [areaParams.area_id]; } else if (toolName === 'things_get_todo_details') { const todoParams = params as z.infer<typeof GetTodoDetailsSchema>; scriptArgs = [todoParams.id]; // Don't pass maxResults for todo details since it's a single item delete options.maxResults; } const output = await executeAppleScriptFile(scriptName, scriptArgs, options); - src/tools/get.ts:72-75 (registration)Registration of the 'things_get_list' tool within the GetToolHandler class definitions.
name: 'things_get_list', description: 'Get all to-dos from a specific list by name', schema: GetListByNameSchema },