Queue counts

get/v1/datasets/{datasetId}/items/queue/stats

How many of the dataset's queue entries are in each state, for a progress bar or a health check, without paging through the queue. Archived entries are not counted.

processing includes entries waiting for the labelling batch. retryable is how many of the failed entries a retry can help: those whose product has at least one photo. A product with no photo fails every time, so a retry does not move it. It is the number POST /v1/datasets/{datasetId}/items/queue/retry would put back.

Private keyapi.v1.datasets.items.queue.statsNo demo

Path parameters

1
datasetIdstring (uuid)required

The dataset's id, as returned when it was created.

Response

200Counts by state.
objectrequired

Entries per state.

pendingintegerrequired

Waiting for a worker.

partial_updateintegerrequired

Waiting for a price or stock update only.

processingintegerrequired

Being processed

completeintegerrequired

Processed into the catalogue.

failedintegerrequired

Failed after their automatic retries.

retryableintegerrequired

The failed entries a retry can help.

totalintegerrequired

Every entry counted above

Errors

21

Every error is JSON with a single error string unless noted. Match on the status code; the message is for humans.

401
Organization not found. Please verify the organizationId.

The organization encoded in the API key no longer exists.

404
Dataset not found for this organization.

No dataset with this datasetId belongs to the key's organization.

curl -X GET "https://stylor.ai/api/v1/datasets/YOUR_DATASET_ID/items/queue/stats" \
  -H "Authorization: Bearer $STYLOR_API_KEY"
Response · 200
{
  "stats": {
    "pending": 12,
    "partial_update": 0,
    "processing": 3,
    "complete": 412,
    "failed": 5,
    "retryable": 4,
    "total": 432
  }
}