Skip to main content
GET
Refresh Stats and Accounting Pipeline (Async)
This endpoint requires authentication. Include your Bearer token in the Authorization header.

Description

Refresh Stats and Accounting Pipeline Queue a comprehensive stats and accounting refresh pipeline using BullMQ. This operation triggers an asynchronous workflow that updates product, asset, and artist statistics followed by accounting recalculation. Method: GET Authorization:
  • Required role: admin or higher
Note: This operation is asynchronous and returns immediately with a flow ID for tracking. The actual processing happens in the background via BullMQ queues. Pipeline Steps:
  1. Product stats queue
  2. Asset stats queue
  3. Artist stats queue
  4. Accounting queue
All steps are deduplicated to prevent redundant processing.

Code Examples

Authorizations

Authorization
string
header
required

JWT Authorization header using the Bearer scheme. Format: "Bearer {token}"

Response

Stats and accounting refresh queued successfully

message
string
Example:

"Stats and accounting refresh queued successfully"

flowId
string

BullMQ flow ID for tracking the pipeline

Example:

"flow-uuid-789"

tenantId
integer

The tenant ID for which refresh was queued

Example:

123

status
enum<string>
Available options:
queued
Example:

"queued"

info
object