> ## 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.

# Retrieve Reports

> Use this endpoint to retrieve reports that have been created before.



## OpenAPI

````yaml /en/openapi/v3-current/reporter.yaml get /v1/reports
openapi: 3.1.0
info:
  title: Reporter
  description: ''
  version: 1.2.0
servers:
  - url: https://reporter.sandbox.lerian.net
security: []
tags: []
paths:
  /v1/reports:
    get:
      tags:
        - Reports API
      summary: Retrieve Reports
      description: Use this endpoint to retrieve reports that have been created before.
      parameters:
        - name: page
          in: query
          description: Page number to be returned.
          required: false
          example: 0
          schema:
            type: integer
        - name: limit
          in: query
          description: Number of records returned.
          required: false
          example: 1
          schema:
            type: integer
        - name: status
          in: query
          description: >-
            The processing status of the report. Allowed values: Processing,
            Finished, Error.
          required: false
          schema:
            type: string
        - name: templateId
          in: query
          description: The identifier of the template.
          required: false
          schema:
            type: string
        - name: createdAt
          in: query
          description: Date and time when the report was created.
          required: false
          schema:
            type: string
        - $ref: '#/components/parameters/Authorization'
        - $ref: '#/components/parameters/XOrganizationId'
      responses:
        '200':
          description: The list of reports in the system.
          content:
            application/json:
              schema:
                type: object
                properties:
                  items:
                    type: array
                    items:
                      $ref: '#/components/schemas/DownloadResponse'
              example:
                items:
                  - id: 0196b268-620d-7d09-afa3-85e4d5369eg3
                    templateId: 0196b264-24d4-7e0b-ad5c-9028cc05138d
                    filters: null
                    status: Processing
                    completedAt: '2025-05-09T00:18:27.507Z'
                    createdAt: '2025-05-09T00:18:27.469Z'
                    updatedAt: '2025-05-09T00:18:27.469Z'
                    deletedAt: null
          headers: {}
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                Error0004:
                  $ref: '#/components/examples/Error0004'
                Error0009:
                  $ref: '#/components/examples/Error0009'
                Error0011:
                  $ref: '#/components/examples/Error0011'
                Error0015:
                  $ref: '#/components/examples/Error0015'
                Error0016:
                  $ref: '#/components/examples/Error0016'
                Error0017:
                  $ref: '#/components/examples/Error0017'
                Error0018:
                  $ref: '#/components/examples/Error0018'
                Error0019:
                  $ref: '#/components/examples/Error0019'
      security: []
components:
  parameters:
    Authorization:
      name: Authorization
      in: header
      description: >-
        The authorization token in the 'Bearer <token>' format.  


        **Important:** This header is required if your environment has Access
        Manager enabled. For more information, refer to the [Access
        Manager](/en/access-manager) documentation.
      required: false
      schema:
        type: string
    XOrganizationId:
      name: X-Organization-id
      in: header
      description: The unique identifier of the Organization associated with the request.
      required: true
      example: 019c96a0-0a98-7287-9a31-786e0809c769
      schema:
        type: string
  schemas:
    DownloadResponse:
      anyOf:
        - $ref: '#/components/schemas/Download'
        - $ref: '#/components/schemas/DownloadFailed'
          description: Details of reports that failed.
      description: Information about the report.
    Error:
      type: object
      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.
      description: Response message error.
      required:
        - code
        - title
        - message
    Download:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier of the report.
        templateId:
          type: string
          description: Unique identifier of the template used to generate the report.
        filters:
          type: object
          description: >-
            Object that defines the filtering criteria applied to the data used
            in the report. Now supports advanced filtering operators including
            `equality`, `comparison`, `range` and list-based conditions.
          additionalProperties:
            $ref: '#/components/schemas/DatabaseFilters'
        status:
          type: string
          description: The status of the report.
          enum:
            - Processing
            - Finished
        createdAt:
          type: string
          description: Timestamp marking when this report request was created.
        completedAt:
          type: string
          description: Timestamp marking when the report processing was completed.
        updatedAt:
          type: string
          description: Timestamp marking the last update to this report request.
        deletedAt:
          type: string
          description: >-
            Timestamp marking when this report request was soft deleted, if
            applicable.
        metadata:
          $ref: '#/components/schemas/Metadata'
      description: Details of reports that are processing or finished.
    DownloadFailed:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier of the report.
        templateId:
          type: string
          description: Unique identifier of the template used to generate the report.
        filters:
          type: object
          description: >-
            Object that defines the filtering criteria applied to the data used
            in the report. Now supports advanced filtering operators including
            `equality`, `comparison`, `range`, and list-based conditions.
          additionalProperties:
            $ref: '#/components/schemas/DatabaseFilters'
        status:
          type: string
          description: The status of the report.
          enum:
            - Error
        createdAt:
          type: string
          description: Timestamp marking when this report request was created.
        completedAt:
          type: string
          description: Timestamp marking when the report processing was completed.
        metadata:
          $ref: '#/components/schemas/Metadata'
      description: Details of reports that failed.
    DatabaseFilters:
      type: object
      description: >-
        Object where the key is the exact identifier of the data source to be
        filtered. Use the specific source ID configured in your organization —
        for example, use 'midaz_onboarding' for Onboarding data or 'plugin_crm'
        for CRM data, rather than generic labels like 'database_name'.  


        This identifier must match the name of a connected and accessible data
        source within your environment.  


        **Important**: This object is **optional**, but if provided, it **must**
        contain all necessary nested structures (`table`, `field` and
        `conditionals`) to ensure valid filtering. Partial or incomplete filter
        definitions will result in an error.
      additionalProperties:
        $ref: '#/components/schemas/TableFilters'
      example:
        midaz_onboarding:
          account:
            created_at:
              between:
                - '2025-08-02'
                - '2025-08-03'
    Metadata:
      type: object
      additionalProperties:
        type: string
      description: >-
        An object containing key-value pairs to add as metadata, where the field
        `name` is the key and the field `value` is the value. For example, to
        add a Cost Center, use 'costCenter': 'BR_11101997'.
    TableFilters:
      type: object
      description: >-
        **Mandatory** object where the key is the exact table name to be
        filtered within the selected data source. Use the precise name as
        defined in the database schema — for example, 'organization', 'account',
        'transaction', or 'fee', rather than a generic placeholder like
        'table_name'. This name must exactly match a table registered in the
        selected data source.
      additionalProperties:
        $ref: '#/components/schemas/FieldFilters'
      example:
        account:
          id:
            eq:
              - abc-123
          createdAt:
            between:
              - '2024-01-01'
              - '2024-12-31'
    FieldFilters:
      type: object
      description: >-
        **Mandatory** object whose key corresponds to the exact column name
        where the filtering conditions are applied. Use the field `name` exactly
        as defined in the table schema — e.g., 'accountId', 'status',
        'createdAt', or 'amount' — rather than a generic placeholder like
        'field_name'. This key must match the column name precisely to ensure
        proper query resolution.
      propertyNames:
        pattern: ^[a-zA-Z_][a-zA-Z0-9_]*$
      additionalProperties:
        $ref: '#/components/schemas/FilterOperators'
      example:
        id:
          eq:
            - abc-123
        createdAt:
          between:
            - '2024-01-01'
            - '2024-12-31'
    FilterOperators:
      type: object
      description: >-
        Object that specifies which logical operator(s) to apply to the selected
        field. Supports both simple and compound expressions. Each key is an
        operator name and its value is an array of operands.
      properties:
        eq:
          type: array
          description: >-
            Equal to — matches rows where the field value equals any of the
            provided values.
          items:
            oneOf:
              - type: string
              - type: number
        gt:
          type: array
          description: >-
            Greater than — matches rows where the field value is greater than
            the provided value.
          items:
            oneOf:
              - type: string
              - type: number
        gte:
          type: array
          description: >-
            Greater than or equal to — matches rows where the field value is
            greater than or equal to the provided value.
          items:
            oneOf:
              - type: string
              - type: number
        lt:
          type: array
          description: >-
            Less than — matches rows where the field value is less than the
            provided value.
          items:
            oneOf:
              - type: string
              - type: number
        lte:
          type: array
          description: >-
            Less than or equal to — matches rows where the field value is less
            than or equal to the provided value.
          items:
            oneOf:
              - type: string
              - type: number
        between:
          type: array
          description: >-
            Range filter — matches rows where the field value falls between two
            boundary values (inclusive). Expects exactly two items.
          minItems: 2
          maxItems: 2
          items:
            oneOf:
              - type: string
              - type: number
        in:
          type: array
          description: >-
            List inclusion — matches rows where the field value is one of the
            provided values.
          items:
            oneOf:
              - type: string
              - type: number
        nin:
          type: array
          description: >-
            List exclusion — matches rows where the field value is not one of
            the provided values.
          items:
            oneOf:
              - type: string
              - type: number
      additionalProperties: false
  examples:
    Error0004:
      summary: Invalid header
      value:
        code: TPL-0004
        title: Invalid header
        message: >-
          One or more header values are missing or incorrectly formatted. Please
          verify required headers %VALUE.
    Error0009:
      summary: Invalid Path Parameter
      value:
        code: TPL-0009
        title: Invalid Path Parameter
        message: >-
          Path parameters is in an incorrect format. Please check the following
          parameter %v and ensure they meet the required format before trying
          again.
    Error0011:
      summary: Entity Not Found
      value:
        code: TPL-0011
        title: Entity Not Found
        message: >-
          No %v entity was found for the given ID. Please make sure to use the
          correct ID for the entity you are trying to manage.
    Error0015:
      summary: Unexpected Fields in the Request
      value:
        code: TPL-0015
        title: Unexpected Fields in the Request
        message: >-
          The request body contains more fields than expected. Please send only
          the allowed fields as per the documentation. The unexpected fields are
          listed in the fields object.
    Error0016:
      summary: Missing Fields in Request
      value:
        code: TPL-0016
        title: Missing Fields in Request
        message: >-
          Your request is missing one or more required fields. Please refer to
          the documentation to ensure all necessary fields are included in your
          request.
    Error0017:
      summary: Bad Request
      value:
        code: TPL-0017
        title: Bad Request
        message: >-
          The server could not understand the request due to malformed syntax.
          Please check the listed fields and try again.
    Error0018:
      summary: Internal Server Error
      value:
        code: TPL-0018
        title: Internal Server Error
        message: >-
          The server encountered an unexpected error. Please try again later or
          contact support.
    Error0019:
      summary: Invalid Query Parameter
      value:
        code: TPL-0019
        title: Invalid Query Parameter
        message: >-
          One or more query parameters are in an incorrect format. Please check
          the following parameters '%v' and ensure they meet the required format
          before trying again.

````