Moving a repeater row is ordinarily a read-modify-write of the entire field: pull every row, reshuffle the array, write it all back. Get the array wrong and rows disappear.
custom-fields/reorder-acf-repeater-rows takes the new order as a list of 1-based indexes — [3, 1, 2] moves the third row to the front — and refuses anything that is not a complete permutation.
At a glance
| Ability | custom-fields/reorder-acf-repeater-rows |
| Toolset | Advanced Custom Fields — toolset/acf |
| Group | Repeater & Flexible Content |
| Requires | Advanced Custom Fields Pro, plus a repeater field registered on the site |
| Capability | manage_options |
| Safety | Writes data |
| Repeatable | Idempotent — running it twice leaves the same result |
| Ships in | AcrossAI Abilities Manager 0.0.34 and later |
How it works
The order array must contain every current index exactly once. A list that is short, long, repeats an index or names one out of range is rejected before any write, rather than quietly dropping the rows it left out.
That strictness is the point. A reorder that silently discards rows is indistinguishable from a successful one until someone notices the missing content.
Because the new order is stated absolutely rather than as a move, the call is idempotent: sending the same order twice leaves the same arrangement.
Input
| Name | Type | Required | What it is |
|---|---|---|---|
target_type | string | No — defaults to post | What the value is attached to: post, user, term, comment or option. post covers pages and any custom post type. |
target_id | integer | string | Yes, for post, user, term and comment | The ID of the target. Optional for option, where it names a specific options page; omit it for the default options store. |
selector | string | Yes | Repeater or flexible-content field name (e.g. cards) or field key. |
order | array of integers | Yes | The new order as 1-based indexes. Must be a permutation of 1..row_count — every index exactly once, none missing or repeated. |
What comes back
| Name | Type | What it is |
|---|---|---|
order | array | The order as applied. |
row_count | integer | How many rows the field holds. |
success | boolean | Whether the call completed. |
message | string | A one-line summary of what happened, suitable for showing a human. |
error_code | string | Present only on failure — a stable machine-readable reason, such as a missing field, a wrong field type or an unmet confirmation. |
Example
Ask your assistant:
Move the last card in the features repeater on page 87 to the top, keeping the other two in order.
It resolves to one call:
{
"ability": "custom-fields/reorder-acf-repeater-rows",
"parameters": {
"target_type": "post",
"target_id": 87,
"selector": "features",
"order": [3, 1, 2]
}
}Worth knowing
- Read the field first with
custom-fields/get-acf-fieldto get the current row count and see which index is which. - Reordering changes positions, never values — sub-field data travels with its row.
- Requires ACF Pro.
Related abilities
- Get ACF Field Value — read the current order first
- Update Repeater Row — change a row rather than move it
Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager
Browse the rest: Every ability, by category