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

# Reset password using a verification code



## OpenAPI

````yaml api-reference/openapi.json post /api/auth/password/reset-with-code
openapi: 3.0.0
info:
  title: Tandem IT API
  version: 1.0.0
  description: API for tandem it backend
servers:
  - url: https://tandem.hlofiys.xyz
    description: Production server
security: []
tags:
  - name: Documentation
    description: API documentation endpoint
paths:
  /api/auth/password/reset-with-code:
    post:
      tags:
        - Authentication
      summary: Reset password using a verification code
      operationId: resetPasswordWithCode
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PasswordResetWithCodeRequest'
      responses:
        '200':
          description: >-
            Password has been successfully reset. Returns a new pair of access
            and refresh tokens
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PasswordResetWithCodeResponse'
        '400':
          description: >-
            Bad Request. The request is malformed, or the provided code is
            invalid/expired
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ValidationError'
        '404':
          description: Not Found. A user with the specified email was not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    PasswordResetWithCodeRequest:
      type: object
      required:
        - email
        - code
        - new_password
      properties:
        email:
          type: string
        code:
          type: string
        new_password:
          type: string
    PasswordResetWithCodeResponse:
      type: object
      required:
        - token
        - refresh_token
      properties:
        token:
          type: string
          description: JWT token
        refresh_token:
          type: string
          description: Refresh token
    ValidationError:
      type: object
      required:
        - message
      properties:
        message:
          type: string
          example: Validation failed
        errors:
          type: object
          description: A map of field names to their respective error messages.
          additionalProperties:
            type: string
          example:
            name: The name field is required.
            price: The price must be a valid number.
            hall_id: A valid hall_id is required.
    Error:
      type: object
      required:
        - message
      properties:
        message:
          type: string

````