Skip to main content
PATCH
Update Business Travel

Update Business Travel

Update an existing business travel record. Only provide the fields you want to change. Emissions will be recalculated automatically if relevant fields are modified.
Even though all fields are individually optional, you must always provide either distance_km OR both origin and destination in every update request — the distance validation runs on every call.

Request

Headers

string
required
Your API key for authenticationExample: sk_live_1234567890abcdef
string
required
Your organization UUIDExample: a8315ef3-dd50-43f8-b7ce-d839e68d51fa
string
required
Must be application/json

Path Parameters

string
required
The unique identifier (UUID) of the business travel recordExample: 550e8400-e29b-41d4-a716-446655440000

Body Parameters

All fields are optional. Only include the fields you want to update.
string
Mode of transportAvailable values: car, metro, train, trolleybus, bus, motorbike, aircraft, ferry
date
Start date of the business travelFormat: YYYY-MM-DD
date
End date of the business travel. Must be on or after start_dateFormat: YYYY-MM-DD
number
Distance traveled in kilometersConstraints: Must be greater than 0
string
Starting location addressConstraints: Max 500 charactersExample: "Madrid, Spain"
string
Ending location address. Cannot be the same as origin unless distance_km is also provided.Constraints: Max 500 charactersExample: "Barcelona, Spain"
string
Optional label for this travel recordConstraints: Max 255 characters
string
Email of the traveler
string
Whether this is a one-way or round tripAvailable values: one_way, round
integer
Number of tripsConstraints: 1 to 10,000 (further limited by date range — max 100 per day)
integer
Number of passengers per tripConstraints: Must be at least 1
string
Vehicle size. Required when transport_type is car, not allowed for other types.Available values: small, medium, large
string
Fuel type. Required when transport_type is car, not allowed for other types.Available values: diesel, petrol, natural_gas, lpg, electric, hybrid, not_fuel_based, do_not_know
string
Whether the vehicle uses renewable energyAvailable values: yes, no, do_not_know
string
Record statusAvailable values: active, pending, loading, completed, error

Response

Returns the updated business travel object.
string
Unique identifier (UUID)
string
Organization UUID
string | null
Travel record label
string | null
Traveler email
string
Mode of transport
date
Start date of travel
date
End date of travel
number | null
Distance in km
string | null
How the distance was obtained: manual, geodesic, or google_maps
string | null
Starting location address
string | null
Ending location address
object | null
Geocoded origin location resolved from the origin address
object | null
Geocoded destination location (same structure as origin_geocode)
string
Trip type: one_way or round
integer
Number of trips
integer
Number of passengers per trip
string | null
Vehicle size (car only)
string | null
Fuel type (car only)
string | null
Renewable energy usage
string
Record status: pending, active, error, loading, or completed
string
Record source: api, manual, bulk_upload, or form
number | null
Calculated CO2 equivalent emissions in kg
string | null
File UUID if created via bulk upload
string | null
Name of the source file, if created via bulk upload
object | null
The user who created this record
datetime
Creation timestamp
datetime | null
Last update timestamp

Example

Successful Response

When updating fields that affect emissions (distance, transport type, travel number, travel type), the co2e value will be recalculated asynchronously. The status may temporarily change to pending.

Common Errors

401 Unauthorized

Cause: Missing or invalid API key

403 Forbidden

Cause: The authenticated user is not a member of the organization

404 Not Found

Cause: Business travel not found or doesn’t belong to your organization

422 Unprocessable Entity

Cause: Missing distance — must provide either distance_km OR both origin and destination
Cause: Unknown field sent in request body (this endpoint rejects extra fields)

Use Cases

Change Route with Distance Recalculation

Update origin and destination to recalculate distance:

Switch to Round Trip

Update Car Details

Get Business Travel

Get current business travel details

Create Business Travel

Create a new business travel record

Delete Business Travel

Remove a business travel record

List Business Travels

Retrieve all business travels