---
search:
  tags:
    - administration
    - POST
seo:
  description: >-
    Allows reordering components and items at the… Reference for the POST
    /administration/project-components/tree/sort endpoint in the Leadtime Public
    API API.
sidebar:
  badge: POST
  label: Move/reorder items in component library tree
title: Move/reorder items in component library tree
type: openapi-operation
---
Allows reordering components and items at the same level, reparenting items to different components or parent items, and moving items between components (automatically updates componentId for all descendants). When parent is null, sorts components. When parent is provided, sorts items within that parent. Automatically handles side-effects including conditions cleanup and timeframe updates. Only library components and items (component.projectId is null) can be reordered through this endpoint.

<Operation source="api-reference" id="componentlibrarycontroller-savecomponentssort" />
