REST DocumentationEmployeesPATCH Update a travel data entry

Update a travel data entry

Changes only the fields that are sent. Moving valid_from onto a day the employee already has an entry for answers 422 on valid_from. Requires the Inovex module.

Availability: Full version only — a Clock instance answers 404 for this endpoint.

Request

PATCH /api/v1/employees/{username}/travel-data/{id}
curl --request PATCH \
     --url 'https://www.zep-online.de/zepinstanz/next/api/v1/employees/{username}/travel-data/{id}' \
     --header 'Accept: application/json' \
     --header 'Authorization: Bearer {token}' \
     --header 'Content-Type: application/json' \
     --data '{
       "valid_from": "2026-01-01",
       "distance": 1.5,
       "travel_time": 1.5
     }'

Path parameters

  • Name
    username
    Type
    string
    Description

    The employee username

  • Name
    id
    Type
    integer
    Description

    Identifier of the travel data entry.

Request body

  • Name
    valid_from
    Type
    string (date)
    Description

    The first day the distance and travel time apply, as Y-m-d. An employee has at most one entry per day.

  • Name
    distance
    Type
    number
    Description

    The distance to the workplace in kilometres, 0 to 99999999.99, at most two decimals.

  • Name
    travel_time
    Type
    number
    Description

    The travel time to the workplace in hours, 0 to 9999.9999, at most four decimals.

Response

{
  "data": {
    "id": 1,
    "username": "max.mustermann",
    "valid_from": "2026-01-01",
    "distance": 1.5,
    "travel_time": 1.5
  }
}

Response fields

  • Name
    id
    Type
    integer
    Description

    Unique identifier of the travel data entry.

  • Name
    username
    Type
    string
    Description

    Username of the employee the entry belongs to.

  • Name
    valid_from
    Type
    string (date)
    Description

    First calendar day the distance and travel time apply, as Y-m-d.

  • Name
    distance
    Type
    number
    Description

    Distance to the workplace in kilometres.

  • Name
    travel_time
    Type
    number
    Description

    Travel time to the workplace in hours.

Generated from the OpenAPI specification — edit the source code, not this page.