QueueFlowDocs

Reference

REST API reference

Every endpoint and schema of the QueueFlow REST API (OpenAPI 1.0.0), generated from the spec the server itself emits.

The server emits this document at /openapi.json and serves an interactive Swagger UI at /docs. A copy of the spec used to build this page is at /openapi.json; the canonical file lives in the queueflow-core repository and is attached to every release.

All /api/v1 routes require Authorization: Bearer <token>. Tenant routes take a tenant token (API key or JWT); the worker-protocol routes take the deployment's worker token. See Authentication and tenants. Durations are plain integer seconds; timestamps are RFC 3339 strings in UTC. Error responses share one shape:

json
{ "error": "job not found", "timestamp": "2026-10-06T12:00:00Z" }

#Endpoints

GET/healthgetHealth
GET/readygetReady
GET/api/v1/jobslistJobs
POST/api/v1/jobscreateJob
POST/api/v1/jobs/batchcreateBatchJobs
GET/api/v1/jobs/{id}getJob
POST/api/v1/jobs/{id}/cancelcancelJob
GET/api/v1/jobs/{id}/eventsstreamJobEvents
GET/api/v1/workflowslistWorkflows
POST/api/v1/workflowscreateWorkflow
GET/api/v1/workflows/{id}getWorkflow
POST/api/v1/workflows/{id}/cancelcancelWorkflow
GET/api/v1/workflows/{id}/diagramgetWorkflowDiagram
GET/api/v1/workflows/{id}/stepsgetWorkflowStepStates
GET/api/v1/cronlistCrons
POST/api/v1/croncreateCron
GET/api/v1/cron/{id}getCron
DELETE/api/v1/cron/{id}deleteCron
POST/api/v1/cron/{id}/pausepauseCron
POST/api/v1/cron/{id}/resumeresumeCron
GET/api/v1/dlqlistDeadLetters
GET/api/v1/dlq/{id}getDeadLetter
POST/api/v1/dlq/{id}/replayreplayDeadLetter
POST/api/v1/jobs/{id}/completecompleteJob
POST/api/v1/jobs/{id}/failfailJob
POST/api/v1/jobs/{id}/heartbeatheartbeatJob
POST/api/v1/queues/{queue}/leaseleaseJobs
GET/api/v1/statsgetStats
GET/api/v1/taskslistTasks

#Health

Liveness and readiness probes

#GET /health

operationId getHealth no auth

Responses

StatusBodyMeaning
200HealthStatusHealthy
503ErrorBodyDatabase unavailable

#GET /ready

operationId getReady no auth

Responses

StatusBodyMeaning
200ReadyStatusReady
503ErrorBodyNot ready

#Jobs

Job lifecycle

#GET /api/v1/jobs

operationId listJobs

Parameters

NameInTypeDescription
statusquerystringFilter by status (e.g. pending, completed).
queuequerystringFilter by queue name (jobs only).
limitqueryinteger (int64)Page size, 1..=100 (default 50).
offsetqueryinteger (int64)Number of records to skip (default 0).
order_byquerystringcreated_at ASC or created_at DESC (default DESC).
include_totalquerybooleanInclude the exact total count in the response (default false; the count is an extra full scan over the filtered set).
cursorquerystringOpaque keyset cursor from a previous page's next_cursor. When set, offset is ignored and listing continues where that page ended.
created_afterquerystring (date-time)Only rows created at or after this instant (RFC 3339, inclusive). With created_before this forms the half-open range [after, before) — the natural shape for walking history period by period.
created_beforequerystring (date-time)Only rows created strictly before this instant (RFC 3339, exclusive).

Responses

StatusBodyMeaning
200ListJobsResponsePage of jobs
401ErrorBodyUnauthorized

#POST /api/v1/jobs

operationId createJob

Parameters

NameInTypeDescription
Idempotency-Keyheaderstring | nullOptional client-supplied key making this create idempotent per tenant: retrying with the same key returns the original job instead of creating a duplicate.

Request body application/json

CreateJobRequest

FieldTypeDescription
task_namerequiredstringThe registered task handler to invoke.
confignull | JobConfigRequest
payloadobjectArbitrary JSON object passed to the handler.
run_atstring (date-time) | nullDon't run before this instant (RFC 3339). The job is created immediately but stays invisible to workers until then.

Responses

StatusBodyMeaning
201CreateJobResponseJob created (or replayed idempotently)
400ErrorBodyInvalid request
401ErrorBodyUnauthorized

#POST /api/v1/jobs/batch

operationId createBatchJobs

Request body application/json

CreateBatchJobsRequest

FieldTypeDescription
jobsrequiredarray<CreateJobRequest>

Responses

StatusBodyMeaning
201CreateBatchJobsResponseJobs created
400ErrorBodyInvalid request
401ErrorBodyUnauthorized

#GET /api/v1/jobs/{id}

operationId getJob

Parameters

NameInTypeDescription
idrequiredpathstringJob id

Responses

StatusBodyMeaning
200JobJob
403ErrorBodyForbidden
404ErrorBodyNot found

#POST /api/v1/jobs/{id}/cancel

operationId cancelJob

Parameters

NameInTypeDescription
idrequiredpathstringJob id

Responses

StatusBodyMeaning
204emptyCancelled
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#GET /api/v1/jobs/{id}/events

operationId streamJobEvents

Stream a job's status transitions as Server-Sent Events until it reaches a terminal state. Lets clients await completion without polling the REST endpoint themselves.

Parameters

NameInTypeDescription
idrequiredpathstringJob id

Responses

StatusBodyMeaning
200string text/event-streamSSE stream; each status event carries the full job JSON. Closes after the job reaches a terminal state.
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#Workflows

Workflow orchestration (DAG of steps)

#GET /api/v1/workflows

operationId listWorkflows

Parameters

NameInTypeDescription
statusquerystringFilter by status (e.g. pending, completed).
queuequerystringFilter by queue name (jobs only).
limitqueryinteger (int64)Page size, 1..=100 (default 50).
offsetqueryinteger (int64)Number of records to skip (default 0).
order_byquerystringcreated_at ASC or created_at DESC (default DESC).
include_totalquerybooleanInclude the exact total count in the response (default false; the count is an extra full scan over the filtered set).
cursorquerystringOpaque keyset cursor from a previous page's next_cursor. When set, offset is ignored and listing continues where that page ended.
created_afterquerystring (date-time)Only rows created at or after this instant (RFC 3339, inclusive). With created_before this forms the half-open range [after, before) — the natural shape for walking history period by period.
created_beforequerystring (date-time)Only rows created strictly before this instant (RFC 3339, exclusive).

Responses

StatusBodyMeaning
200ListWorkflowsResponsePage of workflows
401ErrorBodyUnauthorized

#POST /api/v1/workflows

operationId createWorkflow

Request body application/json

CreateWorkflowRequest Request body for creating a workflow. Shared by the builder DSL and the API so callers and SDKs use the same contract.

FieldTypeDescription
namerequiredstring
stepsrequiredarray<WorkflowStep>
contextobject
metadataobject

Responses

StatusBodyMeaning
201CreateWorkflowResponseWorkflow created
400ErrorBodyInvalid workflow (e.g. dependency cycle)
401ErrorBodyUnauthorized

#GET /api/v1/workflows/{id}

operationId getWorkflow

Parameters

NameInTypeDescription
idrequiredpathstringWorkflow id

Responses

StatusBodyMeaning
200WorkflowWorkflow
403ErrorBodyForbidden
404ErrorBodyNot found

#POST /api/v1/workflows/{id}/cancel

operationId cancelWorkflow

Parameters

NameInTypeDescription
idrequiredpathstringWorkflow id

Responses

StatusBodyMeaning
204emptyCancelled
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#GET /api/v1/workflows/{id}/diagram

operationId getWorkflowDiagram

Parameters

NameInTypeDescription
idrequiredpathstringWorkflow id

Responses

StatusBodyMeaning
200WorkflowDiagramResponseMermaid diagram of the workflow DAG
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#GET /api/v1/workflows/{id}/steps

operationId getWorkflowStepStates

Parameters

NameInTypeDescription
idrequiredpathstringWorkflow id

Responses

StatusBodyMeaning
200WorkflowStepStatesResponseRuntime status of every step, in declaration order. The workflow record carries only step definitions; this is the live progress view.
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#Cron

Recurring enqueues on a cron schedule (UTC)

#GET /api/v1/cron

operationId listCrons

Parameters

NameInTypeDescription
statusquerystringFilter by status (e.g. pending, completed).
queuequerystringFilter by queue name (jobs only).
limitqueryinteger (int64)Page size, 1..=100 (default 50).
offsetqueryinteger (int64)Number of records to skip (default 0).
order_byquerystringcreated_at ASC or created_at DESC (default DESC).
include_totalquerybooleanInclude the exact total count in the response (default false; the count is an extra full scan over the filtered set).
cursorquerystringOpaque keyset cursor from a previous page's next_cursor. When set, offset is ignored and listing continues where that page ended.
created_afterquerystring (date-time)Only rows created at or after this instant (RFC 3339, inclusive). With created_before this forms the half-open range [after, before) — the natural shape for walking history period by period.
created_beforequerystring (date-time)Only rows created strictly before this instant (RFC 3339, exclusive).

Responses

StatusBodyMeaning
200ListCronsResponsePage of cron schedules (status/queue filters do not apply)
401ErrorBodyUnauthorized

#POST /api/v1/cron

operationId createCron

Request body application/json

CreateCronRequest Request body for creating a cron schedule.

FieldTypeDescription
cron_exprrequiredstring5-field crontab (UTC); 6/7 fields with leading seconds also accepted.
namerequiredstringUnique per tenant.
task_namerequiredstring
confignull | JobConfig
payloadobject
queuestring | null

Responses

StatusBodyMeaning
201CreateCronResponseSchedule created; first firing is the next occurrence (UTC)
400ErrorBodyInvalid request (e.g. a bad cron expression)
401ErrorBodyUnauthorized
409ErrorBodyA schedule with this name already exists

#GET /api/v1/cron/{id}

operationId getCron

Parameters

NameInTypeDescription
idrequiredpathstringCron schedule id

Responses

StatusBodyMeaning
200CronScheduleCron schedule
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#DELETE /api/v1/cron/{id}

operationId deleteCron

Parameters

NameInTypeDescription
idrequiredpathstringCron schedule id

Responses

StatusBodyMeaning
204emptyDeleted; already-enqueued jobs are unaffected
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#POST /api/v1/cron/{id}/pause

operationId pauseCron

Parameters

NameInTypeDescription
idrequiredpathstringCron schedule id

Responses

StatusBodyMeaning
204emptyPaused: no further firings until resumed
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#POST /api/v1/cron/{id}/resume

operationId resumeCron

Parameters

NameInTypeDescription
idrequiredpathstringCron schedule id

Responses

StatusBodyMeaning
204emptyResumed: fires at its next future occurrence (missed runs are not caught up)
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#Dlq

Dead-letter queue: inspect terminally-failed jobs and replay them as fresh jobs

#GET /api/v1/dlq

operationId listDeadLetters

Parameters

NameInTypeDescription
statusquerystringFilter by status (e.g. pending, completed).
queuequerystringFilter by queue name (jobs only).
limitqueryinteger (int64)Page size, 1..=100 (default 50).
offsetqueryinteger (int64)Number of records to skip (default 0).
order_byquerystringcreated_at ASC or created_at DESC (default DESC).
include_totalquerybooleanInclude the exact total count in the response (default false; the count is an extra full scan over the filtered set).
cursorquerystringOpaque keyset cursor from a previous page's next_cursor. When set, offset is ignored and listing continues where that page ended.
created_afterquerystring (date-time)Only rows created at or after this instant (RFC 3339, inclusive). With created_before this forms the half-open range [after, before) — the natural shape for walking history period by period.
created_beforequerystring (date-time)Only rows created strictly before this instant (RFC 3339, exclusive).

Responses

StatusBodyMeaning
200ListDeadLettersResponsePage of dead letters, newest first (the status filter does not apply)
401ErrorBodyUnauthorized

#GET /api/v1/dlq/{id}

operationId getDeadLetter

Parameters

NameInTypeDescription
idrequiredpathinteger (int64)Dead letter id

Responses

StatusBodyMeaning
200DeadLetterDead letter
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found

#POST /api/v1/dlq/{id}/replay

operationId replayDeadLetter

Parameters

NameInTypeDescription
idrequiredpathinteger (int64)Dead letter id

Responses

StatusBodyMeaning
201ReplayDeadLetterResponseA fresh job was created from the dead-lettered one (same task/payload/queue/config; workflow linkage is not resurrected)
401ErrorBodyUnauthorized
403ErrorBodyForbidden
404ErrorBodyNot found (the entry, or its original job after retention)
409ErrorBodyAlready replayed

#Worker

Remote worker protocol: lease jobs, heartbeat, report completion/failure. Lets handlers run in any language, outside the server binary.

#POST /api/v1/jobs/{id}/complete

operationId completeJob

Parameters

NameInTypeDescription
idrequiredpathstringJob id

Request body application/json

CompleteJobRequest Body for POST /api/v1/jobs/{id}/complete.

FieldTypeDescription
lease_tokenrequiredstringThe lease token returned by the lease call.
resultobjectHandler result, recorded on the job and merged into workflow context.

Responses

StatusBodyMeaning
204emptyCompleted (idempotent: replaying against an already-finished job also succeeds)
401ErrorBodyUnauthorized
403ErrorBodyAuthenticated, but not with the worker credential
404ErrorBodyNot found
409ErrorBodyLease no longer held (expired and reclaimed)

#POST /api/v1/jobs/{id}/fail

operationId failJob

Parameters

NameInTypeDescription
idrequiredpathstringJob id

Request body application/json

FailJobRequest Body for POST /api/v1/jobs/{id}/fail.

FieldTypeDescription
errorrequiredstringHuman-readable failure reason.
lease_tokenrequiredstringThe lease token returned by the lease call.
retryablebooleanWhether the engine may retry (subject to the job's max_retries). Defaults to true; send false for permanent failures (e.g. bad input).

Responses

StatusBodyMeaning
204emptyFailure recorded; the job is retried or dead-lettered per its config
401ErrorBodyUnauthorized
403ErrorBodyAuthenticated, but not with the worker credential
404ErrorBodyNot found
409ErrorBodyLease no longer held (expired and reclaimed)

#POST /api/v1/jobs/{id}/heartbeat

operationId heartbeatJob

Parameters

NameInTypeDescription
idrequiredpathstringJob id

Request body application/json

HeartbeatRequest Body for POST /api/v1/jobs/{id}/heartbeat.

FieldTypeDescription
extend_secsrequiredinteger (int32)New lease duration in seconds, measured from now (1..=3600). (min 0)
lease_tokenrequiredstringThe lease token returned by the lease call.

Responses

StatusBodyMeaning
200HeartbeatResponseCurrent job status. running = lease extended; anything else (e.g. cancelled) = not extended, stop working on the job.
401ErrorBodyUnauthorized
403ErrorBodyAuthenticated, but not with the worker credential
404ErrorBodyNot found
409ErrorBodyLease no longer held (expired and reclaimed)

#POST /api/v1/queues/{queue}/lease

operationId leaseJobs

Parameters

NameInTypeDescription
queuerequiredpathstringQueue to lease from

Request body application/json

LeaseJobsRequest Body for POST /api/v1/queues/{queue}/lease.

FieldTypeDescription
lease_secsinteger (int32) | nullLease duration in seconds (1..=3600, default 30). Heartbeat to extend. (min 0)
max_jobsinteger | nullMaximum jobs to lease in one call (1..=100, default 1). (min 0)
wait_secsinteger (int32) | nullLong-poll wait when the queue is empty, in seconds (0..=30, default 0). (min 0)

Responses

StatusBodyMeaning
200LeaseJobsResponseZero or more leased jobs (empty if none became available within wait_secs)
401ErrorBodyUnauthorized
403ErrorBodyAuthenticated, but not with the worker credential

#System

Introspection and metrics

#GET /api/v1/stats

operationId getStats

Responses

StatusBodyMeaning
200StatsSnapshotEngine counters. Process-local and reset on restart: in a split api/worker deployment this reflects only the process serving the request; query the database for fleet-wide history.

#GET /api/v1/tasks

operationId listTasks

Responses

StatusBodyMeaning
200TasksResponseRegistered task handlers

#Schemas

Every request and response body is one of these objects. Fields marked required are always present; other fields may be absent or null.

#BackoffStrategy

How retry delays grow between attempts.

One of "fixed", "linear", "exponential".

#CompleteJobRequest

Body for POST /api/v1/jobs/{id}/complete.

FieldTypeDescription
lease_tokenrequiredstringThe lease token returned by the lease call.
resultobjectHandler result, recorded on the job and merged into workflow context.

#CreateBatchJobsRequest

FieldTypeDescription
jobsrequiredarray<CreateJobRequest>

#CreateBatchJobsResponse

FieldTypeDescription
countrequiredinteger (min 0)
job_idsrequiredarray<string>

#CreateCronRequest

Request body for creating a cron schedule.

FieldTypeDescription
cron_exprrequiredstring5-field crontab (UTC); 6/7 fields with leading seconds also accepted.
namerequiredstringUnique per tenant.
task_namerequiredstring
confignull | JobConfig
payloadobject
queuestring | null

#CreateCronResponse

FieldTypeDescription
cron_idrequiredstring

#CreateJobRequest

FieldTypeDescription
task_namerequiredstringThe registered task handler to invoke.
confignull | JobConfigRequest
payloadobjectArbitrary JSON object passed to the handler.
run_atstring (date-time) | nullDon't run before this instant (RFC 3339). The job is created immediately but stays invisible to workers until then.

#CreateJobResponse

FieldTypeDescription
job_idrequiredstring

#CreateWorkflowRequest

Request body for creating a workflow. Shared by the builder DSL and the API so callers and SDKs use the same contract.

FieldTypeDescription
namerequiredstring
stepsrequiredarray<WorkflowStep>
contextobject
metadataobject

#CreateWorkflowResponse

FieldTypeDescription
workflow_idrequiredstring

#CronSchedule

A recurring enqueue schedule. Expressions are standard 5-field crontab (minute hour day-of-month month day-of-week), evaluated in UTC; a 6/7-field form with leading seconds is also accepted.

FieldTypeDescription
created_atrequiredstring (date-time)
cron_exprrequiredstring
enabledrequiredboolean
idrequiredstring
namerequiredstringUnique per tenant.
next_run_atrequiredstring (date-time)The next instant this schedule fires. Missed occurrences (server down) collapse into at most one catch-up firing.
task_namerequiredstring
confignull | JobConfig
last_enqueued_atstring (date-time) | null
payloadobject
queue_namestring | nullQueue for the enqueued jobs (the engine default when absent).
tenant_idstring | null

#DeadLetter

A dead-lettered job: a terminal failure recorded for inspection and replay. The original job row remains (subject to retention); this entry captures why it died and, once replayed, which fresh job took its place.

FieldTypeDescription
created_atrequiredstring (date-time)
idrequiredinteger (int64)
job_idrequiredstring
reasonrequiredstringWhy the job dead-lettered: max_attempts_exceeded, non_retryable, or handler_not_found.
error_messagestring | null
queue_namestring | null
replay_job_idstring | nullThe fresh job created by the replay.
replayed_atstring (date-time) | nullSet once this entry has been replayed; a dead letter replays at most once.
task_namestring | null
tenant_idstring | null

#ErrorBody

FieldTypeDescription
errorrequiredstring
timestamprequiredstring (date-time)

#FailJobRequest

Body for POST /api/v1/jobs/{id}/fail.

FieldTypeDescription
errorrequiredstringHuman-readable failure reason.
lease_tokenrequiredstringThe lease token returned by the lease call.
retryablebooleanWhether the engine may retry (subject to the job's max_retries). Defaults to true; send false for permanent failures (e.g. bad input).

#HealthStatus

FieldTypeDescription
statusrequiredstring
timestamprequiredstring (date-time)
versionrequiredstring

#HeartbeatRequest

Body for POST /api/v1/jobs/{id}/heartbeat.

FieldTypeDescription
extend_secsrequiredinteger (int32)New lease duration in seconds, measured from now (1..=3600). (min 0)
lease_tokenrequiredstringThe lease token returned by the lease call.

#HeartbeatResponse

Response for POST /api/v1/jobs/{id}/heartbeat.

FieldTypeDescription
statusrequiredJobStatusThe job's current status. running means the lease was extended; anything else (cancelled, completed, ...) means it was not, and the worker should stop working on the job.

#Job

A single unit of work.

FieldTypeDescription
configrequiredJobConfig
created_atrequiredstring (date-time)
idrequiredstring
queue_namerequiredstring
retry_countrequiredinteger (int32) (min 0)
scheduled_atrequiredstring (date-time)When the job becomes claimable. created_at for immediate jobs, the requested run_at for scheduled jobs, and the next backoff instant while retrying — the durable delay lives in the row itself.
statusrequiredJobStatus
task_namerequiredstring
completed_atstring (date-time) | null
delivery_countinteger (int32)How many times this job has been claimed (delivered to a worker). Greater than retry_count + 1 means a lease expired without a report — i.e. a worker crashed mid-run. (min 0)
error_messagestring | null
idempotency_keystring | nullClient-supplied key that makes job creation idempotent per tenant: re-submitting the same key returns the original job instead of creating a duplicate.
metadataobject
next_retry_atstring (date-time) | nullWhen this job's next retry becomes claimable (mirrors scheduled_at while the job is retrying; kept for audit/inspection).
payloadobject
resultobject | null
started_atstring (date-time) | null
tenant_idstring | null
workflow_idstring | null
workflow_step_idstring | nullThe owning workflow step's name (steps are addressed by name).

#JobConfig

Per-job execution configuration. All durations are in seconds. Deserialization is partial-friendly: any omitted field takes its [JobConfig::default] value (via per-field serde defaults), so workflow-step and cron config overrides can name just the fields they change, and out-of-band rows with sparse config JSONB still load. Per-field functions rather than a struct-level #[serde(default)]: the struct-level form makes utoipa attach a default beside the BackoffStrategy $ref, which forces a synthetic wrapper type into every generated SDK.

FieldTypeDescription
jitter_factornumber (double) | nullOptional jitter in 0.0..=1.0. 0.1 => +/-10% randomization of each retry delay, which spreads out thundering-herd retries.
max_retriesinteger (int32) (min 0)
priorityinteger (int32)Higher is claimed first within a queue; ties break on scheduled_at, then created_at.
retry_backoffBackoffStrategy
retry_delay_secsinteger (int64) (min 0)
retry_max_delay_secsinteger (int64) (min 0)
timeout_secsinteger (int64) (min 0)

#JobConfigRequest

Optional per-job configuration overrides.

FieldTypeDescription
jitter_factornumber (double) | nullRetry-delay jitter in 0.0..=1.0 (e.g. 0.1 = +/-10%).
max_retriesinteger (int32) | null (min 0)
priorityinteger (int32) | nullHigher is claimed first within a queue (ties: oldest first).
queuestring | nullOverride the destination queue.
retry_backoffnull | BackoffStrategyHow retry delays grow between attempts (default exponential).
retry_delay_secsinteger (int64) | nullBase retry delay, in seconds. (min 0)
retry_max_delay_secsinteger (int64) | nullUpper bound on any computed retry delay, in seconds. (min 0)
timeoutinteger (int64) | nullPer-attempt timeout, in seconds. (min 0)

#JobStatus

Lifecycle state of a single job.

One of "pending", "running", "completed", "failed", "retrying", "cancelled".

#LeaseJobsRequest

Body for POST /api/v1/queues/{queue}/lease.

FieldTypeDescription
lease_secsinteger (int32) | nullLease duration in seconds (1..=3600, default 30). Heartbeat to extend. (min 0)
max_jobsinteger | nullMaximum jobs to lease in one call (1..=100, default 1). (min 0)
wait_secsinteger (int32) | nullLong-poll wait when the queue is empty, in seconds (0..=30, default 0). (min 0)

#LeaseJobsResponse

FieldTypeDescription
jobsrequiredarray<LeasedJob>

#LeasedJob

A job leased to a (possibly remote) worker, together with the lease token needed to heartbeat, complete, or fail it.

FieldTypeDescription
jobrequiredJob
lease_tokenrequiredstringOpaque, unguessable proof of lease ownership, regenerated on every claim. Pass it back on heartbeat/complete/fail; a stale token (the lease expired and the job was reclaimed) is rejected.

#ListCronsResponse

FieldTypeDescription
cronsrequiredarray<CronSchedule>
has_morerequiredboolean
limitrequiredinteger (int64)
offsetrequiredinteger (int64)
next_cursorstring | nullOpaque keyset cursor for the next page (present when has_more). Pass it back as cursor to continue where this page ended; cheaper than deep OFFSET paging.
totalinteger (int64) | nullExact total match count; only present when include_total=true.

#ListDeadLettersResponse

FieldTypeDescription
dead_lettersrequiredarray<DeadLetter>
has_morerequiredboolean
limitrequiredinteger (int64)
offsetrequiredinteger (int64)
next_cursorstring | nullOpaque keyset cursor for the next page (present when has_more). Pass it back as cursor to continue where this page ended; cheaper than deep OFFSET paging.
totalinteger (int64) | nullExact total match count; only present when include_total=true.

#ListJobsResponse

FieldTypeDescription
has_morerequiredboolean
jobsrequiredarray<Job>
limitrequiredinteger (int64)
offsetrequiredinteger (int64)
next_cursorstring | nullOpaque keyset cursor for the next page (present when has_more). Pass it back as cursor to continue where this page ended; cheaper than deep OFFSET paging.
totalinteger (int64) | nullExact total match count. Only present when the request set include_total=true; computing it costs a full count over the filtered set, so it is opt-in.

#ListWorkflowsResponse

FieldTypeDescription
has_morerequiredboolean
limitrequiredinteger (int64)
offsetrequiredinteger (int64)
workflowsrequiredarray<Workflow>
next_cursorstring | nullOpaque keyset cursor for the next page (present when has_more). Pass it back as cursor to continue where this page ended; cheaper than deep OFFSET paging.
totalinteger (int64) | nullExact total match count; only present when include_total=true.

#OnFailure

What to do with downstream steps when a step fails.

One of "halt", "skip", "continue".

#OnSuccess

Reserved for future expansion; only Continue is meaningful today.

One of "continue".

#ReadyStatus

FieldTypeDescription
statusrequiredstring

#ReplayDeadLetterResponse

FieldTypeDescription
job_idrequiredstringThe fresh job created from the dead-lettered one.

#StatsSnapshot

Plain snapshot of [EngineStats].

FieldTypeDescription
jobs_completedrequiredinteger (int64) (min 0)
jobs_createdrequiredinteger (int64) (min 0)
jobs_dead_letteredrequiredinteger (int64) (min 0)
jobs_failedrequiredinteger (int64) (min 0)
jobs_retriedrequiredinteger (int64) (min 0)
workflows_completedrequiredinteger (int64) (min 0)
workflows_createdrequiredinteger (int64) (min 0)
workflows_failedrequiredinteger (int64) (min 0)

#StepStatus

Lifecycle state of a single workflow step.

One of "pending", "running", "completed", "failed", "cancelled", "skipped".

#TasksResponse

FieldTypeDescription
tasksrequiredarray<string>

#Workflow

A workflow instance and its steps.

FieldTypeDescription
created_atrequiredstring (date-time)
idrequiredstring
namerequiredstring
statusrequiredWorkflowStatus
stepsrequiredarray<WorkflowStep>
completed_atstring (date-time) | null
contextobjectAccumulated step results, keyed by step name. Passed to downstream steps under the _context payload key.
metadataobject
started_atstring (date-time) | null
tenant_idstring | null

#WorkflowDiagramResponse

FieldTypeDescription
diagramrequiredstringThe diagram document (Mermaid graph TD).
formatrequiredstringDiagram source format. Always mermaid today.

#WorkflowStatus

Lifecycle state of a workflow instance.

One of "created", "running", "completed", "failed", "partially_failed", "cancelled".

#WorkflowStep

A node in a workflow DAG. Steps are addressed by their unique name; depends_on lists the names of steps that must complete first.

FieldTypeDescription
namerequiredstring
task_namerequiredstring
confignull | JobConfig
depends_onarray<string>
metadataobject
on_failureOnFailure
on_successOnSuccess
payloadobject

#WorkflowStepState

Runtime status of one workflow step (the live progress view).

FieldTypeDescription
namerequiredstringThe step's name (its address within the workflow).
statusrequiredStepStatus
job_idstring | nullThe job executing this step, once one has been scheduled.

#WorkflowStepStatesResponse

FieldTypeDescription
stepsrequiredarray<WorkflowStepState>One entry per step, in declaration order.