Vuelos
Search flights. Returns a session to poll, or the complete result when `wait` is true.
post/v1/flights/search
- Requiere autenticación
Cuerpo de la solicitudFlightSearchRequest
- FlightSlice[]
- originstring
IATA airport or city code.
- destinationstring
- departureDatestring
yyyy-MM-dd.
- PassengerCounts
- adultsinteger (int32)
- childreninteger (int32)
- infantsinteger (int32)
- cabinstringadmite null
economy | premium_economy | business | first. Default economy.
- maxStopsinteger (int32)admite null
Maximum stops per slice; null = any.
- waitboolean
True = block up to ~25 s and return the complete result; false (default) = start a session and poll.
Ejemplo
{
"slices": [
{
"origin": "DXB",
"destination": "LHR",
"departureDate": "2026-11-15"
}
],
"passengers": {
"adults": 1,
"children": 0,
"infants": 0
},
"cabin": "economy",
"wait": true
}Respuestas
200OKFlightSearchResponse
- searchIdstring
- statusstring
in_progress | complete.
- cursorinteger (int32)
- suppliersDoneinteger (int32)
- supplierCountinteger (int32)
- FlightOffer[]
- offerIdstring
- expiresAtstring (date-time)
UTC ISO-8601; the offer must be priced/booked before this.
- validatingCarrierstringadmite null
- Slice[]
- PassengerPricing[]
- Money
Money on the wire: decimal string (never a float) + ISO 4217.
- Money
Money on the wire: decimal string (never a float) + ISO 4217.
- Money
Money on the wire: decimal string (never a float) + ISO 4217.
- refundablebooleanadmite null
- passportRequiredboolean
- selfTransferboolean
- charterboolean
- tripTypestringadmite null
- 400Bad RequestDetalles del problema según RFC 7807
Ejemplos de código
Programas completos que firman la solicitud tal como la verifica la pasarela. Sustituya YOUR_KEY_ID y YOUR_SECRET.
# Sign the request: METHOD \n path+query \n unix time \n nonce \n sha256(body)
KEY_ID="YOUR_KEY_ID"
SECRET="YOUR_SECRET"
BODY='{
"slices": [
{
"origin": "DXB",
"destination": "LHR",
"departureDate": "2026-11-15"
}
],
"passengers": {
"adults": 1,
"children": 0,
"infants": 0
},
"cabin": "economy",
"wait": true
}'
TS=$(date +%s)
NONCE=$(openssl rand -hex 16)
BODY_HASH=$(printf '%s' "$BODY" | openssl dgst -sha256 | sed 's/^.* //')
CANON=$(printf 'POST\n/v1/flights/search\n%s\n%s\n%s' "$TS" "$NONCE" "$BODY_HASH")
SIG=$(printf '%s' "$CANON" | openssl dgst -sha256 -hmac "$SECRET" | sed 's/^.* //')
curl -X POST "https://api.dubaitrip.com/v1/flights/search" \
-H "X-API-Key: $KEY_ID" \
-H "X-Timestamp: $TS" \
-H "X-Nonce: $NONCE" \
-H "X-Signature: $SIG" \
-H "Content-Type: application/json" \
-d "$BODY"