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

# Verify voice identity

> Verify if a new voice sample matches a previously enrolled voice embedding (belongs to the same speaker) and is not AI-generated.

This endpoint provides a dual-layer trust mechanism:
1. **Voice Matching** - Compares the voice sample against the enrolled voiceprint
2. **Authenticity Detection** - Verifies the voice is not AI-generated

**Requirements:**
- Voice sample to compare
- Previously generated voice vector from `/voiceid/enroll`
- Supported formats: WAV, MP3, AAC, FLAC, OGG, M4A



## OpenAPI

````yaml /api-reference/v1/openapi.json post /voiceid/verify
openapi: 3.0.3
info:
  title: Aurigin API
  version: 1.0.0
  description: Updated API with new response structure - v1.0.0
servers:
  - url: https://api.aurigin.ai/v1
security: []
paths:
  /voiceid/verify:
    post:
      tags:
        - Voice ID
      summary: Verify voice identity
      description: >-
        Verify if a new voice sample matches a previously enrolled voice
        embedding (belongs to the same speaker) and is not AI-generated.


        This endpoint provides a dual-layer trust mechanism:

        1. **Voice Matching** - Compares the voice sample against the enrolled
        voiceprint

        2. **Authenticity Detection** - Verifies the voice is not AI-generated


        **Requirements:**

        - Voice sample to compare

        - Previously generated voice vector from `/voiceid/enroll`

        - Supported formats: WAV, MP3, AAC, FLAC, OGG, M4A
      operationId: verifyVoiceIdV1
      requestBody:
        required: true
        description: >-
          Provide the voice sample to verify and the enrolled voice vector to
          compare against.
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                audio_file:
                  type: string
                  format: binary
                  description: Voice sample to compare
                voice_vector:
                  type: string
                  description: >-
                    JSON array string of the voice vector from enrollment (e.g.,
                    "[-0.0123, 0.8472, -0.3391, ...]")
                user_id:
                  type: string
                  description: Optional user identifier for tracking
              required:
                - audio_file
                - voice_vector
          application/json:
            schema:
              $ref: '#/components/schemas/VoiceIdVerifyRequest'
      responses:
        '200':
          description: Verification completed with voice match and authenticity results
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/VoiceIdVerifyResponse'
        '400':
          description: Validation error (e.g., missing voice_vector, invalid format)
          content:
            application/json:
              schema:
                $ref: 1ff44169-9e99-4aae-90bb-2aa7f258a1f8
              example:
                message:
                  detail: >-
                    Audio rejected: AI-generated voice detected (deepfake
                    confidence: 94.6%)
                  type: forbidden_error
                  correlation_id: e2ca498c-aad8-442a-9ef7-4ca4f74177dc
                  timestamp: '2026-01-27T17:15:21.749199Z'
                statusCode: 403
        '401':
          description: Missing or invalid API key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '422':
          description: The audio could not be processed (e.g., corrupted media)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Unexpected server error while verifying the voice
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - api_key: []
      externalDocs:
        description: Voice ID verification guide
        url: https://docs.aurigin.ai/api-reference/v1/endpoint/verify
components:
  schemas:
    VoiceIdVerifyRequest:
      type: object
      properties:
        audio_file:
          type: string
          format: binary
          description: >-
            Voice sample to compare. Supported formats: WAV, MP3, AAC, FLAC,
            OGG, M4A
        voice_vector:
          type: array
          items:
            type: number
            format: float
          description: >-
            The voice vector previously generated with the /enroll endpoint to
            compare against
        user_id:
          type: string
          description: Optional user identifier for tracking
      required:
        - audio_file
        - voice_vector
    VoiceIdVerifyResponse:
      type: object
      properties:
        is_match:
          type: boolean
          description: Whether the voice sample matches the enrolled voiceprint
          example: false
        similarity_score:
          type: number
          format: float
          description: >-
            Similarity score between the voice sample and enrolled profile
            (0.0-1.0)
          example: 0.4861065447330475
        confidence_score:
          type: number
          format: float
          description: Confidence score for the verification result (0.0-1.0)
          example: 0.4861065447330475
        processing_time:
          type: number
          format: float
          description: Time taken to process the audio and verify the voice in seconds
          example: 6.249222755432129
        model_version:
          type: string
          description: Model version used for voice verification
          example: titanet-large
        deepfake_score:
          type: number
          format: float
          nullable: true
          description: >-
            Deepfake detection score (0.0-1.0). null if deepfake detection was
            not performed or voice is authentic
          example: null
      example:
        is_match: false
        similarity_score: 0.4861065447330475
        confidence_score: 0.4861065447330475
        processing_time: 6.249222755432129
        model_version: titanet-large
        deepfake_score: null
    ErrorResponse:
      type: object
      properties:
        error:
          type: string
          description: Machine-readable error identifier
          example: validation_error
        message:
          type: string
          description: Human-readable explanation of the error
          example: Unsupported audio format
        status:
          type: integer
          description: HTTP status code associated with the error
          example: 400
        correlation_id:
          type: string
          description: Unique identifier for tracing failed requests
          example: a1b2c3d4-e5f6-7890-abcd-ef1234567890
  securitySchemes:
    api_key:
      type: apiKey
      in: header
      name: x-api-key

````