feat(api): add parentTaskId support to task update and MCP create
Allow setting ParentTaskId when updating a task via the API (with validation that the parent exists) and when creating a task via the MCP create_task tool. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -39,9 +39,10 @@ public sealed class TaskTools
|
||||
HttpClient client,
|
||||
[Description("Title of the task")] string title,
|
||||
[Description("Optional description")] string? description = null,
|
||||
[Description("Optional category (e.g. Engineering, Email, LaserCutting)")] string? category = null)
|
||||
[Description("Optional category (e.g. Engineering, Email, LaserCutting)")] string? category = null,
|
||||
[Description("Optional parent task ID to create this as a subtask")] int? parentTaskId = null)
|
||||
{
|
||||
var payload = new { title, description, category };
|
||||
var payload = new { title, description, category, parentTaskId };
|
||||
var response = await client.PostAsJsonAsync("/api/tasks", payload, JsonOptions);
|
||||
return await response.Content.ReadAsStringAsync();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user