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

# Preview a structure change

> <Warning>
  **Coming soon.** This endpoint will be available by mid November 2026.
</Warning>

<small>_Requires the `ai-sdr:read` scope (or a broader one that includes it)._</small>

See what setting a sequence structure would change, without changing anything.

The preview lists the current steps that `PUT /v3/sequences/ai-sdr/{sequence_id}/structure` archives or removes, the steps it adds, and the contacts affected. The `structureStepId` values in `stepsToAdd` are the valid values of `inProgressContactsTargetStepId`.



## OpenAPI

````yaml /api-reference/bundled.yaml get /v3/sequences/ai-sdr/{sequence_id}/structure/migration-preview
openapi: 3.1.0
info:
  version: 3.0.0
  title: Reply API
  description: API for managing email sequences, contacts, and automation workflows
servers:
  - url: https://api.reply.io
security:
  - bearerAuth: []
tags:
  - name: Contacts
    description: Manage individual contacts
  - name: Contact Lists
    description: Manage contact lists and contact membership
  - name: Accounts
    description: Manage accounts (companies/organizations)
  - name: Account Lists
    description: Manage account lists and account membership
  - name: Custom Fields
    description: Manage custom contact fields
  - name: Prompt Actions
    description: Save reusable AI prompts and run them on contacts to fill custom fields
  - name: Contact Blacklist Rules
    description: Manage blacklist rules for domains, emails, and email exceptions
  - name: Live Data
    description: >-
      Find new contacts via Live Data searches and read typeahead values for the
      Live Data / Autopilot filter sidebar
  - name: Contact Enrichment
    description: >-
      Enrich contacts with emails, phone numbers, LinkedIn data, and AI-filled
      custom fields
  - name: Email Validations
    description: Estimate and schedule asynchronous email validation jobs
  - name: AI SDR Web Search
    description: Find contacts via AI-driven web search and review past searches
  - name: Sequences
    description: Manage email automation sequences
  - name: Sequence Steps
    description: Manage individual steps in sequences
  - name: Sequence Contacts
    description: Manage contacts within sequences
  - name: Sequence Folders
    description: Organize sequences into folders
  - name: Email Accounts
    description: Manage email accounts used for sending and receiving
  - name: Sequence Email Accounts
    description: Manage email accounts linked to sequences
  - name: LinkedIn Accounts
    description: Manage LinkedIn accounts for outreach
  - name: Sequence LinkedIn Accounts
    description: Manage LinkedIn accounts linked to sequences
  - name: Sequence Templates
    description: Manage sequence templates
  - name: Email Templates
    description: Manage email templates and template folders
  - name: Voices
    description: Manage cloned voices used for AI voice message steps
  - name: Schedules
    description: Manage email send schedules and timing
  - name: Holiday Calendars
    description: Manage holiday calendars for scheduling
  - name: Inbox
    description: >-
      Manage inbox threads — list/filter, read state, replies, category
      assignment, and meeting-intent flagging
  - name: Inbox Categories
    description: Manage per-team inbox thread categories and assign threads to them
  - name: Direct Outreach
    description: >-
      Send one-off outreach directly to a contact outside of any sequence —
      direct emails and LinkedIn connection requests, messages, InMails, and
      voice messages
  - name: Tasks
    description: Manage tasks and to-do items
  - name: Reports
    description: >-
      Generate and access performance reports across email, calls, tasks,
      LinkedIn, and team performance
  - name: AI SDR Sequences
    description: >-
      Manage AI SDR sequences and their AI SDR-specific settings — create, read
      settings, partial update, autopilot enable/disable/force-start, approval
      mode, sequence structure, and playbook/knowledge-base connections
  - name: AI SDR Sequence Structures
    description: >-
      Browse the sequence structures — reusable outlines of AI SDR sequence
      steps — that can be applied to AI SDR sequences
  - name: AI SDR Strategist
    description: Trigger AI Strategist runs
  - name: AI SDR Playbooks
    description: >-
      Manage AI SDR playbooks — tone, voice, and style guides applied during
      personalized message generation
  - name: AI SDR Knowledge Bases
    description: >-
      Manage AI SDR knowledge bases — collections of documents, links, reply
      handlers, and reengagement cards that inform the agent's responses
  - name: AI SDR Offers
    description: >-
      Manage AI SDR offers — bundles of company-context inputs (ICP, pain
      points, value propositions, etc.) used to personalize outreach
  - name: AI SDR Pending Approvals
    description: >-
      Review, send, regenerate, and provide feedback on AI-generated messages
      awaiting human approval
  - name: AI SDR Sequence Preview
    description: >-
      Read and regenerate per-contact previews of the messages a sequence will
      send, and provide feedback on preview messages
  - name: AI SDR Insights
    description: Read AI SDR insights for sequence contacts
  - name: AI SDR Intent Signals
    description: >-
      Read Reply industry IDs and technology slugs used in AI SDR intent-signal
      configuration (typeahead)
  - name: AI Prompts
    description: >-
      Manage the AI prompts used to configure sequence steps, and preview the
      output a prompt produces
  - name: AI SDR Learnings
    description: >-
      Manage the standing rules that shape how the AI writes — list, read,
      create, partially update and delete AI learnings
  - name: Registration
    description: Register the contact that domain purchases are filed under
  - name: Domains
    description: Find domains available to buy for outreach
  - name: Purchased Domains
    description: >-
      List the domains your team bought, with their subscription, setup and
      renewal state, and renew them
  - name: Pre-warmed Domains
    description: >-
      Find pre-warmed domains on sale, with mailboxes that are already warming,
      and list the ones your team bought
  - name: Mailboxes
    description: >-
      Add mailboxes to domains your team already bought, priced before you
      order, and reconnect them
  - name: User Account
    description: Account information and authentication verification
  - name: API Keys
    description: Create, list, edit and delete API keys, as the Settings page does
  - name: Teams
    description: Add existing users of your organization to its teams
  - name: Settings
    description: Manage team and user settings
  - name: Billing
    description: Subscription details and monthly active contacts usage
  - name: Rate Limits
    description: Your API rate limits, your current usage and the packages that raise them
  - name: Support Requests
    description: Raise and follow support requests with Reply's support team
  - name: Webhooks
    description: Manage webhook subscriptions and inspect delivery history
  - name: Background Jobs
    description: >-
      Track and cancel asynchronous background operations (e.g., email
      validation)
  - name: Attachments
    description: >-
      Upload file attachments used across email templates, sequence steps, and
      direct emails
paths:
  /v3/sequences/ai-sdr/{sequence_id}/structure/migration-preview:
    get:
      tags:
        - AI SDR Sequences
      summary: Preview a structure change
      description: >-
        <Warning>
          **Coming soon.** This endpoint will be available by mid November 2026.
        </Warning>


        <small>_Requires the `ai-sdr:read` scope (or a broader one that includes
        it)._</small>


        See what setting a sequence structure would change, without changing
        anything.


        The preview lists the current steps that `PUT
        /v3/sequences/ai-sdr/{sequence_id}/structure` archives or removes, the
        steps it adds, and the contacts affected. The `structureStepId` values
        in `stepsToAdd` are the valid values of
        `inProgressContactsTargetStepId`.
      operationId: GetAiSdrSequenceStructureMigrationPreview
      parameters:
        - name: sequence_id
          in: path
          required: true
          description: Sequence id
          schema:
            type: integer
            minimum: 1
        - name: structure_id
          in: query
          required: true
          description: >-
            Id of the structure to preview: `g-{number}` for library structures,
            `c-{number}` for structures saved by users (e.g. `g-3`, `c-128`).
          schema:
            type: string
            minLength: 1
      responses:
        '200':
          description: Structure change preview
          content:
            application/json:
              schema:
                type: object
                title: Sequence structure change preview
                description: >-
                  What applying a sequence structure to an AI SDR sequence
                  changes
                properties:
                  isMigrationEnabled:
                    type: boolean
                    description: >-
                      `true` when structure changes after sending are enabled
                      for your account, so the structure of a sequence with used
                      steps can be changed.
                  hasUsedSteps:
                    type: boolean
                    description: >-
                      `true` once any step of the sequence has been used: a
                      contact has passed it, it has created a task, or a message
                      from it is waiting to be sent.
                  stepsToArchive:
                    type: array
                    description: >-
                      Current steps that are archived: the used steps and the
                      steps leading to them. Archived steps stay in the
                      sequence's history. Ordered by step number.
                    items:
                      type: object
                      title: Sequence structure change — current step
                      description: >-
                        A current step of the sequence that a structure change
                        archives or removes
                      properties:
                        id:
                          type: integer
                          description: Step id
                          readOnly: true
                          example: 90211
                        number:
                          type: integer
                          description: Step number in the sequence
                          example: 1
                        type:
                          type: string
                          description: Step type
                          enum:
                            - email
                            - linkedIn
                            - call
                            - sms
                            - whatsApp
                            - zapier
                            - task
                            - condition
                            - moveToSequence
                            - merge
                          example: email
                        linkedInActionType:
                          type: string
                          nullable: true
                          description: >-
                            LinkedIn action of a `linkedIn` step. `null` for
                            other step types.
                          enum:
                            - inMail
                            - message
                            - connect
                            - viewProfile
                            - endorseSkills
                            - likeRecentPosts
                            - followProfile
                            - voiceMessage
                            - aiVoiceMessage
                            - commentOnRecentPost
                        displayName:
                          type: string
                          description: Step name as shown in the sequence
                          example: Email 1
                  stepsToDelete:
                    type: array
                    description: >-
                      Current steps that are removed because no contact has used
                      them. Ordered by step number.
                    items:
                      type: object
                      title: Sequence structure change — current step
                      description: >-
                        A current step of the sequence that a structure change
                        archives or removes
                      properties:
                        id:
                          type: integer
                          description: Step id
                          readOnly: true
                          example: 90211
                        number:
                          type: integer
                          description: Step number in the sequence
                          example: 1
                        type:
                          type: string
                          description: Step type
                          enum:
                            - email
                            - linkedIn
                            - call
                            - sms
                            - whatsApp
                            - zapier
                            - task
                            - condition
                            - moveToSequence
                            - merge
                          example: email
                        linkedInActionType:
                          type: string
                          nullable: true
                          description: >-
                            LinkedIn action of a `linkedIn` step. `null` for
                            other step types.
                          enum:
                            - inMail
                            - message
                            - connect
                            - viewProfile
                            - endorseSkills
                            - likeRecentPosts
                            - followProfile
                            - voiceMessage
                            - aiVoiceMessage
                            - commentOnRecentPost
                        displayName:
                          type: string
                          description: Step name as shown in the sequence
                          example: Email 1
                  stepsToAdd:
                    type: array
                    description: Steps of the new structure, in the structure's order
                    items:
                      type: object
                      title: Sequence structure change — new step
                      description: >-
                        A step of the new structure that a structure change adds
                        to the sequence
                      properties:
                        structureStepId:
                          type: integer
                          description: >-
                            Id of the step within the structure. Pass it as
                            `inProgressContactsTargetStepId` to move contacts in
                            progress to this step.
                          example: 2
                        type:
                          type: string
                          description: Step type
                          enum:
                            - email
                            - linkedIn
                            - call
                            - sms
                            - whatsApp
                            - zapier
                            - task
                            - condition
                            - moveToSequence
                            - merge
                          example: email
                        linkedInActionType:
                          type: string
                          nullable: true
                          description: >-
                            LinkedIn action of a `linkedIn` step. `null` for
                            other step types.
                          enum:
                            - inMail
                            - message
                            - connect
                            - viewProfile
                            - endorseSkills
                            - likeRecentPosts
                            - followProfile
                            - voiceMessage
                            - aiVoiceMessage
                            - commentOnRecentPost
                        delayInMinutes:
                          type: integer
                          description: >-
                            Delay before the step starts. For a `condition`
                            step, how long it waits before evaluating.
                          example: 1440
                  contacts:
                    type: object
                    title: Sequence structure change — contacts
                    description: >-
                      Contacts and pending work of the sequence that a structure
                      change affects
                    properties:
                      inProgress:
                        type: integer
                        description: >-
                          Contacts on a step of the sequence that have not
                          finished it and are not paused: active, out-of-office
                          and missing-data contacts. The chosen
                          `inProgressContactsMode` applies to them; an
                          out-of-office contact keeps waiting on its new step
                          until its out-of-office period ends.
                        example: 128
                      paused:
                        type: integer
                        description: >-
                          Paused contacts on a step of the sequence. The chosen
                          `inProgressContactsMode` applies to them too;
                          `restart` and `moveToStep` keep them paused on their
                          new step.
                        example: 4
                      pendingApprovals:
                        type: integer
                        description: >-
                          Generated messages on the current steps waiting for
                          approval
                        example: 7
                      openTasks:
                        type: integer
                        description: Open tasks of the sequence's contacts
                        example: 3
                      notAffected:
                        type: integer
                        description: Contacts that have already finished the sequence
                        example: 310
                  snapshotName:
                    type: string
                    description: >-
                      Name the current steps are saved under when the structure
                      is set with `saveCurrentStructure`
                    example: Acme outbound – before 2026-11-05
        '400':
          description: >-
            Missing `structure_id`, invalid structure id format, structure not
            found, or sequence is not an AI SDR sequence.
          content:
            application/problem+json:
              schema:
                oneOf:
                  - allOf:
                      - allOf:
                          - type: object
                            title: Problem Details
                            description: >-
                              Bare RFC 9457 problem-details envelope. Returned
                              by middleware-level errors

                              that don't carry domain context: 401 Unauthorized
                              (auth middleware),

                              429 Too Many Requests (rate-limit middleware), and
                              route-level 404 / 405 /

                              415 (framework middleware).


                              Business and validation responses extend this
                              envelope and add additional

                              fields — see `business-problem.model.yaml` (adds
                              `code` slug) and

                              `validation-problem.model.yaml` (adds `errors[]`
                              array).
                            properties:
                              title:
                                type: string
                                description: Short, human-readable summary of the problem.
                              status:
                                type: integer
                                description: HTTP status code.
                                minimum: 100
                                maximum: 599
                              detail:
                                type: string
                                description: >-
                                  Human-readable explanation specific to this
                                  occurrence.
                          - type: object
                            properties:
                              errors:
                                type: array
                                description: >-
                                  List of field-level validation errors. Always
                                  non-empty when this

                                  envelope is returned. Each entry pins a single
                                  offending field

                                  via JSON Pointer plus a sanitized detail
                                  string.
                                items:
                                  type: object
                                  title: Validation Error
                                  description: A single field-level validation error.
                                  properties:
                                    pointer:
                                      type: string
                                      description: >-
                                        JSON Pointer (RFC 6901) to the offending
                                        field — e.g.

                                        `/steps/0/subject`.


                                        * An empty string (`""`) means the error
                                        applies to the whole
                                          request body (e.g. body is missing or unparseable).
                                        * For route or query parameter failures
                                        the pointer is the parameter
                                          name (e.g. `id`, `top`).
                                      example: /steps/0/subject
                                    detail:
                                      type: string
                                      description: >-
                                        Sanitized, human-readable explanation of
                                        this field's error. One of a

                                        small set of templates — `"Field is
                                        required."`, `"Value has an

                                        invalid type."`, `"Value has an invalid
                                        format."`, `"Request body is

                                        not valid JSON."`, `"The request body is
                                        required and cannot be

                                        empty."` — or a FluentValidator message
                                        on body endpoints.
                                      example: Field is required.
                        title: Validation Problem
                        description: >-
                          Input-validation error response at 400. Returned when
                          the request body

                          fails binding, FluentValidator rules, or when
                          route/query parameter

                          attribute validation (`[Range]`, `[Required]`) fails.
                          Route, query, and

                          body errors are combined into a single `errors[]`
                          array — clients should

                          not assume one error per request.
                      - example:
                          title: Validation failed
                          status: 400
                          detail: The request body contains validation errors.
                          errors:
                            - pointer: /name
                              detail: Field is required.
                  - allOf:
                      - allOf:
                          - type: object
                            title: Problem Details
                            description: >-
                              Bare RFC 9457 problem-details envelope. Returned
                              by middleware-level errors

                              that don't carry domain context: 401 Unauthorized
                              (auth middleware),

                              429 Too Many Requests (rate-limit middleware), and
                              route-level 404 / 405 /

                              415 (framework middleware).


                              Business and validation responses extend this
                              envelope and add additional

                              fields — see `business-problem.model.yaml` (adds
                              `code` slug) and

                              `validation-problem.model.yaml` (adds `errors[]`
                              array).
                            properties:
                              title:
                                type: string
                                description: Short, human-readable summary of the problem.
                              status:
                                type: integer
                                description: HTTP status code.
                                minimum: 100
                                maximum: 599
                              detail:
                                type: string
                                description: >-
                                  Human-readable explanation specific to this
                                  occurrence.
                          - type: object
                            properties:
                              code:
                                type: string
                                description: >-
                                  Stable, machine-readable error slug in the
                                  form

                                  `"<resource>.<variant>"`.


                                  * `resource` is the camelCased domain — e.g.
                                  `sequence`,
                                    `contact`, `inboxThread`, `blacklistDomainRule`.
                                  * `variant` is the camelCased specific failure
                                  mode — e.g.
                                    `notFound`, `forbidden`, `duplicateName`, `globalRuleReadOnly`.

                                  Use `code` for programmatic error handling;
                                  use `detail` for

                                  user-facing messages. Slugs are stable across
                                  server-side enum

                                  reorderings and never change meaning under a
                                  given resource.
                                pattern: ^[a-z][a-zA-Z0-9]*(\.[a-z][a-zA-Z0-9]*)+$
                                example: sequence.notFound
                        title: Business Problem
                        description: >-
                          Domain error response carrying a stable, namespaced
                          error slug.

                          Emitted for most 4xx responses (business 400, 403,
                          404, 409, …) and

                          for 503 when a downstream dependency is unavailable.
                      - example:
                          title: Bad Request
                          status: 400
                          detail: Pagination parameters are invalid.
                          code: sequence.invalidPagination
              examples:
                invalid_id_format:
                  summary: Structure id is malformed
                  value:
                    title: Bad Request
                    status: 400
                    detail: >-
                      Sequence structure id 'x-1' is invalid. Expected
                      'g-{number}' or 'c-{number}'.
                    code: sequenceStructure.invalidIdFormat
                invalid_structure:
                  summary: Structure not found
                  value:
                    title: Bad Request
                    status: 400
                    detail: Sequence structure 'c-128' not found.
                    code: sequenceStructure.invalidStructure
                not_ai_sdr:
                  summary: Sequence is not an AI SDR sequence
                  value:
                    title: Bad Request
                    status: 400
                    detail: Sequence '4821' is not an AI SDR sequence.
                    code: sequenceStructure.invalidParameter
        '401':
          description: >-
            Unauthorized. The response body is empty; check the
            `WWW-Authenticate` header for the expected scheme.
          content:
            application/problem+json:
              schema:
                allOf:
                  - type: object
                    title: Problem Details
                    description: >-
                      Bare RFC 9457 problem-details envelope. Returned by
                      middleware-level errors

                      that don't carry domain context: 401 Unauthorized (auth
                      middleware),

                      429 Too Many Requests (rate-limit middleware), and
                      route-level 404 / 405 /

                      415 (framework middleware).


                      Business and validation responses extend this envelope and
                      add additional

                      fields — see `business-problem.model.yaml` (adds `code`
                      slug) and

                      `validation-problem.model.yaml` (adds `errors[]` array).
                    properties:
                      title:
                        type: string
                        description: Short, human-readable summary of the problem.
                      status:
                        type: integer
                        description: HTTP status code.
                        minimum: 100
                        maximum: 599
                      detail:
                        type: string
                        description: >-
                          Human-readable explanation specific to this
                          occurrence.
                  - example:
                      title: Unauthorized
                      status: 401
                      detail: Authentication credentials are missing or invalid.
        '403':
          description: >-
            AI SDR feature is not available for the caller's team, or the caller
            cannot manage this sequence.
          content:
            application/problem+json:
              schema:
                allOf:
                  - allOf:
                      - type: object
                        title: Problem Details
                        description: >-
                          Bare RFC 9457 problem-details envelope. Returned by
                          middleware-level errors

                          that don't carry domain context: 401 Unauthorized
                          (auth middleware),

                          429 Too Many Requests (rate-limit middleware), and
                          route-level 404 / 405 /

                          415 (framework middleware).


                          Business and validation responses extend this envelope
                          and add additional

                          fields — see `business-problem.model.yaml` (adds
                          `code` slug) and

                          `validation-problem.model.yaml` (adds `errors[]`
                          array).
                        properties:
                          title:
                            type: string
                            description: Short, human-readable summary of the problem.
                          status:
                            type: integer
                            description: HTTP status code.
                            minimum: 100
                            maximum: 599
                          detail:
                            type: string
                            description: >-
                              Human-readable explanation specific to this
                              occurrence.
                      - type: object
                        properties:
                          code:
                            type: string
                            description: >-
                              Stable, machine-readable error slug in the form

                              `"<resource>.<variant>"`.


                              * `resource` is the camelCased domain — e.g.
                              `sequence`,
                                `contact`, `inboxThread`, `blacklistDomainRule`.
                              * `variant` is the camelCased specific failure
                              mode — e.g.
                                `notFound`, `forbidden`, `duplicateName`, `globalRuleReadOnly`.

                              Use `code` for programmatic error handling; use
                              `detail` for

                              user-facing messages. Slugs are stable across
                              server-side enum

                              reorderings and never change meaning under a given
                              resource.
                            pattern: ^[a-z][a-zA-Z0-9]*(\.[a-z][a-zA-Z0-9]*)+$
                            example: sequence.notFound
                    title: Business Problem
                    description: >-
                      Domain error response carrying a stable, namespaced error
                      slug.

                      Emitted for most 4xx responses (business 400, 403, 404,
                      409, …) and

                      for 503 when a downstream dependency is unavailable.
                  - example:
                      title: Forbidden
                      status: 403
                      detail: You do not have permission to access this resource.
                      code: sequence.forbidden
              example:
                title: Forbidden
                status: 403
                detail: AI SDR feature is not available for your team.
                code: sequenceStructure.forbidden
        '404':
          description: Sequence not found.
          content:
            application/problem+json:
              schema:
                allOf:
                  - allOf:
                      - type: object
                        title: Problem Details
                        description: >-
                          Bare RFC 9457 problem-details envelope. Returned by
                          middleware-level errors

                          that don't carry domain context: 401 Unauthorized
                          (auth middleware),

                          429 Too Many Requests (rate-limit middleware), and
                          route-level 404 / 405 /

                          415 (framework middleware).


                          Business and validation responses extend this envelope
                          and add additional

                          fields — see `business-problem.model.yaml` (adds
                          `code` slug) and

                          `validation-problem.model.yaml` (adds `errors[]`
                          array).
                        properties:
                          title:
                            type: string
                            description: Short, human-readable summary of the problem.
                          status:
                            type: integer
                            description: HTTP status code.
                            minimum: 100
                            maximum: 599
                          detail:
                            type: string
                            description: >-
                              Human-readable explanation specific to this
                              occurrence.
                      - type: object
                        properties:
                          code:
                            type: string
                            description: >-
                              Stable, machine-readable error slug in the form

                              `"<resource>.<variant>"`.


                              * `resource` is the camelCased domain — e.g.
                              `sequence`,
                                `contact`, `inboxThread`, `blacklistDomainRule`.
                              * `variant` is the camelCased specific failure
                              mode — e.g.
                                `notFound`, `forbidden`, `duplicateName`, `globalRuleReadOnly`.

                              Use `code` for programmatic error handling; use
                              `detail` for

                              user-facing messages. Slugs are stable across
                              server-side enum

                              reorderings and never change meaning under a given
                              resource.
                            pattern: ^[a-z][a-zA-Z0-9]*(\.[a-z][a-zA-Z0-9]*)+$
                            example: sequence.notFound
                    title: Business Problem
                    description: >-
                      Domain error response carrying a stable, namespaced error
                      slug.

                      Emitted for most 4xx responses (business 400, 403, 404,
                      409, …) and

                      for 503 when a downstream dependency is unavailable.
                  - example:
                      title: Not Found
                      status: 404
                      detail: The requested resource was not found.
                      code: sequence.notFound
              example:
                title: Not Found
                status: 404
                detail: Sequence '4821' not found.
                code: sequenceStructure.notFound
        '409':
          description: The sequence is archived.
          content:
            application/problem+json:
              schema:
                allOf:
                  - allOf:
                      - type: object
                        title: Problem Details
                        description: >-
                          Bare RFC 9457 problem-details envelope. Returned by
                          middleware-level errors

                          that don't carry domain context: 401 Unauthorized
                          (auth middleware),

                          429 Too Many Requests (rate-limit middleware), and
                          route-level 404 / 405 /

                          415 (framework middleware).


                          Business and validation responses extend this envelope
                          and add additional

                          fields — see `business-problem.model.yaml` (adds
                          `code` slug) and

                          `validation-problem.model.yaml` (adds `errors[]`
                          array).
                        properties:
                          title:
                            type: string
                            description: Short, human-readable summary of the problem.
                          status:
                            type: integer
                            description: HTTP status code.
                            minimum: 100
                            maximum: 599
                          detail:
                            type: string
                            description: >-
                              Human-readable explanation specific to this
                              occurrence.
                      - type: object
                        properties:
                          code:
                            type: string
                            description: >-
                              Stable, machine-readable error slug in the form

                              `"<resource>.<variant>"`.


                              * `resource` is the camelCased domain — e.g.
                              `sequence`,
                                `contact`, `inboxThread`, `blacklistDomainRule`.
                              * `variant` is the camelCased specific failure
                              mode — e.g.
                                `notFound`, `forbidden`, `duplicateName`, `globalRuleReadOnly`.

                              Use `code` for programmatic error handling; use
                              `detail` for

                              user-facing messages. Slugs are stable across
                              server-side enum

                              reorderings and never change meaning under a given
                              resource.
                            pattern: ^[a-z][a-zA-Z0-9]*(\.[a-z][a-zA-Z0-9]*)+$
                            example: sequence.notFound
                    title: Business Problem
                    description: >-
                      Domain error response carrying a stable, namespaced error
                      slug.

                      Emitted for most 4xx responses (business 400, 403, 404,
                      409, …) and

                      for 503 when a downstream dependency is unavailable.
                  - example:
                      title: Conflict
                      status: 409
                      detail: A resource with this name already exists.
                      code: sequence.duplicateName
              example:
                title: Conflict
                status: 409
                detail: >-
                  Sequence 4821 is archived; reactivate it before changing its
                  structure.
                code: sequenceStructure.sequenceArchived
        '502':
          description: Upstream AI SDR service failure.
          content:
            application/problem+json:
              schema:
                allOf:
                  - allOf:
                      - type: object
                        title: Problem Details
                        description: >-
                          Bare RFC 9457 problem-details envelope. Returned by
                          middleware-level errors

                          that don't carry domain context: 401 Unauthorized
                          (auth middleware),

                          429 Too Many Requests (rate-limit middleware), and
                          route-level 404 / 405 /

                          415 (framework middleware).


                          Business and validation responses extend this envelope
                          and add additional

                          fields — see `business-problem.model.yaml` (adds
                          `code` slug) and

                          `validation-problem.model.yaml` (adds `errors[]`
                          array).
                        properties:
                          title:
                            type: string
                            description: Short, human-readable summary of the problem.
                          status:
                            type: integer
                            description: HTTP status code.
                            minimum: 100
                            maximum: 599
                          detail:
                            type: string
                            description: >-
                              Human-readable explanation specific to this
                              occurrence.
                      - type: object
                        properties:
                          code:
                            type: string
                            description: >-
                              Stable, machine-readable error slug in the form

                              `"<resource>.<variant>"`.


                              * `resource` is the camelCased domain — e.g.
                              `sequence`,
                                `contact`, `inboxThread`, `blacklistDomainRule`.
                              * `variant` is the camelCased specific failure
                              mode — e.g.
                                `notFound`, `forbidden`, `duplicateName`, `globalRuleReadOnly`.

                              Use `code` for programmatic error handling; use
                              `detail` for

                              user-facing messages. Slugs are stable across
                              server-side enum

                              reorderings and never change meaning under a given
                              resource.
                            pattern: ^[a-z][a-zA-Z0-9]*(\.[a-z][a-zA-Z0-9]*)+$
                            example: sequence.notFound
                    title: Business Problem
                    description: >-
                      Domain error response carrying a stable, namespaced error
                      slug.

                      Emitted for most 4xx responses (business 400, 403, 404,
                      409, …) and

                      for 503 when a downstream dependency is unavailable.
                  - example:
                      title: Bad Request
                      status: 400
                      detail: Pagination parameters are invalid.
                      code: sequence.invalidPagination
              example:
                title: Bad Gateway
                status: 502
                detail: 'Upstream service failure: Service unavailable.'
                code: sequenceStructure.upstreamFailure
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Authenticate every request with a Bearer token. Pass your Reply API key
        in the

        `Authorization` header:


        ```

        Authorization: Bearer <your-api-key>

        ```


        Get your API key from the Reply dashboard: **Settings → API Key**.

````

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