---
title: "Reorder phases"
method: PUT
path: "/admin/phases/reorder"
tags: ["Task Phases"]
---

# Reorder phases

`PUT /admin/phases/reorder`

## Request

- Base URL: `https://api.production.yourmedley.com`
- URL: `https://api.production.yourmedley.com/admin/phases/reorder`
- Auth: HTTP bearer

Update sort_order for multiple phases at once

## Request body

- object
  - `phases` object[], required
    - `id` string, uuid, required
    - `sort_order` integer, required

## Response `200`

Phases reordered successfully

- object
  - `success` boolean
  - `data` TaskPhaseWithCount[]
    - `id` string, uuid: Unique identifier
    - `name` string: Phase name
    - `slug` string: URL-friendly identifier
    - `description` string, nullable: Description of the phase
    - `sort_order` integer: Display order
    - `is_active` boolean: Whether the phase is active
    - `is_archived` boolean: Whether the phase is archived
    - `created_at` string, date-time
    - `updated_at` string, date-time
    - `template_count` integer: Number of templates in this phase

## Other responses

- `400`: Invalid request body
- `401`: Unauthorized
- `404`: Phase not found

---

[API](https://skmtc.dev/withmedley/apis/medley-api.md) - [All operations](https://skmtc.dev/withmedley/apis/medley-api/llms.txt) - [OpenAPI document](https://skmtc.dev/withmedley/apis/medley-api/revisions/40aaac5ca6bd?raw)
