# Round-Trip Flight Search

Version 2 uses two separately billed requests. First request returns outbound options with price_type=round_trip_starting, itinerary_complete=false, and departure_token. Repeat the same search parameters with one departure_token to get compatible return_legs and price_type=round_trip_total for that exact outbound. Each call completes one upstream lookup, retrying temporary failures of that same lookup; failed calls are not billed. No automatic return or baggage expansion.

- **Documentation:** [https://scrappa.co/docs/google-flights-api/google_flights_round_trip](https://scrappa.co/docs/google-flights-api/google_flights_round_trip)
- **API group:** Google Flights API
- **Endpoint:** `GET https://scrappa.co/api/flights/v2/round-trip`

## Authentication

Send your Scrappa API key in the `X-API-KEY` request header. Paid endpoints also support accountless x402 payments when called without an API key.

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `origin` | string | Yes | Origin airport IATA code |
| `destination` | string | Yes | Destination airport IATA code |
| `departure_date` | string | Yes | Departure date in Y-m-d format |
| `departure_token` | string | No | Copy one token from the outbound response and repeat the same search parameters to request its matching returns. Maximum 16384 characters. |
| `return_date` | string | Yes | Return date in Y-m-d format |
| `adults` | integer | No | Number of adult passengers (1-9) |
| `children` | integer | No | Number of child passengers (0-9) |
| `infants_in_seat` | integer | No | Number of infants in seat (0-9) |
| `infants_on_lap` | integer | No | Number of infants on lap (0-9) |
| `cabin_class` | string | No | Cabin class: economy, premium_economy, business, or first |
| `exclude_basic` | boolean | No | Exclude basic economy fares when searching in economy class (default: false) |
| `max_stops` | string | No | Maximum stops: any, nonstop, one_or_fewer, two_or_fewer |
| `sort_by` | string | No | Sort results by: top_flights, cheapest, departure_time, arrival_time, duration |
| `hl` | string | No | Language code (e.g., en, de, en-US) |
| `gl` | string | No | Country/region code (e.g., us, de, gb) |
| `currency` | string | No | Currency code for prices (e.g., USD, EUR, GBP) |
| `airlines` | array | No | Filter by airline IATA codes (e.g., ["AA", "UA", "DL"] or "AA,UA,DL") |
| `include_baggage` | boolean | No | Only false/0 is supported. No additional baggage lookup is performed. |
| `departure_time_min` | integer | No | Minimum departure hour (0-23). Use with departure_time_max to filter by time range. |
| `departure_time_max` | integer | No | Maximum departure hour (0-23). Use with departure_time_min to filter by time range. |
| `arrival_time_min` | integer | No | Minimum arrival hour (0-23). Use with arrival_time_max to filter by time range. |
| `arrival_time_max` | integer | No | Maximum arrival hour (0-23). Use with arrival_time_min to filter by time range. |
| `max_duration_minutes` | integer | No | Maximum flight duration in minutes. Filters out flights longer than this. |
| `max_price` | integer | No | Maximum price in the search currency. Filters out flights more expensive than this. |
| `bags` | integer | No | Carry-on bag count. Only 0 is currently supported. |

## Example request

```bash
#!/bin/bash

curl -X GET \
    -H "x-api-key: YOUR_API_KEY_HERE" \
    "https://scrappa.co/api/flights/v2/round-trip?origin=TIA&destination=FCO&departure_date=2026-10-08&return_date=2026-10-15&adults=1&currency=EUR"
```

## Example response

```json
{
    "flights": [
        {
            "trip_type": "round_trip",
            "itinerary_complete": false,
            "price_type": "round_trip_starting",
            "departure_token": "COPY_TOKEN_FROM_LIVE_OUTBOUND_RESPONSE",
            "booking_token": null,
            "price": 47,
            "currency": "EUR",
            "stops": null,
            "outbound_stops": 0,
            "return_stops": null,
            "total_duration_minutes": null,
            "outbound_duration_minutes": 100,
            "return_duration_minutes": null,
            "outbound_legs": [
                {
                    "departure_airport": "TIA",
                    "arrival_airport": "FCO",
                    "departure_time": "2026-10-08T06:00:00",
                    "arrival_time": "2026-10-08T07:40:00",
                    "airline": "W4",
                    "flight_number": "5011",
                    "duration_minutes": 100
                }
            ],
            "legs": [
                {
                    "departure_airport": "TIA",
                    "arrival_airport": "FCO",
                    "departure_time": "2026-10-08T06:00:00",
                    "arrival_time": "2026-10-08T07:40:00",
                    "airline": "W4",
                    "flight_number": "5011",
                    "duration_minutes": 100
                }
            ],
            "return_legs": []
        }
    ],
    "search_metadata": {
        "api_version": 2,
        "stage": "outbound",
        "origin": "TIA",
        "destination": "FCO",
        "departure_date": "2026-10-08",
        "return_date": "2026-10-15",
        "currency": "EUR"
    }
}
```

## More Scrappa resources

- [API documentation](https://scrappa.co/docs)
- [Full LLM-readable API reference](https://scrappa.co/llms-full.txt)
- [OpenAPI specification](https://scrappa.co/docs/api.json)
- [Pricing](https://scrappa.co/pricing)
