# Reorder showcases

`PUT https://api.cademi.com.br/api/v3/showcases/order`

Operation ID: `showcases.order.update` · API v3

Sets the display order of the showcases at one level of the hierarchy: the top level when `parent_id` is omitted, or the showcases inside the group identified by `parent_id`.

The request must contain the complete set of showcase IDs at that level. If the supplied set does not match, the request is rejected with `order_set_mismatch` and the existing order remains unchanged.

Required permissions: `showcases.update`.

## Request body

Content type: `application/json`, required.

| Field | Type | Required | Description |
|---|---|---|---|
| `ids` | array of string | yes |  |
| `parent_id` | string or null | no |  |

## Responses

### 200

Returns the showcases at that level in their new order.

Body: `data`: array of Showcase.

Fields of Showcase:

| Field | Type | Required | Description |
|---|---|---|---|
| `created_at` | string (date-time) | yes |  |
| `deleted` | boolean | yes |  |
| `id` | string | yes | Public ID, with the shw_ prefix. |
| `image` | string or null | yes |  |
| `kind` | string, one of `group`, `showcase` | yes |  |
| `name` | string | yes |  |
| `object` | string, one of `showcase` | yes |  |
| `parent_id` | string or null | yes |  |
| `position` | integer | yes |  |
| `products_count` | integer | yes |  |
| `revision` | string | yes |  |
| `status` | string, one of `published`, `draft`, `unlisted`, `hidden` | yes |  |
| `updated_at` | string (date-time) | yes |  |

### 401

The credential is missing, malformed, expired, or revoked.

Body: Error.

### 403

The current credentials do not have the permission required by this operation.

Body: Error.

### 422

The supplied showcase IDs do not match the set of showcases at that level.

Body: Error.

Full schema: https://cademi.dev/openapi/v3.json
