---
title: "Open one flight trip"
method: GET
path: "/v1/flights/trips/{tripId}"
tags: ["Flights"]
---

# Open one flight trip

`GET /v1/flights/trips/{tripId}`

Returns one trip's full itinerary and every fare on it (each kind-tagged), for the given tripId within its searchId. searchId is required – it comes from the search/results snapshot the tripId was read from.

## Path parameters

- `tripId` string, required

## Query parameters

- `searchId` string, required
- `currency` string
- `locale` string
- `view` 'default' | 'detail'

## Response `200`

The full itinerary + all fares for the trip (agent default) or, with ?view=detail, the per-segment detail projection.

- union
  - object — One itinerary carrying its fares (cheapest-first), and what this read resolved currency and locale to.
    - `tripId` string, required — Opaque trip id, shaped {searchId}:{tripCode}; read it back with GET /v1/flights/trips/{tripId}.
    - `featured` 'best_value' | 'cheapest' | 'cheapest_direct' — The single highest-priority featured label, best_value > cheapest > cheapest_direct. best_value ranks on the score of the trip's CHEAPEST fare, the same statistic sort=score_desc orders by, so on a score_desc read it lands on the first result. cheapest and cheapest_direct break a price tie by that same score, then by leg-1 departure – cheapest keeps the LATER departure, cheapest_direct the EARLIER one. Under sort=score_desc the two picks are also MOVED toward positions 2 and 3, matching wego.com. Those positions are targets, not guarantees: a pick already at or above its target stays put, and cheapest_direct lands at position 2 when the first result is itself at the cheapest price.
    - `stops` number, required — Trip-level stop count, the max across legs.
    - `durationMinutes` number, required — Total trip duration in minutes, summed across legs.
    - `outbound` object, required — The outbound leg.
      - `from` string, required — Departure airport IATA code.
      - `to` string, required — Arrival airport IATA code.
      - `departsAt` string, required — Leg departure, ISO 8601 with offset.
      - `arrivesAt` string, required — Leg arrival, ISO 8601 with offset.
      - `durationMinutes` number, required — Total leg duration in minutes.
      - `stops` number, required — Stops on this leg (0 is nonstop).
      - `airlines` string[], required — Raw IATA airline codes on the leg (unchanged). See airlinesDetail for display names.
      - `airlinesDetail` object[] — Index-aligned display names for `airlines`, resolved from the search snapshot's airline dictionary – the same join the results cards use; the bare code is the fallback on a dictionary miss. Omitted when the leg carries no airline codes. Additive – raw `airlines` codes are unaffected.
        - `code` string, required — IATA airline code (the operating/marketing carrier).
        - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
      - `operatingAirlines` object[] — Carriers that fly a segment of this leg they do not market. airlines / airlinesDetail name the MARKETING carriers only, so on a leg sold by one airline every code here is a carrier absent from the ticket; on an interline leg sold by two, one of these may also market a different segment. Read this before telling a traveller who they fly – mileage accrual, lounge access and baggage rules follow the operating carrier. Distinct codes, folded from this leg's own segments; pair it with segments[] to see which flight each one operates. PRESENT ONLY WHEN A SEGMENT PROVES A CODESHARE: absent means none was proven on this leg, never a promise that the marketing carrier operates every segment.
        - `code` string, required — IATA airline code (the operating/marketing carrier).
        - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
      - `transportTypes` string[], required — Distinct transport modes across this leg's segments, in segment order. Always present and never empty: an all-flight leg reads ["FLIGHT"], so one read of this field replaces folding segments[] yourself. Anything else means part of this leg is not a plane, and segments[] says which part.
      - `segments` object[] — Per-segment identity (marketing/operating carrier, flight number, times, transport mode); omitted when upstream carries no segments for the leg. Previously reachable only via ?view=detail.
        - `from` string, required — Departure airport IATA code.
        - `to` string, required — Arrival airport IATA code.
        - `departsAt` string, required — Segment departure, ISO 8601 with offset.
        - `arrivesAt` string, required — Segment arrival, ISO 8601 with offset.
        - `marketingCarrier` object, required — The carrier whose code is on the ticket (the marketing / flight-number airline).
          - `code` string, required — IATA airline code (the operating/marketing carrier).
          - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
        - `operatingCarrier` object — The carrier that actually operates the flight – present ONLY on a codeshare, when it differs from the marketing carrier.
          - `code` string, required — IATA airline code (the operating/marketing carrier).
          - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
        - `flightNumber` string, required — The marketing flight designator, e.g. SQ12.
        - `transportType` 'FLIGHT' | 'TRAIN' | 'BUS' | 'OTHER', required — How this segment travels. FLIGHT is a plane. TRAIN and BUS are surface segments sold under a flight number, which airlines do publish, for example the Etihad coach between Dubai Bus Station and Abu Dhabi. OTHER is a mode upstream states that this API does not model, and is never a flight. Absent upstream is published as FLIGHT, which is what every segment meant before this field existed.
        - `fromName` string — Departure endpoint's display name, when upstream hydrates it on the segment, for example "Dubai Bus Station" beside the bare XNB. Absent rather than guessed when upstream carries no name.
        - `toName` string — Arrival endpoint's display name, when upstream hydrates it on the segment.
        - `fromStationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place the departure endpoint is, when upstream states it. Absent means unstated, never airport: read transportType, which is always present, to judge whether this segment is a flight.
        - `toStationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place the arrival endpoint is, when upstream states it. Absent means unstated, never airport.
    - `return` object — The return leg; present only on a round trip.
      - `from` string, required — Departure airport IATA code.
      - `to` string, required — Arrival airport IATA code.
      - `departsAt` string, required — Leg departure, ISO 8601 with offset.
      - `arrivesAt` string, required — Leg arrival, ISO 8601 with offset.
      - `durationMinutes` number, required — Total leg duration in minutes.
      - `stops` number, required — Stops on this leg (0 is nonstop).
      - `airlines` string[], required — Raw IATA airline codes on the leg (unchanged). See airlinesDetail for display names.
      - `airlinesDetail` object[] — Index-aligned display names for `airlines`, resolved from the search snapshot's airline dictionary – the same join the results cards use; the bare code is the fallback on a dictionary miss. Omitted when the leg carries no airline codes. Additive – raw `airlines` codes are unaffected.
        - `code` string, required — IATA airline code (the operating/marketing carrier).
        - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
      - `operatingAirlines` object[] — Carriers that fly a segment of this leg they do not market. airlines / airlinesDetail name the MARKETING carriers only, so on a leg sold by one airline every code here is a carrier absent from the ticket; on an interline leg sold by two, one of these may also market a different segment. Read this before telling a traveller who they fly – mileage accrual, lounge access and baggage rules follow the operating carrier. Distinct codes, folded from this leg's own segments; pair it with segments[] to see which flight each one operates. PRESENT ONLY WHEN A SEGMENT PROVES A CODESHARE: absent means none was proven on this leg, never a promise that the marketing carrier operates every segment.
        - `code` string, required — IATA airline code (the operating/marketing carrier).
        - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
      - `transportTypes` string[], required — Distinct transport modes across this leg's segments, in segment order. Always present and never empty: an all-flight leg reads ["FLIGHT"], so one read of this field replaces folding segments[] yourself. Anything else means part of this leg is not a plane, and segments[] says which part.
      - `segments` object[] — Per-segment identity (marketing/operating carrier, flight number, times, transport mode); omitted when upstream carries no segments for the leg. Previously reachable only via ?view=detail.
        - `from` string, required — Departure airport IATA code.
        - `to` string, required — Arrival airport IATA code.
        - `departsAt` string, required — Segment departure, ISO 8601 with offset.
        - `arrivesAt` string, required — Segment arrival, ISO 8601 with offset.
        - `marketingCarrier` object, required — The carrier whose code is on the ticket (the marketing / flight-number airline).
          - `code` string, required — IATA airline code (the operating/marketing carrier).
          - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
        - `operatingCarrier` object — The carrier that actually operates the flight – present ONLY on a codeshare, when it differs from the marketing carrier.
          - `code` string, required — IATA airline code (the operating/marketing carrier).
          - `name` string, required — Airline display name from the search snapshot's airline dictionary; the bare code is the fallback on a dictionary miss.
        - `flightNumber` string, required — The marketing flight designator, e.g. SQ12.
        - `transportType` 'FLIGHT' | 'TRAIN' | 'BUS' | 'OTHER', required — How this segment travels. FLIGHT is a plane. TRAIN and BUS are surface segments sold under a flight number, which airlines do publish, for example the Etihad coach between Dubai Bus Station and Abu Dhabi. OTHER is a mode upstream states that this API does not model, and is never a flight. Absent upstream is published as FLIGHT, which is what every segment meant before this field existed.
        - `fromName` string — Departure endpoint's display name, when upstream hydrates it on the segment, for example "Dubai Bus Station" beside the bare XNB. Absent rather than guessed when upstream carries no name.
        - `toName` string — Arrival endpoint's display name, when upstream hydrates it on the segment.
        - `fromStationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place the departure endpoint is, when upstream states it. Absent means unstated, never airport: read transportType, which is always present, to judge whether this segment is a flight.
        - `toStationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place the arrival endpoint is, when upstream states it. Absent means unstated, never airport.
    - `fares` object[], required — Bookable fares for this trip, cheapest-first.
      - `kind` 'wego' | 'airline' | 'partner', required — Fare source: wego (Book-on-Wego), airline (booked with the carrier) or partner (an OTA).
      - `fareId` string, required — Opaque fare id; pass it to the fare-options and booking-link routes.
      - `providerCode` string, required — Booking provider code (the OTA or airline selling this fare).
      - `providerName` string, required — Booking provider display name.
      - `price` object, required — Fare price. total/totalUsd are the whole-party amount, fee-inclusive, and are the authoritative figure for this fare. Search-time fares carry no per-passenger breakdown.
        - `total` number, required — Whole-party total (adults + children + infants) in the requested currency, including payment + booking fees. No separate tax breakdown at search time: the fare options read carries a tax figure, set by the cabin rather than by the individual fare option.
        - `totalUsd` number, required — Whole-party total in USD (the cheapest-first sort key), including fees.
        - `currency` string, required — ISO 4217 currency of total.
        - `scope` 'party', required — total covers the whole party (adults + children + infants), not per-person.
        - `includesFees` true, required — total includes payment + booking fees; there is no separate tax breakdown at search time.
      - `refundable` boolean, required — Whether this fare is refundable, as the provider states it.
      - `hasFareOptions` boolean, required — Whether GET /v1/flights/fares/{fareId}/options can expand this fare into branded options.
      - `handoffUrl` string, required — Deep link that hands the booking off to the provider or wego.com checkout for this fare.
    - `metadata` object, required — What this read resolved currency and locale to, and how each was decided.
      - `currencyCode` string, required — The currency this read ASKED upstream for, and the one every price on it is meant to be in. Read it beside currencyCodeSource before you show a number: a price computed in the wrong currency renders as a perfectly normal price, with no error and no odd shape to notice, so the response states which one rather than leaving it to be inferred. Where the operation also publishes a top-level currencyCode, that field reports the currency the prices actually came back in; the two agree unless upstream declined to reprice.
      - `currencyCodeSource` 'explicit' | 'default', required — How the API resolved currencyCode: explicit (the caller sent currency – including a value equal to the default) or default (USD, no currency sent). A default here is the one signal that the request never carried the currency you meant.
      - `locale` string, required — The language tag this read asked upstream for – what any localized text on it was resolved in (room and board names, airline and airport names, review prose).
      - `localeSource` 'explicit' | 'default', required — How the API resolved locale: explicit (the caller sent locale – including a value equal to the default) or default (en, no locale sent). A default here explains text that came back in a language the caller did not ask for.
  - object — One itinerary with per-segment detail, amenities and seat metadata (?view=detail), and what this read resolved currency and locale to.
    - `tripId` string, required — Opaque trip id, shaped {searchId}:{tripCode}; read it back with GET /v1/flights/trips/{tripId}.
    - `stops` number, required — Trip-level stop count, the max across legs.
    - `durationMinutes` number, required — Total trip duration in minutes, summed across legs.
    - `legs` object[], required — The trip's legs with per-segment detail, outbound first.
      - `direction` 'depart' | 'return', required — Which leg this is: depart or return.
      - `from` object, required — Departure airport for this leg.
        - `code` string, required — Airport IATA code.
        - `name` string, required — Airport display name from the snapshot's places.
        - `city` string — City name, when the dictionary has it.
        - `stationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place this is, when upstream states it. Absent means unstated, never airport.
      - `to` object, required — Arrival airport for this leg.
        - `code` string, required — Airport IATA code.
        - `name` string, required — Airport display name from the snapshot's places.
        - `city` string — City name, when the dictionary has it.
        - `stationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place this is, when upstream states it. Absent means unstated, never airport.
      - `departsAt` string, required — Leg departure, ISO 8601 with offset.
      - `arrivesAt` string, required — Leg arrival, ISO 8601 with offset.
      - `arrivalDayOffset` number, required — Calendar days the arrival lands after departure (the +1 badge).
      - `overnight` boolean, required — The leg spans a night.
      - `durationMinutes` number, required — Leg duration in minutes.
      - `stops` number, required — Stops on this leg (0 is nonstop).
      - `layoverMinutes` number — Total layover across the leg's stops, minutes.
      - `segments` object[], required — The individual flights that make up this leg.
        - `from` object, required — Departure airport for this segment.
          - `code` string, required — Airport IATA code.
          - `name` string, required — Airport display name from the snapshot's places.
          - `city` string — City name, when the dictionary has it.
          - `stationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place this is, when upstream states it. Absent means unstated, never airport.
        - `to` object, required — Arrival airport for this segment.
          - `code` string, required — Airport IATA code.
          - `name` string, required — Airport display name from the snapshot's places.
          - `city` string — City name, when the dictionary has it.
          - `stationType` 'airport' | 'bus_station' | 'train_station' | 'other' — What kind of place this is, when upstream states it. Absent means unstated, never airport.
        - `departsAt` string, required — Segment departure, ISO 8601 with offset.
        - `arrivesAt` string, required — Segment arrival, ISO 8601 with offset.
        - `durationMinutes` number, required — Segment duration in minutes.
        - `airline` object, required — An airline resolved to code, name and logo.
          - `code` string, required — IATA airline code.
          - `name` string, required — Airline display name.
          - `logoUrl` string, required — Airline logo URL; may 404, fall back to the name.
        - `operatedBy` string — Present only when the operating carrier differs.
        - `flightNumber` string, required — Marketing flight designator, e.g. SQ12.
        - `aircraft` string, required — Aircraft type name, e.g. Boeing 777-300ER. On a surface segment this carries the equipment label ("Bus"); transportType is the typed form of the same fact.
        - `transportType` 'FLIGHT' | 'TRAIN' | 'BUS' | 'OTHER', required — How this segment travels. FLIGHT is a plane. TRAIN and BUS are surface segments sold under a flight number, which airlines do publish, for example the Etihad coach between Dubai Bus Station and Abu Dhabi. OTHER is a mode upstream states that this API does not model, and is never a flight. Absent upstream is published as FLIGHT, which is what every segment meant before this field existed.
        - `cabin` string, required — Cabin class on this segment.
        - `amenities` object — Cabin amenities on the segment, by kind; each present only when upstream reports it.
          - `wifi` object — One cabin amenity on a segment.
            - `text` string, required — Human label for the amenity.
            - `exists` boolean, required — The amenity is present on the segment.
            - `free` boolean, required — The amenity is included, not sold as an extra.
          - `power` object — One cabin amenity on a segment.
            - `text` string, required — Human label for the amenity.
            - `exists` boolean, required — The amenity is present on the segment.
            - `free` boolean, required — The amenity is included, not sold as an extra.
          - `entertainment` object — One cabin amenity on a segment.
            - `text` string, required — Human label for the amenity.
            - `exists` boolean, required — The amenity is present on the segment.
            - `free` boolean, required — The amenity is included, not sold as an extra.
          - `meal` object — One cabin amenity on a segment.
            - `text` string, required — Human label for the amenity.
            - `exists` boolean, required — The amenity is present on the segment.
            - `free` boolean, required — The amenity is included, not sold as an extra.
        - `seat` object — Seat pitch and layout for the segment, when reported.
          - `pitch` string — Seat pitch, e.g. "76 cm seat pitch".
          - `layout` string — Row layout, e.g. "3-3-3".
    - `fares` object[], required — Bookable fares for this trip, cheapest-first.
      - `kind` 'wego' | 'airline' | 'partner', required — Fare source: wego (Book-on-Wego), airline (booked with the carrier) or partner (an OTA).
      - `fareId` string, required — Opaque fare id; pass it to the fare-options and booking-link routes.
      - `provider` object, required — A booking provider resolved to code, name, logo and brand color.
        - `code` string, required — Booking provider (OTA/airline) code.
        - `name` string, required — Provider display name.
        - `logoUrl` string, required — Synthesized provider logo URL; may 404 – fall back to name.
        - `color` string — Provider brand color, when known.
      - `price` object, required — Fare price for the whole party, fee-inclusive.
        - `total` number, required — Whole-party total, including payment + booking fees.
        - `totalUsd` number, required — Whole-party total in USD.
        - `currency` string, required — ISO 4217 currency of total.
        - `includesTaxesAndFees` boolean, required — Upstream totals are fee-inclusive; no separate tax breakdown at search time.
      - `baggage` object — Baggage allowance for this fare, when the provider states it.
        - `cabin` string — Cabin baggage allowance display string.
        - `checked` string — Checked baggage allowance display string.
      - `refundable` boolean, required — Whether this fare is refundable, as the provider states it.
      - `hasFareOptions` boolean, required — Whether GET /v1/flights/fares/{fareId}/options can expand this fare into branded options.
      - `handoffUrl` string, required — Deep link to the provider or wego.com checkout for this fare.
    - `metadata` object, required — What this read resolved currency and locale to, and how each was decided.
      - `currencyCode` string, required — The currency this read ASKED upstream for, and the one every price on it is meant to be in. Read it beside currencyCodeSource before you show a number: a price computed in the wrong currency renders as a perfectly normal price, with no error and no odd shape to notice, so the response states which one rather than leaving it to be inferred. Where the operation also publishes a top-level currencyCode, that field reports the currency the prices actually came back in; the two agree unless upstream declined to reprice.
      - `currencyCodeSource` 'explicit' | 'default', required — How the API resolved currencyCode: explicit (the caller sent currency – including a value equal to the default) or default (USD, no currency sent). A default here is the one signal that the request never carried the currency you meant.
      - `locale` string, required — The language tag this read asked upstream for – what any localized text on it was resolved in (room and board names, airline and airport names, review prose).
      - `localeSource` 'explicit' | 'default', required — How the API resolved locale: explicit (the caller sent locale – including a value equal to the default) or default (en, no locale sent). A default here explains text that came back in a language the caller did not ask for.

## Other responses

- `400` — Invalid request body/query/path parameters.
- `401` — Missing or invalid bearer token.
- `404` — Unknown or expired trip. Ids are context-bound: a tripId resolves only with the searchId it came from, and retrying an expired one never recovers - create a new search and rethread.
- `429` — Rate limit exceeded; retry after the `Retry-After` seconds.
- `502` — The upstream flights service returned an invalid response.
- `503` — The flights service is temporarily unavailable (`upstream_unavailable`) or rate-limited upstream (`upstream_rate_limited`); retry after the `Retry-After` seconds.

---

[API](https://skmtc.net/wego/apis/wego-api.md) · [All operations](https://skmtc.net/wego/apis/wego-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/wego/wego-api/revisions/e5d7af502419/schema)
