Skip to content

Derive Booking Url

POST
/api/v1/booking-urls
Code sample: cURL
curl -X POST "https://d1vrh75868.execute-api.us-east-2.amazonaws.com/api/v1/booking-urls" -H "Authorization: Bearer <YOUR_API_KEY>" -H "Content-Type: application/json"

Exchange a booking_token from a prior flight-search result for a live third-party booking URL.

Synchronous upstream redirect lookup against Skiplagged; typically returns in 3-6 seconds. Call this lazily — only for offers the user actually intends to book — to avoid paying the upstream cost for the full result set returned by /api/v1/flight-searches.

Media type application/json
BookingUrlRequest
object
booking_token
required
Booking Token

Provide the opaque booking_token string returned with each PriceOffer from a prior flight-search result. Send the value verbatim; do not decode or modify it. Tokens are derived from upstream itinerary identifiers and have a finite freshness window aligned with the originating search (~30 minutes). Expired tokens return 410 with code booking_token_expired; malformed tokens return 400 with code invalid_booking_token.

string
>= 1 characters
Example generated
{
"booking_token": "example"
}

Successful Response

Media type application/json
Envelope[BookingUrlResponse]
object
data
required
BookingUrlResponse
object
booking_url
required
Booking Url

The third-party booking URL Skiplagged returns for the offer identified by the supplied token. Hand this to the end user as a redirect target; do not parse it for stability — the path, query parameters, and host may change as Skiplagged rotates partner deeplinks.

string
meta
required
ResponseMeta
object
cache
Any of:
CacheMetadata
object
hit
required
Hit
boolean
ttl_seconds
required
Ttl Seconds
integer
resource
required
Resource
string
returned
Any of:
integer
request_id
Request Id
string
sources_used
Sources Used
Array<string>
total_results
Any of:
integer
data_freshness
Any of:
string format: date-time
processing_time_ms
required
Processing Time Ms
integer
warnings
Warnings
Array<object>
WarningItem
object
code
required
Code
string
source
required
Source
string
message
required
Message
string
Example generated
{
"data": {
"booking_url": "example"
},
"meta": {
"cache": {
"hit": true,
"ttl_seconds": 1
},
"resource": "example",
"returned": 1,
"request_id": "example",
"sources_used": [
"example"
],
"total_results": 1,
"data_freshness": "2026-04-15T12:00:00Z",
"processing_time_ms": 1
},
"warnings": [
{
"code": "example",
"source": "example",
"message": "example"
}
]
}

Validation Error

Media type application/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationError
object
ctx
Context
object
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
Example generated
{
"detail": [
{
"ctx": {},
"loc": [
"example"
],
"msg": "example",
"type": "example",
"input": "example"
}
]
}