---
title: "API schemas"
description: "Field-level request and response contracts for the external API."
category: "Reference"
---

These schemas accompany the [external API reference](/docs/api). Required fields, constraints, defaults, and enum values are included below. Runtime limitations described in the guides still apply to fields accepted for compatibility.

## PipelineDefinition



Related schemas: [StageCreate](/docs/api/schemas#stagecreate), [PipelineKeyword](/docs/api/schemas#pipelinekeyword), [ContextItem](/docs/api/schemas#contextitem).

```yaml
type: object
required:
  - name
  - stages
properties:
  apiKey:
    type: string
    writeOnly: true
    deprecated: true
    description: Required only by the legacy `/pipelines` endpoint; ignored by the
      idempotent endpoint.
  name:
    type: string
    minLength: 1
    maxLength: 255
  traceId:
    type: string
    maxLength: 36
    description: Optional tracing identifier; not part of idempotency intent comparison.
  policies:
    type: array
    items:
      type: object
      additionalProperties: true
  stages:
    type: array
    minItems: 1
    maxItems: 100
    items:
      $ref: "#/components/schemas/StageCreate"
  pipelineKeywords:
    type: array
    maxItems: 64
    items:
      $ref: "#/components/schemas/PipelineKeyword"
  pipelineContextItems:
    type: array
    maxItems: 64
    description: Do not use pipeline context as the consumer's sole business system
      of record.
    items:
      $ref: "#/components/schemas/ContextItem"
```

## LegacyPipelineCreateRequest



Related schemas: [PipelineDefinition](/docs/api/schemas#pipelinedefinition).

```yaml
allOf:
  - $ref: "#/components/schemas/PipelineDefinition"
  - type: object
    required:
      - apiKey
```

## IdempotentPipelineCreateRequest



Related schemas: [PipelineDefinition](/docs/api/schemas#pipelinedefinition).

```yaml
allOf:
  - $ref: "#/components/schemas/PipelineDefinition"
  - type: object
    required:
      - idempotencyKey
    properties:
      idempotencyKey:
        type: string
        minLength: 1
        maxLength: 200
        description: Application-scoped key retained for the lifetime of the pipeline.
```

## IdempotentPipelineCreateResponse



Related schemas: [PipelineResponse](/docs/api/schemas#pipelineresponse).

```yaml
type: object
required:
  - pipeline
  - created
  - wasExisting
properties:
  pipeline:
    $ref: "#/components/schemas/PipelineResponse"
  created:
    type: boolean
    description: True only when this request inserted the pipeline.
  wasExisting:
    type: boolean
    description: True when an existing pipeline for the key was returned.
```

## PipelineIdempotencyLookupRequest



```yaml
type: object
required:
  - idempotencyKey
properties:
  idempotencyKey:
    type: string
    minLength: 1
    maxLength: 200
```

## PipelineResponse



Related schemas: [StageResponse](/docs/api/schemas#stageresponse), [ContextItem](/docs/api/schemas#contextitem), [PipelineKeyword](/docs/api/schemas#pipelinekeyword).

```yaml
type: object
required:
  - id
  - name
  - status
  - createdAt
  - isTerminal
properties:
  id:
    type: integer
  name:
    type: string
  traceId:
    type: string
  status:
    type: string
    enum:
      - NotStarted
      - Pending
      - Running
      - Paused
      - Completed
      - Failed
      - Cancelled
  createdAt:
    type: string
    format: date-time
  finishedAt:
    type: string
    format: date-time
    nullable: true
  applicationId:
    type: integer
  stageStatuses:
    type: array
    items:
      type: string
  stages:
    type: array
    items:
      $ref: "#/components/schemas/StageResponse"
  pipelineContextItems:
    type: array
    description: Sensitive values are returned as `[REDACTED]` while preserving
      `isSensitive=true`.
    items:
      $ref: "#/components/schemas/ContextItem"
  pipelineKeywords:
    type: array
    items:
      $ref: "#/components/schemas/PipelineKeyword"
  isEvent:
    type: boolean
  idempotencyKey:
    type: string
    description: Present for pipelines created through the idempotent contract.
  isTerminal:
    type: boolean
    description: True for Completed, Failed, or Cancelled pipeline status.
  wasExisting:
    type: boolean
    description: Compatibility field; creation outcome is authoritative in the
      idempotent response wrapper.
```

## StageCreate



Related schemas: [StageOptions](/docs/api/schemas#stageoptions).

```yaml
type: object
required:
  - stageName
  - stageHandlerName
properties:
  stageName:
    type: string
    minLength: 1
    maxLength: 255
  stageHandlerName:
    type: string
    minLength: 1
    maxLength: 300
  description:
    type: string
    maxLength: 255
  input:
    type: string
    description: JSON-serialized input payload, at most 262144 bytes.
  policies:
    type: array
    items:
      type: object
      additionalProperties: true
  options:
    $ref: "#/components/schemas/StageOptions"
  isEvent:
    type: boolean
  runNextIfFailed:
    type: boolean
    description: Compatibility field. Standard pipeline creation uses
      options.runNextIfFailed; set the option to configure continuation after a
      failed dependency.
```

## StageInfo

Stage appended by the external append API. stageId and pipelineId are ignored; the URL chooses the pipeline.

Related schemas: [StageOptions](/docs/api/schemas#stageoptions).

```yaml
type: object
required:
  - stageName
  - stageHandlerName
properties:
  stageName:
    type: string
    minLength: 1
    maxLength: 255
  stageHandlerName:
    type: string
    minLength: 1
    maxLength: 300
  description:
    type: string
    maxLength: 255
  input:
    description: Any JSON value is accepted. Strings are unwrapped; other non-null
      JSON values are serialized as the stage input string. Omitted or null
      input becomes empty.
  policies:
    type: array
    items:
      type: object
      additionalProperties: true
  options:
    $ref: "#/components/schemas/StageOptions"
  isEvent:
    type: boolean
  runNextIfFailed:
    type: boolean
    description: Continuation setting for this appended stage;
      options.runNextIfFailed takes precedence.
  stageId:
    type: integer
    nullable: true
    description: Compatibility field; ignored.
  pipelineId:
    type: integer
    nullable: true
    description: Compatibility field; ignored.
  runNextIfCurrentFailed:
    type: boolean
    description: Compatibility alias; when present, overrides top-level
      runNextIfFailed. options.runNextIfFailed takes precedence over both
      aliases.
description: Stage appended by the external append API. stageId and pipelineId
  are ignored; the URL chooses the pipeline.
```

## StageOptions



```yaml
type: object
properties:
  runNextIfFailed:
    type: boolean
    description: Allows this stage to proceed when a required earlier stage failed.
      Set this on the dependent stage.
  retryInterval:
    type: integer
    minimum: 0
    description: Base retry delay in seconds. StageOptions automatic retry requires
      both retryInterval > 0 and maxRetries > 0.
  maxRetries:
    type: integer
    minimum: 0
    description: Maximum number of automatic retries after the first execution.
  timeOut:
    type: integer
    minimum: 1
    description: Handler timeout in seconds.
  retryOnErrorCodes:
    type: array
    description: |
      When non-empty, StageOptions retries only matching error codes.
      Terminal codes such as BUSINESS_REJECTED, VALIDATION_ERROR,
      INVALID_STATE, and MISSING_REQUIRED_DATA are never retried
      automatically.
    items:
      type: string
      minLength: 1
  backoff:
    type: string
    enum:
      - fixed
      - linear
      - exponential
    default: fixed
  maxRetryInterval:
    type: integer
    minimum: 1
    description: Maximum retry delay in seconds.
  jitter:
    type: boolean
    default: false
  dependsOn:
    type: array
    items:
      type: string
    description: Names of stages in this pipeline. When omitted or empty, the
      dispatcher waits for all earlier stages. Use exact stage names, not stage
      IDs or cross-pipeline references.
  runInParallelWith:
    type: array
    items:
      type: string
    description: Stored compatibility metadata; the current server dispatcher does
      not use this field to enable parallel execution. Use supported dependency
      behavior.
  failIfOutputEmpty:
    type: boolean
    description: Stored compatibility metadata; the current server result consumer
      does not enforce empty-output failure.
  notifyOnFailure:
    type: boolean
    description: Stored compatibility metadata; this field does not enable the
      current server alerting configuration.
  runAsUser:
    type: string
    description: Stored compatibility metadata; the current server does not
      impersonate this user when executing a handler.
```

## StageResponse



Related schemas: [StageLog](/docs/api/schemas#stagelog), [StageOptions](/docs/api/schemas#stageoptions).

```yaml
type: object
required:
  - id
  - pipelineId
  - name
  - createdAt
  - isTerminal
properties:
  id:
    type: integer
  pipelineId:
    type: integer
  spanId:
    type: string
  name:
    type: string
  stageHandlerName:
    type: string
  description:
    type: string
  status:
    type: string
    enum:
      - NotStarted
      - Running
      - Pending
      - RetryScheduled
      - Throttled
      - WaitingForApproval
      - Completed
      - Failed
      - Skipped
      - Cancelled
  createdAt:
    type: string
    format: date-time
  finishedAt:
    type: string
    format: date-time
    nullable: true
  startedAt:
    type: string
    format: date-time
    nullable: true
  nextRetryAt:
    type: string
    format: date-time
    nullable: true
  output:
    type: string
    nullable: true
  input:
    type: string
    nullable: true
  isSkipped:
    type: boolean
  isEvent:
    type: boolean
  nextStageId:
    type: integer
    nullable: true
  logs:
    type: array
    items:
      $ref: "#/components/schemas/StageLog"
  options:
    $ref: "#/components/schemas/StageOptions"
  failureCount:
    type: integer
    minimum: 0
  lastFailedAt:
    type: string
    format: date-time
    nullable: true
  hasFailureHistory:
    type: boolean
  attempt:
    type: integer
    minimum: 0
    description: Stable 1-based execution attempt for the current dispatched
      execution; zero before first dispatch.
  retryAttempt:
    type: integer
    minimum: 0
    description: Number of retries scheduled so far.
  lastErrorCode:
    type: string
    description: Last handler or timeout error code.
  failureDisposition:
    type: string
    enum:
      - retryable
      - terminal
  isTerminal:
    type: boolean
    description: True for Completed, Failed, Skipped, or Cancelled stage status.
```

## ContextItem



```yaml
type: object
required:
  - key
properties:
  key:
    type: string
    minLength: 1
    maxLength: 300
  value:
    type: string
    description: String value, defaulting to empty when omitted. Idempotent pipeline
      creation limits it to 65536 bytes. Status reads redact sensitive values.
      Ignored for a worker-result tombstone.
  valueType:
    type: string
  isSensitive:
    type: boolean
    default: false
    description: Marks the value for redaction from status responses and persisted logs.
  isDeleted:
    type: boolean
    default: false
    description: In worker-result context updates, removes this key; value is
      ignored. Intended for updates, not initial pipeline context.
```

## PipelineKeyword



```yaml
type: object
required:
  - key
  - value
properties:
  key:
    type: string
    minLength: 1
    maxLength: 300
  value:
    type: string
    minLength: 1
    maxLength: 300
```

## StageLog



```yaml
type: object
required:
  - message
  - created
properties:
  id:
    type: integer
  stageId:
    type: integer
  message:
    type: string
  logLevel:
    type: string
  created:
    type: string
    format: date-time
```

## AppendStagesRequest



Related schemas: [StageInfo](/docs/api/schemas#stageinfo).

```yaml
type: object
required:
  - stages
properties:
  stages:
    type: array
    minItems: 1
    items:
      $ref: "#/components/schemas/StageInfo"
```

## AppendStagesResponse



Related schemas: [StageDto](/docs/api/schemas#stagedto).

```yaml
type: object
required:
  - stages
properties:
  stages:
    type: array
    items:
      $ref: "#/components/schemas/StageDto"
```

## StageDto



```yaml
type: object
required:
  - id
  - pipelineId
  - name
  - stageHandlerName
  - status
  - createdAt
  - isSkipped
  - isEvent
  - runNextIfCurrentFailed
properties:
  id:
    type: integer
  pipelineId:
    type: integer
  name:
    type: string
  stageHandlerName:
    type: string
  status:
    type: string
  createdAt:
    type: string
    format: date-time
  input:
    type: string
  nextStageId:
    type: integer
    nullable: true
  isSkipped:
    type: boolean
  isEvent:
    type: boolean
  runNextIfCurrentFailed:
    type: boolean
  finishedAt:
    type: string
    format: date-time
    nullable: true
  startedAt:
    type: string
    format: date-time
    nullable: true
```

## ResumeStageRequest



```yaml
type: object
required:
  - approved
properties:
  approved:
    type: boolean
  rejectionReason:
    type: string
    nullable: true
```

## StageLeaseRequest



```yaml
type: object
required:
  - executionId
  - workerId
properties:
  executionId:
    type: string
    minLength: 1
    description: Opaque execution token received in the stage delivery.
  workerId:
    type: string
    minLength: 1
    description: Worker ID associated with the authenticated worker session.
```

## StageLeaseResponse



```yaml
type: object
required:
  - acquired
properties:
  acquired:
    type: boolean
  attempt:
    type: integer
    minimum: 1
    description: Execution attempt accepted by the server.
  leaseExpiresAt:
    type: string
    format: date-time
    nullable: true
  reason:
    type: string
    description: Machine-readable explanation when acquired is false.
```

## PullJobRequest



```yaml
type: object
required:
  - queue
properties:
  queue:
    type: string
    description: "StageNext queue of this application:
      app_{applicationId}_{handler}_StageNext."
  waitSeconds:
    type: integer
    minimum: 0
    maximum: 20
    default: 0
    description: Seconds to wait for a message before answering 204.
```

## PullJobResponse



Related schemas: [StageNextMessage](/docs/api/schemas#stagenextmessage).

```yaml
type: object
required:
  - token
  - queue
  - payload
properties:
  token:
    type: string
    description: Opaque credential for jobs/ack, held in the API process that
      performed this pull. Separate from the execution lease.
  queue:
    type: string
  messageId:
    type: string
  payload:
    $ref: "#/components/schemas/StageNextMessage"
  headers:
    type: object
    additionalProperties: true
```

## AckJobRequest



```yaml
type: object
required:
  - token
properties:
  token:
    type: string
    minLength: 1
  requeue:
    type: boolean
    default: false
    description: True returns the message to the queue instead of acknowledging it.
```

## StageResultSubmit



Related schemas: [StageResultLog](/docs/api/schemas#stageresultlog), [ContextItem](/docs/api/schemas#contextitem), [WorkerAppendedStage](/docs/api/schemas#workerappendedstage).

```yaml
type: object
required:
  - stageId
  - executionId
  - attempt
properties:
  pipelineId:
    type: integer
    nullable: true
    description: Pipeline the stage belongs to, as delivered in the stage job.
  stageId:
    type: integer
    minimum: 1
    description: Must equal the stageId in the route.
  executionId:
    type: string
    minLength: 1
    description: Execution token from the stage delivery; the consumer fences on it.
  attempt:
    type: integer
    minimum: 1
    description: Execution attempt accepted by the lease.
  isSuccess:
    type: boolean
    default: false
    description: Always send explicitly. Omission decodes as false.
  result:
    type: string
    description: Handler output, at most 262144 bytes.
  isWaitingForApproval:
    type: boolean
    description: Parks the stage in WaitingForApproval instead of completing it.
  errorCode:
    type: string
    description: Failure classification; must not contain control characters.
  retryable:
    type: boolean
    nullable: true
    description: False disables automatic retries. True does not override terminal
      error codes or create retry configuration; an applicable policy or
      StageOptions retry configuration is still required.
  nextStageId:
    type: integer
    nullable: true
    description: Accepted compatibility field; the current result consumer does not
      use it to route execution.
  runNextIfCurrentFailed:
    type: boolean
    description: Accepted compatibility field; the current result consumer does not
      use it. Configure continuation on the dependent stage with
      options.runNextIfFailed.
  logs:
    type: array
    items:
      $ref: "#/components/schemas/StageResultLog"
  contextItems:
    type: array
    items:
      $ref: "#/components/schemas/ContextItem"
  appendedStages:
    type: array
    items:
      $ref: "#/components/schemas/WorkerAppendedStage"
```

## StageResultLog



```yaml
type: object
required:
  - message
properties:
  message:
    type: string
  logLevel:
    type: string
  created:
    type: string
    format: date-time
```

## StageResultAccepted



```yaml
type: object
required:
  - accepted
  - stageId
properties:
  accepted:
    type: boolean
  stageId:
    type: integer
  executionId:
    type: string
```

## ScheduleUpsertRequest



Related schemas: [PipelineDefinition](/docs/api/schemas#pipelinedefinition).

```yaml
type: object
required:
  - kind
  - definition
properties:
  kind:
    type: string
    enum:
      - Cron
      - Interval
      - Once
  cronExpression:
    type: string
    description: |
      Standard 5-field cron, or @every <duration>, @hourly, @daily,
      @midnight. Six-field (seconds) expressions are not accepted.
  timeZone:
    type: string
    default: UTC
    description: IANA zone. Ticks are computed here and stored in UTC.
  intervalSeconds:
    type: integer
    minimum: 10
    nullable: true
  runAt:
    type: string
    format: date-time
    nullable: true
    description: Required for Once, and must be in the future.
  overlapPolicy:
    type: string
    enum:
      - Skip
      - Queue
      - Replace
      - Allow
    description: New schedules default to Skip. On an existing schedule, omission
      preserves the stored policy. Allow permits concurrent runs. This reference
      does not promise strict cross-pipeline serialization for Queue.
  catchupPolicy:
    type: string
    enum:
      - None
      - One
      - All
    description: New schedules default to None. On an existing schedule, omission
      preserves the stored policy.
  catchupMax:
    type: integer
    minimum: 1
    maximum: 1000
    default: 10
  jitterSeconds:
    type: integer
    minimum: 0
    maximum: 3600
    default: 0
  definition:
    $ref: "#/components/schemas/PipelineDefinition"
```

## Schedule



Related schemas: [PipelineDefinition](/docs/api/schemas#pipelinedefinition), [ScheduleHealth](/docs/api/schemas#schedulehealth).

```yaml
type: object
required:
  - id
  - applicationId
  - name
  - status
  - kind
  - timeZone
  - definition
  - definitionVersion
  - overlapPolicy
  - catchupPolicy
  - catchupMax
  - jitterSeconds
  - createdAt
  - updatedAt
properties:
  id:
    type: integer
    format: int64
  applicationId:
    type: integer
  name:
    type: string
  status:
    type: string
    enum:
      - Active
      - Paused
      - Archived
  kind:
    type: string
    enum:
      - Cron
      - Interval
      - Once
  cronExpression:
    type: string
  timeZone:
    type: string
  intervalSeconds:
    type: integer
    nullable: true
  runAt:
    type: string
    format: date-time
    nullable: true
  definition:
    $ref: "#/components/schemas/PipelineDefinition"
  definitionVersion:
    type: integer
    description: Incremented only when something that changes behaviour changed.
  overlapPolicy:
    type: string
    enum:
      - Skip
      - Queue
      - Replace
      - Allow
  catchupPolicy:
    type: string
    enum:
      - None
      - One
      - All
  catchupMax:
    type: integer
  jitterSeconds:
    type: integer
  nextRunAt:
    type: string
    format: date-time
    nullable: true
  lastRunAt:
    type: string
    format: date-time
    nullable: true
  lastRunStatus:
    type: string
    enum:
      - Created
      - Skipped
      - Failed
  createdBy:
    type: string
  createdAt:
    type: string
    format: date-time
  updatedAt:
    type: string
    format: date-time
  health:
    $ref: "#/components/schemas/ScheduleHealth"
```

## ScheduleHealth

Summary of the last 20 runs, for the dashboard list.

```yaml
type: object
description: Summary of the last 20 runs, for the dashboard list.
properties:
  recentRuns:
    type: integer
  recentFailed:
    type: integer
  recentSkipped:
    type: integer
  outcomes:
    type: array
    maxItems: 20
    description: Newest first.
    items:
      type: string
      enum:
        - Created
        - Skipped
        - Failed
  lagSeconds:
    type: number
    nullable: true
```

## ScheduleRun



```yaml
type: object
required:
  - id
  - scheduleId
  - scheduledFor
  - firedAt
  - trigger
  - outcome
  - definitionVersion
  - lagSeconds
properties:
  id:
    type: integer
    format: int64
  scheduleId:
    type: integer
    format: int64
  scheduledFor:
    type: string
    format: date-time
    description: The planned tick.
  firedAt:
    type: string
    format: date-time
  trigger:
    type: string
    enum:
      - Cron
      - Interval
      - Once
      - Manual
      - Catchup
  outcome:
    type: string
    enum:
      - Created
      - Skipped
      - Failed
  skipReason:
    type: string
    enum:
      - Overlap
      - Paused
      - Catchup
      - NoWorker
    description: NoWorker means an automatic tick was skipped because the
      application had no live registered worker. Manual triggers bypass this
      automatic liveness gate.
  pipelineId:
    type: integer
    nullable: true
  definitionVersion:
    type: integer
  error:
    type: string
    description: Present when outcome is Failed. The schedule keeps ticking.
  lagSeconds:
    type: number
    description: firedAt minus scheduledFor.
  pipelineStatus:
    type: string
  pipelineFinishedAt:
    type: string
    format: date-time
    nullable: true
```

## ScheduleListResponse



Related schemas: [Schedule](/docs/api/schemas#schedule).

```yaml
type: object
required:
  - schedules
properties:
  schedules:
    type: array
    items:
      $ref: "#/components/schemas/Schedule"
  nextCursor:
    type: string
```

## ScheduleRunListResponse



Related schemas: [ScheduleRun](/docs/api/schemas#schedulerun).

```yaml
type: object
required:
  - runs
properties:
  runs:
    type: array
    items:
      $ref: "#/components/schemas/ScheduleRun"
  nextCursor:
    type: string
```

## ScheduleTriggerRequest



```yaml
type: object
properties:
  input:
    description: Optional non-null JSON value replacing the first stage input. The
      raw JSON representation is stored, including JSON string quotation marks.
      Omitted or null input leaves the definition input unchanged.
```

## ScheduleTriggerResponse



```yaml
type: object
required:
  - runId
  - pipelineId
  - trigger
properties:
  runId:
    type: integer
    format: int64
  pipelineId:
    type: integer
  trigger:
    type: string
    enum:
      - Manual
```

## ProblemDetails



```yaml
type: object
required:
  - title
  - status
properties:
  type:
    type: string
  title:
    type: string
  status:
    type: integer
  detail:
    type: string
  traceId:
    type: string
  errors:
    type: object
    additionalProperties:
      type: array
      items:
        type: string
```

## VersionInfo



```yaml
type: object
properties:
  version:
    type: string
    example: v0.5.0
  commit:
    type: string
  buildDate:
    type: string
  goVersion:
    type: string
  tier:
    type: string
    enum:
      - community
      - pro
      - enterprise
```

## LogRequest



Related schemas: [PipelineKeyword](/docs/api/schemas#pipelinekeyword).

```yaml
type: object
properties:
  message:
    type: string
    nullable: true
  logLevel:
    type: string
    example: INFO
    nullable: true
  created:
    type: string
    format: date-time
    nullable: true
  keywords:
    type: array
    items:
      $ref: "#/components/schemas/PipelineKeyword"
  apiKey:
    type: string
    nullable: true
    writeOnly: true
    description: Optional legacy application attribution key in the body; see the
      operation description. It is not a header-auth requirement.
  id:
    type: integer
    nullable: true
    description: Compatibility field; ignored when storing a new log.
```

## LogResponse



Related schemas: [PipelineKeyword](/docs/api/schemas#pipelinekeyword).

```yaml
type: object
properties:
  id:
    type: integer
  applicationId:
    type: integer
  message:
    type: string
  logLevel:
    type: string
  created:
    type: string
    format: date-time
  keywords:
    type: array
    items:
      $ref: "#/components/schemas/PipelineKeyword"
```

## WorkerBootstrapRequest



```yaml
type: object
required:
  - workerName
properties:
  workerName:
    type: string
  instanceId:
    type: string
    description: Identity within the application. Rebootstrap reuses the worker
      record and replaces its token. Concurrent processes must not share an
      instanceId.
  workerVersion:
    type: string
  sdkVersion:
    type: string
  environment:
    type: string
  hostName:
    type: string
  pid:
    type: integer
  supportedHandlers:
    type: array
    items:
      type: string
  capabilities:
    type: object
    additionalProperties: true
  metadata:
    type: object
    additionalProperties: true
```

## WorkerBootstrapResponse



```yaml
type: object
properties:
  workerId:
    type: string
  workerSessionToken:
    type: string
    description: Session credential for lease, result, heartbeat, events, and
      shutdown. Result submission also requires the application API key. Default
      session TTL is 24 hours; heartbeat does not renew it.
  configVersion:
    type: string
  application:
    type: object
    properties:
      applicationId:
        type: integer
      applicationName:
        type: string
      appId:
        type: string
        description: Queue prefix for this application
        example: app_12
  messageBroker:
    type: object
    description: Included in bootstrap for all worker transports. HTTP workers
      ignore this object. connectionString is empty when
      WORKER_BROKER_HANDOUT=false.
    properties:
      type:
        type: string
        example: rabbitmq
      connectionString:
        type: string
      prefetch:
        type: integer
      topologyOwnership:
        type: string
        enum:
          - server-owned
          - client-owned
      dlqEnabled:
        type: boolean
      dlqTtlSec:
        type: integer
  queues:
    type: object
    properties:
      stageResult:
        type: string
      stageSetStatus:
        type: string
      stageUpdatedFanout:
        type: string
      stageNextPattern:
        type: string
        example: "{appId}_{handler}_StageNext"
        description: Substitute application.appId (for example app_12) and the stage
          handler name. This field is a literal pattern.
  heartbeat:
    type: object
    properties:
      intervalSec:
        type: integer
      offlineAfterSec:
        type: integer
  observability:
    type: object
    properties:
      traceLinkTemplate:
        type: string
      logsLinkTemplate:
        type: string
required:
  - workerId
  - workerSessionToken
  - configVersion
  - application
  - messageBroker
  - queues
  - heartbeat
  - observability
```

## WorkerHeartbeatRequest



```yaml
type: object
required:
  - workerId
properties:
  workerId:
    type: string
  state:
    type: string
    enum:
      - starting
      - ready
      - degraded
      - draining
      - stopped
      - error
      - offline
    description: Recognized states, normalized case-insensitively. Omitted or
      unrecognized values keep the previous state.
  uptimeSec:
    type: integer
  brokerConnected:
    type: boolean
  inFlightJobs:
    type: integer
  jobsProcessed:
    type: integer
  jobsFailed:
    type: integer
  queueLag:
    type: integer
  cpuPercent:
    type: number
  memoryMb:
    type: number
  lastError:
    type: string
  message:
    type: string
  metadata:
    type: object
    additionalProperties: true
```

## WorkerEventsRequest



```yaml
type: object
required:
  - workerId
  - events
properties:
  workerId:
    type: string
  events:
    type: array
    items:
      type: object
      properties:
        ts:
          type: string
          format: date-time
          description: Defaults to server receive time when omitted.
        level:
          type: string
          enum:
            - TRACE
            - DEBUG
            - INFO
            - WARN
            - WARNING
            - ERROR
          default: INFO
          description: Case-insensitive. WARNING normalizes to WARN; omitted or
            unrecognized levels normalize to INFO.
        eventType:
          type: string
          example: worker.state_changed
          default: worker.event
        message:
          type: string
          default: worker event
        details:
          type: object
          additionalProperties: true
    minItems: 1
    description: Nonempty batch; the configurable WORKER_EVENTS_MAX_BATCH limit
      defaults to 200.
```

## WorkerShutdownRequest



```yaml
type: object
required:
  - workerId
properties:
  workerId:
    type: string
  reason:
    type: string
```

## WorkerAppendedStage

Stage dynamically appended by a worker result. The current consumer inserts new stages and ignores supplied stageId/pipelineId. Input must be a string; inline policies and top-level continuation aliases are not consumed here.

Related schemas: [StageOptions](/docs/api/schemas#stageoptions).

```yaml
type: object
required:
  - stageName
  - stageHandlerName
properties:
  stageName:
    type: string
    minLength: 1
    maxLength: 255
  stageHandlerName:
    type: string
    minLength: 1
    maxLength: 300
  description:
    type: string
    maxLength: 255
  input:
    type: string
    description: String stage input. This worker-result path is subject to the
      complete result-request body cap; it does not perform the
      idempotent-create per-stage input check.
  options:
    $ref: "#/components/schemas/StageOptions"
  isEvent:
    type: boolean
  stageId:
    type: integer
    nullable: true
    description: Compatibility field; ignored.
  pipelineId:
    type: integer
    nullable: true
    description: Compatibility field; ignored.
description: Stage dynamically appended by a worker result. The current consumer
  inserts new stages and ignores supplied stageId/pipelineId. Input must be a
  string; inline policies and top-level continuation aliases are not consumed
  here.
```

## StageNextMessage



Related schemas: [ContextItem](/docs/api/schemas#contextitem).

```yaml
type: object
required:
  - appId
  - stageId
properties:
  appId:
    type: integer
    description: Numeric application ID; distinct from the bootstrap queue-prefix
      string application.appId.
  stageId:
    type: integer
  pipelineId:
    type: integer
  executionId:
    type: string
    description: Opaque current execution identity; preserve for lease and result
      operations.
  attempt:
    type: integer
    description: Current execution attempt; preserve in results.
  idempotencyKey:
    type: string
  timeoutSeconds:
    type: integer
  traceId:
    type: string
  spanId:
    type: string
  traceparent:
    type: string
  tracestate:
    type: string
  stageHandlerName:
    type: string
  input:
    type: string
  prevStageOutput:
    type: string
  contextItems:
    type: array
    items:
      $ref: "#/components/schemas/ContextItem"
```
