iotoms Docs

Get an account ledger

GET
/api/v1/accounting/gl/accounts/{id}/ledger

Returns the ledger for one account: opening balance before from, every posted line in the from–to range, and a running balance. Omit the dates for the full history.

Authorization

BearerAuth
headerAuthorizationBearer <JWT>

Path Parameters

id*string

ID of the record (UUID).

Formatuuid

Query Parameters

from?string

Start date, YYYY-MM-DD.

Formatdate
to?string

End date, YYYY-MM-DD.

Formatdate

Header Parameters

X-TenantID*string

Your merchant's tenant code — the value typed in the Domain field on the iotoms login screen. See Concepts.

Response Body

OK

*/*
  1. response
status*string

Outcome of the call: SUCCESS when the request was processed; otherwise an error status.

message*string

Short human-readable message describing the outcome, e.g. which record was saved or why the call failed.

data?

The account ledger: opening balance, posted lines in the date range and closing balance.

Example Request
curl -X GET 'https://beta.iotoms.com/api/v1/accounting/gl/accounts/497f6eca-6276-4993-bfeb-53cbbbba6f08/ledger' \  -H 'X-TenantID: your-tenant-code'
Example Response
{  "status": "string",  "message": "string",  "data": {    "accountId": "3d07c219-0a88-45be-9cfc-91e9d095a1e9",    "accountCode": "string",    "accountName": "string",    "accountType": "ASSET",    "currency": "string",    "from": "2019-08-24",    "to": "2019-08-24",    "openingBalanceMinor": 0,    "closingBalanceMinor": 0,    "rows": [      {        "entryId": "09a8b554-45ca-4bab-a638-265db4b3e828",        "lineId": 0,        "effectiveAt": "2019-08-24",        "postedAt": "2019-08-24T14:15:22Z",        "memo": "string",        "sourceSystem": "string",        "eventType": "string",        "direction": "DEBIT",        "amountMinor": 0,        "runningBalanceMinor": 0      }    ]  }}