Reverse a journal transaction
Posts the mirror image of an existing journal transaction: every entry of the original is written back with its sides swapped, as a NEW transaction. The original is left as it is — nothing is deleted or amended — and the new transaction records the original's id in its metadata, which is also how the already-reversed check below finds it. The reversal goes through the same posting path as a direct journal transaction, so every refusal that path raises applies here too.
Authorization
bearerAuth In: header
Path Parameters
Identifier of the journal transaction to reverse.
Request Body
application/json
Optional. An absent or empty body is accepted — the decode tolerates EOF — so the reason may simply be omitted.
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/ledgers/journals/497f6eca-6276-4993-bfeb-53cbbbba6f08/reverse" \ -H "Content-Type: application/json" \ -d '{}'{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"type": "string",
"status": "string",
"total_amount": {
"amount": "123456",
"currency": "EUR",
"precision": 2
},
"currency_id": "305e0674-ee79-42b7-bf83-278294a47a7b",
"currency_code": "string",
"description": "string",
"reference_id": "string",
"timestamp": "2019-08-24T14:15:22Z",
"value_date": "2019-08-24T14:15:22Z",
"completed_at": "2019-08-24T14:15:22Z",
"reconciled_at": "2019-08-24T14:15:22Z",
"metadata": {},
"created_at": "2019-08-24T14:15:22Z",
"modified_at": "2019-08-24T14:15:22Z",
"created_by": "ee824cad-d7a6-4f48-87dc-e8461a9201c4",
"modified_by": "e8d4374d-93a1-4e98-a6c6-fdcf00c5059f",
"total_debit_lcy": {
"amount": "123456",
"currency": "EUR",
"precision": 2
},
"total_credit_lcy": {
"amount": "123456",
"currency": "EUR",
"precision": 2
},
"active": true,
"id_client": "string"
}{
"status": 0,
"message": "string",
"code": "string",
"class": "validation",
"retryable": true,
"details": [
{
"field": "string",
"message": "string"
}
]
}{
"status": 0,
"message": "string",
"code": "string",
"class": "validation",
"retryable": true,
"details": [
{
"field": "string",
"message": "string"
}
]
}{
"status": 0,
"message": "string",
"code": "string",
"class": "validation",
"retryable": true,
"details": [
{
"field": "string",
"message": "string"
}
]
}{
"status": 0,
"message": "string",
"code": "string",
"class": "validation",
"retryable": true,
"details": [
{
"field": "string",
"message": "string"
}
]
}Create a balanced multi-entry journal transaction with automatic currency conversion to the system's base currency.
Create a new ledger entry and update the ledger balance in a single transaction, with cascading updates to parent ledgers. The ledger can be identified using one of three methods: by UUID (ledger_id), by code (ledger_code), or by numeric ID (ledger_num_id). At least one of these identifiers must be provided.