---
title: "Update a vehicle's details."
url: "https://developers.vzconnect.com/apis/vehicle-api-v1/versions/3941fe83-a6d1-4bef-90e3-c94cadaf0d4d/operations/updateVehicle"
---

> Full API specification: https://developers.vzconnect.com/apis/vehicle-api-v1/versions/3941fe83-a6d1-4bef-90e3-c94cadaf0d4d.md

# Update a vehicle's details.

`PUT` `/cmd/v1/vehicles/{vehiclenumber}`

Operation ID: `updateVehicle`

Update a vehicle's profile details. The vehicle must already be assigned a unique Vehicle Number in order to update via the API. PUT methods do not return an object; the response is limited to standard HTTP status codes. This is a partial update: fields marked as nullable in the request schema that are omitted or null are left unchanged. If VehicleNumber is provided, the vehicle's Vehicle Number is changed to that value. HasNavigationDevice cannot be updated through this method.

## Path parameters

- `vehiclenumber` (string, required) - The Vehicle Number; the unique identifier used to reference the vehicle within the API.

## Request body

Content types: `application/json`

## Responses

- `204` - Vehicle successfully updated.
- `400` - Bad request. No vehicle exists with the specified vehicle number (message: "The Client Vehicle ID specified was not a valid ID."), or the request body is invalid.
- `401` - Unauthorized. Authentication credentials are missing or invalid.
- `500` - Internal server error.

## OpenAPI definition

```yaml
openapi: 3.0.0
info:
  title: Vehicle API
  version: "1.0"
servers:
  - url: https://api.us.vzconnect.com
paths:
  /cmd/v1/vehicles/{vehiclenumber}:
    put:
      summary: Update a vehicle's details.
      description: >-
        Update a vehicle's profile details. The vehicle must already be assigned
        a unique Vehicle Number in order to update via the API. PUT methods do
        not return an object; the response is limited to standard HTTP status
        codes.


        This is a partial update: fields marked as nullable in the request
        schema that are omitted or null are left unchanged. If VehicleNumber is
        provided, the vehicle's Vehicle Number is changed to that value.
        HasNavigationDevice cannot be updated through this method.
      operationId: updateVehicle
      tags:
        - Vehicle API
      parameters:
        - name: vehiclenumber
          in: path
          required: true
          description: The Vehicle Number; the unique identifier used to reference the
            vehicle within the API.
          schema:
            type: string
            example: "890001"
      requestBody:
        description: Vehicle attributes to update.
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/VehicleUpdateRequest"
            example:
              Name: Vehicle 1
              RegistrationNumber: "44046"
              VehicleNumber: "890001"
              VehicleSize: 0
              FuelType: 1
      responses:
        "204":
          description: Vehicle successfully updated.
          content:
            application/json: {}
        "400":
          description: 'Bad request. No vehicle exists with the specified vehicle number
            (message: "The Client Vehicle ID specified was not a valid ID."), or
            the request body is invalid.'
          content:
            application/json: {}
        "401":
          description: Unauthorized. Authentication credentials are missing or invalid.
          content:
            application/json: {}
        "500":
          description: Internal server error.
          content:
            application/json: {}
      x-kong-route-defaults:
        strip_path: false
        paths:
          - ~/cmd/v1/vehicles/[^/]+/?$
components:
  schemas:
    VehicleUpdateRequest:
      type: object
      description: Request body to update a vehicle's profile details.
      properties:
        Name:
          type: string
          nullable: true
          description: The Vehicle Name as recorded within the REVEAL vehicle profile.
          example: Vehicle 1
        VehicleNumber:
          type: string
          nullable: true
          description: The Vehicle Number; the unique identifier used to reference the
            vehicle within the API.
          example: "890001"
        RegistrationNumber:
          type: string
          nullable: true
          description: Registration Number. When provided it must be unique within an
            account.
          example: "44046"
        VIN:
          type: string
          nullable: true
          description: Vehicle Identification Number.
          example: null
        Make:
          type: string
          nullable: true
          description: The vehicle manufacturer's brand.
          example: null
        Year:
          type: integer
          nullable: true
          description: The year the vehicle was manufactured.
          example: null
        Model:
          type: string
          nullable: true
          description: The type of vehicle by the manufacturer.
          example: null
        TankCapacity:
          type: number
          format: double
          nullable: true
          description: Tank Capacity in liters.
          example: null
        HighwayMPG:
          type: number
          format: double
          nullable: true
          description: Estimated Highway MPG in liters.
          example: null
        CityMPG:
          type: number
          format: double
          nullable: true
          description: Estimated City MPG in liters.
          example: null
        VehicleSize:
          type: integer
          nullable: true
          description: "Vehicle Size classification. 0: Light Duty, 1: Medium Duty, 2:
            Heavy Duty, 3: Super Heavy Duty."
          enum:
            - 0
            - 1
            - 2
            - 3
          example: 0
        FuelType:
          type: integer
          description: "The Fuel Type of the vehicle. 0: Not set, 1: Unleaded, 2: Diesel,
            3: Electric."
          enum:
            - 0
            - 1
            - 2
            - 3
          example: 1
```
