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

# Update client



## OpenAPI

````yaml patch /users/{id}
openapi: 3.0.0
info:
  title: Identety API
  description: Identity Provider API
  version: '1.0'
  contact: {}
servers: []
security: []
tags: []
paths:
  /users/{id}:
    patch:
      tags:
        - User
      summary: Update client
      operationId: UserController_updateUser
      parameters:
        - name: id
          required: true
          in: path
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateUserDto'
      responses:
        '200':
          description: Client updated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserResponseModel'
        '401':
          description: Unauthorized. Invalid API key.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UnAuthorizedResponseSwaggerModel'
        '404':
          description: Client not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NotFoundResponseSwaggerModel'
      security:
        - x-api-key: []
components:
  schemas:
    UpdateUserDto:
      type: object
      properties:
        name:
          type: string
          example: John Doe
        givenName:
          type: string
          example: John
        familyName:
          type: string
          example: Doe
        picture:
          type: string
          example: https://example.com/photo.jpg
        locale:
          type: string
          example: en-US
        address:
          $ref: '#/components/schemas/UserAddressDto'
        metadata:
          type: object
          example:
            customField: value
      required:
        - name
        - givenName
        - familyName
        - picture
        - locale
        - address
        - metadata
    UserResponseModel:
      type: object
      properties:
        id:
          type: string
          example: 43fad864-738d-4367-a012-2b8c6948c36a
        name:
          type: string
          example: John Doe
        givenName:
          type: string
          example: John
        familyName:
          type: string
          example: Doe
        picture:
          type: string
          example: https://example.com/photo.jpg
        locale:
          type: string
          example: en-US
        address:
          $ref: '#/components/schemas/UserAddressResponseModel'
        metadata:
          type: object
          example:
            customField: value
      required:
        - id
        - name
        - givenName
        - familyName
        - picture
        - locale
        - address
        - metadata
    UnAuthorizedResponseSwaggerModel:
      type: object
      properties:
        message:
          type: string
          example: Invalid API key
        statusCode:
          type: number
          example: 401
        error:
          type: string
          example: Unauthorized
      required:
        - message
        - statusCode
        - error
    NotFoundResponseSwaggerModel:
      type: object
      properties:
        message:
          type: string
          example: Not Found
        statusCode:
          type: number
          example: 401
      required:
        - message
        - statusCode
    UserAddressDto:
      type: object
      properties:
        streetAddress:
          type: string
          example: 123 Main St
        locality:
          type: string
          example: New York
        region:
          type: string
          example: NY
        postalCode:
          type: string
          example: '10001'
        country:
          type: string
          example: USA
      required:
        - streetAddress
        - locality
        - region
        - postalCode
        - country
    UserAddressResponseModel:
      type: object
      properties:
        streetAddress:
          type: string
          example: 123 Main St
        locality:
          type: string
          example: New York
        region:
          type: string
          example: NY
        postalCode:
          type: string
          example: '10001'
        country:
          type: string
          example: USA
      required:
        - streetAddress
        - locality
        - region
        - postalCode
        - country
  securitySchemes:
    x-api-key:
      type: apiKey
      in: header
      name: x-api-key

````