Zum Inhalt springen
Leadtime
Deutsch
Esc
↑↓navigieren↵öffnen⌘Jvorschau

Create a new component item (Epic, Work Package, Todo List, or Test Suite)

Creates a new component item within a library component. Items are the building blocks that structure component templates.

What are Component Items? Items are the building blocks within components that organize and structure project work. Each item can be one of four types:

  1. Epic: Major sections or phases that group related work packages around a common theme or goal

    • Example: “Technical Implementation”, “Design & Development”, “Project Kickoff & Preparation”
    • Can contain Work Packages, Todo Lists, or Test Suites
    • Can nest other Epics to create complex hierarchies (arbitrary nesting depth)
    • TimeFrame is not required for Epics
  2. Work Package: Self-contained, clearly defined tasks that deliver tangible results

    • Example: “Set up domain and hosting”, “Design homepage layout”, “Configure CMS”
    • Can have timeframes/estimates (required field)
    • Can contain Questions (to capture customer requirements), Todos (checklist items), and Test Cases (acceptance test steps)
    • Can nest other Work Packages for complex tasks
  3. Todo List: Checklists of sub-steps or checkpoints

    • Example: “Kickoff Checklist”, “Quality Control Checklist”, “Go-live Approval”
    • Perfect for recurring processes (tests, approvals, installation steps)
    • Each todo item within the list can be checked off individually
    • TimeFrame is required
  4. Test Suite: Formal acceptance tests for project results

    • Example: “Contact Form Tests”, “Responsive Design Check”, “SEO Review”
    • Contains multiple test cases with steps and expected results
    • TimeFrame is required

Item Placement: Items can be created at the root level of a component or nested under parent items (Epics or other Work Packages).

Content Format: The description and internalNote fields accept HTML or Markdown input and are automatically converted to the internal IDoc format for storage.

Validation Rules: TimeFrame is required for all item types except Epic. Only library component items (component.projectId is null) can be created through this endpoint.

POST/administration/project-components/items
Authorization
AuthorizationOAuth2 access token · headerrequired
Scopes:api:write
or
AuthorizationBearer token (JWT) · headerrequired
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
Request body
requiredapplication/json
componentIdstringrequired

Parent component ID

conditionsSaveComponentItemConditionDto[]

Array of conditions (optional)

Show properties
Array of SaveComponentItemConditionDto
containsTypestringrequired

Contains type

Allowed:SomeAll
idstring | null

Condition ID (optional, for updates)

targetQuestionIdstring | null

Target question ID (optional)

targetTestCaseIdstring | null

Target test case ID (optional)

targetTodoIdstring | null

Target todo ID (optional)

targetValuestring | null

Target value (optional)

typestringrequired

Condition type

Allowed:QuestionAnsweredQuestionNotAnsweredQuestionAnswerContainsQuestionAnswerDoesNotContainQuestionAnswerEqualQuestionAnswerDoesNotEqualTodoIsDoneTodoIsNotDoneTestCasePassedTestCaseFailed
descriptionstringrequired

Description in HTML or Markdown format (will be converted to IDoc)

iconobject | null

Icon identifier in the format :icon_name: (e.g., :rocket:, :check:, :star:). Optional.

includeInSpecificationbooleanrequired

Whether to include in specification

internalNotestring | null

Internal note in HTML or Markdown format (optional, will be converted to IDoc)

namestringrequired

Name of the component item

parentIdstring | null

Parent item ID (optional, for nested items)

tagsstring[]

Array of tag UUIDs (optional)

timeFramenumber

Time frame in hours (required for all types except Epic)

typestringrequired

Type of component item

Allowed:EpicWorkPackageTodoListTestSuite
Responses
201

Component item created successfully

idstringrequired

Created item ID

successbooleanrequired

Success status

400

Invalid request: invalid UUID format, missing required fields, or validation errors

401

Unauthorized - Invalid or missing authentication token

403

Insufficient permissions to edit component library

404

Component not found or does not belong to library (has projectId)

422

Editor content conversion errors

Try it
Server
Authorization
Parameters
Bodyapplication/json
Request
curl -X POST "https://leadtime.app/api/public/administration/project-components/items" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "componentId": "550e8400-e29b-41d4-a716-446655440000",
  "conditions": [
    {
      "containsType": "Some",
      "id": "550e8400-e29b-41d4-a716-446655440013",
      "targetQuestionId": "550e8400-e29b-41d4-a716-446655440014",
      "targetTestCaseId": "550e8400-e29b-41d4-a716-446655440016",
      "targetTodoId": "550e8400-e29b-41d4-a716-446655440015",
      "targetValue": "option-value",
      "type": "QuestionAnswered"
    }
  ],
  "description": "<p>Epic description in HTML</p>",
  "icon": ":check:",
  "includeInSpecification": true,
  "internalNote": "<p>Internal implementation notes</p>",
  "name": "User Authentication Epic",
  "parentId": null,
  "tags": [
    "550e8400-e29b-41d4-a716-446655440020"
  ],
  "timeFrame": 20,
  "type": "Epic"
}'
Response
{
  "id": "550e8400-e29b-41d4-a716-446655440001",
  "success": true
}