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

# Get confidence level summary

> Retrieve OCR confidence level summary for bank statement pages



## OpenAPI

````yaml /api-specs/anycheck.yaml get /bank-statements/{id}/confidence-summary
openapi: 3.0.3
info:
  title: AnyCheck API
  version: 1.0.0
  description: >
    # AnyCheck API Documentation


    The AnyCheck API (formerly KYB API) provides comprehensive business and
    identity verification services through a RESTful interface.


    ## Features

    - **Identity Verification**: KTP, NIK, and other identity document
    validation

    - **Business Documents**: BPKB, land certificates, and business registration
    verification

    - **Compliance**: PEP screening and fraud detection

    - **Bank Statement Analysis**: OCR extraction and financial analysis

    - **Template Management**: Create and manage verification templates

    - **Async Processing**: Queue-based verification with webhook notifications


    ## Authentication

    All endpoints (except `/ping` and `/health`) require authentication via the
    `X-API-Key` header.
  contact:
    name: API Support
    email: bd@fintelite.ai
  license:
    name: Proprietary
servers:
  - url: https://api.anycheck.ai
    description: Production server
security:
  - apiKey: []
tags:
  - name: Health
    description: Health check endpoints
  - name: Upload
    description: File upload operations
  - name: Authentication
    description: User authentication and registration
  - name: Groups
    description: Group resource management
  - name: Services
    description: Verification service operations
  - name: Folders
    description: Folder management for organizing verifications
  - name: Verifications
    description: Document verification operations
  - name: Templates
    description: Verification template management
  - name: Bank Statement Analysis
    description: Bank statement OCR extraction, review, and financial analytics
  - name: Drafts
    description: 'Draft verification management: save, edit, and submit verifications'
paths:
  /bank-statements/{id}/confidence-summary:
    get:
      tags:
        - Bank Statement Analysis
      summary: Get confidence level summary
      description: Retrieve OCR confidence level summary for bank statement pages
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: Verification ID
        - name: file_index
          in: query
          required: true
          schema:
            type: integer
            minimum: 0
          description: File index (required, 0-based)
      responses:
        '200':
          description: Confidence level summary data
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    format: uuid
                    description: Verification ID
                  file_path:
                    type: string
                    description: Path to the analyzed file
                  confidence_summary:
                    $ref: '#/components/schemas/BSAConfidenceLevelSummary'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '408':
          $ref: '#/components/responses/RequestTimeout'
components:
  schemas:
    BSAConfidenceLevelSummary:
      type: object
      properties:
        confidence_summary:
          type: array
          items:
            $ref: '#/components/schemas/BSAConfidenceLevelPage'
          description: Summary of confidence levels across pages
          example:
            - confidence_level: LOW
              total: 2
              pages:
                - 1
                - 2
            - confidence_level: MEDIUM
              total: 0
              pages: []
            - confidence_level: HIGH
              total: 0
              pages: []
        file_path:
          type: string
          description: Path to the bank statement file
          example: >-
            files/4868d25b-8468-481c-a421-0470cb85200f/2e5eb232-1954-4ee0-8ca5-ac7b5ebd02d9/uploads/b43eb8f5-763a-4c47-80cf-79816dcd9852_OCBC.pdf
        id:
          type: string
          format: uuid
          description: Verification ID
          example: c65a9c6a-f453-47c9-b457-befd4b487021
      required:
        - confidence_summary
        - file_path
        - id
    BSAConfidenceLevelPage:
      type: object
      properties:
        confidence_level:
          type: string
          enum:
            - LOW
            - MEDIUM
            - HIGH
          description: Confidence level category
          example: LOW
        total:
          type: integer
          description: Total number of pages with this confidence level
          example: 2
        pages:
          type: array
          items:
            type: integer
          description: List of page numbers with this confidence level
          example:
            - 1
            - 2
    ErrorResponse:
      type: object
      properties:
        error_code:
          type: string
          example: INVALID_REQUEST
          description: Error code identifying the type of error
        message:
          type: string
          example: Invalid request. Please check input data format and try again
          description: Human-readable error message
        errors:
          type: array
          description: Field-specific validation errors (optional)
          items:
            $ref: '#/components/schemas/FieldError'
    FieldError:
      type: object
      properties:
        field:
          type: string
          description: Name of the field with validation error
          example: service_id
        message:
          type: string
          description: Field-specific error message
          example: This field is required
      required:
        - field
        - message
  responses:
    BadRequest:
      description: Bad request - Invalid input data
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            required_field:
              summary: Required field missing
              value:
                error_code: INVALID_REQUEST
                message: Invalid request. Please check input data format and try again
                errors:
                  - field: service_id
                    message: This field is required
            invalid_format:
              summary: Invalid field format
              value:
                error_code: INVALID_REQUEST
                message: Invalid request. Please check input data format and try again
                errors:
                  - field: email
                    message: This field should be a valid email
                  - field: folder_id
                    message: Must be a valid UUID
            multiple_errors:
              summary: Multiple validation errors
              value:
                error_code: INVALID_REQUEST
                message: Invalid request. Please check input data format and try again
                errors:
                  - field: service_id
                    message: This field is required
                  - field: configuration
                    message: This field is required
                  - field: folder_id
                    message: Must be a valid UUID
    Unauthorized:
      description: Unauthorized - Authentication required or invalid
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          examples:
            invalid_api_key:
              summary: Invalid API key
              value:
                error_code: INVALID_API_KEY
                message: API key is invalid
            api_key_expired:
              summary: Expired API key
              value:
                error_code: API_KEY_EXPIRED
                message: API key is expired
            unauthorized:
              summary: Missing authentication
              value:
                error_code: UNAUTHORIZED
                message: You are not authorized to perform this action
    Forbidden:
      description: Forbidden - User lacks required permissions
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error_code: FORBIDDEN
            message: You are forbidden to perform this action
    NotFound:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error_code: NOT_FOUND
            message: Resource not found
    RequestTimeout:
      description: Request timeout
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error_code: REQUEST_TIMEOUT
            message: Request timed out. Please try again later
  securitySchemes:
    apiKey:
      type: apiKey
      in: header
      name: X-API-Key
      description: API key for service-to-service authentication

````