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

# Get a Pix Schedule

> Retrieve a schedule by its unique identifier. Cross-account lookups return 404 —
existence is never leaked across accounts.



## OpenAPI

````yaml en/openapi/v3-current/indirect-pix.yaml GET /v1/schedules/{schedule_id}
openapi: 3.0.3
info:
  title: Plugin BR Pix Indirect - Complete API
  description: |
    Complete API for Brazilian Pix instant payment system including
    Pix key dictionary operations, QR code generation/decoding, transactions and
    transaction limits.
  version: 1.7.6
servers:
  - url: https://plugin-pix-indirect.api.lerian.net
security:
  - bearerAuth: []
paths:
  /v1/schedules/{schedule_id}:
    get:
      tags:
        - Schedules API
      summary: Get a Pix Schedule
      description: >-
        Retrieve a schedule by its unique identifier. Cross-account lookups
        return 404 —

        existence is never leaked across accounts.
      parameters:
        - name: schedule_id
          in: path
          description: Schedule ID (UUID v7)
          required: true
          schema:
            type: string
          example: 019cf6ef-e418-7ced-80c0-7b9816faa798
        - $ref: '#/components/parameters/XAccountId'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ScheduleOutput'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
        '404':
          description: Not Found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
      security:
        - bearerAuth: []
components:
  parameters:
    XAccountId:
      name: X-Account-Id
      in: header
      description: Unique identifier of the Midaz Ledger Account (UUID format).
      required: true
      example: 019c96a0-0a98-7287-9a31-786e0809c769
      schema:
        type: string
  schemas:
    ScheduleOutput:
      properties:
        accountId:
          description: AccountID echoes the input AccountID for audit / log correlation.
          example: 019cf6ef-e418-7ced-80c0-7b9816faa798
          type: string
        amount:
          description: Amount is the BRL amount with 2 decimal places.
          example: '100.50'
          type: string
        attemptCount:
          description: AttemptCount is the number of fire attempts made so far.
          example: 0
          type: integer
        attempts:
          description: >-
            Attempts is the chronological list of failed prior fire attempts.
            The successful attempt is not included here; it is recorded on the
            schedule itself via its TransferID and EndToEndID. Empty array when
            no failures have been recorded.
          items:
            $ref: '#/components/schemas/ScheduleAttemptOutput'
          type: array
        cancelledAt:
          description: |-
            CancelledAt is the moment the schedule reached CANCELLED. Absent for
            non-CANCELLED rows.
          example: '2026-05-19T09:15:33Z'
          format: date-time
          type: string
        createdAt:
          description: CreatedAt is the persistence timestamp (ISO 8601 UTC).
          example: '2026-05-26T12:30:00Z'
          format: date-time
          type: string
        description:
          description: Description is the optional human-readable transfer message.
          example: Recurring charge installment 03/12
          type: string
        destination:
          allOf:
            - $ref: '#/components/schemas/ScheduleDestination'
          description: Destination is the destination snapshot captured on the schedule.
        endToEndId:
          description: >-
            EndToEndID is the BACEN end-to-end identifier of the settled
            transfer (resolved via TransferID). Absent for non-EXECUTED states.
          example: E1234567820260815060012345678901
          type: string
        executedAt:
          description: |-
            ExecutedAt is the moment the schedule reached EXECUTED. Absent for
            non-EXECUTED rows.
          example: '2026-08-15T06:00:04Z'
          format: date-time
          type: string
        failedAt:
          description: >-
            FailedAt is the moment the schedule reached the terminal FAILED
            state.

            Absent for non-FAILED rows. Symmetric with ExecutedAt / CancelledAt.
          example: '2026-08-15T06:00:04Z'
          format: date-time
          type: string
        failureMessage:
          description: >-
            FailureMessage is the free-text (PII-sanitized) human-readable
            failure

            description. Absent for non-FAILED rows.
          type: string
        failureReason:
          description: |-
            FailureReason categorizes a terminal failure. Snapshot of the latest
            Attempts[] entry's FailureReason. Absent for non-FAILED rows.
          enum:
            - INSUFFICIENT_FUNDS
            - BTG_REJECTED
            - MIDAZ_REJECTED
            - VALIDATION_FAILED
            - SCHEDULE_STALE_TIMEOUT
            - SCHEDULE_RETRIES_EXHAUSTED
          example: INSUFFICIENT_FUNDS
          type: string
        firedAt:
          description: >-
            FiredAt is the most recent dispatch instant. Absent until the
            schedule starts processing (PROCESSING / EXECUTED / FAILED).
          example: '2026-08-15T06:00:04Z'
          format: date-time
          type: string
        id:
          description: ID is the unique schedule identifier (UUID v7, app-generated).
          example: 01989f9e-6508-79f8-9540-835be49fbd0d
          type: string
        initiationId:
          description: >-
            InitiationID is the payment initiation referenced at create time
            (audit anchor). It is never reused at fire time; each fire attempt
            uses its own initiation, surfaced per attempt as
            Attempts[].InitiationID.
          example: 550e8400-e29b-41d4-a716-446655440010
          type: string
        initiationType:
          description: >-
            InitiationType records how the destination was captured (MANUAL,
            KEY,

            QR_CODE).
          enum:
            - MANUAL
            - KEY
            - QR_CODE
          example: MANUAL
          type: string
        maxAttempts:
          description: MaxAttempts is the per-row retry cap accepted at create time.
          example: 2
          type: integer
        recurrenceId:
          description: >-
            RecurrenceID echoes the parent recurrence anchor when the schedule
            was

            created from a recurring flow. Empty for direct POST /v1/schedules
            calls.
          example: 01988a7c-1234-7abc-8def-111122223333
          type: string
        scheduledFor:
          description: ScheduledFor is the wall-clock fire moment (ISO 8601 UTC).
          example: '2026-08-15T09:00:00Z'
          format: date-time
          type: string
        status:
          description: |-
            Status is the schedule lifecycle status. Always SCHEDULED on create.
            Lifecycle: SCHEDULED -> PROCESSING -> EXECUTED | FAILED | CANCELLED.
          enum:
            - SCHEDULED
            - PROCESSING
            - EXECUTED
            - FAILED
            - CANCELLED
          example: SCHEDULED
          type: string
        transferId:
          description: >-
            TransferID is the identifier of the settled transfer. Populated only
            on EXECUTED.
          example: c8d27e3f-4a5b-6c7d-8e9f-0a1b2c3d4e5f
          type: string
        updatedAt:
          description: UpdatedAt is the last status-transition timestamp (ISO 8601 UTC).
          example: '2026-05-26T12:30:00Z'
          format: date-time
          type: string
      type: object
    ErrorFormat:
      type: object
      description: The response message error.
      required:
        - code
        - title
        - message
      properties:
        code:
          type: string
          description: A unique, stable identifier for the error.
        title:
          type: string
          description: A brief summary of the issue.
        message:
          type: string
          description: Detailed guidance for resolving the error.
    ScheduleAttemptOutput:
      properties:
        attemptedAt:
          description: AttemptedAt is the dispatch instant for this attempt (ISO 8601 UTC).
          example: '2026-08-15T06:00:02Z'
          format: date-time
          type: string
        endToEndId:
          description: |-
            EndToEndID is the BACEN end-to-end identifier of the attempt's SPI
            message. Co-present with TransferID.
          example: E1234567820260815060011111111111
          type: string
        failureMessage:
          description: FailureMessage is the human-readable detail (PII-sanitized).
          example: 'Midaz error: balance below required (06:00 BRT attempt)'
          type: string
        failureReason:
          description: FailureReason categorizes the failure.
          enum:
            - INSUFFICIENT_FUNDS
            - BTG_REJECTED
            - MIDAZ_REJECTED
            - VALIDATION_FAILED
            - SCHEDULE_STALE_TIMEOUT
          example: INSUFFICIENT_FUNDS
          type: string
        initiationId:
          description: >-
            InitiationID is the payment initiation used for this attempt
            (created at fire time, not the create-time initiation). Absent when
            the attempt was rejected before a settlement was recorded.
          example: a1111111-1111-4111-8111-111111111111
          type: string
        transferId:
          description: >-
            TransferID is the identifier of the transfer produced by the failed
            fire. Absent when the cashout was rejected before a settlement was
            recorded.
          example: f1a2b3c4-1111-4d5e-9f6a-7b8c9d0e1f23
          type: string
      type: object
    ScheduleDestination:
      properties:
        account:
          allOf:
            - $ref: '#/components/schemas/ScheduleDestinationAccount'
          description: Account holds branch / number / participant ISPB / account type.
        key:
          description: >-
            Key is the Pix key associated with the destination at initiation
            time,

            when the user paid via KEY or QR_CODE. Snapshot only — not used at

            fire time.
          example: john.doe@example.com
          type: string
        owner:
          allOf:
            - $ref: '#/components/schemas/ScheduleDestinationOwner'
          description: |-
            Owner holds the document, name, and optional trade name of the
            destination account holder.
      type: object
    ScheduleDestinationAccount:
      properties:
        branch:
          description: Branch is the bank branch code (typically 4 digits, leading zeros).
          example: '0001'
          type: string
        number:
          description: Number is the account number at the destination institution.
          example: '123456789'
          type: string
        participant:
          description: Participant is the 8-digit ISPB of the destination institution.
          example: '12345678'
          type: string
        type:
          description: 'Type is the account kind: CACC, SVGS, TRAN, OTHR.'
          enum:
            - CACC
            - SVGS
            - TRAN
            - OTHR
          example: CACC
          type: string
      type: object
    ScheduleDestinationOwner:
      properties:
        document:
          description: Document is the owner's CPF (11 digits) or CNPJ (14 digits).
          example: '12345678901'
          type: string
        name:
          description: Name is the full name or registered name of the destination owner.
          example: John Doe
          type: string
        tradeName:
          description: TradeName is the optional business trade name (legal persons only).
          example: John's Business
          type: string
      type: object
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````