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

# Audit Trail Stats



## OpenAPI

````yaml /api-reference/openapi.json get /api/audit-trail/stats
openapi: 3.1.0
info:
  title: Blindsight API
  version: 0.1.0
servers: []
security: []
paths:
  /api/audit-trail/stats:
    get:
      tags:
        - audit-trail
      summary: Audit Trail Stats
      operationId: audit_trail_stats_api_audit_trail_stats_get
      parameters:
        - name: search
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Search
        - name: event_types
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Comma-separated event types
            title: Event Types
          description: Comma-separated event types
        - name: categories
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Comma-separated categories
            title: Categories
          description: Comma-separated categories
        - name: actors
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Comma-separated actors
            title: Actors
          description: Comma-separated actors
        - name: entity_type
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Entity Type
        - name: entity_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Entity Id
        - name: severities
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: Comma-separated severities
            title: Severities
          description: Comma-separated severities
        - name: date_from
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Date From
        - name: date_to
          in: query
          required: false
          schema:
            anyOf:
              - type: string
                format: date-time
              - type: 'null'
            title: Date To
        - name: application_id
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Application Id
        - name: registered_params_only
          in: query
          required: false
          schema:
            type: boolean
            default: false
            title: Registered Params Only
        - name: param_filters
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: JSON array of {key, operator, value}
            title: Param Filters
          description: JSON array of {key, operator, value}
        - name: X-API-Key
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Api-Key
        - name: blindsight_session
          in: cookie
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Blindsight Session
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuditTrailStatsResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    AuditTrailStatsResponse:
      properties:
        by_event_type:
          additionalProperties:
            type: integer
          type: object
          title: By Event Type
        by_category:
          additionalProperties:
            type: integer
          type: object
          title: By Category
        by_severity:
          additionalProperties:
            type: integer
          type: object
          title: By Severity
        by_actor:
          additionalProperties:
            type: integer
          type: object
          title: By Actor
        total:
          type: integer
          title: Total
          default: 0
        usage_by_day:
          items:
            $ref: '#/components/schemas/AuditTimelinePoint'
          type: array
          title: Usage By Day
      type: object
      title: AuditTrailStatsResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    AuditTimelinePoint:
      properties:
        date:
          type: string
          title: Date
        total_records:
          type: integer
          title: Total Records
          default: 0
      type: object
      required:
        - date
      title: AuditTimelinePoint
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````