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

# Check a document photo before it is confirmed

> What the web SDK calls on its review screen. Authenticate with `Authorization: Bearer <client_token>`; multipart with one `image`. A vision model says what to fix, the most basic first: `not_a_document`, `wrong_side`, `cut_off`, `obstructed`, `glare`, `illegible`, or null. Advice only: nothing is stored or billed, and on any error or timeout the answer is `{"issue": null, "checked": false}`. 20 calls a minute per session.



## OpenAPI

````yaml /openapi.json post /v1/sessions/{id}/precheck
openapi: 3.1.0
info:
  title: VerifNer API
  version: 1.0.0
  description: >-
    Identity verification for Nigerien passports and national identity cards.
    One call, a reasoned verdict: five checks with evidence, a score, VERIFIED
    at 0.90 and above, REVIEW from 0.60, REJECTED below.
servers:
  - url: https://api.verifner.com
security:
  - apiKey: []
tags:
  - name: Verify
    description: Server-to-server verification with the secret key.
  - name: Sessions
    description: >-
      Browser flows: your server opens a session, the web SDK uploads with a
      client token.
  - name: Webhooks
    description: verification.completed, signed with HMAC-SHA256, retried with backoff.
paths:
  /v1/sessions/{id}/precheck:
    post:
      tags:
        - Sessions
      summary: Check a document photo before it is confirmed
      description: >-
        What the web SDK calls on its review screen. Authenticate with
        `Authorization: Bearer <client_token>`; multipart with one `image`. A
        vision model says what to fix, the most basic first: `not_a_document`,
        `wrong_side`, `cut_off`, `obstructed`, `glare`, `illegible`, or null.
        Advice only: nothing is stored or billed, and on any error or timeout
        the answer is `{"issue": null, "checked": false}`. 20 calls a minute per
        session.
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
        - name: document
          in: query
          schema:
            type: string
            enum:
              - cni
              - cni_old
              - passport
            default: cni
        - name: side
          in: query
          schema:
            type: string
            enum:
              - front
              - back
            default: front
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
                - image
              properties:
                image:
                  type: string
                  format: binary
      responses:
        '200':
          description: Advice
          content:
            application/json:
              schema:
                type: object
                properties:
                  issue:
                    type:
                      - string
                      - 'null'
                    enum:
                      - not_a_document
                      - wrong_side
                      - cut_off
                      - obstructed
                      - glare
                      - illegible
                      - null
                  checked:
                    type: boolean
                  latency_ms:
                    type: integer
        '400':
          description: No image, or a bad query
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: Bad token
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - clientToken: []
components:
  schemas:
    Error:
      $schema: http://json-schema.org/draft-07/schema#
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: string
            message:
              type: string
          required:
            - code
            - message
          additionalProperties: false
      required:
        - error
      additionalProperties: false
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      description: '`vn_live_…` or `vn_test_…`, from the console.'
    clientToken:
      type: http
      scheme: bearer
      description: '`vn_ct_…` from POST /v1/sessions.'

````