> ## Documentation Index
> Fetch the complete documentation index at: https://docs.open.cx/llms.txt
> Use this file to discover all available pages before exploring further.

> Update, append or remove steps in one transactional batch, in any status. Use to change copy or delays on a live sequence without disturbing people mid-journey.

# Surgically edit steps — update content/delays, append, remove (any status)

A recorded per-contact skip pins its step position. Removing that step or an earlier step is refused because it would change which step the contact skipped. Content and delay edits, and appending steps, remain available.


## OpenAPI

````yaml patch /sequences/{sequenceId}/steps
openapi: 3.1.0
info:
  title: OpenCX API
  description: >

    OpenCX is an AI-powered, all-in-one platform for customer support and
    outbound communications.


    Use this API to manage your OpenCX organization's AI agents, actions,
    conversations, contacts, and more.


    To get started, generate a new API key from the dashboard.


    ## Authentication

    All API endpoints require authentication using a Bearer token. You can
    generate an API key from your OpenCX dashboard.


    ## Rate Limiting

    API requests are rate limited to ensure fair usage. The current limits are:

    - 100 requests per minute for standard endpoints

    - 1000 requests per minute for streaming endpoints


    ## Error Handling

    The API uses standard HTTP status codes and returns detailed error messages
    in the response body.
  version: 1.0-beta
  license:
    name: MIT
    url: https://opensource.org/licenses/MIT
servers:
  - url: http://localhost:8080
    description: Development
  - url: https://api.open.cx
    description: Production
security:
  - bearerAuth: []
paths:
  /sequences/{sequenceId}/steps:
    patch:
      summary: >-
        Surgically edit steps — update content/delays, append, remove (any
        status)
      description: >-
        One transactional batch of typed edits. Execution order is fixed:
        removes (highest index first), then appends, then updates — indices
        address the array AFTER earlier phases of the same batch. Content/delay
        updates are allowed on any step (people already past it keep what they
        received); append is always allowed (completed people do not revive);
        remove is refused for any step somebody already reached. Any illegal
        edit rejects the whole batch, named by its position. The response is the
        sequence plus variable_coverage for every source the resulting steps
        bind.
      operationId: editSequenceSteps
      parameters:
        - schema:
            type: string
            format: uuid
            pattern: >-
              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          in: path
          name: sequenceId
          required: true
          description: The unique identifier of the sequence
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/EditSequenceStepsDto'
      responses:
        '200':
          description: Default Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SequenceStepsWriteDto'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorDto'
components:
  schemas:
    EditSequenceStepsDto:
      $schema: https://json-schema.org/draft/2020-12/schema
      $id: '#/components/schemas/EditSequenceStepsDtoInput'
      type: object
      properties:
        edits:
          minItems: 1
          maxItems: 50
          type: array
          items:
            oneOf:
              - type: object
                properties:
                  op:
                    type: string
                    const: update
                  step_index:
                    type: integer
                    minimum: 0
                    maximum: 9007199254740991
                  content:
                    description: >-
                      New content for the step. Must keep the step on its
                      current channel.
                    anyOf:
                      - type: object
                        properties:
                          type:
                            type: string
                            const: whatsapp_template
                          template_name:
                            type: string
                            minLength: 1
                          template_language:
                            type: string
                            minLength: 1
                          variables:
                            type: object
                            propertyNames:
                              type: string
                            additionalProperties:
                              type: object
                              properties:
                                source:
                                  type: string
                                  minLength: 1
                                  maxLength: 200
                                  description: >-
                                    A recipient column ('display_name', 'phone',
                                    'email') or the exact name of a key in the
                                    person's attached data (extra_data). Those
                                    three names always read the column — a key
                                    spelled the same is unreachable; any other
                                    string reads the attached data, matched
                                    verbatim as a top-level key. A missing or
                                    empty value falls to `fallback`, and with no
                                    fallback the person parks (needs_data).
                                fallback:
                                  type: string
                                type:
                                  description: >-
                                    Optional. Applies to attached-data sources
                                    only — ignored on the three columns. How to
                                    read the value: string, number, boolean,
                                    date, string[] or number[] — the same
                                    vocabulary as People-table columns. Absent:
                                    text and numbers pass through, anything else
                                    counts as missing. Declared: text is parsed
                                    where it is unambiguous ("250" as a number
                                    or a string, "true" as a boolean, an
                                    ISO-shaped date such as "2026-03-12" — other
                                    date spellings and epoch numbers are
                                    missing), a date renders as a plain day in
                                    the person's timezone, a list needs an
                                    actual list in the data and joins with
                                    commas, dropping items it cannot read, and a
                                    value that cannot be read as the declared
                                    type counts as missing.
                                  type: string
                                  enum:
                                    - string
                                    - number
                                    - boolean
                                    - date
                                    - string[]
                                    - number[]
                              required:
                                - source
                            description: >-
                              Body bindings keyed by positional index ("1", "2")
                              or exact parameter name ("first_name").
                          buttons:
                            type: object
                            propertyNames:
                              type: string
                              pattern: ^[0-9]$
                            additionalProperties:
                              type: object
                              properties:
                                source:
                                  type: string
                                  minLength: 1
                                  maxLength: 200
                                  description: >-
                                    A recipient column ('display_name', 'phone',
                                    'email') or the exact name of a key in the
                                    person's attached data (extra_data). Those
                                    three names always read the column — a key
                                    spelled the same is unreachable; any other
                                    string reads the attached data, matched
                                    verbatim as a top-level key. A missing or
                                    empty value falls to `fallback`, and with no
                                    fallback the person parks (needs_data).
                                fallback:
                                  type: string
                                type:
                                  description: >-
                                    Optional. Applies to attached-data sources
                                    only — ignored on the three columns. How to
                                    read the value: string, number, boolean,
                                    date, string[] or number[] — the same
                                    vocabulary as People-table columns. Absent:
                                    text and numbers pass through, anything else
                                    counts as missing. Declared: text is parsed
                                    where it is unambiguous ("250" as a number
                                    or a string, "true" as a boolean, an
                                    ISO-shaped date such as "2026-03-12" — other
                                    date spellings and epoch numbers are
                                    missing), a date renders as a plain day in
                                    the person's timezone, a list needs an
                                    actual list in the data and joins with
                                    commas, dropping items it cannot read, and a
                                    value that cannot be read as the declared
                                    type counts as missing.
                                  type: string
                                  enum:
                                    - string
                                    - number
                                    - boolean
                                    - date
                                    - string[]
                                    - number[]
                              required:
                                - source
                        required:
                          - type
                          - template_name
                          - template_language
                          - variables
                      - type: object
                        properties:
                          type:
                            type: string
                            const: voice_call
                          extra_instructions:
                            type: string
                            minLength: 1
                            maxLength: 8000
                          variables:
                            type: object
                            propertyNames:
                              type: string
                              minLength: 1
                              maxLength: 64
                            additionalProperties:
                              type: object
                              properties:
                                source:
                                  type: string
                                  minLength: 1
                                  maxLength: 200
                                  description: >-
                                    A recipient column ('display_name', 'phone',
                                    'email') or the exact name of a key in the
                                    person's attached data (extra_data). Those
                                    three names always read the column — a key
                                    spelled the same is unreachable; any other
                                    string reads the attached data, matched
                                    verbatim as a top-level key. A missing or
                                    empty value falls to `fallback`, and with no
                                    fallback the person parks (needs_data).
                                fallback:
                                  type: string
                                type:
                                  description: >-
                                    Optional. Applies to attached-data sources
                                    only — ignored on the three columns. How to
                                    read the value: string, number, boolean,
                                    date, string[] or number[] — the same
                                    vocabulary as People-table columns. Absent:
                                    text and numbers pass through, anything else
                                    counts as missing. Declared: text is parsed
                                    where it is unambiguous ("250" as a number
                                    or a string, "true" as a boolean, an
                                    ISO-shaped date such as "2026-03-12" — other
                                    date spellings and epoch numbers are
                                    missing), a date renders as a plain day in
                                    the person's timezone, a list needs an
                                    actual list in the data and joins with
                                    commas, dropping items it cannot read, and a
                                    value that cannot be read as the declared
                                    type counts as missing.
                                  type: string
                                  enum:
                                    - string
                                    - number
                                    - boolean
                                    - date
                                    - string[]
                                    - number[]
                              required:
                                - source
                        required:
                          - type
                      - type: object
                        properties:
                          type:
                            type: string
                            const: email
                          subject:
                            type: string
                            minLength: 1
                          html:
                            type: string
                            minLength: 1
                          text:
                            type: string
                            minLength: 1
                          variables:
                            default: {}
                            type: object
                            propertyNames:
                              type: string
                            additionalProperties:
                              type: object
                              properties:
                                source:
                                  type: string
                                  minLength: 1
                                  maxLength: 200
                                  description: >-
                                    A recipient column ('display_name', 'phone',
                                    'email') or the exact name of a key in the
                                    person's attached data (extra_data). Those
                                    three names always read the column — a key
                                    spelled the same is unreachable; any other
                                    string reads the attached data, matched
                                    verbatim as a top-level key. A missing or
                                    empty value falls to `fallback`, and with no
                                    fallback the person parks (needs_data).
                                fallback:
                                  type: string
                                type:
                                  description: >-
                                    Optional. Applies to attached-data sources
                                    only — ignored on the three columns. How to
                                    read the value: string, number, boolean,
                                    date, string[] or number[] — the same
                                    vocabulary as People-table columns. Absent:
                                    text and numbers pass through, anything else
                                    counts as missing. Declared: text is parsed
                                    where it is unambiguous ("250" as a number
                                    or a string, "true" as a boolean, an
                                    ISO-shaped date such as "2026-03-12" — other
                                    date spellings and epoch numbers are
                                    missing), a date renders as a plain day in
                                    the person's timezone, a list needs an
                                    actual list in the data and joins with
                                    commas, dropping items it cannot read, and a
                                    value that cannot be read as the declared
                                    type counts as missing.
                                  type: string
                                  enum:
                                    - string
                                    - number
                                    - boolean
                                    - date
                                    - string[]
                                    - number[]
                              required:
                                - source
                        required:
                          - type
                          - subject
                          - html
                  delay_minutes:
                    description: New wait before this step, in minutes. Step 0 must stay 0.
                    type: integer
                    minimum: 0
                    maximum: 129600
                required:
                  - op
                  - step_index
              - type: object
                properties:
                  op:
                    type: string
                    const: append
                  steps:
                    minItems: 1
                    maxItems: 20
                    type: array
                    items:
                      oneOf:
                        - type: object
                          properties:
                            channel:
                              type: string
                              const: whatsapp
                            content:
                              type: object
                              properties:
                                type:
                                  type: string
                                  const: whatsapp_template
                                template_name:
                                  type: string
                                  minLength: 1
                                template_language:
                                  type: string
                                  minLength: 1
                                variables:
                                  type: object
                                  propertyNames:
                                    type: string
                                  additionalProperties:
                                    type: object
                                    properties:
                                      source:
                                        type: string
                                        minLength: 1
                                        maxLength: 200
                                        description: >-
                                          A recipient column ('display_name',
                                          'phone', 'email') or the exact name of a
                                          key in the person's attached data
                                          (extra_data). Those three names always
                                          read the column — a key spelled the same
                                          is unreachable; any other string reads
                                          the attached data, matched verbatim as a
                                          top-level key. A missing or empty value
                                          falls to `fallback`, and with no
                                          fallback the person parks (needs_data).
                                      fallback:
                                        type: string
                                      type:
                                        description: >-
                                          Optional. Applies to attached-data
                                          sources only — ignored on the three
                                          columns. How to read the value: string,
                                          number, boolean, date, string[] or
                                          number[] — the same vocabulary as
                                          People-table columns. Absent: text and
                                          numbers pass through, anything else
                                          counts as missing. Declared: text is
                                          parsed where it is unambiguous ("250" as
                                          a number or a string, "true" as a
                                          boolean, an ISO-shaped date such as
                                          "2026-03-12" — other date spellings and
                                          epoch numbers are missing), a date
                                          renders as a plain day in the person's
                                          timezone, a list needs an actual list in
                                          the data and joins with commas, dropping
                                          items it cannot read, and a value that
                                          cannot be read as the declared type
                                          counts as missing.
                                        type: string
                                        enum:
                                          - string
                                          - number
                                          - boolean
                                          - date
                                          - string[]
                                          - number[]
                                    required:
                                      - source
                                  description: >-
                                    Body bindings keyed by positional index
                                    ("1", "2") or exact parameter name
                                    ("first_name").
                                buttons:
                                  type: object
                                  propertyNames:
                                    type: string
                                    pattern: ^[0-9]$
                                  additionalProperties:
                                    type: object
                                    properties:
                                      source:
                                        type: string
                                        minLength: 1
                                        maxLength: 200
                                        description: >-
                                          A recipient column ('display_name',
                                          'phone', 'email') or the exact name of a
                                          key in the person's attached data
                                          (extra_data). Those three names always
                                          read the column — a key spelled the same
                                          is unreachable; any other string reads
                                          the attached data, matched verbatim as a
                                          top-level key. A missing or empty value
                                          falls to `fallback`, and with no
                                          fallback the person parks (needs_data).
                                      fallback:
                                        type: string
                                      type:
                                        description: >-
                                          Optional. Applies to attached-data
                                          sources only — ignored on the three
                                          columns. How to read the value: string,
                                          number, boolean, date, string[] or
                                          number[] — the same vocabulary as
                                          People-table columns. Absent: text and
                                          numbers pass through, anything else
                                          counts as missing. Declared: text is
                                          parsed where it is unambiguous ("250" as
                                          a number or a string, "true" as a
                                          boolean, an ISO-shaped date such as
                                          "2026-03-12" — other date spellings and
                                          epoch numbers are missing), a date
                                          renders as a plain day in the person's
                                          timezone, a list needs an actual list in
                                          the data and joins with commas, dropping
                                          items it cannot read, and a value that
                                          cannot be read as the declared type
                                          counts as missing.
                                        type: string
                                        enum:
                                          - string
                                          - number
                                          - boolean
                                          - date
                                          - string[]
                                          - number[]
                                    required:
                                      - source
                              required:
                                - type
                                - template_name
                                - template_language
                                - variables
                            delay_minutes:
                              type: integer
                              minimum: 0
                              maximum: 129600
                          required:
                            - channel
                            - content
                            - delay_minutes
                        - type: object
                          properties:
                            channel:
                              type: string
                              const: voice
                            content:
                              type: object
                              properties:
                                type:
                                  type: string
                                  const: voice_call
                                extra_instructions:
                                  type: string
                                  minLength: 1
                                  maxLength: 8000
                                variables:
                                  type: object
                                  propertyNames:
                                    type: string
                                    minLength: 1
                                    maxLength: 64
                                  additionalProperties:
                                    type: object
                                    properties:
                                      source:
                                        type: string
                                        minLength: 1
                                        maxLength: 200
                                        description: >-
                                          A recipient column ('display_name',
                                          'phone', 'email') or the exact name of a
                                          key in the person's attached data
                                          (extra_data). Those three names always
                                          read the column — a key spelled the same
                                          is unreachable; any other string reads
                                          the attached data, matched verbatim as a
                                          top-level key. A missing or empty value
                                          falls to `fallback`, and with no
                                          fallback the person parks (needs_data).
                                      fallback:
                                        type: string
                                      type:
                                        description: >-
                                          Optional. Applies to attached-data
                                          sources only — ignored on the three
                                          columns. How to read the value: string,
                                          number, boolean, date, string[] or
                                          number[] — the same vocabulary as
                                          People-table columns. Absent: text and
                                          numbers pass through, anything else
                                          counts as missing. Declared: text is
                                          parsed where it is unambiguous ("250" as
                                          a number or a string, "true" as a
                                          boolean, an ISO-shaped date such as
                                          "2026-03-12" — other date spellings and
                                          epoch numbers are missing), a date
                                          renders as a plain day in the person's
                                          timezone, a list needs an actual list in
                                          the data and joins with commas, dropping
                                          items it cannot read, and a value that
                                          cannot be read as the declared type
                                          counts as missing.
                                        type: string
                                        enum:
                                          - string
                                          - number
                                          - boolean
                                          - date
                                          - string[]
                                          - number[]
                                    required:
                                      - source
                              required:
                                - type
                            delay_minutes:
                              type: integer
                              minimum: 0
                              maximum: 129600
                          required:
                            - channel
                            - content
                            - delay_minutes
                        - type: object
                          properties:
                            channel:
                              type: string
                              const: email
                            content:
                              type: object
                              properties:
                                type:
                                  type: string
                                  const: email
                                subject:
                                  type: string
                                  minLength: 1
                                html:
                                  type: string
                                  minLength: 1
                                text:
                                  type: string
                                  minLength: 1
                                variables:
                                  default: {}
                                  type: object
                                  propertyNames:
                                    type: string
                                  additionalProperties:
                                    type: object
                                    properties:
                                      source:
                                        type: string
                                        minLength: 1
                                        maxLength: 200
                                        description: >-
                                          A recipient column ('display_name',
                                          'phone', 'email') or the exact name of a
                                          key in the person's attached data
                                          (extra_data). Those three names always
                                          read the column — a key spelled the same
                                          is unreachable; any other string reads
                                          the attached data, matched verbatim as a
                                          top-level key. A missing or empty value
                                          falls to `fallback`, and with no
                                          fallback the person parks (needs_data).
                                      fallback:
                                        type: string
                                      type:
                                        description: >-
                                          Optional. Applies to attached-data
                                          sources only — ignored on the three
                                          columns. How to read the value: string,
                                          number, boolean, date, string[] or
                                          number[] — the same vocabulary as
                                          People-table columns. Absent: text and
                                          numbers pass through, anything else
                                          counts as missing. Declared: text is
                                          parsed where it is unambiguous ("250" as
                                          a number or a string, "true" as a
                                          boolean, an ISO-shaped date such as
                                          "2026-03-12" — other date spellings and
                                          epoch numbers are missing), a date
                                          renders as a plain day in the person's
                                          timezone, a list needs an actual list in
                                          the data and joins with commas, dropping
                                          items it cannot read, and a value that
                                          cannot be read as the declared type
                                          counts as missing.
                                        type: string
                                        enum:
                                          - string
                                          - number
                                          - boolean
                                          - date
                                          - string[]
                                          - number[]
                                    required:
                                      - source
                              required:
                                - type
                                - subject
                                - html
                                - text
                            delay_minutes:
                              type: integer
                              minimum: 0
                              maximum: 129600
                          required:
                            - channel
                            - content
                            - delay_minutes
                    description: Steps added at the END of the journey, in order.
                required:
                  - op
                  - steps
              - type: object
                properties:
                  op:
                    type: string
                    const: remove
                  step_index:
                    type: integer
                    minimum: 0
                    maximum: 9007199254740991
                required:
                  - op
                  - step_index
      required:
        - edits
    SequenceStepsWriteDto:
      $schema: https://json-schema.org/draft/2020-12/schema
      $id: '#/components/schemas/SequenceStepsWriteDto'
      type: object
      properties:
        id:
          type: string
          format: uuid
          pattern: >-
            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
        org_id:
          type: string
          format: uuid
          pattern: >-
            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
        name:
          type: string
        status:
          type: string
          enum:
            - draft
            - active
            - paused
        steps:
          type: array
          items:
            oneOf:
              - type: object
                properties:
                  channel:
                    type: string
                    const: whatsapp
                  content:
                    type: object
                    properties:
                      type:
                        type: string
                        const: whatsapp_template
                      template_name:
                        type: string
                        minLength: 1
                      template_language:
                        type: string
                        minLength: 1
                      variables:
                        type: object
                        propertyNames:
                          type: string
                        additionalProperties:
                          type: object
                          properties:
                            source:
                              type: string
                              minLength: 1
                              maxLength: 200
                              description: >-
                                A recipient column ('display_name', 'phone',
                                'email') or the exact name of a key in the
                                person's attached data (extra_data). Those three
                                names always read the column — a key spelled the
                                same is unreachable; any other string reads the
                                attached data, matched verbatim as a top-level
                                key. A missing or empty value falls to
                                `fallback`, and with no fallback the person
                                parks (needs_data).
                            fallback:
                              type: string
                            type:
                              description: >-
                                Optional. Applies to attached-data sources only
                                — ignored on the three columns. How to read the
                                value: string, number, boolean, date, string[]
                                or number[] — the same vocabulary as
                                People-table columns. Absent: text and numbers
                                pass through, anything else counts as missing.
                                Declared: text is parsed where it is unambiguous
                                ("250" as a number or a string, "true" as a
                                boolean, an ISO-shaped date such as "2026-03-12"
                                — other date spellings and epoch numbers are
                                missing), a date renders as a plain day in the
                                person's timezone, a list needs an actual list
                                in the data and joins with commas, dropping
                                items it cannot read, and a value that cannot be
                                read as the declared type counts as missing.
                              type: string
                              enum:
                                - string
                                - number
                                - boolean
                                - date
                                - string[]
                                - number[]
                          required:
                            - source
                          additionalProperties: false
                        description: >-
                          Body bindings keyed by positional index ("1", "2") or
                          exact parameter name ("first_name").
                      buttons:
                        type: object
                        propertyNames:
                          type: string
                          pattern: ^[0-9]$
                        additionalProperties:
                          type: object
                          properties:
                            source:
                              type: string
                              minLength: 1
                              maxLength: 200
                              description: >-
                                A recipient column ('display_name', 'phone',
                                'email') or the exact name of a key in the
                                person's attached data (extra_data). Those three
                                names always read the column — a key spelled the
                                same is unreachable; any other string reads the
                                attached data, matched verbatim as a top-level
                                key. A missing or empty value falls to
                                `fallback`, and with no fallback the person
                                parks (needs_data).
                            fallback:
                              type: string
                            type:
                              description: >-
                                Optional. Applies to attached-data sources only
                                — ignored on the three columns. How to read the
                                value: string, number, boolean, date, string[]
                                or number[] — the same vocabulary as
                                People-table columns. Absent: text and numbers
                                pass through, anything else counts as missing.
                                Declared: text is parsed where it is unambiguous
                                ("250" as a number or a string, "true" as a
                                boolean, an ISO-shaped date such as "2026-03-12"
                                — other date spellings and epoch numbers are
                                missing), a date renders as a plain day in the
                                person's timezone, a list needs an actual list
                                in the data and joins with commas, dropping
                                items it cannot read, and a value that cannot be
                                read as the declared type counts as missing.
                              type: string
                              enum:
                                - string
                                - number
                                - boolean
                                - date
                                - string[]
                                - number[]
                          required:
                            - source
                          additionalProperties: false
                    required:
                      - type
                      - template_name
                      - template_language
                      - variables
                    additionalProperties: false
                  delay_minutes:
                    type: integer
                    minimum: 0
                    maximum: 129600
                required:
                  - channel
                  - content
                  - delay_minutes
                additionalProperties: false
              - type: object
                properties:
                  channel:
                    type: string
                    const: voice
                  content:
                    type: object
                    properties:
                      type:
                        type: string
                        const: voice_call
                      extra_instructions:
                        type: string
                        minLength: 1
                        maxLength: 8000
                      variables:
                        type: object
                        propertyNames:
                          type: string
                          minLength: 1
                          maxLength: 64
                        additionalProperties:
                          type: object
                          properties:
                            source:
                              type: string
                              minLength: 1
                              maxLength: 200
                              description: >-
                                A recipient column ('display_name', 'phone',
                                'email') or the exact name of a key in the
                                person's attached data (extra_data). Those three
                                names always read the column — a key spelled the
                                same is unreachable; any other string reads the
                                attached data, matched verbatim as a top-level
                                key. A missing or empty value falls to
                                `fallback`, and with no fallback the person
                                parks (needs_data).
                            fallback:
                              type: string
                            type:
                              description: >-
                                Optional. Applies to attached-data sources only
                                — ignored on the three columns. How to read the
                                value: string, number, boolean, date, string[]
                                or number[] — the same vocabulary as
                                People-table columns. Absent: text and numbers
                                pass through, anything else counts as missing.
                                Declared: text is parsed where it is unambiguous
                                ("250" as a number or a string, "true" as a
                                boolean, an ISO-shaped date such as "2026-03-12"
                                — other date spellings and epoch numbers are
                                missing), a date renders as a plain day in the
                                person's timezone, a list needs an actual list
                                in the data and joins with commas, dropping
                                items it cannot read, and a value that cannot be
                                read as the declared type counts as missing.
                              type: string
                              enum:
                                - string
                                - number
                                - boolean
                                - date
                                - string[]
                                - number[]
                          required:
                            - source
                          additionalProperties: false
                    required:
                      - type
                    additionalProperties: false
                  delay_minutes:
                    type: integer
                    minimum: 0
                    maximum: 129600
                required:
                  - channel
                  - content
                  - delay_minutes
                additionalProperties: false
              - type: object
                properties:
                  channel:
                    type: string
                    const: email
                  content:
                    type: object
                    properties:
                      type:
                        type: string
                        const: email
                      subject:
                        type: string
                        minLength: 1
                      html:
                        type: string
                        minLength: 1
                      text:
                        type: string
                        minLength: 1
                      variables:
                        default: {}
                        type: object
                        propertyNames:
                          type: string
                        additionalProperties:
                          type: object
                          properties:
                            source:
                              type: string
                              minLength: 1
                              maxLength: 200
                              description: >-
                                A recipient column ('display_name', 'phone',
                                'email') or the exact name of a key in the
                                person's attached data (extra_data). Those three
                                names always read the column — a key spelled the
                                same is unreachable; any other string reads the
                                attached data, matched verbatim as a top-level
                                key. A missing or empty value falls to
                                `fallback`, and with no fallback the person
                                parks (needs_data).
                            fallback:
                              type: string
                            type:
                              description: >-
                                Optional. Applies to attached-data sources only
                                — ignored on the three columns. How to read the
                                value: string, number, boolean, date, string[]
                                or number[] — the same vocabulary as
                                People-table columns. Absent: text and numbers
                                pass through, anything else counts as missing.
                                Declared: text is parsed where it is unambiguous
                                ("250" as a number or a string, "true" as a
                                boolean, an ISO-shaped date such as "2026-03-12"
                                — other date spellings and epoch numbers are
                                missing), a date renders as a plain day in the
                                person's timezone, a list needs an actual list
                                in the data and joins with commas, dropping
                                items it cannot read, and a value that cannot be
                                read as the declared type counts as missing.
                              type: string
                              enum:
                                - string
                                - number
                                - boolean
                                - date
                                - string[]
                                - number[]
                          required:
                            - source
                          additionalProperties: false
                    required:
                      - type
                      - subject
                      - html
                      - text
                      - variables
                    additionalProperties: false
                  delay_minutes:
                    type: integer
                    minimum: 0
                    maximum: 129600
                required:
                  - channel
                  - content
                  - delay_minutes
                additionalProperties: false
        settings:
          type: object
          properties:
            block_active_elsewhere:
              type: boolean
            block_contacted_before:
              type: boolean
            respect_office_hours:
              type: boolean
            office_hours_id:
              type: string
              format: uuid
              pattern: >-
                ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
          additionalProperties: false
        brief:
          type: string
        reply_instructions:
          type: string
        criteria:
          type: object
          properties:
            must:
              maxItems: 20
              type: array
              items:
                type: object
                properties:
                  label:
                    type: string
                    minLength: 2
                    maxLength: 60
                    description: >-
                      A few words naming this criterion, shown in the dashboard
                      — "Recent invoicing complaint", "Business account". Not a
                      sentence.
                  text:
                    type: string
                    minLength: 3
                    maxLength: 500
                    description: >-
                      The full instruction the judge reads. Name the boundary
                      explicitly — what counts and what does not. Never shown in
                      the table.
                required:
                  - label
                  - text
                additionalProperties: false
            nice:
              maxItems: 20
              type: array
              items:
                type: object
                properties:
                  label:
                    type: string
                    minLength: 2
                    maxLength: 60
                    description: >-
                      A few words naming this criterion, shown in the dashboard
                      — "Recent invoicing complaint", "Business account". Not a
                      sentence.
                  text:
                    type: string
                    minLength: 3
                    maxLength: 500
                    description: >-
                      The full instruction the judge reads. Name the boundary
                      explicitly — what counts and what does not. Never shown in
                      the table.
                  grade:
                    type: string
                    enum:
                      - high
                      - medium
                      - low
                required:
                  - label
                  - text
                  - grade
                additionalProperties: false
          required:
            - must
            - nice
          additionalProperties: false
        columns:
          maxItems: 12
          type: array
          items:
            type: object
            properties:
              key:
                type: string
                minLength: 1
                maxLength: 59
                pattern: ^[a-z0-9_]+$
              label:
                type: string
                minLength: 1
                maxLength: 60
              path:
                type: string
                minLength: 1
                maxLength: 300
              type:
                type: string
                enum:
                  - string
                  - number
                  - boolean
                  - date
                  - string[]
                  - number[]
            required:
              - key
              - label
              - path
              - type
            additionalProperties: false
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        deleted_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
        variable_coverage:
          $ref: '#/components/schemas/SequenceVariableCoverageDto'
      required:
        - id
        - org_id
        - name
        - status
        - steps
        - settings
        - brief
        - reply_instructions
        - criteria
        - columns
        - created_at
        - updated_at
        - deleted_at
        - variable_coverage
      additionalProperties: false
    ErrorDto:
      type: object
      properties:
        statusCode:
          type: integer
        message:
          type: string
        error:
          type: string
    SequenceVariableCoverageDto:
      $schema: https://json-schema.org/draft/2020-12/schema
      $id: '#/components/schemas/SequenceVariableCoverageDto'
      type: object
      properties:
        sampled:
          type: boolean
          description: >-
            True when the sequence holds more people than the sample these
            counts read.
        sample_size:
          type: integer
          minimum: -9007199254740991
          maximum: 9007199254740991
          description: People the counts were read over (first N by id).
        total:
          type: integer
          minimum: -9007199254740991
          maximum: 9007199254740991
          description: Enrolled people on the sequence.
        sources:
          type: object
          propertyNames:
            type: string
          additionalProperties:
            type: object
            properties:
              present:
                type: integer
                minimum: -9007199254740991
                maximum: 9007199254740991
                description: People in the sample with a non-blank value.
              missing:
                type: integer
                minimum: -9007199254740991
                maximum: 9007199254740991
                description: People in the sample without one.
            required:
              - present
              - missing
            additionalProperties: false
          description: >-
            Keyed by each binding's `source` — a recipient column or an
            attached-data key.
      required:
        - sampled
        - sample_size
        - total
        - sources
      additionalProperties: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.