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

# Update a driver

> This endpoint updates an existing driver by its ID.
<br/><i>This action is not enabled by default. You must request additional permissions to perform this action.</i>




## OpenAPI

````yaml /api/specs/identity-api.json patch /identity/v1/drivers/{driverId}
openapi: 3.0.0
info:
  title: Lynkwell API
  version: 1.376.0
  description: API Documentation for identity service
servers:
  - url: https://api.lynkwell.com
security: []
tags: []
paths:
  /identity/v1/drivers/{driverId}:
    patch:
      tags:
        - Driver
      summary: Update a driver
      description: >
        This endpoint updates an existing driver by its ID.

        <br/><i>This action is not enabled by default. You must request
        additional permissions to perform this action.</i>
      parameters:
        - in: path
          name: driverId
          schema:
            type: string
          required: true
      requestBody:
        description: The driver object to update.
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateDriverParams'
      responses:
        '200':
          description: The updated driver object.
          content:
            application/json:
              schema:
                type: object
                required:
                  - data
                properties:
                  data:
                    $ref: '#/components/schemas/UpdateDriverParams'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IdentityBadRequestError'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DefaultUnauthorizedError'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IdentityDefaultForbiddenError'
        '404':
          description: The resources that was requested could not be found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IdentityNotFoundError'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/IdentityInternalServerError'
      security:
        - oauth2:
            - write:driver
components:
  schemas:
    UpdateDriverParams:
      type: object
      properties:
        name:
          description: The name of the driver
          type: object
          nullable: true
          properties:
            first:
              type: string
            last:
              type: string
        preferredLocale:
          type: string
          nullable: true
          description: >-
            A string that is a valid [Unicode BCP 47 Locale
            Identifier](https://unicode.org/reports/tr35/#Unicode_locale_identifier).


            For example: "fa", "es-MX", "zh-Hant-TW".


            See [MDN - Intl - locales
            argument](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Intl#locales_argument).
        physicalAddress:
          $ref: '#/components/schemas/PhysicalAddress'
        contactDetails:
          type: object
          nullable: true
          description: At least one of "email" or "phone" is required.
          properties:
            email:
              type: string
            phone:
              type: string
    IdentityBadRequestError:
      type: object
      description: The response body for a 400 request
      properties:
        type:
          type: string
          enum:
            - BAD_REQUEST
        code:
          type: string
          enum:
            - INVALID_REQUEST_PARAMETERS
            - NETWORK_NOT_ENROLLED
            - INVITE_CODE_FOUND
            - CONTACT_DETAILS_ALREADY_EXISTS
            - TOKEN_ALREADY_EXISTS
            - INACTIVE_SITEHOST_STATUS
            - INACTIVE_INVITE_CODE
            - NOT_SITE_HOST
            - INVITATION_ALREADY_RESOLVED
            - DRIVER_ALREADY_ATTACHED
            - TOKEN_IS_ARCHIVED
            - DRIVER_IS_ARCHIVED
            - INACTIVE_SUBSCRIPTION
            - PENDING_INVOICE_ITEMS
            - UNSUCESSFULL_JUNCTION_DETACHMENT
        message:
          type: string
    DefaultUnauthorizedError:
      type: object
      description: The response body for a 401 request
      properties:
        type:
          type: string
          enum:
            - UNAUTHORIZED
        code:
          type: string
          enum:
            - UNAUTHORIZED
        message:
          type: string
    IdentityDefaultForbiddenError:
      type: object
      description: The response body for a 403 request
      properties:
        message:
          type: string
    IdentityNotFoundError:
      type: object
      description: The response body for a 404 request
      properties:
        type:
          type: string
          enum:
            - NOT_FOUND
        code:
          type: string
          enum:
            - TOKEN_NOT_FOUND
            - DRIVER_NOT_FOUND
            - INVITE_CODE_NOT_FOUND
            - TOKEN_AND_SITE_PARTNER_NOT_FOUND
            - INVITATION_NOT_FOUND
            - SITE_PARTNER_NOT_FOUND
            - NETWORK_VERIFY_SERVICE_NOT_FOUND
            - PAYMENT_TERMINAL_NOT_FOUND
            - ASSET_NOT_FOUND
            - ACTIVE_SUBSCRIPTION_NOT_FOUND
            - UNSUCESSFULL_JUNCTION_DETACHMENT
        message:
          type: string
    IdentityInternalServerError:
      type: object
      description: The response body for a 500 request
      properties:
        type:
          type: string
          enum:
            - INTERNAL_ERROR
        code:
          type: string
          enum:
            - INTERNAL_SERVER_ERROR
        message:
          type: string
    PhysicalAddress:
      description: Physical address details
      type: object
      properties:
        streetNumber:
          type: string
          minLength: 1
          maxLength: 100
        streetName:
          type: string
          minLength: 1
          maxLength: 100
        streetDetails:
          type: string
          minLength: 1
          maxLength: 100
        city:
          type: string
          minLength: 1
          maxLength: 100
        state:
          $ref: '#/components/schemas/USStates'
        postalCode:
          type: string
          minLength: 1
          maxLength: 10
        countryCode:
          type: string
          enum:
            - US
            - CA
      required:
        - streetNumber
        - streetName
        - city
        - state
        - postalCode
        - countryCode
    USStates:
      type: string
      enum:
        - AL
        - AK
        - AZ
        - AR
        - CA
        - CO
        - CT
        - DE
        - FL
        - GA
        - HI
        - ID
        - IL
        - IN
        - IA
        - KS
        - KY
        - LA
        - ME
        - MD
        - MA
        - MI
        - MN
        - MS
        - MO
        - MT
        - NE
        - NV
        - NH
        - NJ
        - NM
        - NY
        - NC
        - ND
        - OH
        - OK
        - OR
        - PA
        - RI
        - SC
        - SD
        - TN
        - TX
        - UT
        - VT
        - VA
        - WA
        - WV
        - WI
        - WY
        - DC
        - AS
        - GU
        - MP
        - PR
        - UM
        - VI
  securitySchemes:
    oauth2:
      type: oauth2
      description: OAuth2 Client Credentials Flow
      flows:
        clientCredentials:
          tokenUrl: https://lynkwell-prod.us.auth0.com/oauth/token
          scopes:
            read:asset: Retrieve assets
            write:asset: Create and update assets
            read:assetgroup: Retrieve asset groups
            write:assetgroup: Create and update asset groups
            read:assetstatus: Retrieve asset statuses
            read:chargingstationmodel: Retrieve charging station models
            write:chargingstationmodel: Create and update charging station models
            write:network: Create and update networks
            write:sitepartner: Create and update site partners
            read:sitepartner: Retrieve site partners
            write:sitepartneruser: Create and update site partner users
            read:sitepartneruser: Retrieve site partner users
            read:networkaccessprofile: Retrieve network access profiles
            write:paymentprofile: Create payment profile
            write:onboardinglink: Create an onboarding link
            read:invoice: Retrieve an invoice
            write:session: Create or update a session
            read:session: Retrieve a session
            write:ticket: Create a ticket
            write:verificationcode: Send and confirm verification codes
            write:driver: Create and update drivers
            read:driver: Retrieve drivers
            write:token: Create and update tokens
            read:token: Retrieve tokens
            read:tokenvalue: Retrieve token by ID including its value
            write:invitecode: Create and update invite codes
            write:invitation: Create and update invitations
            read:invitation: Retrieve invitations
            read:payment_terminals_payment: Read payments from payment terminal
            abort:session: Abruptly end session
            read:paymentprofile: Retrieve payment profile from payment terminal
            write:ocpp: Sends request over OCPP
            write:ocpp.raw_request: Sends raw request over OCPP
            write:notification.email: Create and update email
            read:invoiceitem: Retrieve invoice item
            read:subscription: Retrieve subscription
            write:plugandcharge_enrollment: Update Plug and Charge enrollment status
            write:projects: Create and update projects
            read:projects: Retrieve projects
            write:project_stations: Create and update project stations
            write:panel: Create and update panels.
            read:panel: Retrieve panels.
            write:webhooks: Create, update, and delete webhooks
            read:webhooks: Retrieve webhooks

````