- Auth
- Customer
- Passengers
- invoice Info
- Favorite Flights
- Notifications
- Fast Actions
- Customer - Get ProfileGET
- Customer - Update ProfilePOST
- Customer - Update PasswordPOST
- Search History - FlightGET
- Customer - Remove AccountDELETE
- Utils
- Flight
- Search
- Domestic
- International
- One Way / 1 ADT
- Round Trip / 1 ADT
- Round Trip / 2 ADT
- Search Flight - FilterPOST
- Price Alerts
- Load Journey (dev only)GET
- Bus
- Hotel
- Socket
- Auto Completes
- Queue / Socket
- Misc
- Payment
- Orders
- Blog
- Contents
- Refund
- Notifications
- Checkout
- Otp VerifyPOST
- StatusGET
Allocate
POST
https://test-api.ucuzyolu.com/flight/allocate
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.Example:
Authorization: Bearer ********************
Header Params
client-id
string
optional
Default:
302382-1928283273-237723829-292999
Body Params application/json
journeyId
string
required
flights
array [object {3}]
required
searchId
string
required
flightId
string
required
items
array [object {1}]
required
Example
{
"journeyId": "{{journeyId}}",
"flights": [
{
"searchId": "{{searchId}}",
"flightId": "{{flightId}}",
"items": [
{
"paxId": "{{paxId}}"
}
]
},
{
"searchId": "{{searchId}}",
"flightId": "{{returnFlightId}}",
"items": [
{
"paxId": "{{returnPaxId}}"
}
]
}
]
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://test-api.ucuzyolu.com/flight/allocate' \
--header 'client-id: 302382-1928283273-237723829-292999' \
--header 'Content-Type: application/json' \
--data-raw '{
"journeyId": "",
"flights": [
{
"searchId": "",
"flightId": "",
"items": [
{
"paxId": ""
}
]
},
{
"searchId": "",
"flightId": "",
"items": [
{
"paxId": ""
}
]
}
]
}'
Responses
🟢200OK
application/json
Body
data
object (FlightSearchResponse)
required
isSuccess
boolean
optional
isFavorited
boolean
optional
errorMessage
string | null
optional
success
boolean
optional
isDomestic
boolean
required
currency
enum<string>
required
Allowed values:
TRYUSDEUR
action
string
optional
flightType
optional
status
string
optional
bookingStatus
enum<string>
required
Allowed values:
pendingallocatedpassenger_settledprebookedpayment_confirmedcompleted
searchStatus
string | null
optional
journeyId
string
required
filters
array[object (FilterItem) {7}]
optional
results
array[object (FlightItem) {44}]
optional
bookingItems
array[object (FlightItem) {44}]
required
relations
object
optional
sortOptions
array [object {4}]
required
success
boolean
required
code
integer
required
message
string
required
Example
{
"data": {
"isSuccess": true,
"isFavorited": true,
"errorMessage": "string",
"success": true,
"isDomestic": true,
"currency": "TRY",
"action": "string",
"flightType": "oneway",
"status": "string",
"bookingStatus": "pending",
"searchStatus": "string",
"journeyId": "string",
"filters": [
{
"name": "string",
"alias": "string",
"type": "base",
"attributes": [
{
"name": "string",
"alias": "string",
"value": "string",
"isSelected": true
}
],
"filters": [
{}
],
"min": 0,
"max": 0
}
],
"results": [
{
"searchId": "string",
"flightId": "string",
"journeyId": "string",
"flightNumber": "string",
"isTransit": true,
"isDomestic": true,
"duration": "14:15:22Z",
"airDuration": "14:15:22Z",
"waitDuration": "14:15:22Z",
"seatsAvailable": 0,
"segments": [
{
"segmentId": "string",
"flightNumber": "string",
"type": "string",
"sequenceNo": 0,
"airplaneCode": "string",
"airplaneName": "string",
"duration": "14:15:22Z",
"cabinClass": "string",
"cabin": "s",
"seatsAvailable": 0,
"originAirport": "string",
"originAirportCode": "string",
"originCity": "string",
"originCityCode": "string",
"originCountry": "string",
"originCountryCode": "string",
"destinationAirport": "string",
"destinationAirportCode": "string",
"destinationCity": "string",
"destinationCityCode": "string",
"destinationCountry": "string",
"destinationCountryCode": "string",
"departureDate": "string",
"departureTime": "string",
"departureDateTime": "string",
"arrivalDate": "string",
"arrivalTime": "string",
"arrivalDateTime": "string",
"airlineLabel": "string",
"airlineMarketing": "string",
"airlineOperating": "string"
}
],
"informationTexts": [
{
"code": "string",
"text": "string"
}
],
"paxItems": [
{
"paxId": "string",
"serviceId": "string",
"paxCode": "ADT",
"sequence": 0,
"freeBaggage": [
{
"value": 0,
"paxCode": "string",
"unit": "string",
"unitType": "string"
}
],
"serviceFee": 0,
"serviceFeeOriginal": 0,
"serviceFeeDiscount": 0,
"tax": 0,
"taxDiscount": 0,
"netFare": 0,
"totalFare": 0,
"currency": "string",
"priceIncludesRoundPrice": true,
"ourFare": 0,
"totalPrice": 0
}
],
"alternativePrices": [
{
"serviceId": "string",
"paxId": "string",
"fareType": "string",
"fareBasisCode": "string",
"paxCode": "string",
"paxSequence": 0,
"isPromo": true,
"businessLounge": true,
"seatSelection": true,
"isSelected": true,
"brandCode": "string",
"brandKey": "string",
"brandName": "string",
"freeBaggage": [
{
"value": 0,
"paxCode": "string",
"unit": "string",
"unitType": "string"
}
],
"bonus": {
"available": true,
"amount": 0,
"airlineIcon": null
},
"meal": {
"mealCode": "string",
"mealName": "string",
"mealSubCode": "string",
"mealDescription": "string"
},
"cancellationPolicies": [
{
"price": 0,
"currency": "string",
"dateFrom": "string",
"dateTo": "string",
"hoursBeforeFlight": 0,
"isRefundable": true,
"text": "string"
}
],
"changePolicies": [
{
"price": 0,
"currency": "string",
"dateFrom": "string",
"dateTo": "string",
"hoursBeforeFlight": 0,
"isChangeable": true,
"text": "string"
}
],
"informationTexts": [
{
"code": "string",
"text": "string"
}
],
"serviceFee": 0,
"serviceFeeOriginal": 0,
"serviceFeeDiscount": 0,
"tax": 0,
"taxDiscount": 0,
"netFare": 0,
"totalFare": 0,
"currency": "string",
"priceIncludesRoundPrice": true,
"vqFare": 0,
"yrFare": 0,
"ourFare": 0,
"totalPrice": 0,
"baseFare": 0,
"needsRefresh": true,
"cabin": "string",
"cabinClass": "string"
}
],
"stops": 0,
"combinations": [
{}
],
"serviceFee": 0,
"serviceFeeOriginal": 0,
"serviceFeeDiscount": 0,
"tax": 0,
"taxDiscount": 0,
"netFare": 0,
"totalFare": 0,
"currency": "string",
"priceIncludesRoundPrice": true,
"ourFare": 0,
"totalPrice": 0,
"departureDate": "string",
"departureTime": "string",
"departureDateTime": "string",
"arrivalDate": "string",
"arrivalTime": "string",
"arrivalDateTime": "string",
"airlineLabel": "string",
"airlineMarketing": "string",
"airlineOperating": "string",
"providerSearchId": "string",
"providerId": "string",
"providerName": "string",
"bookingProviderId": null,
"bookingProviderCode": null,
"cabin": "string",
"cabinClass": "string",
"documentRequires": [
{
"name": "string",
"description": "string",
"code": "string",
"required": true
}
]
}
],
"bookingItems": [
{
"searchId": "string",
"flightId": "string",
"journeyId": "string",
"flightNumber": "string",
"isTransit": true,
"isDomestic": true,
"duration": "14:15:22Z",
"airDuration": "14:15:22Z",
"waitDuration": "14:15:22Z",
"seatsAvailable": 0,
"segments": [
{
"segmentId": "string",
"flightNumber": "string",
"type": "string",
"sequenceNo": 0,
"airplaneCode": "string",
"airplaneName": "string",
"duration": "14:15:22Z",
"cabinClass": "string",
"cabin": "s",
"seatsAvailable": 0,
"originAirport": "string",
"originAirportCode": "string",
"originCity": "string",
"originCityCode": "string",
"originCountry": "string",
"originCountryCode": "string",
"destinationAirport": "string",
"destinationAirportCode": "string",
"destinationCity": "string",
"destinationCityCode": "string",
"destinationCountry": "string",
"destinationCountryCode": "string",
"departureDate": "string",
"departureTime": "string",
"departureDateTime": "string",
"arrivalDate": "string",
"arrivalTime": "string",
"arrivalDateTime": "string",
"airlineLabel": "string",
"airlineMarketing": "string",
"airlineOperating": "string"
}
],
"informationTexts": [
{
"code": "string",
"text": "string"
}
],
"paxItems": [
{
"paxId": "string",
"serviceId": "string",
"paxCode": "ADT",
"sequence": 0,
"freeBaggage": [
{
"value": 0,
"paxCode": "string",
"unit": "string",
"unitType": "string"
}
],
"serviceFee": 0,
"serviceFeeOriginal": 0,
"serviceFeeDiscount": 0,
"tax": 0,
"taxDiscount": 0,
"netFare": 0,
"totalFare": 0,
"currency": "string",
"priceIncludesRoundPrice": true,
"ourFare": 0,
"totalPrice": 0
}
],
"alternativePrices": [
{
"serviceId": "string",
"paxId": "string",
"fareType": "string",
"fareBasisCode": "string",
"paxCode": "string",
"paxSequence": 0,
"isPromo": true,
"businessLounge": true,
"seatSelection": true,
"isSelected": true,
"brandCode": "string",
"brandKey": "string",
"brandName": "string",
"freeBaggage": [
{
"value": 0,
"paxCode": "string",
"unit": "string",
"unitType": "string"
}
],
"bonus": {
"available": true,
"amount": 0,
"airlineIcon": null
},
"meal": {
"mealCode": "string",
"mealName": "string",
"mealSubCode": "string",
"mealDescription": "string"
},
"cancellationPolicies": [
{
"price": 0,
"currency": "string",
"dateFrom": "string",
"dateTo": "string",
"hoursBeforeFlight": 0,
"isRefundable": true,
"text": "string"
}
],
"changePolicies": [
{
"price": 0,
"currency": "string",
"dateFrom": "string",
"dateTo": "string",
"hoursBeforeFlight": 0,
"isChangeable": true,
"text": "string"
}
],
"informationTexts": [
{
"code": "string",
"text": "string"
}
],
"serviceFee": 0,
"serviceFeeOriginal": 0,
"serviceFeeDiscount": 0,
"tax": 0,
"taxDiscount": 0,
"netFare": 0,
"totalFare": 0,
"currency": "string",
"priceIncludesRoundPrice": true,
"vqFare": 0,
"yrFare": 0,
"ourFare": 0,
"totalPrice": 0,
"baseFare": 0,
"needsRefresh": true,
"cabin": "string",
"cabinClass": "string"
}
],
"stops": 0,
"combinations": [
{}
],
"serviceFee": 0,
"serviceFeeOriginal": 0,
"serviceFeeDiscount": 0,
"tax": 0,
"taxDiscount": 0,
"netFare": 0,
"totalFare": 0,
"currency": "string",
"priceIncludesRoundPrice": true,
"ourFare": 0,
"totalPrice": 0,
"departureDate": "string",
"departureTime": "string",
"departureDateTime": "string",
"arrivalDate": "string",
"arrivalTime": "string",
"arrivalDateTime": "string",
"airlineLabel": "string",
"airlineMarketing": "string",
"airlineOperating": "string",
"providerSearchId": "string",
"providerId": "string",
"providerName": "string",
"bookingProviderId": null,
"bookingProviderCode": null,
"cabin": "string",
"cabinClass": "string",
"documentRequires": [
{
"name": "string",
"description": "string",
"code": "string",
"required": true
}
]
}
],
"relations": {},
"sortOptions": [
{
"name": "string",
"description": "string",
"field": "string",
"type": "string"
}
]
},
"success": true,
"code": 0,
"message": "string"
}
🟢200Success (Non-async)
Modified at 2024-11-28 01:29:13