iotoms Docs

Run accounting posting now

POST
/api/v1/accounting/posting-runs/trigger

Posts new sales and goods receipts into the journal immediately instead of waiting for the scheduled run every 15 minutes. Safe to call repeatedly.

How to use it

  1. Call it after confirming goods receipts, approving commission runs or recording payouts to book them without waiting for the 15-minute schedule.
  2. If executed is false, no posting rules are active yet; set them up with Update posting rules.
  3. Check each source's exceptions count and fix failures listed in List failed accounting postings.

Authorization

BearerAuth
headerAuthorizationBearer <JWT>

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 request: SUCCESS when it worked; errors return an error status with the reason in message.

message*string

Short human-readable message describing the outcome.

data?

The result of the posting run, with counts per document source.

Example Request
curl -X POST 'https://beta.iotoms.com/api/v1/accounting/posting-runs/trigger' \  -H 'X-TenantID: your-tenant-code'
Example Response
{  "status": "string",  "message": "string",  "data": {    "ranAt": "2019-08-24T14:15:22Z",    "executed": true,    "sources": [      {        "source": "string",        "eventType": "string",        "scanned": 0,        "posted": 0,        "alreadyPosted": 0,        "exceptions": 0,        "zeroSkipped": 0      }    ]  }}