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

# Get Category Distribution

<Info>Required API key permission: `metrics:read`.</Info>


## OpenAPI

````yaml /openapi.json get /v1/findings/category-distribution
openapi: 3.1.0
info:
  title: MindFort API
  version: 1.0.0
  description: >-
    The MindFort Public API supports targets, assessments, finding lifecycle and
    analytics, and reports. Public responses use positive field allowlists and
    call informational non-vulnerable results `secured`.
servers:
  - url: https://api.mindfort.app
    description: Production
security:
  - bearerAuth: []
paths:
  /v1/findings/category-distribution:
    get:
      tags:
        - Analytics
      summary: Get Category Distribution
      operationId: getCategoryDistribution
      parameters:
        - name: target_id
          in: query
          required: false
          description: Optionally scope organization-wide results to one target
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CategoryDistributionResponse'
        '400':
          description: Invalid request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Missing or invalid API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Not permitted for this organization
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Resource not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    CategoryDistributionResponse:
      properties:
        owasp_category_distribution:
          $ref: '#/components/schemas/OwaspCategoryDistribution'
        vulnerability_tag_distribution:
          $ref: '#/components/schemas/VulnerabilityTagDistribution'
      type: object
      required:
        - owasp_category_distribution
        - vulnerability_tag_distribution
      title: CategoryDistributionResponse
      additionalProperties: false
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
          description: Human-readable error message
        request_id:
          type: string
          description: Unique request identifier for debugging
    OwaspCategoryDistribution:
      properties:
        broken_access_control:
          type: integer
          title: Broken Access Control
        cryptographic_failures:
          type: integer
          title: Cryptographic Failures
        injection:
          type: integer
          title: Injection
        insecure_design:
          type: integer
          title: Insecure Design
        security_misconfiguration:
          type: integer
          title: Security Misconfiguration
        vulnerable_components:
          type: integer
          title: Vulnerable Components
        auth_failures:
          type: integer
          title: Auth Failures
        data_integrity_failures:
          type: integer
          title: Data Integrity Failures
        logging_monitoring_failures:
          type: integer
          title: Logging Monitoring Failures
        ssrf:
          type: integer
          title: Ssrf
        count:
          type: integer
          title: Count
      type: object
      required:
        - broken_access_control
        - cryptographic_failures
        - injection
        - insecure_design
        - security_misconfiguration
        - vulnerable_components
        - auth_failures
        - data_integrity_failures
        - logging_monitoring_failures
        - ssrf
        - count
      title: OwaspCategoryDistribution
      additionalProperties: false
    VulnerabilityTagDistribution:
      properties:
        xss:
          type: integer
          title: Xss
        sql_injection:
          type: integer
          title: Sql Injection
        command_injection:
          type: integer
          title: Command Injection
        ssti:
          type: integer
          title: Ssti
        xxe:
          type: integer
          title: Xxe
        path_traversal:
          type: integer
          title: Path Traversal
        broken_access_control:
          type: integer
          title: Broken Access Control
        idor:
          type: integer
          title: Idor
        csrf:
          type: integer
          title: Csrf
        open_redirect:
          type: integer
          title: Open Redirect
        information_disclosure:
          type: integer
          title: Information Disclosure
        api_security:
          type: integer
          title: Api Security
        ssrf:
          type: integer
          title: Ssrf
        file_upload:
          type: integer
          title: File Upload
        business_logic:
          type: integer
          title: Business Logic
        security_misconfiguration:
          type: integer
          title: Security Misconfiguration
        clickjacking:
          type: integer
          title: Clickjacking
        network_security:
          type: integer
          title: Network Security
        authentication:
          type: integer
          title: Authentication
        session_management:
          type: integer
          title: Session Management
        cryptographic_issues:
          type: integer
          title: Cryptographic Issues
        vulnerable_components:
          type: integer
          title: Vulnerable Components
        insecure_deserialization:
          type: integer
          title: Insecure Deserialization
        logging_monitoring:
          type: integer
          title: Logging Monitoring
        count:
          type: integer
          title: Count
      type: object
      required:
        - xss
        - sql_injection
        - command_injection
        - ssti
        - xxe
        - path_traversal
        - broken_access_control
        - idor
        - csrf
        - open_redirect
        - information_disclosure
        - api_security
        - ssrf
        - file_upload
        - business_logic
        - security_misconfiguration
        - clickjacking
        - network_security
        - authentication
        - session_management
        - cryptographic_issues
        - vulnerable_components
        - insecure_deserialization
        - logging_monitoring
        - count
      title: VulnerabilityTagDistribution
      additionalProperties: false
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key generated from the MindFort dashboard. Pass as `Authorization:
        Bearer <your-api-key>`.

````