Reverse a deposit or withdrawal.
DELETE
/api/ledger/{accountId}/cash-movements/{entryId}
const url = 'https://api.tradr.cloud/api/ledger/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/cash-movements/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0';const options = {method: 'DELETE'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url https://api.tradr.cloud/api/ledger/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/cash-movements/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0Appends a flipped-direction reversal entry that returns the balance to what it was before the movement. The original row is never removed — both persist. A second call against the same movement answers 409.
Authorizations
Section titled “Authorizations”Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters”accountId
required
string format: uuid
entryId
required
string format: uuid
Responses
Section titled “ Responses ”The reversal entry, plus the balance either side of it.
Media typeapplication/json
object
newBalance
string
previousBalance
string
reversal
object
Example
{ "newBalance": "1000.0000", "previousBalance": "2000.0000"}Not authenticated.
No such account for this user
The movement has already been reversed.