BizKitHub
DocsAPI ReferenceProduct/bff/product/product-reorder
postProductAdmin BFF

/bff/product/product-reorder

Atomically redistributes existing position values among the listed products according to the new order. Verifies global density (positions 1..N without gaps) with a cheap aggregate query and runs a window-function repack only if needed.

ProductpostBffProductProduct-reorder

Parameters

JSON body

Request body

application/json
orderedCodesstring[]Required

Product codes in their new visual order. Their existing position values are redistributed among them (swapped mutually); products outside this list keep their absolute positions. A global 1..N repack runs only if a position gap is detected after the swap.

Response schema

1 status code documented

200Success
successbooleanRequired

Whether the reorder completed.

reorderednumberRequired

Number of products whose positions were swapped.

totalProductsnumberRequired

Total non-deleted products in the organisation.

repackedbooleanRequired

Whether a global 1..N repack pass was applied (true if a gap was detected).

Response example

application/json
{
  "success": false,
  "reordered": 0,
  "totalProducts": 0,
  "repacked": false
}

Request example

POST /bff/product/product-reorder

post
curl -X POST "https://api.bizkithub.com/bff/product/product-reorder" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{
  "orderedCodes": [
    "string"
  ]
}'

Need an API key?

All BizKitHub public API endpoints require authentication via API key.

Get API Key