update_task
Modify task details in Yokan Board MCP by updating title, description, due date, or subtasks to keep project management current and organized.
Instructions
Updates the title, description, due date, and/or subtasks of an existing task.
Args: board_id (int): The ID of the board containing the task. task_id (str): The ID of the task to update. auth (AuthContext): The authentication context containing user ID and token. title (Optional[str], optional): The new title for the task. Defaults to None. description (Optional[str], optional): The new description for the task. Defaults to None. dueDate (Optional[str], optional): The new due date for the task (e.g., "YYYY-MM-DD"). Defaults to None. subtasks (Optional[List[str]], optional): A list of subtask IDs. Defaults to None.
Returns: None
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| board_id | Yes | ||
| task_id | Yes | ||
| auth | Yes | ||
| title | No | ||
| description | No | ||
| dueDate | No | ||
| subtasks | No |
Implementation Reference
- src/main.py:492-543 (handler)The implementation of the `update_task` MCP tool, which updates task properties and calls `yokan_client.update_board` to persist changes.
async def update_task( board_id: int, task_id: str, auth: AuthContext, title: Optional[str] = None, description: Optional[str] = None, dueDate: Optional[str] = None, subtasks: Optional[List[str]] = None, ) -> None: """Updates the title, description, due date, and/or subtasks of an existing task. Args: board_id (int): The ID of the board containing the task. task_id (str): The ID of the task to update. auth (AuthContext): The authentication context containing user ID and token. title (Optional[str], optional): The new title for the task. Defaults to None. description (Optional[str], optional): The new description for the task. Defaults to None. dueDate (Optional[str], optional): The new due date for the task (e.g., "YYYY-MM-DD"). Defaults to None. subtasks (Optional[List[str]], optional): A list of subtask IDs. Defaults to None. Returns: None """ board = await yokan_client.get_board(board_id=board_id, token=auth.token) if "columns" not in board.data: raise McpError(error=ErrorData(code=NOT_FOUND, message="Task not found")) task_found = False for column in board.data["columns"].values(): for task in column.get("tasks", []): if task.get("id") == task_id: if title is not None: task["content"] = title if description is not None: task["description"] = description if dueDate is not None: task["dueDate"] = dueDate if subtasks is not None: task["subtasks"] = subtasks task_found = True break if task_found: break if not task_found: raise McpError(error=ErrorData(code=NOT_FOUND, message="Task not found")) await yokan_client.update_board( board_id=board_id, name=board.name, data=board.data, token=auth.token ) - src/main.py:490-490 (registration)Registration of the `update_task` tool using the `@app_instance.tool` decorator.
@app_instance.tool