POST /api/v1/sites/{siteId}/reorder changes page order inside a folder, moves a page into another folder, or sets a folder's sort mode. Requires content:write. Use `/` for the site root.
Request
Required scope:content:writeThe body is discriminated by operation:
operation: reorder
Set the exact order of pages inside one folder. order must list every page in that folder — positions are set to the list index.Use "folder": "/" for pages at the site root.
operation: move
Move a page into a folder. When position (0-based) is present, the destination folder is renumbered so the page lands at that slot; otherwise the page is appended.
operation: sort
Set a folder's sort mode — the same setting the Pages panel uses. Root ("/") sets the site-wide default.mode must be one of: manual, name-asc, name-desc, recent, published.
Examples (curl)
Reorder pages in a collection:Move a page to the top of the blog:
Responses
200 OK — operation succeeded:
Status
Code
When
400
VALIDATION_ERROR
Missing fields, incomplete order list, or invalid mode
403
FORBIDDEN
Missing content:write or no access to the site
404
PAGE_NOT_FOUND
page path does not exist
404
FOLDER_NOT_FOUND
folder path does not exist
MCP tool
The Aveiro MCP server exposes aveiro_reorder_pages with the same operation, folder, order, page, position, and mode fields. Default tokens with content:write can call it from Cursor or Claude.Typical agent flow: aveiro_list_pages → build the desired order → aveiro_reorder_pages with operation: "reorder".