list_tasks
Retrieve tasks from the Helios-9 project management system with filtering options for project, initiative, status, assignee, or search terms to organize and track work efficiently.
Instructions
List tasks with optional filtering by project, initiative, status, or assignee
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| project_id | No | Filter tasks by project ID | |
| initiative_id | No | Filter tasks by initiative ID | |
| status | No | Filter tasks by status | |
| assignee_id | No | Filter tasks by assignee | |
| search | No | Search tasks by title or description | |
| limit | No | Maximum number of tasks to return |
Implementation Reference
- src/tools/tasks.ts:97-118 (handler)The core handler function for the 'list_tasks' tool. Validates input using Zod schema, fetches tasks from Supabase service with applied filters, performs client-side filtering for initiative_id, logs the operation, and returns the list of tasks with total count and applied filters.export const listTasks = requireAuth(async (args: any) => { const { project_id, initiative_id, status, assignee_id, search, limit } = ListTasksSchema.parse(args) logger.info('Listing tasks', { project_id, initiative_id, status, assignee_id, search, limit }) let tasks = await supabaseService.getTasks( { project_id, status, assignee_id, search }, { limit }, { field: 'updated_at', order: 'desc' } ) // Filter by initiative_id if provided (since API doesn't support it directly yet) if (initiative_id) { tasks = tasks.filter(task => task.initiative_id === initiative_id) } return { tasks, total: tasks.length, filters_applied: { project_id, initiative_id, status, assignee_id, search } } })
- src/tools/tasks.ts:13-20 (schema)Zod input validation schema defining optional filters for listing tasks: project_id, initiative_id, status, assignee_id, search term, and limit (default 20, max 100).const ListTasksSchema = z.object({ project_id: z.string().uuid().optional(), initiative_id: z.string().uuid().optional(), status: z.enum(['todo', 'in_progress', 'done']).optional(), assignee_id: z.string().uuid().optional(), search: z.string().optional(), limit: z.number().int().positive().max(100).default(20) })
- src/tools/tasks.ts:56-95 (registration)MCPTool definition for 'list_tasks' including name, description, and JSON inputSchema matching the Zod schema for MCP protocol compatibility.export const listTasksTool: MCPTool = { name: 'list_tasks', description: 'List tasks with optional filtering by project, initiative, status, or assignee', inputSchema: { type: 'object', properties: { project_id: { type: 'string', format: 'uuid', description: 'Filter tasks by project ID' }, initiative_id: { type: 'string', format: 'uuid', description: 'Filter tasks by initiative ID' }, status: { type: 'string', enum: ['todo', 'in_progress', 'done'], description: 'Filter tasks by status' }, assignee_id: { type: 'string', format: 'uuid', description: 'Filter tasks by assignee' }, search: { type: 'string', description: 'Search tasks by title or description' }, limit: { type: 'number', minimum: 1, maximum: 100, default: 20, description: 'Maximum number of tasks to return' } } } }
- src/tools/tasks.ts:1157-1167 (registration)Export of taskHandlers object mapping 'list_tasks' to its handler function, imported and spread into global allHandlers in src/index.ts for MCP server registration.export const taskHandlers = { list_tasks: listTasks, create_task: createTask, get_task: getTask, update_task: updateTask, add_task_dependency: addTaskDependency, get_task_dependencies: getTaskDependencies, create_task_workflow: createTaskWorkflow, bulk_update_tasks: bulkUpdateTasks, get_task_workflow_status: getTaskWorkflowStatus }
- src/index.ts:143-155 (registration)Global registration in MCP server constructor where taskHandlers (including list_tasks) is spread into allHandlers, making the tool available for MCP tool calls.this.allHandlers = { ...projectHandlers, ...taskHandlers, ...documentHandlers, ...conversationHandlers, ...contextAggregationHandlers, ...workflowAutomationHandlers, ...intelligentSearchHandlers, ...analyticsInsightsHandlers, ...initiativeHandlers, ...promptToProjectTools.reduce((acc, tool) => ({ ...acc, [tool.name]: tool.handler }), {}), ...debugHandlers, }