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

# List connections

> Use this endpoint to list all database connections configured for your organization. You can apply filters, pagination, and sorting to narrow down results and find specific connections based on your criteria.



## OpenAPI

````yaml /en/openapi/v3-current/connections.yaml get /v1/management/connections
openapi: 3.1.0
info:
  title: Database Connections
  description: >-
    The database connections API provides endpoints for managing the database
    connections used by Reporter. It allows you to create, list, update, delete,
    and test database connections, as well as validate schemas against
    configured data sources.
  version: 1.0.0
servers:
  - url: https://reporter.sandbox.lerian.net
security: []
tags:
  - name: Database Connections
    description: Endpoints for managing database connections used by Reporter.
paths:
  /v1/management/connections:
    get:
      tags:
        - Database Connections
      summary: List connections
      description: >-
        Use this endpoint to list all database connections configured for your
        organization. You can apply filters, pagination, and sorting to narrow
        down results and find specific connections based on your criteria.
      parameters:
        - $ref: '#/components/parameters/Authorization'
        - name: X-Product-Name
          in: header
          description: >-
            Filter connections by product name. When provided, only connections
            associated with this product are returned. Must contain only
            alphanumeric characters, underscores, and hyphens (max 100
            characters). The value is normalized to lowercase.
          required: false
          schema:
            type: string
            maxLength: 100
            pattern: ^[a-zA-Z0-9_-]+$
            example: my-product
        - $ref: '#/components/parameters/Page'
        - $ref: '#/components/parameters/Limit'
        - $ref: '#/components/parameters/SortOrder'
        - name: type
          in: query
          description: Filter connections by database type.
          required: false
          schema:
            type: string
            enum:
              - ORACLE
              - SQL_SERVER
              - POSTGRESQL
              - MONGODB
              - MYSQL
        - name: host
          in: query
          description: Filter connections by hostname or IP address.
          required: false
          schema:
            type: string
        - name: databaseName
          in: query
          description: Filter connections by database name.
          required: false
          schema:
            type: string
        - name: startDate
          in: query
          description: >-
            Filter connections created on or after this date (format
            `YYYY-MM-DD`).
          required: false
          schema:
            type: string
            format: date
            example: '2025-01-01'
        - name: endDate
          in: query
          description: >-
            Filter connections created on or before this date (format
            `YYYY-MM-DD`).
          required: false
          schema:
            type: string
            format: date
            example: '2025-12-31'
      responses:
        '200':
          description: The list of all connections available for the organization.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConnectionListResponse'
              example:
                page: 1
                limit: 50
                total: 3
                items:
                  - id: 019996b8-f3d1-7d2b-a192-6e91464d82fc
                    configName: Midaz - Banco Transacional
                    productName: my-product
                    type: POSTGRESQL
                    host: postgres.cliente.com.br
                    port: 5432
                    databaseName: transaction
                    userName: user_midaz_read
                    schema: public
                    ssl:
                      mode: require
                    metadata: {}
                    createdAt: '2025-09-25T10:30:00Z'
                    updatedAt: '2025-09-25T10:30:00Z'
                  - id: 019996b9-174d-7a23-9f87-f7336d5ad98c
                    configName: Midaz - Metadados de Transacao
                    productName: my-product
                    type: MONGODB
                    host: mongo.cliente.com.br
                    port: 27017
                    databaseName: transaction
                    userName: user_midaz_meta
                    ssl:
                      mode: disable
                    metadata: {}
                    createdAt: '2025-09-25T10:32:00Z'
                    updatedAt: '2025-09-25T10:32:00Z'
                  - id: 019996b9-3b1e-7475-bb50-c81bbb553432
                    configName: Midaz - Metadados de Onboarding
                    productName: my-product
                    type: MONGODB
                    host: mongo.cliente.com.br
                    port: 27017
                    databaseName: onboarding
                    userName: user_onboarding_meta
                    ssl:
                      mode: disable
                    metadata: {}
                    createdAt: '2025-09-24T18:00:00Z'
                    updatedAt: '2025-09-24T18:00:00Z'
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                Error0405:
                  $ref: '#/components/examples/Error0405'
                Error0408:
                  $ref: '#/components/examples/Error0408'
                Error0409:
                  $ref: '#/components/examples/Error0409'
                Error0406:
                  $ref: '#/components/examples/Error0406'
                Error0407:
                  $ref: '#/components/examples/Error0407'
      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/platform/access-manager/access-manager) documentation.
      required: false
      schema:
        type: string
        example: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...
    Page:
      name: page
      in: query
      description: The page number to retrieve (1-indexed).
      required: false
      schema:
        type: integer
        minimum: 1
        default: 1
        example: 1
    Limit:
      name: limit
      in: query
      description: Maximum number of items returned per page (max 1000).
      required: false
      schema:
        type: integer
        minimum: 1
        maximum: 1000
        default: 50
        example: 50
    SortOrder:
      name: sortOrder
      in: query
      description: The order used to sort the results.
      required: false
      schema:
        type: string
        enum:
          - asc
          - desc
        default: desc
        example: desc
  schemas:
    ConnectionListResponse:
      type: object
      description: Paginated list of connections.
      required:
        - items
        - page
        - limit
        - total
      properties:
        page:
          type: integer
          description: Current page number in the paginated results (1-indexed).
          example: 1
        limit:
          type: integer
          description: Maximum number of items returned per page.
          example: 50
        total:
          type: integer
          description: Total count of items available across all pages.
          example: 3
        items:
          type: array
          description: Array containing the connections for the current page.
          maxItems: 100
          items:
            $ref: '#/components/schemas/ConnectionResponse'
    Error:
      type: object
      description: >-
        Response message error. Error codes use the `FET` prefix to identify
        issues related to the database connections API.
      required:
        - code
        - title
        - message
      properties:
        code:
          type: string
          description: A unique, stable identifier for the error (prefixed with `FET`).
          example: FET-0001
        title:
          type: string
          description: A brief summary of the issue.
          example: Missing required fields
        message:
          type: string
          description: Detailed guidance for resolving the error.
          example: >-
            One or more required fields are missing. Please ensure all required
            fields like configName, host, port, userName, and password are
            included.
    ConnectionResponse:
      type: object
      description: Response object containing connection details.
      required:
        - id
        - configName
        - type
        - host
        - port
        - databaseName
        - userName
        - createdAt
      properties:
        id:
          type: string
          format: uuid
          description: Unique identifier of the connection (UUID format).
          example: a1b2c3d4-e5f6-7890-abcd-ef1234567890
        productName:
          type: string
          description: >-
            The product name associated with this connection. May be empty if
            the connection has not been assigned to a product.
          example: my-product
        configName:
          type: string
          description: Unique identifier name for this connection configuration.
          example: production-db
        type:
          type: string
          description: >-
            Database engine type. Supported values: `ORACLE`, `SQL_SERVER`,
            `POSTGRESQL`, `MONGODB`, `MYSQL`. Note that the data source `type`
            field in the [List Data
            Sources](/en/reference/reporter/list-data-sources) endpoint returns
            lowercase identifiers (`postgresql`, `mongodb`).
          enum:
            - ORACLE
            - SQL_SERVER
            - POSTGRESQL
            - MONGODB
            - MYSQL
          example: POSTGRESQL
        host:
          type: string
          description: Hostname or IP address of the database server.
          example: db.example.com
        port:
          type: integer
          description: Network port number for the database connection.
          example: 5432
        databaseName:
          type: string
          description: Name of the database to connect to on the target server.
          example: mydatabase
        userName:
          type: string
          description: Username credential for database authentication.
          example: dbuser
        schema:
          type: string
          description: Database schema name, when set.
          example: public
        ssl:
          $ref: '#/components/schemas/SSL'
        metadata:
          $ref: '#/components/schemas/Metadata'
        createdAt:
          type: string
          format: date-time
          description: ISO 8601 timestamp indicating when the connection was created.
          example: '2024-01-15T10:30:00Z'
        updatedAt:
          type: string
          format: date-time
          description: ISO 8601 timestamp indicating when the connection was last updated.
          example: '2024-01-15T10:30:00Z'
    SSL:
      type: object
      description: SSL configuration object containing certificate and security options.
      required:
        - mode
      properties:
        mode:
          type: string
          description: >-
            SSL connection mode. Supported values: - `disable`: No SSL
            connection - `require`: SSL required but no certificate verification
            - `verify-ca`: SSL with CA certificate verification - `verify-full`:
            SSL with full certificate verification
          enum:
            - disable
            - require
            - verify-ca
            - verify-full
          example: require
        ca:
          type: string
          description: >-
            Certificate Authority (CA) certificate for server verification (PEM
            format).
          example: |
            -----BEGIN CERTIFICATE-----
            MIIDdzCCAl+gAwIBAgIEbV...
            -----END CERTIFICATE-----
        cert:
          type: string
          description: Client certificate for SSL mutual authentication (PEM format).
        key:
          type: string
          description: Private key for the client certificate (PEM format).
    Metadata:
      type: object
      additionalProperties:
        type: string
        maxLength: 2000
      description: >-
        An object containing key-value pairs for storing additional
        connection-related information. Keys (max 100 characters) and values
        (max 2000 characters) must be strings. Nested objects are not allowed.
      example:
        environment: production
        team: data-engineering
  examples:
    Error0405:
      summary: Invalid Query Parameter
      value:
        code: FET-0405
        title: Invalid Query Parameter
        message: >-
          One or more query parameters are in an incorrect format. Please check
          the following parameters and ensure they meet the required format
          before trying again.
    Error0408:
      summary: Invalid Date Format Error
      value:
        code: FET-0408
        title: Invalid Date Format Error
        message: >-
          The 'startDate', 'endDate', or both are in the incorrect format.
          Please use the 'YYYY-MM-DD' format and try again.
    Error0409:
      summary: Invalid Final Date Error
      value:
        code: FET-0409
        title: Invalid Final Date Error
        message: >-
          The 'endDate' cannot be earlier than the 'startDate'. Please verify
          the dates and try again.
    Error0406:
      summary: Pagination Limit Exceeded
      value:
        code: FET-0406
        title: Pagination Limit Exceeded
        message: >-
          The pagination limit exceeds the maximum allowed of 1000 items per
          page. Please verify the limit and try again.
    Error0407:
      summary: Invalid Sort Order
      value:
        code: FET-0407
        title: Invalid Sort Order
        message: >-
          The 'sortOrder' field must be 'asc' or 'desc'. Please provide a valid
          sort order and try again.

````