# Get submerchant commission invoices

Endpoint: GET /flow/{flowServiceId}/submerchants/{submerchantId}/finances/invoices
Version: 1.0.0
Security: bearerAuth

## Security:

  - `bearerAuth` (unknown)
    http bearer scopes: flow.submerchants.finances, flow.submerchants.finances.invoices

## Path parameters:

  - `flowServiceId` (string, required)
    Flow service ID

  - `submerchantId` (string, required)
    Submerchant ID (`flsm_...`) or its `customId`

## Query parameters:

  - `page` (integer)
    Page number (15 records per page)

## Response 200 fields (application/json):

  - `success` (boolean, required)
    Request status

  - `data` (array, required)

  - `data.period` (string)
    Settlement period (MM/YYYY)
    Example: 09/2026

  - `data.year` (integer)
    Example: 2026

  - `data.month` (integer)
    Example: 9

  - `data.totalTransactions` (number)
    Total transactions in the period

  - `data.totalCommission` (number)
    Total commission in the period

  - `data.invoiceUrl` (string)
    Invoice URL

  - `data.currencyRate` (number)
    Currency rate

  - `data.createdAt` (string)
    Creation date in format: ISO 8601

  - `data.wallet` (object)

  - `data.wallet.id` (string)

  - `data.wallet.type` (object)

  - `data.wallet.type.id` (string)
    Example: payment

  - `data.wallet.type.name` (string)

  - `data.wallet.currencyCode` (string)
    Example: PLN

  - `pagination` (object, required)

  - `pagination.total` (integer, required)
    Total number of records
    Example: 1

  - `pagination.count` (integer, required)
    Number of records on the current page
    Example: 1

  - `pagination.per_page` (integer, required)
    Maximum number of records per page
    Example: 15

  - `pagination.current_page` (integer, required)
    Current page
    Example: 1

  - `pagination.total_pages` (integer, required)
    Total number of pages
    Example: 1

  - `pagination.links` (object, required)
    URLs to pages

  - `pagination.links.next_page` (string, required)
    URL to the next page
    Example: null

  - `pagination.links.prev_page` (string, required)
    URL to the previous page
    Example: null

## Response 401:

  - `401` (unknown)
    Unauthorized

## Response 401 fields (application/json):

  - `feedbackUrl` (string)
    URL for reporting API problems (`POST /feedback`). Returned for authenticated API keys.
    Example: https://api.simpay.pl/feedback

  - `success` (boolean, required)
    Request status

  - `errorCode` (string, required)
    Error status code
    Enum: "UNAUTHORIZED"

## Response 403:

  - `403` (unknown)
    Forbidden

## Response 403 fields (application/json):

  - `feedbackUrl` (string)
    URL for reporting API problems (`POST /feedback`). Returned for authenticated API keys.
    Example: https://api.simpay.pl/feedback

  - `success` (boolean, required)
    Request status

  - `errorCode` (string, required)
    Error status code
    Enum: "INVALID_ABILITY_PROVIDED", "IP_ADDRESS_NOT_WHITELISTED"

## Response 404:

  - `404` (unknown)
    Submerchant not found (`FLOW_SUBMERCHANT_NOT_FOUND`)

## Response 404 fields (application/json):

  - `success` (boolean, required)
    Request status

  - `message` (string)
    Error description

  - `errorCode` (string, required)
    Error code

