> ## Documentation Index
> Fetch the complete documentation index at: https://docs.series.hr/llms.txt
> Use this file to discover all available pages before exploring further.

# Book Passenger Seat

> Book seats in a ticket class with capacity validation & Gamepass checks

Allocate or book seats in a ticket class on a flight. Verifies available capacity and checks if the Roblox user owns the required Gamepass if the class is restricted.

## Request

```bash theme={null}
curl -X POST "https://api.series.hr/flights/book-seat" \
  -H "apikey: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "FlightId": "flt_1740000000000_abcde",
    "ClassId": "class_first",
    "TargetUserId": "714760171",
    "SeatsCount": 1
  }'
```

## Parameters

<ParamField body="FlightId" type="string" required>
  The `FlightId` or `FlightNumber` of the flight.
</ParamField>

<ParamField body="ClassId" type="string" required>
  The Class ID (e.g. `class_first`), Class Name (e.g. `First Class`), or Class Code (e.g. `F`).
</ParamField>

<ParamField body="TargetUserId" type="string">
  Roblox User ID or Username of the passenger (optional, but required for gamepass verification if the class requires a gamepass).
</ParamField>

<ParamField body="SeatsCount" type="integer" default="1">
  Number of seats to book.
</ParamField>

## Response

<ResponseField status={200} name="200">
  ```json theme={null}
  {
    "success": true,
    "data": {
      "Message": "Successfully booked 1 seat(s) in First Class",
      "FlightNumber": "RA 101",
      "Class": {
        "ClassId": "class_first",
        "ClassName": "First Class",
        "ClassCode": "F",
        "Capacity": 30,
        "BookedSeats": 13,
        "GamepassRequired": true,
        "GamepassId": 12345678,
        "PriorityBoarding": true
      },
      "Passenger": {
        "UserId": 714760171,
        "Username": "RobloxPlayer",
        "DisplayName": "PlayerOne",
        "AvatarUrl": "https://tr.rbxcdn.com/..."
      }
    }
  }
  ```
</ResponseField>

## Status Codes

* `200`: Seats booked successfully
* `400`: Class is full or invalid input
* `401`: API key is required
* `403`: Passenger does not own the required Gamepass
* `404`: Flight or ticket class not found
