Transport

Update a segment

Only the fields given change. trip_id re-files it on another trip in the same account. Correcting the places or date of an inferred drive makes it a real leg.

patch/api/segments/{id}

Request

  • Base URL: https://trvlrr.app
  • URL: https://trvlrr.app/api/segments/{id}
  • Auth: HTTP bearer

Path parameters

idstring required

The id.

Request body

mode'flight' | 'train' | 'bus' | 'ferry' | 'car_rental' | 'drive' | 'other'

How: flight, train, bus, ferry, car_rental, drive or other.

providerstring nullable

Airline, rail operator, bus or rental company, e.g. Qantas.

servicestring nullable

Flight or service number, e.g. QF1.

from_placestring nullable

Where it leaves from, e.g. Sydney or Sydney Airport.

from_countrystring nullable

Country it leaves from (name or ISO code).

from_codestring nullable

Departure airport or station code, e.g. SYD.

to_placestring nullable

Where it arrives.

to_countrystring nullable

Country it arrives in.

to_codestring nullable

Arrival airport or station code, e.g. LHR.

depart_datestring nullable

Departure date. Date, YYYY-MM-DD.

depart_timestring nullable

Local departure time "HH:MM".

arrive_timestring nullable

Local arrival time "HH:MM", with " +N" if it lands N days after departure, e.g. "05:20 +1".

depart_tzstring nullable

IANA time zone at departure, e.g. Australia/Sydney.

arrive_tzstring nullable

IANA time zone at arrival.

depart_utcstring nullable

Derived from the local time and zone; only set to override.

arrive_utcstring nullable

Derived from the local time and zone; only set to override.

booking_refstring nullable

Booking or confirmation reference.

price_rawstring nullable

Price with currency, e.g. "AUD 420.00".

statusstring nullable

Free text, e.g. "Confirmed".

notesstring nullable

Anything else worth keeping.

categorystring nullable

Free text category.

operating_carrierstring nullable

Operating carrier if different from the provider.

aircraftstring nullable

Aircraft type.

cabinstring nullable

Cabin or class.

seatsstring nullable

Seat numbers.

depart_terminalstring nullable

Departure terminal.

arrive_terminalstring nullable

Arrival terminal.

ticket_numbersstring nullable

Ticket numbers.

agencystring nullable

Booked through (travel agency or site).

distance_kmnumber nullable

Distance in km, if known.

payment_status'paid' | 'due' | 'on_arrival' | 'null' nullable

paid, due (to pay before the trip) or on_arrival (pay there or on the day).

payment_method'card' | 'cash' | 'null' nullable

card or cash.

traveler_idsstring[]

Who travelled; defaults to the trip's travellers.

trip_idstring

Move the segment to this trip (same account, both writable).

Response

Updated.

okboolean required

Changes

No recorded changes to this operation across all 1 revision of this API.