---
title: "Book a flight"
method: POST
path: "/flights/book"
---

# Book a flight

`POST /flights/book`

## Request

- Base URL: `https://api.tellandgo.com/api/v1/agent`
- URL: `https://api.tellandgo.com/api/v1/agent/flights/book`
- Auth: API key in header `X-API-Key`

Creates a flight booking from a valid quote. Returns a hosted checkout session
URL for payment. After payment, the booking is confirmed automatically via webhook.

## Headers

- `Idempotency-Key` string, required

## Request body

- FlightBookRequest
  - `quote_id` string, required: Quote ID from flight quote
  - `passengers` FlightPassenger[], required
    - `title` 'mr' | 'ms' | 'mrs' | 'miss' | 'dr'
    - `first_name` string, required
    - `last_name` string, required
    - `email` string, email, required
    - `phone` string, required: Phone number with country code
    - `born_on` string, date, required: Date of birth (YYYY-MM-DD)
    - `gender` 'm' | 'f', required
    - `document_type` 'passport' | 'national_identity_card'
    - `document_number` string
    - `document_expiry` string, date: Document expiry date (YYYY-MM-DD)
    - `nationality` string: ISO 3166-1 alpha-2 country code

## Response `201`

Flight booking created

- FlightBookResponse
  - `success` boolean
  - `booking` object
    - `id` string
    - `flight_booking_id` string
    - `status` 'pending_payment' | 'confirmed' | 'cancelled'
    - `reference` string
    - `airline` object
      - `name` string
      - `iata_code` string
      - `logo_url` string, uri
    - `slices` FlightSlice[]
      - `origin` string: Origin IATA code
      - `destination` string: Destination IATA code
      - `duration` string: Duration in ISO 8601 format
      - `segments` FlightSegment[]
        - `carrier` string: Airline name
        - `carrier_code` string: IATA airline code
        - `flight_number` string
        - `origin` string
        - `destination` string
        - `departure_time` string, date-time
        - `arrival_time` string, date-time
        - `cabin_class` string
    - `passengers` object[]
      - `name` string
      - `type` string
    - `total` object
      - `amount` number
      - `currency` string
    - `payment` object
      - `method` string
      - `url` string, uri: Hosted checkout URL
      - `session_id` string: Hosted checkout session ID
      - `expires_at` string, date-time
    - `created_at` string, date-time

## Other responses

- `400`: Invalid request
- `401`: Authentication required or invalid
- `404`: Quote not found or expired

---

[API](https://skmtc.dev/tellandgo/apis/tell-go-travel-agent-api.md) · [All operations](https://skmtc.dev/tellandgo/apis/tell-go-travel-agent-api/llms.txt) · [OpenAPI document](https://skmtc.dev/tellandgo/apis/tell-go-travel-agent-api/revisions/3d84f816eb4f?raw)
