---
title: "Remove a key fob assignment from a driver."
url: "https://developers.vzconnect.com/apis/driver-api/versions/dd59d93e-671c-494a-b1e2-63fbd7c9d7da/operations/removeDriverKey"
---

> Full API specification: https://developers.vzconnect.com/apis/driver-api/versions/dd59d93e-671c-494a-b1e2-63fbd7c9d7da.md

# Remove a key fob assignment from a driver.

`DELETE` `/cmd/v1/drivers/{drivernumber}/keys`

Operation ID: `removeDriverKey`

Delete the key fobs associated with a driver.

## Path parameters

- `drivernumber` (string, required) - The Driver Number whose key fobs are to be deleted.

## Request body (required)

Content types: `application/json`

## Responses

- `204` - Key fob assignment successfully removed from the driver. The response has no body.
- `400` - Bad request. The request body is invalid, or one or more key fobs are assigned to a different driver.
- `401` - Unauthorized. Authentication credentials are missing or invalid.
- `404` - Driver not found with the specified driver number.
- `500` - Internal server error.

## OpenAPI definition

```yaml
openapi: 3.0.0
info:
  title: Driver API
  version: "1.0"
servers:
  - url: https://api.us.vzconnect.com
paths:
  /cmd/v1/drivers/{drivernumber}/keys:
    delete:
      summary: Remove a key fob assignment from a driver.
      description: Delete the key fobs associated with a driver.
      operationId: removeDriverKey
      tags:
        - Driver API
      parameters:
        - name: drivernumber
          in: path
          required: true
          description: The Driver Number whose key fobs are to be deleted.
          schema:
            type: string
      requestBody:
        description: Key fob details identifying which key fob assignment to remove.
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/KeyFobList"
            example:
              - "23456789"
        required: true
      responses:
        "204":
          description: Key fob assignment successfully removed from the driver. The
            response has no body.
        "400":
          description: Bad request. The request body is invalid, or one or more key fobs
            are assigned to a different driver.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
        "401":
          description: Unauthorized. Authentication credentials are missing or invalid.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
        "404":
          description: Driver not found with the specified driver number.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
        "500":
          description: Internal server error.
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
components:
  schemas:
    KeyFobList:
      type: array
      description: A list of key fob identifiers. Each id is a hexadecimal string of
        8, 12 or 16 characters (12 and 16 character forms are reduced to 8).
        Returned ids are uppercase hexadecimal.
      items:
        type: string
        example: "23456789"
      example:
        - "23456789"
    Error:
      type: object
      description: Generic error response. The documentation does not define an
        explicit error body schema.
      properties:
        message:
          type: string
          description: A human-readable description of the error.
```
