Undo a reconciled trade's reconciliation
POST/api/v1/reconciliation/undo/:tradeId
Reverses a mistaken reconciliation (#1104, #1157) and reopens the trade (unmarks it reconciled), recomputing its aggregates. The reversal depends on how the trade was reconciled. For an add-fill reconciliation the synthetic fills it added are removed (soft-deleted) and the real broker fills stay attached, so the prior drift reappears; revertedFillCount reports how many synthetic fills were removed. For a match or create the linked broker fills return to the needs-attention queue (detached and set back to pending_review) and synthetic placeholders stay attached; unlinkedCount reports how many fills returned to the queue. Fills follow their order (#1334): for a broker fill that carries an orderId, undo clears order.tradeId and detaches every execution on that order, not just the ones counted against this trade, so a wrongly linked order cannot stay pointed at the old trade and re-attach future fills to it. Backs the per-row Undo on the Reconciled tab, gated by the shared before/after confirm dialog.
Request
Responses
- 200
- 400
- 401
- 404
- 500
Trade reconciliation undone
Invalid trade ID format
Authentication required
Trade not found
Server error