Job Management

Count jobs by status and type

How many of your jobs are in each status and of each type, as one table: a row per status and type that has any, with its count. Takes the filters GET /api/v1/jobs takes, except status and type — those are the table's two dimensions — and every cell is the meta.total that listing would report for that status and type.

To count by status alone, sum the rows for each status; to count the statuses within one type, keep that type's rows first.

USE THIS WHEN:

  • Checking how many jobs failed, or are still running, without paging through them
  • Showing a count beside each status or type filter

DO NOT USE WHEN:

  • You need the jobs themselves → use GET /api/v1/jobs
  • You need credits spent → use GET /api/v1/usage
get/api/v1/jobs/counts

Request

  • Base URL: https://api.imagestep.dev
  • URL: https://api.imagestep.dev/api/v1/jobs/counts
  • Auth: API key in header Authorization

Query parameters

presetstring

Only jobs that ran this preset, as on GET /api/v1/jobs: a slug or id for every version of it, or slug@version. A preset that is not yours is 404 preset_not_found.

opstring

Only jobs submitted as this op — one entry of GET /api/v1/ops.

rootJobIdstring

Only the attempts of one job: the ones whose rootJobId is this — the first attempt's id, the first attempt included.

createdFromstring

Submitted at or after this. Epoch millis, or an ISO-8601 date or instant read as UTC.

createdTostring

Submitted at or before this. Same forms as createdFrom; a bare date includes the whole of that day.

Response

The non-zero cells; an empty list when nothing matches

Changes

No recorded changes to this operation across all 1 revision of this API.