taskUpcoming
Organize upcoming tasks by week and sort alphabetically for better task management within Routine's MCP server.
Instructions
Non-allocated organized by week and sorted alphabetically.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools.ts:864-886 (handler)The handler function for the MCP tool 'taskUpcoming', which retrieves non-allocated tasks organized by week and sorted alphabetically by delegating to the backend RPC 'task.upcoming'. This is the core implementation of the tool's logic."taskUpcoming", "Non-allocated organized by week and sorted alphabetically.", {}, async ({}) => { try { const data = await sendRpcRequest("task.upcoming", []); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; } catch (error) { logger.error("Error fetching task.upcoming: %o", error); return { content: [ { type: "text", text: `Error fetching auth id: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } } );
- src/tools.ts:864-886 (registration)Registration of the 'taskUpcoming' tool on the MCP server using server.tool, including empty parameter schema and the inline handler."taskUpcoming", "Non-allocated organized by week and sorted alphabetically.", {}, async ({}) => { try { const data = await sendRpcRequest("task.upcoming", []); return { content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; } catch (error) { logger.error("Error fetching task.upcoming: %o", error); return { content: [ { type: "text", text: `Error fetching auth id: ${error instanceof Error ? error.message : String(error)}`, }, ], isError: true, }; } } );
- src/index.ts:234-235 (registration)Call to registerServerTools which includes the registration of 'taskUpcoming' among other tools.registerServerTools(server, sendRpcRequest, logger);