Skip to main content
Glama

update_task

Modify an existing TickTick task by updating its title, description, due date, priority, or tags using the task ID.

Instructions

Update an existing task

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskIdYesTask ID to update (required)
titleNoNew task title
contentNoNew task description/content
dueDateNoNew due date in ISO format
priorityNoNew task priority (0=None, 1=Low, 3=Medium, 5=High)
tagsNoNew task tags

Implementation Reference

  • MCP tool handler for update_task: validates taskId presence and delegates to TickTickClient.updateTask, then returns success response with updated task JSON.
    case 'update_task': if (!args?.taskId) { throw new McpError(ErrorCode.InvalidParams, 'Task ID is required'); } const updatedTask = await this.ticktickClient!.updateTask(args.taskId as string, args); return { content: [ { type: 'text', text: `Task updated successfully: ${JSON.stringify(updatedTask, null, 2)}`, }, ], };
  • Schema definition for the update_task tool, specifying input parameters including required taskId and optional fields like title, content, dueDate, priority, tags.
    { name: 'update_task', description: 'Update an existing task', inputSchema: { type: 'object', properties: { taskId: { type: 'string', description: 'Task ID to update (required)', }, title: { type: 'string', description: 'New task title', }, content: { type: 'string', description: 'New task description/content', }, dueDate: { type: 'string', description: 'New due date in ISO format', }, priority: { type: 'number', description: 'New task priority (0=None, 1=Low, 3=Medium, 5=High)', }, tags: { type: 'array', items: { type: 'string' }, description: 'New task tags', }, }, required: ['taskId'], }, },
  • Implementation of updateTask in TickTickClient: ensures authentication, makes POST request to /task/{taskId} API endpoint with updates, returns the updated task or throws error.
    async updateTask(taskId: string, updates: Partial<TickTickTask>): Promise<TickTickTask> { await this.ensureAuthenticated(); try { const response = await this.client.post(`/task/${taskId}`, updates); return response.data; } catch (error) { throw new Error(`Failed to update task: ${error instanceof Error ? error.message : 'Unknown error'}`); } }

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/rafliruslan/ticktick-mcp-server'

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