FlyRail
Browse the docs

API reference

Version 1.0.0. Download the OpenAPI file or the Postman collection.

  • Live: https://api.flyrail.space/v1
  • Sandbox: https://sandbox-api.flyrail.space/v1

get
/ping

Check your key and environment

Responses: 200 OK

get
/airports

List airports

Responses: 200 Airports

get
/airlines

List airlines available to your key's environment

Responses: 200 Airlines

post
/offers/{offer}/price

Price an offer for your exact party (scope `search`)

Parameters
ParameterInType
offer *pathstring
Request body
FieldTypeNotes
adultsinteger
childreninteger
infantsinteger

Responses: 200 Confirmed price404 Error409 Error

post
/bookings

Book and ticket (scope `book`)

Holds the total in your wallet, reserves the seat, then issues the ticket in the background. The booking starts as `ticketing`; poll it or wait for `booking.ticketed`.

Parameters
ParameterInType
Idempotency-Key *headerstring
Request body
FieldTypeNotes
offer_id *string
client_referencestring
passengers *array
contact *object

Responses: 201 Booking created402 Error409 Error422 Error

get
/bookings

List your bookings (scope `read`)

Parameters
ParameterInType
statusquerystring
per_pagequeryinteger

Responses: 200 Bookings

get
/bookings/{booking}

Get a booking (scope `read`)

Parameters
ParameterInType
booking *pathstring

Responses: 200 Booking404 Error

post
/bookings/{booking}/cancel

Cancel a booking (scope `cancel`)

Refunds follow the fare rules. A same-day cancellation is a full void including our service fee. Repeating the call is safe.

Parameters
ParameterInType
booking *pathstring

Responses: 200 Booking409 Error

get
/bookings/{booking}/ticket

Get the e-ticket (scope `read`)

Parameters
ParameterInType
booking *pathstring

Responses: 200 Ticket409 Error

get
/wallet

Wallet balances (scope `read`)

Responses: 200 Balances

get
/wallet/transactions

Wallet movements, newest first (scope `read`)

Responses: 200 Transactions

get
/webhooks/events

Recent webhook deliveries and their status (scope `read`)

Responses: 200 Events