Skip to content

Delete a position (any status).

DELETE
/api/positions/{id}
curl --request DELETE \
--url https://api.tradr.cloud/api/positions/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0

Authed. Hard-deletes a position in any status (draft, open, or closed) and cascades to its fills. When the position had written a ledger entry via its close, a compensating position_pnl_reversal row is posted in the same transaction so the account balance is not left inflated; the ledger stays append-only (positionId is set NULL on the affected rows, which net to zero in the balance).

id
required
string format: uuid

Position deleted; its fills cascade and any prior close is reversed in the ledger.

Position not found (or not owned by the user).