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

# Split workflow block

> Divides one block into two at a step you choose, so a link can enter at that step or a step can branch. Send `expectedSteps` as your last read returned them; if the block changed since then, the call returns 409 and writes nothing.



## OpenAPI

````yaml /specs-prettified/realtime/openapi.stable.json post /v1/stable/workflow/{workflowID}/block/{blockID}/split
openapi: 3.0.0
info:
  title: Realtime
  description: Realtime gateway API service
  version: 1.0.0
  contact: {}
servers:
  - url: https://realtime-api.voiceflow.com
security: []
tags: []
paths:
  /v1/stable/workflow/{workflowID}/block/{blockID}/split:
    post:
      tags:
        - Workflow
      summary: Split workflow block
      description: Divides one block into two at a step you choose, so a link can
        enter at that step or a step can branch. Send `expectedSteps` as your
        last read returned them; if the block changed since then, the call
        returns 409 and writes nothing.
      operationId: StableWorkflowController_splitBlock
      parameters:
        - name: workflowID
          required: true
          in: path
          schema:
            type: string
          x-vf-doc:
            description: The ID of the workflow to operate on.
          description: The ID of the workflow to operate on.
        - name: blockID
          required: true
          in: path
          schema:
            type: string
          x-vf-doc:
            description: The ID of the block to operate on.
          description: The ID of the block to operate on.
        - name: projectID
          required: true
          in: query
          schema:
            type: string
            description: The ID of the project to operate on.
        - name: environmentAlias
          required: true
          in: query
          schema:
            type: string
            description: The alias of the environment to operate on (e.g. `main`).
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/StableWorkflowBlockSplitRequest"
      responses:
        "201":
          description: Returns both blocks, `head` for the part that keeps the original ID
            and `tail` for the new one. Link a port to the tail block next.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/StableWorkflowSplitResponse"
          x-vf-doc:
            description: Returns both blocks, `head` for the part that keeps the original ID
              and `tail` for the new one. Link a port to the tail block next.
      security:
        - token: []
components:
  schemas:
    StableWorkflowBlockSplitRequest:
      type: object
      properties:
        atStepID:
          type: string
          description: The step that starts the new block. It and every step below it move
            there, and the step above it becomes the last step of the block. To
            make step X the last step, so that its fail and path ports run, send
            the step below X. It must not be the first step.
        name:
          description: 'The new block name. Default: the block name with " (continued)".'
          type: string
          minLength: 1
          maxLength: 255
        expectedSteps:
          type: array
          items:
            type: string
          description: The block's step IDs exactly as your last read returned them. If
            the block changed, nothing is written.
        acknowledgeRewire:
          description: Required when the step that becomes the last step has hidden links
            or actions. The split keeps them, so they start to run. An action
            list on its next exit is deleted, because next links to the new
            block.
          type: boolean
      required:
        - atStepID
        - expectedSteps
      additionalProperties: false
    StableWorkflowSplitResponse:
      type: object
      properties:
        head:
          $ref: "#/components/schemas/StableWorkflowBlock"
        tail:
          $ref: "#/components/schemas/StableWorkflowBlock"
        clearedLinks:
          description: Actions on the next exit of the head’s new last step that were
            deleted, because next now links to the new block. Its hidden links
            are kept and now run.
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowClearedLink"
      required:
        - head
        - tail
    StableWorkflowBlock:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        inboundFrom:
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowInbound"
          description: Every step port that links to this block.
        steps:
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowStep"
          description: The steps in the order they run.
      required:
        - id
        - name
        - inboundFrom
        - steps
    StableWorkflowInbound:
      type: object
      properties:
        stepID:
          type: string
        port:
          type: string
      required:
        - stepID
        - port
    StableWorkflowStep:
      type: object
      properties:
        id:
          type: string
        kind:
          $ref: "#/components/schemas/StableWorkflowStepKind"
        exitClass:
          $ref: "#/components/schemas/StableWorkflowExitClass"
        content:
          $ref: "#/components/schemas/StableWorkflowStepContent"
        fallsThroughTo:
          nullable: true
          description: "When the step is not the last of its block: the step it continues
            to. Otherwise null."
          type: string
        suppressedPorts:
          type: array
          items:
            type: string
          description: Ports that run into the next step instead of their link, because
            the step is not last.
        links:
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowLink"
        reconciledPorts:
          allOf:
            - $ref: "#/components/schemas/StableWorkflowReconciledPorts"
        warnings:
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowDiagnostic"
      required:
        - id
        - kind
        - exitClass
        - content
        - fallsThroughTo
        - suppressedPorts
        - links
    StableWorkflowStepKind:
      type: string
      enum:
        - message
        - end
        - set
        - workflow
        - listen
        - condition
        - buttons
        - card
        - carousel
        - code
        - api
        - function
        - integration
        - mcp
        - playbook
        - operator
        - crew
        - handoff
        - legacy
        - goToBlock
        - callForward
      description: What the step does. api, function, integration and mcp are Tool
        steps. playbook and operator are Agent steps. goToBlock jumps to a block
        or a workflow start and ends the path. callForward transfers a phone
        call and ends the path. legacy is a step these operations show but
        cannot change.
      x-enumNames:
        - MESSAGE
        - END
        - SET
        - WORKFLOW
        - LISTEN
        - CONDITION
        - BUTTONS
        - CARD
        - CAROUSEL
        - CODE
        - API
        - FUNCTION
        - INTEGRATION
        - MCP
        - PLAYBOOK
        - OPERATOR
        - CREW
        - HANDOFF
        - LEGACY
        - GO_TO_BLOCK
        - CALL_FORWARD
    StableWorkflowExitClass:
      type: string
      enum:
        - sequential
        - branch
        - async-branch
        - terminal
      description: "How the step leaves. sequential: it continues to the step below
        it, or through next when it is last. branch: it leaves through one of
        its links, so it must be last. async-branch: a Card or Carousel, whose
        linked buttons run from any position. terminal: it ends the path."
      x-enumNames:
        - SEQUENTIAL
        - BRANCH
        - ASYNC_BRANCH
        - TERMINAL
    StableWorkflowStepContent:
      anyOf:
        - $ref: "#/components/schemas/StableWorkflowStepMessageContent"
        - $ref: "#/components/schemas/StableWorkflowStepEndContent"
        - $ref: "#/components/schemas/StableWorkflowStepSetContent"
        - $ref: "#/components/schemas/StableWorkflowStepWorkflowContent"
        - $ref: "#/components/schemas/StableWorkflowStepListenContent"
        - $ref: "#/components/schemas/StableWorkflowStepConditionContent"
        - $ref: "#/components/schemas/StableWorkflowStepButtonsContent"
        - $ref: "#/components/schemas/StableWorkflowStepCardContent"
        - $ref: "#/components/schemas/StableWorkflowStepCarouselContent"
        - $ref: "#/components/schemas/StableWorkflowStepCodeContent"
        - $ref: "#/components/schemas/StableWorkflowStepApiContent"
        - $ref: "#/components/schemas/StableWorkflowStepFunctionContent"
        - $ref: "#/components/schemas/StableWorkflowStepIntegrationContent"
        - $ref: "#/components/schemas/StableWorkflowStepMcpContent"
        - $ref: "#/components/schemas/StableWorkflowStepOperatorContent"
        - $ref: "#/components/schemas/StableWorkflowStepPlaybookContent"
        - $ref: "#/components/schemas/StableWorkflowStepCrewContent"
        - $ref: "#/components/schemas/StableWorkflowStepHandoffContent"
        - $ref: "#/components/schemas/StableWorkflowStepGoToBlockContent"
        - $ref: "#/components/schemas/StableWorkflowStepCallForwardContent"
        - $ref: "#/components/schemas/StableWorkflowStepReadOnlyContent"
      description: The step's settings, shaped by its kind. A step these operations
        cannot show reads as readOnly.
    StableWorkflowStepMessageContent:
      oneOf:
        - type: object
          properties:
            responseType:
              type: string
              enum:
                - message
              x-enumNames:
                - MESSAGE
            messageID:
              nullable: true
              description: The ID of the message this step says, or null. Read its words with
                the message operations.
              type: string
            waitForUserResponse:
              type: boolean
              description: Whether the step waits for the user to reply before it continues.
          required:
            - responseType
            - messageID
            - waitForUserResponse
        - type: object
          properties:
            responseType:
              type: string
              enum:
                - prompt
              x-enumNames:
                - PROMPT
            promptID:
              nullable: true
              description: The ID of the prompt this step runs, or null. Read it with the
                prompt operations.
              type: string
            waitForUserResponse:
              type: boolean
              description: Whether the step waits for the user to reply before it continues.
          required:
            - responseType
            - promptID
            - waitForUserResponse
    StableWorkflowStepEndContent:
      oneOf:
        - type: object
          properties:
            responseType:
              type: string
              enum:
                - message
              x-enumNames:
                - MESSAGE
            messageID:
              nullable: true
              description: The ID of the message this step says, or null. Read its words with
                the message operations.
              type: string
            responseEnabled:
              type: boolean
              description: Whether the step says something before it ends the conversation.
          required:
            - responseType
            - messageID
            - responseEnabled
        - type: object
          properties:
            responseType:
              type: string
              enum:
                - prompt
              x-enumNames:
                - PROMPT
            promptID:
              nullable: true
              description: The ID of the prompt this step runs, or null. Read it with the
                prompt operations.
              type: string
            responseEnabled:
              type: boolean
              description: Whether the step says something before it ends the conversation.
          required:
            - responseType
            - promptID
            - responseEnabled
    StableWorkflowStepSetContent:
      type: object
      properties:
        assignments:
          type: array
          items:
            oneOf:
              - type: object
                properties:
                  id:
                    type: string
                  type:
                    type: string
                    enum:
                      - value
                    x-enumNames:
                      - VALUE
                  variableID:
                    nullable: true
                    type: string
                  label:
                    nullable: true
                    type: string
                  value:
                    nullable: true
                    allOf:
                      - $ref: "#/components/schemas/VariableReferenceString"
                required:
                  - id
                  - type
                  - variableID
                  - label
                  - value
              - type: object
                properties:
                  id:
                    type: string
                  type:
                    type: string
                    enum:
                      - prompt
                    x-enumNames:
                      - PROMPT
                  variableID:
                    nullable: true
                    type: string
                  label:
                    nullable: true
                    type: string
                  promptID:
                    nullable: true
                    description: The prompt whose answer is stored in the variable.
                    type: string
                required:
                  - id
                  - type
                  - variableID
                  - label
                  - promptID
        parallelExecution:
          type: boolean
          description: Whether the assignments run at the same time instead of in order.
        transcriptProperties:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              operationType:
                type: string
                enum:
                  - append
                  - replace
                x-enumNames:
                  - APPEND
                  - REPLACE
              propertyID:
                nullable: true
                type: string
              label:
                nullable: true
                type: string
              value:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/VariableReferenceString"
            required:
              - id
              - operationType
              - propertyID
              - label
              - value
      required:
        - assignments
        - parallelExecution
        - transcriptProperties
    VariableReferenceString:
      type: string
      description: Plain text; markdown is not interpreted. {variable_name} inserts a
        variable or entity, {variable_name.path} a field of a variable. Escape a
        literal { or \ with a backslash. A name matching neither is stored as
        literal text and reported in unresolvedReferences; secrets are not
        available here.
    StableWorkflowStepWorkflowContent:
      type: object
      properties:
        targetWorkflowID:
          nullable: true
          description: The workflow this step runs, by the ID the workflow list returns,
            or null.
          type: string
        targetWorkflowName:
          nullable: true
          description: Read-only. The name of that workflow.
          type: string
        variableMap:
          nullable: true
          type: object
          properties:
            inputs:
              type: array
              items:
                minItems: 2
                maxItems: 2
                type: array
                items:
                  nullable: true
                  type: string
            outputs:
              type: array
              items:
                minItems: 2
                maxItems: 2
                type: array
                items:
                  nullable: true
                  type: string
          required:
            - inputs
            - outputs
      required:
        - targetWorkflowID
        - targetWorkflowName
        - variableMap
    StableWorkflowStepListenContent:
      type: object
      properties:
        variableID:
          nullable: true
          description: The variable that receives the user's reply.
          type: string
        noReply:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoReply"
        listenForOtherTriggers:
          type: boolean
      required:
        - variableID
        - noReply
        - listenForOtherTriggers
    StableWorkflowNoReply:
      type: object
      properties:
        enabled:
          type: boolean
          description: "Whether the no-reply path is on: the step then leaves through its
            no-reply port."
        repromptID:
          nullable: true
          description: The message said when the user does not reply, or null.
          type: string
        inactivityTime:
          nullable: true
          description: Seconds to wait for a reply, or null for the default.
          type: number
      required:
        - enabled
        - repromptID
        - inactivityTime
    StableWorkflowStepConditionContent:
      type: object
      properties:
        items:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
                description: The branch ID, which is also its port key.
              label:
                nullable: true
                type: string
              matchAll:
                type: boolean
              assertions:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                      description: The assertion's ID. Send it back with the assertion in a write to
                        keep it.
                    lhs:
                      type: object
                      properties:
                        variableID:
                          nullable: true
                          type: string
                        path:
                          nullable: true
                          type: string
                      required:
                        - variableID
                        - path
                    operation:
                      $ref: "#/components/schemas/ConditionOperation"
                    rhs:
                      $ref: "#/components/schemas/VariableReferenceString"
                  required:
                    - id
                    - lhs
                    - operation
                    - rhs
            required:
              - id
              - label
              - matchAll
              - assertions
        elsePath:
          type: boolean
          description: "Whether the else port is on: a reply that matches no branch leaves
            through it."
        elseReprompt:
          nullable: true
          type: object
          properties:
            repromptID:
              nullable: true
              type: string
          required:
            - repromptID
      required:
        - items
        - elsePath
        - elseReprompt
    ConditionOperation:
      type: string
      enum:
        - is
        - is_not
        - greater_than
        - greater_or_equal
        - less_than
        - less_or_equal
        - contains
        - not_contains
        - starts_with
        - ends_with
        - is_empty
        - is_not_empty
      x-enumNames:
        - IS
        - IS_NOT
        - GREATER_THAN
        - GREATER_OR_EQUAL
        - LESS_THAN
        - LESS_OR_EQUAL
        - CONTAINS
        - NOT_CONTAINS
        - STARTS_WITH
        - ENDS_WITH
        - IS_EMPTY
        - IS_NOT_EMPTY
    StableWorkflowStepButtonsContent:
      type: object
      properties:
        items:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              label:
                $ref: "#/components/schemas/VariableReferenceString"
              url:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/VariableReferenceString"
              openInNewTab:
                description: "Read-only. Present when the button has a URL: true opens the URL
                  in a new tab."
                type: boolean
            required:
              - id
              - label
              - url
        noMatch:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoMatch"
        noReply:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoReply"
        listenForOtherTriggers:
          type: boolean
      required:
        - items
        - noMatch
        - noReply
        - listenForOtherTriggers
    StableWorkflowNoMatch:
      type: object
      properties:
        enabled:
          type: boolean
          description: "Whether the no-match path is on: the step then leaves through its
            else port."
        repromptID:
          nullable: true
          description: The message said when the reply matches nothing, or null.
          type: string
      required:
        - enabled
        - repromptID
    StableWorkflowStepCardContent:
      type: object
      properties:
        title:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/VariableReferenceString"
        description:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/MarkdownLikeString"
        imageUrl:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/VariableReferenceString"
        buttons:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              label:
                $ref: "#/components/schemas/VariableReferenceString"
              url:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/VariableReferenceString"
              openInNewTab:
                description: "Read-only. Present when the button has a URL: true opens the URL
                  in a new tab."
                type: boolean
            required:
              - id
              - label
              - url
        noMatch:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoMatch"
        noReply:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoReply"
      required:
        - title
        - description
        - imageUrl
        - buttons
        - noMatch
        - noReply
    MarkdownLikeString:
      type: string
      description: "Message text shown to the end user. Limited markdown: **bold**,
        _italic_, <u>underline</u>, ~~strikethrough~~, [label](url).
        {variable_name} inserts a variable or entity, {variable_name.path} a
        field of a variable. Escape a literal { or \\ with a backslash. A name
        matching neither is stored as literal text and reported in
        unresolvedReferences; secrets are not available here."
    StableWorkflowStepCarouselContent:
      type: object
      properties:
        layout:
          type: string
          enum:
            - List
            - Carousel
          x-enumNames:
            - LIST
            - CAROUSEL
        cards:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              title:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/VariableReferenceString"
              description:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/MarkdownLikeString"
              imageUrl:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/VariableReferenceString"
              buttons:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                    label:
                      $ref: "#/components/schemas/VariableReferenceString"
                    url:
                      nullable: true
                      allOf:
                        - $ref: "#/components/schemas/VariableReferenceString"
                    openInNewTab:
                      description: "Read-only. Present when the button has a URL: true opens the URL
                        in a new tab."
                      type: boolean
                  required:
                    - id
                    - label
                    - url
            required:
              - id
              - title
              - description
              - imageUrl
              - buttons
        noMatch:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoMatch"
        noReply:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowNoReply"
      required:
        - layout
        - cards
        - noMatch
        - noReply
    StableWorkflowStepCodeContent:
      type: object
      properties:
        code:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/VariableReferenceString"
        paths:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              label:
                type: string
            required:
              - id
              - label
        fallback:
          type: boolean
          description: "Whether the fail port is on: an error in the code leaves through
            it."
      required:
        - code
        - paths
        - fallback
    StableWorkflowStepApiContent:
      type: object
      properties:
        apiToolID:
          type: string
        apiToolName:
          nullable: true
          description: Read-only.
          type: string
        description:
          nullable: true
          type: string
        inputs:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              description:
                default: null
                nullable: true
                type: string
              defaultValue:
                default: null
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/DefaultValueString"
              apiToolInputVariableID:
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
              required:
                type: boolean
                description: "Whether the agent must supply a value for this input. Omit it and
                  the API infers: false when defaultValue holds a secret
                  reference (the secret is injected and the model is never asked
                  for it), true otherwise. Sending true together with a secret
                  defaultValue is rejected."
            required:
              - id
              - apiToolInputVariableID
              - required
        captureResponse:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              path:
                type: string
              variableOrEntityID:
                nullable: true
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
            required:
              - id
              - path
              - variableOrEntityID
        failPath:
          type: boolean
          description: "Whether the fail port is on: a failed call leaves through it."
        asyncExecution:
          type: boolean
          description: Read-only. When true, the path continues without waiting for the
            call to finish.
      required:
        - apiToolID
        - apiToolName
        - description
        - inputs
        - captureResponse
        - failPath
        - asyncExecution
    DefaultValueString:
      type: string
      description: Plain text resolved at runtime and never shown to a model.
        {variable_name} inserts a variable or entity, {secret_name} a project
        secret, {variable_name.path} a field of a variable. Escape a literal {
        or \ with a backslash. When a name is both a variable and a secret, the
        secret wins. A name matching none is stored as literal text and reported
        in unresolvedReferences. Where the field is sent to an upstream system,
        an unresolved placeholder may be sent as literal text; on an MCP server
        it is re-resolved by name at connect time, so a literal that matches a
        real secret binds.
    ToolNodeCaptureType:
      type: string
      enum:
        - variable
        - property
      x-enumNames:
        - VARIABLE
        - PROPERTY
    StableWorkflowStepFunctionContent:
      type: object
      properties:
        functionID:
          type: string
        functionName:
          nullable: true
          description: Read-only.
          type: string
        paths:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              label:
                type: string
            required:
              - id
              - label
          description: Read-only. The function's paths; each is also a port key of this
            step.
        description:
          nullable: true
          type: string
        inputs:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              description:
                default: null
                nullable: true
                type: string
              defaultValue:
                default: null
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/DefaultValueString"
              functionInputVariableID:
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
              required:
                type: boolean
                description: "Whether the agent must supply a value for this input. Omit it and
                  the API infers: false when defaultValue holds a secret
                  reference (the secret is injected and the model is never asked
                  for it), true otherwise. Sending true together with a secret
                  defaultValue is rejected."
            required:
              - id
              - functionInputVariableID
              - required
        captureResponse:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              variableOrEntityID:
                nullable: true
                type: string
              functionOutputVariableID:
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
            required:
              - id
              - variableOrEntityID
              - functionOutputVariableID
        failPath:
          type: boolean
          description: "Whether the fail port is on: a failed call leaves through it."
        asyncExecution:
          type: boolean
          description: Read-only. When true, the path continues without waiting for the
            call to finish.
      required:
        - functionID
        - functionName
        - paths
        - description
        - inputs
        - captureResponse
        - failPath
        - asyncExecution
    StableWorkflowStepIntegrationContent:
      type: object
      properties:
        integrationToolID:
          type: string
        integrationToolName:
          nullable: true
          description: Read-only.
          type: string
        description:
          nullable: true
          type: string
        inputs:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              description:
                default: null
                nullable: true
                type: string
              defaultValue:
                default: null
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/DefaultValueString"
              integrationToolVariableName:
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
              required:
                type: boolean
                description: "Whether the agent must supply a value for this input. Omit it and
                  the API infers: false when defaultValue holds a secret
                  reference (the secret is injected and the model is never asked
                  for it), true otherwise. Sending true together with a secret
                  defaultValue is rejected."
            required:
              - id
              - integrationToolVariableName
              - required
        captureResponse:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              path:
                type: string
              variableOrEntityID:
                nullable: true
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
            required:
              - id
              - path
              - variableOrEntityID
      required:
        - integrationToolID
        - integrationToolName
        - description
        - inputs
        - captureResponse
    StableWorkflowStepMcpContent:
      type: object
      properties:
        mcpToolID:
          type: string
        mcpToolName:
          nullable: true
          description: Read-only.
          type: string
        description:
          nullable: true
          type: string
        inputs:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              description:
                default: null
                nullable: true
                type: string
              defaultValue:
                default: null
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/DefaultValueString"
              mcpIntegrationVariableName:
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
              required:
                type: boolean
                description: "Whether the agent must supply a value for this input. Omit it and
                  the API infers: false when defaultValue holds a secret
                  reference (the secret is injected and the model is never asked
                  for it), true otherwise. Sending true together with a secret
                  defaultValue is rejected."
            required:
              - id
              - mcpIntegrationVariableName
              - required
        captureResponse:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              path:
                type: string
              variableOrEntityID:
                nullable: true
                type: string
              captureType:
                allOf:
                  - $ref: "#/components/schemas/ToolNodeCaptureType"
            required:
              - id
              - path
              - variableOrEntityID
      required:
        - mcpToolID
        - mcpToolName
        - description
        - inputs
        - captureResponse
    StableWorkflowStepOperatorContent:
      type: object
      properties:
        agentID:
          nullable: true
          type: string
        agentName:
          nullable: true
          description: Read-only.
          type: string
        paths:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              label:
                type: string
            required:
              - id
              - label
          description: Read-only. The agent's paths; each is also a port key of this step.
        exitEveryConversationalTurn:
          type: boolean
        listenForOtherTriggers:
          type: boolean
        useAsRoutingAgent:
          type: boolean
      required:
        - agentID
        - agentName
        - paths
        - exitEveryConversationalTurn
        - listenForOtherTriggers
        - useAsRoutingAgent
    StableWorkflowStepPlaybookContent:
      type: object
      properties:
        agentID:
          nullable: true
          type: string
        agentName:
          nullable: true
          description: Read-only.
          type: string
        paths:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              label:
                type: string
            required:
              - id
              - label
          description: Read-only. The agent's paths; each is also a port key of this step.
        exitEveryConversationalTurn:
          type: boolean
        listenForOtherTriggers:
          type: boolean
        waitForUserResponse:
          type: boolean
          description: "Read-only. True: the step waits for the user to speak first.
            False: the Playbook talks first, the canvas default."
      required:
        - agentID
        - agentName
        - paths
        - exitEveryConversationalTurn
        - listenForOtherTriggers
        - waitForUserResponse
    StableWorkflowStepCrewContent:
      type: object
      properties:
        rootAgent:
          nullable: true
          type: object
          properties:
            agentID:
              type: string
            description:
              nullable: true
              type: string
            condition:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/StableExpressionCondition"
            requiredVariables:
              type: array
              items:
                type: object
                properties:
                  id:
                    type: string
                  description:
                    nullable: true
                    type: string
                  variableOrEntityID:
                    nullable: true
                    type: string
                required:
                  - id
                  - description
                  - variableOrEntityID
          required:
            - agentID
            - description
            - condition
            - requiredVariables
        subAgents:
          type: array
          items:
            type: object
            properties:
              agentID:
                type: string
              description:
                nullable: true
                type: string
              condition:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/StableExpressionCondition"
              requiredVariables:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                    description:
                      nullable: true
                      type: string
                    variableOrEntityID:
                      nullable: true
                      type: string
                  required:
                    - id
                    - description
                    - variableOrEntityID
            required:
              - agentID
              - description
              - condition
              - requiredVariables
        subFlows:
          type: array
          items:
            type: object
            properties:
              flowID:
                type: string
              description:
                nullable: true
                type: string
              condition:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/StableExpressionCondition"
              requiredVariables:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                    description:
                      nullable: true
                      type: string
                    variableOrEntityID:
                      nullable: true
                      type: string
                  required:
                    - id
                    - description
                    - variableOrEntityID
            required:
              - flowID
              - description
              - condition
              - requiredVariables
        exitPaths:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
                description: The exit path ID, which is also its port key.
              name:
                type: string
              description:
                nullable: true
                type: string
              requiredVariables:
                type: array
                items:
                  type: object
                  properties:
                    id:
                      type: string
                    description:
                      nullable: true
                      type: string
                    variableOrEntityID:
                      nullable: true
                      type: string
                  required:
                    - id
                    - description
                    - variableOrEntityID
              messages:
                nullable: true
                allOf:
                  - $ref: "#/components/schemas/StableWorkflowCrewExitMessages"
              delayMessageSeconds:
                nullable: true
                type: number
            required:
              - id
              - name
              - description
              - requiredVariables
              - messages
              - delayMessageSeconds
        listenForOtherTriggers:
          type: boolean
        waitForUserResponse:
          type: boolean
      required:
        - rootAgent
        - subAgents
        - subFlows
        - exitPaths
        - listenForOtherTriggers
        - waitForUserResponse
    StableExpressionCondition:
      type: object
      properties:
        type:
          type: string
          enum:
            - value-variable
          x-enumNames:
            - VALUE_VARIABLE
        matchAll:
          type: boolean
        assertions:
          type: array
          items:
            $ref: "#/components/schemas/StableConditionAssertion"
      required:
        - type
        - matchAll
        - assertions
    StableConditionAssertion:
      type: object
      properties:
        key:
          type: string
        lhs:
          $ref: "#/components/schemas/ConditionAssertionLhs"
        rhs:
          $ref: "#/components/schemas/VariableReferenceString"
        operation:
          default: is
          allOf:
            - $ref: "#/components/schemas/ConditionOperation"
      required:
        - key
        - lhs
        - rhs
    ConditionAssertionLhs:
      type: object
      properties:
        variableID:
          nullable: true
          type: string
        path:
          type: string
      required:
        - variableID
    StableWorkflowCrewExitMessages:
      type: object
      properties:
        generative:
          type: object
          properties:
            execution:
              allOf:
                - $ref: "#/components/schemas/StableToolMessageGenerative"
            failure:
              allOf:
                - $ref: "#/components/schemas/StableToolMessageGenerative"
            delay:
              allOf:
                - $ref: "#/components/schemas/StableToolMessageGenerative"
            completion:
              allOf:
                - $ref: "#/components/schemas/StableToolMessageGenerative"
        delayMessageID:
          nullable: true
          type: string
        failureMessageID:
          nullable: true
          type: string
        executionMessageID:
          nullable: true
          type: string
        completionMessageID:
          nullable: true
          type: string
      required:
        - delayMessageID
        - failureMessageID
        - executionMessageID
        - completionMessageID
    StableToolMessageGenerative:
      type: object
      properties:
        enabled:
          type: boolean
        examples:
          type: array
          items:
            $ref: "#/components/schemas/MarkdownLikeString"
      required:
        - enabled
    StableWorkflowStepHandoffContent:
      type: object
      properties:
        config:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/StableWorkflowHandoffConfig"
        handoffContext:
          type: object
          properties:
            type:
              type: string
              enum:
                - full
                - none
                - custom
              x-enumNames:
                - FULL
                - NONE
                - CUSTOM
            variableID:
              nullable: true
              type: string
          required:
            - type
            - variableID
        returnPath:
          type: boolean
          description: Whether the step continues through its next port when the agent
            hands the conversation back.
        failPath:
          type: boolean
          description: Whether the step continues through its fail port when the handoff
            cannot start.
      required:
        - config
        - handoffContext
        - returnPath
        - failPath
    StableWorkflowHandoffConfig:
      oneOf:
        - type: object
          properties:
            provider:
              type: string
              enum:
                - ujet
              x-enumNames:
                - UJET
            menuID:
              $ref: "#/components/schemas/VariableReferenceString"
            userID:
              $ref: "#/components/schemas/VariableReferenceString"
            userEmail:
              $ref: "#/components/schemas/VariableReferenceString"
            userLanguage:
              $ref: "#/components/schemas/VariableReferenceString"
            metadata:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
          required:
            - provider
            - menuID
            - userID
            - userEmail
            - userLanguage
            - metadata
        - type: object
          properties:
            provider:
              type: string
              enum:
                - genesys
              x-enumNames:
                - GENESYS
            integrationId:
              $ref: "#/components/schemas/VariableReferenceString"
            userEmail:
              $ref: "#/components/schemas/VariableReferenceString"
            customerName:
              $ref: "#/components/schemas/VariableReferenceString"
            customerAccountId:
              $ref: "#/components/schemas/VariableReferenceString"
            queueName:
              $ref: "#/components/schemas/VariableReferenceString"
            queueId:
              $ref: "#/components/schemas/VariableReferenceString"
            inactivityTimeout:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
            metadata:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
          required:
            - provider
            - integrationId
            - userEmail
            - customerName
            - customerAccountId
            - queueName
            - queueId
            - inactivityTimeout
            - metadata
        - type: object
          properties:
            provider:
              type: string
              enum:
                - kustomer
              x-enumNames:
                - KUSTOMER
            endUserId:
              $ref: "#/components/schemas/VariableReferenceString"
            userEmail:
              $ref: "#/components/schemas/VariableReferenceString"
            customerName:
              $ref: "#/components/schemas/VariableReferenceString"
            userLanguage:
              $ref: "#/components/schemas/VariableReferenceString"
            assignedTeamId:
              $ref: "#/components/schemas/VariableReferenceString"
            brand:
              $ref: "#/components/schemas/VariableReferenceString"
            title:
              $ref: "#/components/schemas/VariableReferenceString"
            metadata:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
          required:
            - provider
            - endUserId
            - userEmail
            - customerName
            - userLanguage
            - assignedTeamId
            - brand
            - title
            - metadata
        - type: object
          properties:
            provider:
              type: string
              enum:
                - dixa
              x-enumNames:
                - DIXA
            endUserId:
              $ref: "#/components/schemas/VariableReferenceString"
            userEmail:
              $ref: "#/components/schemas/VariableReferenceString"
            customerName:
              $ref: "#/components/schemas/VariableReferenceString"
            userLanguage:
              $ref: "#/components/schemas/VariableReferenceString"
            queueId:
              $ref: "#/components/schemas/VariableReferenceString"
            metadata:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
          required:
            - provider
            - endUserId
            - userEmail
            - customerName
            - userLanguage
            - queueId
            - metadata
        - type: object
          properties:
            provider:
              type: string
              enum:
                - sunshine
              x-enumNames:
                - SUNSHINE
            endUserId:
              $ref: "#/components/schemas/VariableReferenceString"
            userEmail:
              $ref: "#/components/schemas/VariableReferenceString"
            customerName:
              $ref: "#/components/schemas/VariableReferenceString"
            userLanguage:
              $ref: "#/components/schemas/VariableReferenceString"
            groupId:
              $ref: "#/components/schemas/VariableReferenceString"
            brandId:
              $ref: "#/components/schemas/VariableReferenceString"
            priority:
              $ref: "#/components/schemas/VariableReferenceString"
            metadata:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
          required:
            - provider
            - endUserId
            - userEmail
            - customerName
            - userLanguage
            - groupId
            - brandId
            - priority
            - metadata
        - type: object
          properties:
            provider:
              type: string
              enum:
                - custom
              x-enumNames:
                - CUSTOM
            endUserId:
              $ref: "#/components/schemas/VariableReferenceString"
            userEmail:
              $ref: "#/components/schemas/VariableReferenceString"
            userPhone:
              $ref: "#/components/schemas/VariableReferenceString"
            customerName:
              $ref: "#/components/schemas/VariableReferenceString"
            userLanguage:
              $ref: "#/components/schemas/VariableReferenceString"
            queueId:
              $ref: "#/components/schemas/VariableReferenceString"
            metadata:
              nullable: true
              allOf:
                - $ref: "#/components/schemas/VariableReferenceString"
          required:
            - provider
            - endUserId
            - userEmail
            - userPhone
            - customerName
            - userLanguage
            - queueId
            - metadata
    StableWorkflowStepGoToBlockContent:
      type: object
      properties:
        targetWorkflowID:
          nullable: true
          description: The workflow the path jumps to, by its workflow ID. It is this
            workflow when the target is in it. Null when that workflow no longer
            exists; the step then carries a GO_TO_TARGET_MISSING warning.
          type: string
        targetWorkflowName:
          nullable: true
          description: Read-only. The name of that workflow.
          type: string
        targetBlockID:
          nullable: true
          description: The block the path jumps to, or the target workflow's start step ID.
          type: string
      required:
        - targetWorkflowID
        - targetWorkflowName
        - targetBlockID
    StableWorkflowStepCallForwardContent:
      type: object
      properties:
        addressType:
          type: string
          enum:
            - phone
            - sip
          description: Whether address is a phone number or a SIP address.
          x-enumNames:
            - PHONE
            - SIP
        address:
          $ref: "#/components/schemas/VariableReferenceString"
        extension:
          nullable: true
          allOf:
            - $ref: "#/components/schemas/VariableReferenceString"
        callerIDPassthrough:
          type: boolean
          description: Whether the forwarded call shows the caller's own number.
      required:
        - addressType
        - address
        - extension
        - callerIDPassthrough
      description: Forwards the call to a phone number or SIP address, then ends the
        path. address is the number or SIP address; extension is the digits
        dialled after the call connects, or null.
    StableWorkflowStepReadOnlyContent:
      type: object
      properties:
        readOnly:
          type: boolean
          enum:
            - true
          x-enumNames:
            - "TRUE"
        storedType:
          type: string
          description: The stored step type.
        reason:
          type: string
          description: Why these operations do not show or change this step's content.
      required:
        - readOnly
        - storedType
        - reason
    StableWorkflowLink:
      type: object
      properties:
        port:
          type: string
          description: "The port key: next, else, fail, no-reply, conversation-turn, or
            the ID of a branch or path."
        label:
          type: string
        to:
          nullable: true
          description: The block this port reaches. With actions, the block after the last
            action. Null when it points nowhere, or when its actions end the
            path.
          type: string
        actions:
          description: The port actions this exit runs, in order, before it reaches to.
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowPortAction"
        overridden:
          description: Present when this link does not run, because the step is not the
            last of its block.
          type: boolean
          enum:
            - true
          x-enumNames:
            - "TRUE"
        effectiveTo:
          description: "With overridden: the step that runs instead."
          type: string
      required:
        - port
        - label
        - to
    StableWorkflowPortAction:
      type: object
      properties:
        id:
          type: string
          description: The action ID. Use it with the step operations to read, change or
            delete this action.
        kind:
          $ref: "#/components/schemas/StableWorkflowStepKind"
        content:
          $ref: "#/components/schemas/StableWorkflowStepContent"
        warnings:
          type: array
          items:
            $ref: "#/components/schemas/StableWorkflowDiagnostic"
      required:
        - id
        - kind
        - content
      description: One action on an exit. Actions run in array order.
    StableWorkflowDiagnostic:
      type: object
      properties:
        code:
          $ref: "#/components/schemas/StableWorkflowDiagnosticCode"
        detail:
          type: string
          description: What is wrong, in one or two sentences, naming the step, block and
            port.
      required:
        - code
        - detail
    StableWorkflowDiagnosticCode:
      type: string
      enum:
        - BRANCH_NOT_LAST
        - TERMINAL_NOT_LAST
        - HIDDEN_LINK
        - UNREACHABLE_BLOCK
        - DANGLING_LINK
        - ORPHAN_STEP
        - GO_TO_TARGET_MISSING
      x-enumNames:
        - BRANCH_NOT_LAST
        - TERMINAL_NOT_LAST
        - HIDDEN_LINK
        - UNREACHABLE_BLOCK
        - DANGLING_LINK
        - ORPHAN_STEP
        - GO_TO_TARGET_MISSING
    StableWorkflowReconciledPorts:
      type: object
      properties:
        added:
          type: array
          items:
            type: string
          description: Paths that exist on the agent or function but had no port on this
            step.
        removed:
          type: array
          items:
            type: string
          description: Ports whose path no longer exists. They are not shown.
      required:
        - added
        - removed
    StableWorkflowClearedLink:
      type: object
      properties:
        stepID:
          type: string
          description: The step whose port lost its link.
        port:
          type: string
          description: The port key, for example fail or a path ID.
        to:
          nullable: true
          description: The block the path reached before the write, after any actions.
            Null when it reached no block.
          type: string
        actions:
          description: The actions that ran on this exit. They were deleted with the link.
          type: array
          items:
            type: string
      required:
        - stepID
        - port
        - to
  securitySchemes:
    token:
      scheme: bearer
      bearerFormat: JWT
      type: http
      description: Voiceflow bearer token
````
