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

# Get organization metrics

> Retrieve calculated financial metrics for a specific organization using provided filters.
    #### [Authorization scenarios](/content/developer-guide/introduction/authorization#scenarios)
    | Guest | Host | Self |
    |-------|------|------|
    | ✅    | ❌   | ✅  |



## OpenAPI

````yaml /content/developer-guide/api-reference/openapi_v1.json get /organizations/{org_id}/metrics
openapi: 3.1.0
info:
  title: API - V1
  version: 1.0.0
servers:
  - url: https://api.mycreditapp.ai/v1-beta
security: []
paths:
  /organizations/{org_id}/metrics:
    get:
      tags:
        - Organization Metrics
      summary: Get organization metrics
      description: >-
        Retrieve calculated financial metrics for a specific organization using
        provided filters.
            #### [Authorization scenarios](/content/developer-guide/introduction/authorization#scenarios)
            | Guest | Host | Self |
            |-------|------|------|
            | ✅    | ❌   | ✅  |
      operationId: get_organization_metrics_organizations__org_id__metrics_get
      parameters:
        - name: org_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            description: >-
              Unique identifier of the
              [organization](https://docs.mycreditapp.ai/api-reference/organizations/get-organization)
            examples:
              - a3c9e8f1-2b4d-4c6e-8f0a-1b2c3d4e5f60
            title: Org Id
          description: >-
            Unique identifier of the
            [organization](https://docs.mycreditapp.ai/api-reference/organizations/get-organization)
        - name: period_type
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/ReportingPeriod'
              - type: 'null'
            description: Optional filter by reporting period type
            title: Period Type
          description: Optional filter by reporting period type
        - name: date_from
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            description: Optional start date for metric filtering
            examples:
              - '2025-01-01'
            title: Date From
          description: Optional start date for metric filtering
        - name: date_to
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date
              - type: 'null'
            description: Optional end date for metric filtering
            examples:
              - '2025-12-31'
            title: Date To
          description: Optional end date for metric filtering
        - name: metric_type
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/MetricType'
              - type: 'null'
            description: Optional filter by specific metric type
            title: Metric Type
          description: Optional filter by specific metric type
        - name: metric_section_type
          in: query
          required: false
          schema:
            anyOf:
              - $ref: '#/components/schemas/MetricSectionType'
              - type: 'null'
            description: Optional filter by specific metric section type
            title: Metric Section Type
          description: Optional filter by specific metric section type
        - name: order_by
          in: query
          required: false
          schema:
            enum:
              - period
              - period_type
              - metric_type
              - metric_section_type
            type: string
            description: Field by which to order the results (e.g., period, metric_type)
            default: period
            title: Order By
          description: Field by which to order the results (e.g., period, metric_type)
        - name: order_dir
          in: query
          required: false
          schema:
            enum:
              - asc
              - desc
            type: string
            description: >-
              Direction to order the results (asc for ascending, desc for
              descending)
            default: desc
            title: Order Dir
          description: >-
            Direction to order the results (asc for ascending, desc for
            descending)
        - name: Requester-Organization-ID
          in: header
          required: true
          schema:
            type: string
            format: uuid
            description: |

              The unique identifier of the organization making the request.
              **This ID is used to authorize the requester within the system**.
            examples:
              - 054b4106-174b-46b0-97f8-86d8d7b6f0af
            title: Requester-Organization-Id
          description: |

            The unique identifier of the organization making the request.
            **This ID is used to authorize the requester within the system**.
        - name: Target-Organization-ID
          in: header
          required: true
          schema:
            type: string
            format: uuid
            description: >

              The unique identifier of the organization that is the target of
              the request.

              The `Target-Organization-ID` may match the
              `Requester-Organization-ID` if the requester accesses their own
              resources.

              If the `Target-Organization-ID` differs from the
              `Requester-Organization-ID`, the requester can access third-party
              resources **if the requester has a connection with the target
              organization and is authorized to perform such actions**.
            examples:
              - 123e4567-e89b-12d3-a456-426614174000
            title: Target-Organization-Id
          description: >

            The unique identifier of the organization that is the target of the
            request.

            The `Target-Organization-ID` may match the
            `Requester-Organization-ID` if the requester accesses their own
            resources.

            If the `Target-Organization-ID` differs from the
            `Requester-Organization-ID`, the requester can access third-party
            resources **if the requester has a connection with the target
            organization and is authorized to perform such actions**.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrganizationMetricsList'
        '400':
          description: Bad Request
          content:
            application/json:
              example:
                detail:
                  - loc: []
                    msg: Unsupported CRUD operation!
                    type: request
                    code: unsupported_crud_operation
              schema:
                $ref: '#/components/schemas/APIError'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
              example:
                detail:
                  - loc: []
                    msg: Token is required!
                    type: token
                    code: token_required
                  - loc: []
                    msg: The token has expired!
                    type: token
                    code: token_expired
                  - loc: []
                    msg: Invalid token!
                    type: token
                    code: invalid_token
        '403':
          description: Forbidden
          content:
            application/json:
              example:
                detail:
                  - loc: []
                    msg: Access denied!
                    type: request
                    code: access_denied
              schema:
                $ref: '#/components/schemas/APIError'
        '404':
          description: Not Found
          content:
            application/json:
              example:
                detail:
                  - loc: []
                    msg: Account not found!
                    type: request
                    code: account_not_found
                  - loc: []
                    msg: Organization not found!
                    type: request
                    code: organization_not_found
              schema:
                $ref: '#/components/schemas/APIError'
        '409':
          description: Conflict
          content:
            application/json:
              example:
                detail:
                  - loc: []
                    msg: >-
                      The account is in the process of being deleted! The
                      Account's email can only be reused after its data has been
                      completely deleted. The removal process may take up to 24
                      hours.
                    type: request
                    code: account_being_deleted
                  - loc: []
                    msg: >-
                      The organization is in the process of being deleted! The
                      removal process may take up to 24 hours.
                    type: request
                    code: organization_being_deleted
              schema:
                $ref: '#/components/schemas/APIError'
        '413':
          description: Request Entity Too Large
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
              example:
                detail:
                  - loc: []
                    msg: The request is too large!
                    type: request
                    code: request_too_large
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
              example:
                detail:
                  - loc:
                      - string
                      - 0
                    msg: string
                    type: string
                    code: validation_error
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
              example:
                detail:
                  - loc: []
                    msg: Error processing request, please try later!
                    type: try_later
                    code: internal_conflict_error
        '503':
          description: Service Unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIError'
              example:
                detail:
                  - loc: []
                    msg: Service is under maintenance, please try later!
                    type: maintanance
                    code: service_under_maintenance
      security:
        - Token: []
components:
  schemas:
    ReportingPeriod:
      type: string
      enum:
        - quarterly
        - yearly
      title: ReportingPeriod
    MetricType:
      type: string
      enum:
        - approximate_repayment_period
        - average_balance
        - average_inventory_holding_days
        - average_trade_payable_days
        - average_trade_receivables_days
        - cap_exp
        - cash_flow_efficiency_1
        - cash_flow_efficiency_2
        - cash_flows_from_financing_activities
        - cash_flows_from_investing_activities
        - cash_flows_from_operating_activities
        - cop
        - cpltd_fcf_coverage
        - current_ratio
        - dscr
        - ebit_margin
        - ebitda_margin
        - ending_balance
        - financial_leverage
        - fixed_assets_productivity_ratio
        - fixed_assets_turnover_ratio
        - free_cash_flow
        - gross_profit_margin
        - higher_financial_leverage_and_higher_operating_leverage
        - inventory_turnover_ratio
        - iscr
        - margin_money_contribution_to_ace
        - margin_money_contribution_to_nwc
        - margin_money_contribution_to_tangible_fixed_assets
        - margin_money_contribution_to_total_assets
        - margin_money_in_nwc
        - net_profit_margin
        - net_working_capital_cycle
        - operating_leverage
        - quick_ratio
        - roace
        - short_term_debt_cpltd_to_free_cash_flow
        - total_balance_sheet_leverage
      title: MetricType
    MetricSectionType:
      type: string
      enum:
        - brief_cash_flows_profile
        - cash_strength
        - debt_repayment_capacity_cushion
        - fixed_assets_efficiency
        - profitability
        - production_offtake_indicator
        - riskiness_of_net_operating_cash_flows
        - short_term_liquidity_and_working_capital
        - solvency
        - sustenance_of_the_business_growth_thriving
        - working_capital_operating_efficiency
      title: MetricSectionType
    OrganizationMetricsList:
      properties:
        items:
          items:
            $ref: '#/components/schemas/OrganizationMetric'
          type: array
          title: Items
          description: List of organization metrics returned by the query
        total_items:
          type: integer
          minimum: 0
          title: Total Items
          description: >-
            Total number of organization metrics matching the query, ignoring
            pagination
          examples:
            - 1
            - 25
            - 100
      type: object
      required:
        - items
        - total_items
      title: OrganizationMetricsList
    APIError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ErrorItem'
          type: array
          title: Detail
          description: >

            List of returned errors.

            **All unsuccessful error codes except code `422` can only contain 1
            element in the list**.
      type: object
      required:
        - detail
      title: APIError
    OrganizationMetric:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Unique identifier of the metric
          examples:
            - 3fa85f64-5717-4562-b3fc-2c963f66afa6
        metric_section_type:
          $ref: '#/components/schemas/MetricSectionType'
          description: The section or category of the metricfor calculating the total score
        metric_type:
          $ref: '#/components/schemas/MetricType'
          description: The type of the measured metric for calculating the total score
        period:
          type: string
          format: date
          title: Period
          description: Reporting period of the metric
          examples:
            - '2025-09-30'
        period_type:
          $ref: '#/components/schemas/ReportingPeriod'
          description: Type of reporting period (e.g., monthly, quarterly, yearly)
        value:
          anyOf:
            - type: number
            - type: 'null'
          title: Value
          description: Value of the metric for the specified period
          examples:
            - 0.75
            - 0.6
        value_type:
          $ref: '#/components/schemas/MetricDataType'
          description: Type of the metric value (e.g., real, average)
        points:
          anyOf:
            - type: number
            - type: 'null'
          title: Points
          description: >-
            Points awarded for the metric based on its value and the scoring
            system
          examples:
            - 5
            - 7.5
        created_at:
          type: string
          format: date-time
          title: Created At
          description: Timestamp when the metric record was created
          examples:
            - '2025-09-23T16:07:35.675578'
        updated_at:
          type: string
          format: date-time
          title: Updated At
          description: Timestamp when the metric record was last updated
          examples:
            - '2025-09-23T16:07:35.675578'
      type: object
      required:
        - id
        - metric_section_type
        - metric_type
        - period
        - period_type
        - value_type
        - created_at
        - updated_at
      title: OrganizationMetric
    ErrorItem:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Loc
          description: |

            Shows the dynamic location of the current error.
            If an empty array is returned, the error is static.
          examples:
            - - body
              - date_field
              - 0
            - - header
              - Authorization
        msg:
          type: string
          title: Msg
          description: |

            A human-readable message providing more details about the error.
          examples:
            - Token is required!
            - Invalid token!
        type:
          type: string
          title: Type
          description: >

            A string indicating the type of error.

            **The list is not fixed, so it's necessary to pay attention to the
            possible type for a specific error**.
          examples:
            - token
            - request
            - try_later
        code:
          type: string
          title: Code
          description: >

            Unique text error code identifying the error.

            **The list is not fixed, so it's necessary to pay attention to the
            possible code for a specific error**.
          examples:
            - token_required
            - invalid_token
            - access_denied
      type: object
      required:
        - loc
        - msg
        - type
        - code
      title: ErrorItem
    MetricDataType:
      type: string
      enum:
        - real
        - average
        - predicted
      title: MetricDataType
  securitySchemes:
    Token:
      type: http
      description: >-
        [Bearer
        authentication](/content/developer-guide/introduction/authentication)
        using a JWT token. Provide a valid access token. Authorization header
        format: `Authorization: Bearer <token>`.
      scheme: bearer

````