Zum Inhalt springen
Leadtime
Deutsch
Esc
navigateopen⌘Jpreview

Duplicate a task

Creates a copy of an existing task in the same project. The duplicated task keeps the source task configuration such as type, status, description, priority, assignee, accountable person, tags, custom fields, guest access, and task products. The new task title gets a (Copy) suffix. Accepts either a UUID or a numeric short number (with or without # prefix). Organization members can only duplicate tasks with guest access enabled.

POST/tasks/{identifier}/duplicate
Authorization
AuthorizationOAuth2 access token · headerrequired
Scopes:api:write
or
AuthorizationBearer token (JWT) · headerrequired
Path parameters
identifierstringrequired
Task UUID or short number (e.g., "550e8400-e29b-41d4-a716-446655440000" or "123" or "#123")
Query parameters
fieldsToReturnstring
Comma-separated list of top-level response fields to return. Overrides the endpoint compact default unless responseShape=full is used.
responseShapestring
Advanced override. Omit for the endpoint compact default. Use full only when you need the complete endpoint response, including nested fields that are not selectable with fieldsToReturn.
Allowed:compactfull
Header parameters
LT-Response-Shapestring
Advanced override. Set to full only when you need the complete endpoint response, including nested fields that are not selectable with fieldsToReturn.
Allowed:full
Responses
201Task duplicated successfully
accountableobject
Accountable user details
accountableIdstring
Accountable user ID
assignedToobject
Assigned user details
assignedToIdstring
Assigned user ID
billedbooleanrequired
Whether task is billed
childSpentTimenumberrequired
Child tasks spent time in minutes
commentsany[][]required
Task comments; each `body` is HTML and may contain the same embedded `appImage` / `appFile` / `appVideo` divs with `fileId` as the task description. Fetch binaries via authenticated `/api/public/workspace/files/{fileId}` with the same Public API Bearer token when needed.
componentItemIdobject
Component item ID
createdAtstring<date-time>required
Task creation timestamp
customFieldsobjectrequired
Custom fields values
deadlinestring<date-time>
Task deadline
descriptionstringrequired
Task description in HTML. May include embedded assets as elements such as `<div data-type="appImage" fileId="…" filename="…">` (images), `appFile`, or `appVideo`—binary content is not embedded; use authenticated GET `{appOrigin}/api/public/workspace/files/{fileId}` with the same Public API Bearer token to retrieve it.
emailDetailsobject
Email details
emailSendErrorstring
Email send error message
emailSendErrorCodestring
Email send error code
emailSendFailedAtstring<date-time>
Email send failed timestamp
emailSendFailedToany[][]
Email send failed recipients
enableSupportContingentbooleanrequired
Enable support contingent
estimatedTimenumber
Estimated time in hours
guestAccessbooleanrequired
Guest access enabled for organization members
historyany[][]required
Task history entries
iconobject
Task icon identifier in the format `:icon_name:` (e.g., `:rocket:`, `:bug:`, `:memo:`). Can be null if no custom icon is set.
iconIsGeneratingbooleanrequired
Whether icon is being generated by AI
idstringrequired
Task ID (UUID)
isChangeRequestbooleanrequired
Whether task is a change request
isParticipantbooleanrequired
Whether current user is a participant
notificationSettingsobjectrequired
Notification settings
parentTaskIdobject
Parent task ID for subtasks
participantsCountnumberrequired
Number of participants
participantsListany[][]required
List of participant user IDs
priorityobjectrequired
Task priority (TaskPriority enum)
productsany[][]required
Task products
projectobjectrequired
Project information
projectIdstringrequired
Project ID
quotationsany[][]required
Express quotations
shortNumbernumberrequired
Task short number (workspace-scoped)
skipFromBillingboolean
Skip from billing
spentTimenumberrequired
Total spent time in minutes
statusIdstringrequired
Task status ID
subTasksIdsany[][]required
Child task IDs
summarystring
Task summary
summaryIsGeneratingbooleanrequired
Whether summary is being generated by AI
tagsany[][]required
Task tags
titlestringrequired
Task title
titleIsGeneratingbooleanrequired
Whether title is being generated by AI
typeIdstringrequired
Task type ID
userIdstringrequired
Creator user ID
400Invalid identifier format (not UUID and not numeric)
401Unauthorized - Invalid or missing authentication token
403Access denied: Missing Tasks.create permission, no project access, or OrganizationMember accessing a non-guest task
404Task not found
Request
curl -X POST "https://leadtime.app/api/public/tasks/123/duplicate" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
Response
{
  "accountable": {},
  "accountableId": "string",
  "assignedTo": {},
  "assignedToId": "string",
  "billed": true,
  "childSpentTime": 0,
  "comments": [
    [
      null
    ]
  ],
  "componentItemId": {},
  "createdAt": "2024-01-01T00:00:00Z",
  "customFields": {},
  "deadline": "2024-01-01T00:00:00Z",
  "description": "string",
  "emailDetails": {},
  "emailSendError": "string",
  "emailSendErrorCode": "string",
  "emailSendFailedAt": "2024-01-01T00:00:00Z",
  "emailSendFailedTo": [
    [
      null
    ]
  ],
  "enableSupportContingent": true,
  "estimatedTime": 0,
  "guestAccess": true,
  "history": [
    [
      null
    ]
  ],
  "icon": {},
  "iconIsGenerating": true,
  "id": "string",
  "isChangeRequest": true,
  "isParticipant": true,
  "notificationSettings": {},
  "parentTaskId": {},
  "participantsCount": 0,
  "participantsList": [
    [
      null
    ]
  ],
  "priority": {},
  "products": [
    [
      null
    ]
  ],
  "project": {},
  "projectId": "string",
  "quotations": [
    [
      null
    ]
  ],
  "shortNumber": 0,
  "skipFromBilling": true,
  "spentTime": 0,
  "statusId": "string",
  "subTasksIds": [
    [
      null
    ]
  ],
  "summary": "string",
  "summaryIsGenerating": true,
  "tags": [
    [
      null
    ]
  ],
  "title": "string",
  "titleIsGenerating": true,
  "typeId": "string",
  "userId": "string"
}