Custody Move State Conflict
URI: https://docs.ankatech.co/errors/custody-move-state-conflict
HTTP Status: 409 Conflict
When you see this
A key custody operation addressed a move that is not in a state the operation applies to. Nothing was changed.
A move is recorded PENDING, becomes SCHEDULED when its start is fixed, then runs (a window passes through DRAINING, PREPARING, VERIFYING, SWAPPED and FLIPPED; an online move through REWRAPPING and RETIRING) and ends COMPLETED, ABORTED or CANCELLED. Each operation applies to some of those states only.
Common Causes
- Choosing a destination, rescheduling or cancelling a move that has already started.
- Cancelling or aborting a move that has already finished.
- Choosing a destination for an Edition change to a lower tier: its destination is that Edition's tier and is not chosen.
- Two operators acting on the same move at once: the second request sees the state the first one left.
Response Example
{
"type": "https://docs.ankatech.co/errors/custody-move-state-conflict",
"title": "Custody Move State Conflict",
"status": 409,
"detail": "The key custody move is not in a state this operation applies to. Nothing was changed.",
"instance": "/api/v3/admin/tenants/8f14e45f-ceea-467a-9575-0d5b2a1f3c11/key-custody/moves/5e2d4c6b-8a1f-4b3c-9d7e-0f1a2b3c4d5e/cancel",
"timestamp": 1793696400,
"extensions": {
"requestId": "9c41e7a2-5b08-4d3f-a6e1-2f7c90b4d815"
}
}
Content-Type: application/problem+json — the response follows RFC 9457 Problem Details.
How to Resolve
- Read the move (
GET .../key-custody/moves) and check itsstateandawaits. - Pick the operation that applies to that state: a running window is aborted rather than cancelled; a finished move needs no operation; a move that awaits its destination has it chosen before it is scheduled.
Related Errors
- Custody Move Past Its Swap (409) - the abort of a window whose keys are already live on the destination
- Custody Move In Progress (409) - a second move asked for while one is open
For full schema definitions, examples, and interactive testing, see the Developer Hub Reference.