Reputation: 427
I'm building a web app and was integrating Sabre with it. I was following the "Low Fare Search and Book" workflow and I'm done shopping flights using Bargain Finder Max so I wanted to book the flights selected through Create Passenger Name Record. I'm stuck in sending Create PNR Request. I was consuming Create Passenger Name Record with the following payloads:
{
"CreatePassengerNameRecordRQ": {
"version": "2.1.0",
"targetCity": "G1OJ",
"haltOnAirPriceError": true,
"TravelItineraryAddInfo": {
"AgencyInfo": {
"Address": {
"AddressLine": "UNIT 707 PRINCE GREGORY CONDO 12TH AVENUE, CUBAO",
"CityName": "QUEZON CITY",
"CountryCode": "PH",
"PostalCode": "1109",
"StreetNmbr": "#105"
},
"Ticketing": {
"TicketType": "7TAW"
}
},
"CustomerInfo": {
"ContactNumbers": {
"ContactNumber": [
{
"NameNumber": "1.1",
"Phone": "639053314785",
"PhoneUseType": "H"
},
{
"NameNumber": "2.1",
"Phone": "639053314785",
"PhoneUseType": "H"
}
]
},
"PersonName": [
{
"NameNumber": "1.1",
"PassengerType": "ADT",
"GivenName": "ERWIN",
"Surname": "PLAZA"
},
{
"NameNumber": "2.1",
"PassengerType": "ADT",
"GivenName": "AMABELLE",
"Surname": "PLAZA"
}
]
}
},
"AirBook": {
"HaltOnStatus": [
{
"Code": "HL"
},
{
"Code": "KK"
},
{
"Code": "LL"
},
{
"Code": "NN"
},
{
"Code": "NO"
},
{
"Code": "UC"
},
{
"Code": "US"
}
],
"OriginDestinationInformation": {
"FlightSegment": [
{
"ArrivalDateTime": "2019-01-28T11:40:00",
"DepartureDateTime": "2019-01-28T10:35:00",
"FlightNumber": "1853",
"NumberInParty": "2",
"ResBookDesigCode": "T",
"Status": "NN",
"InstantPurchase": true,
"DestinationLocation": {
"LocationCode": "CEB"
},
"MarketingAirline": {
"Code": "PR",
"FlightNumber": "1853"
},
"MarriageGrp": "O",
"OriginLocation": {
"LocationCode": "MNL"
}
},
{
"ArrivalDateTime": "2019-01-30T23:05:00",
"DepartureDateTime": "2019-01-30T21:50:00",
"FlightNumber": "2880",
"NumberInParty": "2",
"ResBookDesigCode": "T",
"Status": "NN",
"InstantPurchase": true,
"DestinationLocation": {
"LocationCode": "MNL"
},
"MarketingAirline": {
"Code": "PR",
"FlightNumber": "2880"
},
"MarriageGrp": "O",
"OriginLocation": {
"LocationCode": "CEB"
}
}
]
}
},
"PostProcessing": {
"RedisplayReservation": true,
"ARUNK": "please do the arunk thing",
"EndTransaction": {
"Source": {
"ReceivedFrom": "MOSCONI"
}
},
"PostBookingHKValidation": {
"waitInterval": 100,
"numAttempts": 6
},
"WaitForAirlineRecLoc": {
"waitInterval": 100,
"numAttempts": 6
}
}
}
}
and I believe I provided the 5 mandatory elements in creating a PNR. P Phone Number R Received From I Itinerary N Name of Traveler T Ticketing Time Limit
However, I still get this Error
"Error": [
{
"type": "Application",
"timeStamp": "2019-01-24T02:05:47.767-06:00",
"SystemSpecificResults": [
{
"Message": [
{
"code": "ERR.SP.PROVIDER_ERROR",
"content": "Unable to perform air booking step"
}
]
}
]
What am I missing on my payload?
Upvotes: 2
Views: 1825
Reputation: 144
Try to use this structure, I did notice your Json is missing some steps: CreatePassengerNameRecordRQ, TravelItineraryAddInfo, AirBook AirPrice(Required), MiscSegment, SpecialReqDetails, PostProcessing
{
"CreatePassengerNameRecordRQ": {
"version": "2.1.0",
"targetCity": "G7HE",
"haltOnAirPriceError": true,
"TravelItineraryAddInfo": {
"AgencyInfo": {
"Address": {
"AddressLine": "My corp",
"CityName": "SOUTHLAKE",
"CountryCode": "US",
"PostalCode": "76092",
"StateCountyProv": {
"StateCode": "TX"
},
"StreetNmbr": "9000 street corp"
},
"Ticketing": {
"TicketType": "7TAW"
}
},
"CustomerInfo": {
"ContactNumbers": {
"ContactNumber": [
{
"NameNumber": "1.1",
"Phone": "001-222-1111",
"PhoneUseType": "H"
},
{
"NameNumber": "2.1",
"Phone": "111-111-1111",
"PhoneUseType": "W"
}
]
},
"CreditCardData": {
"BillingInformation": {
"cardHolderName": "SP TEST",
"streetAddress": "2323, Hommer J Simpson",
"city": "NEW YORK",
"stateOrProvince": "NY",
"PostalCode": "V9B0L2"
}
},
"PersonName": [
{
"NameNumber": "1.1",
"NameReference": "ABC123",
"PassengerType": "ADT",
"GivenName": "Hommer",
"Surname": "Simpson"
},
{
"NameNumber": "2.1",
"NameReference": "DEF456",
"PassengerType": "ADT",
"GivenName": "Bart",
"Surname": "Simpson"
}
]
}
},
"AirBook": {
"HaltOnStatus": [
{
"Code": "HL"
},
{
"Code": "KK"
},
{
"Code": "LL"
},
{
"Code": "NN"
},
{
"Code": "NO"
},
{
"Code": "UC"
},
{
"Code": "US"
}
],
"OriginDestinationInformation": {
"FlightSegment": [
{
"ArrivalDateTime": "2018-09-10T19:14:00",
"DepartureDateTime": "2018-09-10T11:35:00",
"FlightNumber": "745",
"NumberInParty": "2",
"ResBookDesigCode": "W",
"Status": "NN",
"InstantPurchase": true,
"DestinationLocation": {
"LocationCode": "DTW"
},
"MarketingAirline": {
"Code": "DL",
"FlightNumber": "745"
},
"MarriageGrp": "O",
"OriginLocation": {
"LocationCode": "SFO"
}
},
{
"ArrivalDateTime": "2018-09-10T20:59:00",
"DepartureDateTime": "2018-09-10T19:55:00",
"FlightNumber": "2010",
"NumberInParty": "2",
"ResBookDesigCode": "W",
"Status": "NN",
"InstantPurchase": true,
"DestinationLocation": {
"LocationCode": "MCI"
},
"MarketingAirline": {
"Code": "DL",
"FlightNumber": "2010"
},
"MarriageGrp": "O",
"OriginLocation": {
"LocationCode": "DTW"
}
},
{
"ArrivalDateTime": "2018-09-17T18:50:00",
"DepartureDateTime": "2018-09-17T17:10:00",
"FlightNumber": "1076",
"NumberInParty": "2",
"ResBookDesigCode": "W",
"Status": "NN",
"InstantPurchase": true,
"DestinationLocation": {
"LocationCode": "MSP"
},
"MarketingAirline": {
"Code": "DL",
"FlightNumber": "1076"
},
"MarriageGrp": "O",
"OriginLocation": {
"LocationCode": "MCI"
}
},
{
"ArrivalDateTime": "2018-09-18T00:13:00",
"DepartureDateTime": "2018-09-17T20:15:00",
"FlightNumber": "2214",
"NumberInParty": "2",
"ResBookDesigCode": "W",
"Status": "NN",
"InstantPurchase": true,
"DestinationLocation": {
"LocationCode": "JFK"
},
"MarketingAirline": {
"Code": "DL",
"FlightNumber": "2214"
},
"MarriageGrp": "O",
"OriginLocation": {
"LocationCode": "MSP"
}
}
]
}
},
"AirPrice": [
{
"PriceComparison": [
{
"AmountSpecified": 1000,
"AcceptablePriceIncrease": {
"HaltOnNonAcceptablePrice": false,
"Amount": 500
}
}
],
"PriceRequestInformation": {
"Retain": true,
"OptionalQualifiers": {
"FOP_Qualifiers": {
"BasicFOP": {
"Type": "CK"
}
},
"PricingQualifiers": {
"NameSelect": [
{
"NameNumber": "1.1"
}
],
"PassengerType": [
{
"Code": "ADT",
"Quantity": "1"
}
]
}
}
}
},
{
"PriceComparison": [
{
"AmountSpecified": 1000,
"AcceptablePriceDecrease": {
"HaltOnNonAcceptablePrice": false,
"Percent": 500
}
}
],
"PriceRequestInformation": {
"Retain": true,
"OptionalQualifiers": {
"FOP_Qualifiers": {
"BasicFOP": {
"Type": "CK"
}
},
"PricingQualifiers": {
"NameSelect": [
{
"NameNumber": "2.1"
}
],
"PassengerType": [
{
"Code": "ADR",
"Quantity": "1"
}
]
}
}
}
}
],
"MiscSegment": {
"VendorPrefs": {
"Airline": {
"Code": "AS"
}
},
"DepartureDateTime": "09-13",
"NumberInParty": 2,
"Text": "TEST OTH MISCELLANEOUS SEGMENT",
"Type": "OTH",
"OriginLocation": {
"LocationCode": "ORD"
},
"Status": "GK"
},
"SpecialReqDetails": {
"AddRemark": {
"RemarkInfo": {
"FOP_Remark": {
"Type": "CHECK"
}
}
},
"SpecialService": {
"SpecialServiceInfo": {
"SecureFlight": [
{
"SegmentNumber": "A",
"PersonName": {
"DateOfBirth": "2001-01-01",
"Gender": "M",
"NameNumber": "1.1",
"GivenName": "Hommer",
"Surname": "Simpson"
},
"VendorPrefs": {
"Airline": {
"Hosted": false
}
}
},
{
"SegmentNumber": "A",
"PersonName": {
"DateOfBirth": "2002-02-02",
"Gender": "M",
"NameNumber": "2.1",
"GivenName": "Bart",
"Surname": "Simpson"
},
"VendorPrefs": {
"Airline": {
"Hosted": false
}
}
}
],
"Service": [
{
"SSR_Code": "VGML",
"Text": "CC Hommer Simpson"
}
]
}
}
},
"PostProcessing": {
"RedisplayReservation": true,
"ARUNK": "please do the arunk thing",
"EndTransaction": {
"Source": {
"ReceivedFrom": "SP TEST"
}
},
"PostBookingHKValidation": {
"waitInterval": 100,
"numAttempts": 6
},
"WaitForAirlineRecLoc": {
"waitInterval": 100,
"numAttempts": 6
}
}
}
}
Upvotes: 1