Duplicate a task and its subtasks
Tasks View as Markdown
POST/api/task/{taskId}/duplicate
Recursively duplicates a task and its subtasks. Comments and attachments are not duplicated.
Parameters
taskIdintegerpathRequired- ID of the task.
Request body
copyToProjectIdinteger | null- ID of the project to copy into. Omit or
nullto copy within the same project. Statuses and milestones are not inherited when copying to another project. prefixstring- Text added before each copied task name, for example
Copy of. Defaults to an empty string. suffixstring- Text added after each copied task name. Defaults to an empty string.
startDateinteger | null- New start date as a Unix timestamp in milliseconds. The earliest date in the copied tree moves to this day and all other dates shift by the same amount. Only applies when
inherit.dueDateistrue. inheritobject- Which properties of the original task the copies inherit. Anything not set to
trueis left empty.
Responses
200Duplicated tasks400Invalid body401Authentication is required403Not a project member404Task not found