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

# Financial Ratio Features

> Computes financial ratio features from raw financial statement data. Automatically calculates profitability, liquidity, leverage, and efficiency ratios for credit scoring and financial analysis. [Tier: ENTERPRISE, Credits: 10]



## OpenAPI

````yaml api-specs/ml.json post /quantlib/ml/features/financial-ratios
openapi: 3.1.0
info:
  title: FinceptQuantLib API - ML
  description: >-
    Machine Learning and Credit Risk module endpoints for FinceptQuantLib API.
    Pro Tier access required (5 credits per request). Covers credit scoring,
    model validation, regression models, clustering, anomaly detection, feature
    engineering, and preprocessing.
  version: 3.0.0
  contact:
    name: Fincept API Support
    url: https://fincept.in
servers:
  - url: https://api.fincept.in
    description: Fincept API Production Server
security:
  - APIKeyHeader: []
tags:
  - name: quantlib-ml
    description: Machine Learning and Credit Risk Analytics
    x-displayName: ML
paths:
  /quantlib/ml/features/financial-ratios:
    post:
      tags:
        - quantlib-ml
      summary: Financial Ratio Features
      description: >-
        Computes financial ratio features from raw financial statement data.
        Automatically calculates profitability, liquidity, leverage, and
        efficiency ratios for credit scoring and financial analysis. [Tier:
        ENTERPRISE, Credits: 10]
      operationId: financial_ratio_features
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - data
              properties:
                data:
                  type: object
                  description: >-
                    Financial statement data (revenue, assets, liabilities,
                    equity, etc.)
                  additionalProperties:
                    type: array
                    items:
                      type: number
                  example:
                    revenue:
                      - 1000000
                      - 1200000
                    net_income:
                      - 100000
                      - 150000
                    total_assets:
                      - 500000
                      - 600000
                    total_liabilities:
                      - 300000
                      - 350000
                    equity:
                      - 200000
                      - 250000
      responses:
        '200':
          description: Computed financial ratios
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  data:
                    type: object
                    description: Financial ratio features (ROA, ROE, debt-to-equity, etc.)
                    example:
                      roa:
                        - 0.2
                        - 0.25
                      roe:
                        - 0.5
                        - 0.6
                      debt_to_equity:
                        - 1.5
                        - 1.4
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '402':
          $ref: '#/components/responses/InsufficientCreditsError'
        '422':
          $ref: '#/components/responses/ValidationError'
components:
  responses:
    UnauthorizedError:
      description: Authentication information is missing or invalid
      content:
        application/json:
          schema:
            type: object
            properties:
              detail:
                type: string
                example: Invalid API key
    InsufficientCreditsError:
      description: Insufficient credits for this operation
      content:
        application/json:
          schema:
            type: object
            properties:
              detail:
                type: string
                example: Insufficient credits. This endpoint requires 5 credits.
    ValidationError:
      description: Request validation error
      content:
        application/json:
          schema:
            type: object
            properties:
              detail:
                type: array
                items:
                  type: object
                  properties:
                    loc:
                      type: array
                      items:
                        type: string
                    msg:
                      type: string
                    type:
                      type: string
  securitySchemes:
    APIKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        API key for authentication. Get your key at
        https://api.fincept.in/auth/register

````