# Reorder showcase products

`PUT https://api.cademi.com.br/api/v3/showcases/{showcase_id}/products/order`

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

Sets the display order of the products in a showcase. Requires both the `products.update` and `showcases.update` permissions.

The request must contain the complete set of product IDs currently in the showcase. If the supplied set does not match, the request is rejected with `order_set_mismatch` and the existing order remains unchanged. This operation does not move products between showcases; to change a product's showcase, update the product's `showcase_id`.

Send the showcase's current `ETag` value in the `If-Match` header to avoid overwriting a newer version.

Required permissions: `products.update`, `showcases.update`.

## Parameters

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `showcase_id` | path | string | yes |  |
| `If-Match` | header | string | no |  |

## Request body

Content type: `application/json`, required.

| Field | Type | Required | Description |
|---|---|---|---|
| `ids` | array of string | yes |  |

## Responses

### 200

Returns the showcase's products in their new order, in summary form.

Body: `data`: array of ProductSummary.

Fields of ProductSummary:

| Field | Type | Required | Description |
|---|---|---|---|
| `id` | string | yes | Public ID, with the prd_ prefix. |
| `name` | string | yes |  |
| `object` | string, one of `product` | yes |  |
| `position` | integer | yes |  |
| `status` | string, one of `published`, `draft`, `unlisted`, `hidden` | 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.

### 404

The showcase was not found or is not accessible with the current credentials.

Body: Error.

### 412

The showcase has changed since the supplied revision was retrieved.

Body: Error.

### 422

The supplied product IDs do not match the set of products in the showcase.

Body: Error.

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