---
title: "Update driver"
method: PATCH
path: "/drivers/{id}"
tags: ["drivers"]
---

# Update driver

`PATCH /drivers/{id}`

## Request

- Base URL: `https://api.vepathos.com`
- URL: `https://api.vepathos.com/drivers/{id}`
- Auth: API key in header `Authorization`

Send only the fields to change.

## Path parameters

- `id` integer, required

## Request body

- DriverUpdate
  - `first_name` string, nullable
  - `last_name` string, nullable
  - `work_schedules` string[], nullable: Working hours. RFC 5545 VEVENT: `DTSTART` plus `DTEND` or `DURATION`, optionally `RRULE`. Join lines with `\n`.
  - `start_point` string, nullable: Where the driver starts the day. Coordinates in ISO 6709 decimal degrees, latitude then longitude with signs, e.g. `+40.7128-74.0060`.
  - `end_point` string, nullable: Where the driver ends the day. Coordinates in ISO 6709 decimal degrees, latitude then longitude with signs, e.g. `+40.7128-74.0060`.
  - `work_areas` array[], nullable: Polygons, each an array of `geo_point` vertices.
    - string[]
  - `vehicles` DriverVehicleCreate[], nullable: Vehicle types the driver can operate.
    - `qty` integer, required
    - `id` string, required

## Response `200`

The updated driver.

- DriverResponse
  - `first_name` string, required
  - `last_name` string, nullable
  - `work_schedules` string[], nullable: Working hours. RFC 5545 VEVENT: `DTSTART` plus `DTEND` or `DURATION`, optionally `RRULE`. Join lines with `\n`.
  - `start_point` string, nullable: Where the driver starts the day. Coordinates in ISO 6709 decimal degrees, latitude then longitude with signs, e.g. `+40.7128-74.0060`.
  - `end_point` string, nullable: Where the driver ends the day. Coordinates in ISO 6709 decimal degrees, latitude then longitude with signs, e.g. `+40.7128-74.0060`.
  - `work_areas` array[], nullable: Polygons, each an array of `geo_point` vertices.
    - string[]
  - `id` union, required
    - string
    - integer
  - `vehicles` DriverVehicleResponse[], nullable: Vehicle types the driver can operate.
    - `name` string, required
    - `volume` integer, nullable
    - `volume_unit` 'CUBIC_CENTIMETER' | 'CUBIC_METER' | 'LITER' | 'CUBIC_INCH' | 'CUBIC_FEET' | 'GALLON'
    - `weight` integer, nullable
    - `weight_unit` 'GRAMS' | 'KILOGRAMS' | 'OUNCES' | 'POUNDS'
    - `consumption` integer, nullable
    - `consumption_unit` 'LITERS_PER_100KM' | 'KILOMETERS_PER_LITER' | 'MILES_PER_GALLON' | 'GALLONS_PER_MILE'
    - `category_type` 'TRUCK' | 'VAN' | 'PICKUP' | 'MOTORCYCLE' | 'BICYCLE'
    - `engine_type` 'GASOLINE' | 'DIESEL' | 'CNG' | 'ELECTRIC' | 'HYBRID' | 'MECHANIC'
    - `id` union, required
      - string
      - integer
    - `qty` integer, required

## Other responses

- `401`: Missing, expired or invalid access token.
- `404`: The resource does not exist in your account.
- `422`: The body or a parameter does not match the schema.

---

[API](https://skmtc.dev/vepathos/apis/vepathos-route-optimization-api.md) · [All operations](https://skmtc.dev/vepathos/apis/vepathos-route-optimization-api/llms.txt) · [OpenAPI document](https://skmtc.dev/vepathos/apis/vepathos-route-optimization-api/revisions/00caa1ca62d9?raw)
