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

# List payouts

> Payout requests of all affiliates, newest first.

**Permission:** `modules.affiliates.payouts.read`



## OpenAPI

````yaml /docs/modules-api.yaml get /application/modules/affiliates/payouts
openapi: 3.1.0
info:
  title: Spartan Module API
  version: '2026.11'
  description: >-
    Endpoints added by modules. Key endpoints live under
    `/api/application/modules/<module>/` and need an API key with the module
    permission. Content modules (Blog, News, Knowledge Base, Status) also offer
    keyless read only endpoints under `/api/public/modules/<module>/` that only
    return what an anonymous visitor can see.
servers:
  - url: https://{domain}/api
    description: Your Spartan installation
    variables:
      domain:
        default: billing.example.com
        description: Domain of your Spartan installation, without https://
security:
  - bearerAuth: []
tags:
  - name: Blog
  - name: Blog (public)
  - name: News
  - name: News (public)
  - name: Knowledge Base
  - name: Knowledge Base (public)
  - name: Status
  - name: Status (public)
  - name: Forms
  - name: Affiliates
  - name: Deprecated endpoints
paths:
  /application/modules/affiliates/payouts:
    get:
      tags:
        - Affiliates
      summary: List payouts
      description: |-
        Payout requests of all affiliates, newest first.

        **Permission:** `modules.affiliates.payouts.read`
      operationId: listAffiliatePayouts
      parameters:
        - name: status
          in: query
          required: false
          schema:
            type: string
            enum:
              - pending
              - processing
              - completed
              - failed
        - name: affiliate
          in: query
          required: false
          schema:
            type: integer
            minimum: 1
          description: Affiliate id.
        - name: per_page
          in: query
          required: false
          schema:
            type: integer
            default: 25
            minimum: 1
            maximum: 100
          description: Items per page.
        - name: page
          in: query
          required: false
          schema:
            type: integer
            default: 1
            minimum: 1
          description: Page number.
      responses:
        '200':
          description: Success.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/AffiliatePayout'
                  meta:
                    $ref: '#/components/schemas/ListMeta'
                required:
                  - data
                  - meta
              example:
                data:
                  - id: 27
                    reference: 8c94a71a-26f7-4c01-a544-61ce3f675676
                    affiliate:
                      id: 1
                      code: '81719002'
                      user:
                        id: 2
                        name: Alex Morgan
                        email: alex.morgan@example.com
                    amount: 251
                    currency: USD
                    payout_method: credits
                    status: completed
                    admin_notes: null
                    processed_at: '2026-09-05T12:37:53Z'
                    processed_by: null
                    created_at: '2026-09-05T12:37:53Z'
                    updated_at: '2026-09-05T12:37:53Z'
                  - id: 26
                    reference: 590fe45a-a0ee-4735-8e9b-01aa52124e21
                    affiliate:
                      id: 1
                      code: '81719002'
                      user:
                        id: 2
                        name: Alex Morgan
                        email: alex.morgan@example.com
                    amount: 22
                    currency: USD
                    payout_method: credits
                    status: completed
                    admin_notes: null
                    processed_at: '2026-03-14T17:57:14Z'
                    processed_by:
                      id: 2
                      name: Alex Morgan
                    created_at: '2026-03-14T17:57:14Z'
                    updated_at: '2026-03-14T17:57:14Z'
                meta:
                  request_id: 34f201af-ad66-4819-9909-e2d242fba592
                  pagination:
                    current_page: 1
                    per_page: 2
                    total: 4
                    last_page: 2
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '422':
          description: Validation failed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationError'
              examples:
                validation_failed:
                  summary: Invalid input
                  value:
                    error:
                      code: validation_failed
                      message: The request data is invalid.
                      details:
                        per_page:
                          - The per page field must not be greater than 100.
                    request_id: 3f6c2a1e-8b4d-4f7a-9c2e-5d1b7a9e0c42
components:
  schemas:
    AffiliatePayout:
      type: object
      properties:
        id:
          type: integer
        reference:
          type: string
        affiliate:
          type: object
          properties:
            id:
              type: integer
            code:
              type: string
            user:
              type:
                - object
                - 'null'
              properties:
                id:
                  type: integer
                name:
                  type: string
                email:
                  type: string
        amount:
          type: number
        currency:
          type: string
        payout_method:
          type: string
          description: For example `credits`, `paypal`, `bank`.
        status:
          type: string
          enum:
            - pending
            - processing
            - completed
            - failed
        admin_notes:
          type:
            - string
            - 'null'
        processed_at:
          type:
            - string
            - 'null'
          format: date-time
        processed_by:
          type:
            - object
            - 'null'
          properties:
            id:
              type: integer
            name:
              type: string
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
    ListMeta:
      type: object
      properties:
        request_id:
          type: string
          format: uuid
          description: Request id.
        pagination:
          $ref: '#/components/schemas/Pagination'
      required:
        - request_id
        - pagination
    ValidationError:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              enum:
                - validation_failed
              description: Always `validation_failed`.
            message:
              type: string
              description: Always `The request data is invalid.`
            details:
              type: object
              properties: {}
              description: >-
                Map of field name to a list of messages. Nested fields use dot
                notation, for example `ticket_ids.0`.
              additionalProperties:
                type: array
                items:
                  type: string
          required:
            - code
            - message
            - details
        request_id:
          type: string
          format: uuid
          description: Request id.
      description: Returned with HTTP 422 when the body or query string fails validation.
      required:
        - error
        - request_id
    Pagination:
      type: object
      properties:
        current_page:
          type: integer
          description: Current page, starting at 1.
        per_page:
          type: integer
          description: Items per page.
        total:
          type: integer
          description: Total number of matching items.
        last_page:
          type: integer
          description: Last page number.
      required:
        - current_page
        - per_page
        - total
        - last_page
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
              description: >-
                Machine readable error code, for example `unauthorized`,
                `forbidden`, `not_found`, `invalid_service_state`.
            message:
              type: string
              description: Human readable explanation.
            details:
              type: object
              properties: {}
              description: Extra context. An empty object for most errors.
              additionalProperties: true
          required:
            - code
            - message
            - details
        request_id:
          type: string
          format: uuid
          description: >-
            Request id. Also returned in the `X-Request-ID` header. Send your
            own with `X-Request-ID` to correlate logs.
      description: Error envelope returned by every failed request.
      required:
        - error
        - request_id
  responses:
    Unauthorized:
      description: Missing, invalid or inactive API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            missing:
              summary: No Authorization header
              value:
                error:
                  code: unauthorized
                  message: Bearer token required.
                  details: {}
                request_id: 9aca26ca-e06f-4725-8e4b-4385d6c03422
            invalid:
              summary: Unknown or inactive key
              value:
                error:
                  code: unauthorized
                  message: Invalid or inactive token.
                  details: {}
                request_id: 8802a669-6f06-453e-a1d8-0b81621167c3
    Forbidden:
      description: >-
        The key lacks the permission for this endpoint, or the request IP is not
        in the key allow list.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            forbidden:
              summary: Missing permission
              value:
                error:
                  code: forbidden
                  message: Insufficient permissions for this action.
                  details: {}
                request_id: 6bf04242-ac61-44b9-9dbf-b63a114b54c8
            ip_not_allowed:
              summary: IP not allowed
              value:
                error:
                  code: ip_not_allowed
                  message: Access denied from this IP address.
                  details: {}
                request_id: 3f6c2a1e-8b4d-4f7a-9c2e-5d1b7a9e0c42
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key created in Admin, API. Send it as `Authorization: Bearer <key>`.
        Each key has its own permissions and optional IP allow list.

````

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