Skip to main content
Glama

get_tasks_overdue_in_do

Identify overdue tasks within the Do realm of the addTaskManager MCP Server to help users manage deadlines effectively and maintain productivity.

Instructions

Find tasks overdue in Do realm.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • src/index.ts:634-637 (registration)
    Registration of the 'get_tasks_overdue_in_do' tool in the ListToolsRequestSchema handler, defining its name, description, and empty input schema.
    name: 'get_tasks_overdue_in_do', description: 'Find tasks overdue in Do realm.', inputSchema: { type: 'object', properties: {} } }
  • Primary handler for the 'get_tasks_overdue_in_do' MCP tool. Dispatches to CloudKitService in production mode or provides mock response with formatted overdue tasks list.
    private async getTasksOverdueInDo() { return this.withCloudKitOrMock( 'getTasksOverdueInDo', async () => { // CloudKit production implementation const overdueTasks = await this.cloudKitService.getTasksInDoOverdue(); let response = `Overdue items in Do realm (past due dates - need immediate attention):\n`; if (overdueTasks.length === 0) { response += 'No overdue tasks in Do realm! 🎉 Great job staying on track!'; } else { response += overdueTasks.map((task: any) => { const name = task.fields?.taskName?.value || 'Unnamed Task'; const contextRecordName = task.fields?.context?.value?.recordName; const contextName = contextRecordName?.replace('context_', '') || 'No context'; const priority = task.fields?.taskPriority?.value || 3; const priorityIcon = priority === 1 ? '🔴 High' : priority === 2 ? '🟡 Medium' : '🟢 Low'; const endDate = task.fields?.endDate?.value; const overdueDays = Math.ceil((Date.now() - new Date(endDate).getTime()) / (24 * 60 * 60 * 1000)); const urgency = overdueDays > 3 ? '⚠️ URGENT' : '❗ Overdue'; return `- ${urgency} ${name} (${task.recordName}) - ${overdueDays} day${overdueDays > 1 ? 's' : ''} overdue - ${contextName} - ${priorityIcon}`; }).join('\n'); } return { content: [{ type: 'text', text: response }] }; }, async () => { // Mock implementation const now = new Date(); const yesterday = new Date(now.getTime() - 86400000); const weekAgo = new Date(now.getTime() - 7 * 86400000); const mockTasks = [ { recordName: 'task_overdue_1', taskName: 'Submit expense report', realmId: 3, endDate: yesterday.toISOString().split('T')[0], contextRecordName: 'context_work', priority: 1, daysOverdue: 1 }, { recordName: 'project_overdue_1', projectName: 'Clean garage', realmId: 3, endDate: weekAgo.toISOString().split('T')[0], contextRecordName: 'context_home', priority: 3, daysOverdue: 7 } ]; let response = `Overdue items in Do realm (past due dates - need immediate attention):\n`; response += mockTasks.map(item => { const type = item.recordName.startsWith('task_') ? 'Task' : 'Project'; const name = item.taskName || (item as any).projectName; const contextName = item.contextRecordName?.replace('context_', '') || 'No context'; const priority = item.priority === 1 ? '🔴 High' : item.priority === 2 ? '🟡 Medium' : '🟢 Low'; const overdueDays = item.daysOverdue; const urgency = overdueDays > 3 ? '⚠️ URGENT' : '❗ Overdue'; return `- ${urgency} ${name} (${item.recordName}) - ${overdueDays} day${overdueDays > 1 ? 's' : ''} overdue - ${contextName} - ${priority}`; }).join('\n'); return { content: [{ type: 'text', text: response }] }; } ); }
  • Core query helper method implementing the CloudKit database query for tasks in Do realm (realmId=3) with endDate < now, sorted by endDate ascending (most overdue first). Called by the MCP tool handler in production.
    * Get overdue tasks in Do realm */ async getTasksInDoOverdue(): Promise<ZenTaskticTask[]> { const now = new Date().getTime(); return this.queryRecords<ZenTaskticTask>('Task', { filterBy: [ { fieldName: 'realmId', fieldValue: 3, comparator: 'EQUALS' }, { fieldName: 'endDate', fieldValue: now, comparator: 'LESS_THAN' } ], sortBy: [{ fieldName: 'endDate', ascending: true }] // Most overdue first }); }
  • Input schema for the tool: empty object (no parameters required).
    }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/dragosroua/addtaskmanager-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server