Accounting
Get Accounting Queue Status
Get Accounting Queue Status
GET
Get Accounting Queue Status
This endpoint requires authentication. Include your Bearer token in the Authorization header.
Description
Get Accounting Queue Status Check the status of accounting recalculation jobs. Can query a specific job by ID or get overall queue status. Method: GET Authorization:- Required role:
adminor higher
Without jobId: Returns queue overview and recent jobs
With jobId: Returns detailed status for that specific job
Polling and job retention:
The accounting queue removes a job record as soon as the job finishes
(
removeOnComplete / removeOnFail), which frees the stable job ID for
the next legitimate re-run. A poller must therefore expect the record to
disappear the moment the work is done — that is the normal end of a
successful run, not an error.
Two fields on the single-job response make this unambiguous:
When
retained is false the response also carries a human-readable
note. A job that exhausted its retries is reported as state: failed
with failedReason, resolved from the accounting dead-letter queue,
which does retain records.
Known limitation: because both completed and failed records are
removed, “ran and completed” and “this job ID never existed” are
indistinguishable. A well-formed job ID belonging to the caller’s own
tenant that never ran is reported as completed with retained: false.
A job ID that is not a valid accounting job ID returns 404; one
belonging to another tenant returns 403.
Code Examples
Authorizations
Response
Queue status retrieved successfully
- Specific Job Status
- Queue Overview