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

# Verify 2FA

> Verify 2FA code and complete authentication



## OpenAPI

````yaml post /v1/verify-2fa
openapi: 3.0.0
info:
  title: Authentication API
  version: 1.0.0
  description: API for authentication and authorization
servers: []
security:
  - bearerAuth: []
  - apiKeyAuth: []
tags:
  - name: Authentication
    description: Authentication operations
paths:
  /v1/verify-2fa:
    post:
      tags:
        - Authentication
      summary: Verify 2FA
      description: Verify 2FA code and complete authentication
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/VerifyOTPRequest'
      responses:
        '200':
          description: 2FA verification successful
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TokenResponse'
        '400':
          $ref: '#/components/responses/InvalidOTP'
components:
  schemas:
    VerifyOTPRequest:
      type: object
      required:
        - user_id
        - otp
      properties:
        user_id:
          type: string
          format: uuid
        otp:
          type: string
          minLength: 6
          maxLength: 6
    TokenResponse:
      type: object
      required:
        - access_token
        - expires_in
        - user_id
      properties:
        access_token:
          type: string
        expires_in:
          type: integer
          description: Token expiration in seconds
        user_id:
          type: string
          format: uuid
    Error:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
        message:
          type: string
  responses:
    InvalidOTP:
      description: Invalid OTP
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          example:
            code: auth.invalid_otp
            message: Invalid or expired OTP
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
    apiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key

````