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

# Update Details

> Update current user's details



## OpenAPI

````yaml Post /user/details
openapi: 3.0.1
info:
  title: User API
  version: 1.0.0
servers:
  - url: https://our-secret-api-url.com
security: []
paths:
  /user/details:
    post:
      description: Update current user's details
      operationId: updateCurrentUserDetails
      parameters:
        - $ref: '#/components/parameters/X-API-KEY'
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: Name of the user
                username:
                  type: string
                  description: Username of the user
                email:
                  type: string
                  description: User's email
                phone:
                  type: string
                  description: User's phone number
                bio:
                  type: string
                  description: User's bio
                  maxLength: 160
                image:
                  type: string
                  description: Previously uploaded profile image URL
                newImage:
                  type: string
                  format: binary
                  description: New profile image to upload
      responses:
        '200':
          description: User details updated successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                    description: HTTP status code
                  id:
                    type: integer
                    description: User ID
                  username:
                    type: string
                    description: Updated username of the user
                  name:
                    type: string
                    description: Updated name of the user
                  image:
                    type: string
                    description: Updated profile image URL
                  bio:
                    type: string
                    description: Updated biography of the user
                  email:
                    type: string
                    description: Updated email of the user
                  phone:
                    type: string
                    description: Updated phone number of the user
                  verifiedAt:
                    type: string
                    format: date-time
                    nullable: true
                    description: Verification timestamp if the user is verified
                  role:
                    type: string
                    enum:
                      - user
                      - admin
                    description: Role of the user
        '422':
          description: Validation errors or image upload failure
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                    description: HTTP status code
                  message:
                    type: string
                    description: Error message explaining the validation failure
                  errors:
                    type: array
                    items:
                      type: object
                      properties:
                        path:
                          type: string
                          description: Path of the field that caused the validation error
                        message:
                          type: string
                          description: Validation error message
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: integer
                    description: HTTP status code
                  message:
                    type: string
                    description: Error message
      security:
        - bearerAuth: []
components:
  parameters:
    X-API-KEY:
      name: X-API-KEY
      description: API key required for authentication
      in: header
      required: true
      schema:
        type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````