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

# Read Settlement Report Export

> Read one settlement report export and retrieve a signed download URL when available.



## OpenAPI

````yaml /api-reference/openapi.yaml get /v1/aggregators/{raast-aggregator-id}/settlements/report-exports/{report-export-id}
openapi: 3.1.0
info:
  title: Raast Wire
  version: 1.0.0
  description: ''
servers:
  - url: https://api.getsafepay.com/raastwire
security: []
tags:
  - name: Aggregators
  - name: Access Keys
  - name: Merchants
  - name: Raast Merchants
  - name: Payments
  - name: Refunds
  - name: QRs
  - name: Utilities
  - name: Aliases
  - name: Ledgers
  - name: Webhooks
paths:
  /v1/aggregators/{raast-aggregator-id}/settlements/report-exports/{report-export-id}:
    get:
      tags:
        - Settlement Reports
      summary: Read Settlement Report Export
      description: >-
        Read one settlement report export and retrieve a signed download URL
        when available.
      parameters:
        - name: aggregator_id
          in: path
          required: true
          description: Aggregator identifier that owns the settlement report exports.
          schema:
            type: string
            example: agg_b49985f2-e099-412e-8eb2-98756059cc0d
        - name: report_export_id
          in: path
          required: true
          description: Settlement report export identifier.
          schema:
            type: string
            example: rpt_7670f587-0396-4939-ba4b-585ca67983a2
      responses:
        '200':
          $ref: '#/components/responses/ReadSettlementReportExportResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
      security:
        - apiKey: []
components:
  responses:
    ReadSettlementReportExportResponse:
      description: Settlement report export job details.
      headers:
        Content-Length:
          $ref: '#/components/headers/ContentLengthHeader'
        Date:
          $ref: '#/components/headers/DateHeader'
      content:
        application/json:
          schema:
            allOf:
              - $ref: '#/components/schemas/StandardResponse'
              - type: object
                properties:
                  data:
                    type: object
                    properties:
                      report_export:
                        $ref: '#/components/schemas/SettlementReportExport'
                      signed_url:
                        type: string
                        description: >-
                          Pre-signed URL for downloading the generated report
                          file.
          examples:
            SettlementReportExportRead:
              value:
                api_version: v1
                data:
                  report_export:
                    id: '58'
                    token: rpt_7670f587-0396-4939-ba4b-585ca67983a2
                    settlement_batch_id: sb_6eb80843-eb2b-4df2-b85f-25d50f03d2a1
                    merchant_id: mer_0e4b3a32-754b-483a-9c85-80581dbef4cf
                    kind: REPORT_KIND_MERCHANT
                    status: REPORT_STATUS_SUCCEEDED
                    attempts: 1
                    error_message: ''
                    s3_key: >-
                      reports/partner_37e414c3-c0cc-4541-9bea-ab5a22964bd8/sb_6eb80843-eb2b-4df2-b85f-25d50f03d2a1/mer_0e4b3a32-754b-483a-9c85-80581dbef4cf/merchant-settlement-report-1775215823-v1.csv
                    record_count: '2'
                    file_size: '1234'
                    started_at: '2026-04-03T11:30:24Z'
                    finished_at: '2026-04-03T11:30:24Z'
                    created_at: '2026-04-03T11:30:09Z'
                    updated_at: '2026-04-03T11:30:24Z'
                    partner_id: partner_37e414c3-c0cc-4541-9bea-ab5a22964bd8
                    version: 1
                  signed_url: >-
                    https://raast-settlement-reports.s3.us-east-1.amazonaws.com/reports/partner_37e414c3-c0cc-4541-9bea-ab5a22964bd8/sb_6eb80843-eb2b-4df2-b85f-25d50f03d2a1/mer_0e4b3a32-754b-483a-9c85-80581dbef4cf/merchant-settlement-report-1775215823-v1.csv?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-SignedHeaders=host&X-Amz-Signature=example
    BadRequest:
      description: Bad request
      headers:
        Content-Length:
          $ref: '#/components/headers/ContentLengthHeader'
        Date:
          $ref: '#/components/headers/DateHeader'
      content:
        application/json:
          schema:
            allOf:
              - $ref: '#/components/schemas/ErrorResponse'
              - type: object
                properties:
                  code:
                    example: error.bad_request
                  message:
                    example: Invalid request parameters
    Unauthorized:
      description: Unauthorized
      headers:
        Content-Length:
          $ref: '#/components/headers/ContentLengthHeader'
        Date:
          $ref: '#/components/headers/DateHeader'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ApiErrorEnvelope'
          examples:
            Unauthorized:
              value:
                api_version: v1
                error:
                  code: error.unauthorized_access
                  message: partner access key is required in request header
    NotFound:
      description: Resource not found
      headers:
        Content-Length:
          $ref: '#/components/headers/ContentLengthHeader'
        Date:
          $ref: '#/components/headers/DateHeader'
      content:
        application/json:
          schema:
            allOf:
              - $ref: '#/components/schemas/ErrorResponse'
              - type: object
                properties:
                  code:
                    example: error.not_found
                  message:
                    example: Requested resource not found
  headers:
    ContentLengthHeader:
      schema:
        type: string
        example: '256'
    DateHeader:
      schema:
        type: string
        example: Sat, 12 Aug 2023 08:55:04 GMT
  schemas:
    StandardResponse:
      type: object
      description: Standard response structure for successful operations
      properties:
        api_version:
          type: string
          example: v1
          description: The current version of the API spec
        data:
          type: object
          description: Contains the response data
    SettlementReportExport:
      type: object
      description: Settlement report export job metadata and processing status.
      properties:
        id:
          type: string
          example: '58'
        token:
          type: string
          example: rpt_7670f587-0396-4939-ba4b-585ca67983a2
        settlement_batch_id:
          type: string
          example: sb_6eb80843-eb2b-4df2-b85f-25d50f03d2a1
        merchant_id:
          type: string
          example: mer_0e4b3a32-754b-483a-9c85-80581dbef4cf
        kind:
          type: string
          example: REPORT_KIND_MERCHANT
        status:
          type: string
          example: REPORT_STATUS_SUCCEEDED
        attempts:
          type: integer
          example: 1
        error_message:
          type: string
          example: ''
        s3_key:
          type: string
          example: >-
            reports/partner_37e414c3-c0cc-4541-9bea-ab5a22964bd8/sb_6eb80843-eb2b-4df2-b85f-25d50f03d2a1/mer_0e4b3a32-754b-483a-9c85-80581dbef4cf/merchant-settlement-report-1775215823-v1.csv
        record_count:
          type: string
          example: '2'
        file_size:
          type: string
          example: '1234'
        started_at:
          allOf:
            - $ref: '#/components/schemas/Timestamp'
          nullable: true
        finished_at:
          allOf:
            - $ref: '#/components/schemas/Timestamp'
          nullable: true
        created_at:
          $ref: '#/components/schemas/Timestamp'
        updated_at:
          $ref: '#/components/schemas/Timestamp'
        partner_id:
          type: string
          example: partner_37e414c3-c0cc-4541-9bea-ab5a22964bd8
        version:
          type: integer
          example: 1
    ErrorResponse:
      type: object
      description: Standard error response structure
      properties:
        code:
          type: string
          description: Error code identifying the type of error
        message:
          type: string
          description: Human-readable error message
    ApiErrorEnvelope:
      type: object
      description: Error wrapper that includes the API version and error metadata
      properties:
        api_version:
          type: string
          description: Indicates the API version associated with the response
          example: v1
        error:
          description: Structured error details describing why the request failed
          allOf:
            - $ref: '#/components/schemas/ErrorResponse'
          example:
            code: error.unauthorized_access
            message: partner access key is required in request header
    Timestamp:
      type: string
      format: date-time
      description: ISO 8601 timestamp in UTC
      example: '2025-03-13T09:12:34.000Z'
  securitySchemes:
    apiKey:
      type: apiKey
      name: X-SFPY-AGGREGATOR-SECRET-KEY
      in: header

````