Skip to content

Create air pnr

Request

Creates a new air booking with the given itinerary

Security
Bearer
Bodyapplication/jsonrequired
bookingIdstring

The booking ID for which the PNR is being created. This is returned in the revalidate itinerary API response.

Example:"booking-id"
initiateBookingIdstring

Initiate booking id is returned in response to air-initiate-booking API call. This id is required if in case the booking id is not available due to third-party redirection.

Example:"eCfghty567jkHG56DFgh"
preSearchAnswersobject(PreSearchAnswers)
postPaymentVerificationInfoPostStripeVerificationInfoWrapper (object) or PostUrlBasedVerificationInfoWrapper (object) or AmadeusCheckoutVerificationInfoWrapper (object) or ThreeDSecure2PostVerificationInfoWrapper (object) or RazorpayPostVerificationInfoWrapper (object)(PostPaymentVerificationInfo)
One of:

Wrapper for post stripe verification info object.

isPreAuthApprovalRequiredboolean

Flag to check if the pre-authorization approval is enabled.

Example:false
customFieldV3ResponsesArray of objects(CustomFieldV3Response)

Custom field responses for the booking.

manualRemarksArray of any(ThirdPartyPnrRemark)

Remarks from the frontend to be added to the PNR during creation.

isTmcMoRForPaymentboolean

Flag to check if the tmc is the merchant of record for payment (MoR).

Example:false
tripDataobject(TripData)

Trip data to book a PNR.

ccPostVerificationUrlstring

The URL the user will be directed to after credit card verification.

holdInfoobject(CreatePnrHoldInfo)

Hold information for the create PNR request.

groupBookingInfoobject(AirCreatePnrRequestGroupBookingInfo)

Group booking information for the create PNR request.

waiveOffInfoobject(WaiveOffInfo)

Waive off info.

pnrIdstring

Existing PNR ID, used in pre-approval flow.

preBookAnswersobject(PreBookAnswers)deprecated
curl -i -X POST \
  https://api-ext-sboxmeta.partners.spotnana.com/v2/air/create-pnr \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "bookingId": "booking-id",
    "initiateBookingId": "eCfghty567jkHG56DFgh",
    "preBookAnswers": {
      "answers": [
        {
          "entityId": "string",
          "userInput": "string",
          "itemIds": [
            0
          ],
          "answers": [
            {
              "item": "string",
              "value": "string",
              "description": "string"
            }
          ],
          "customFieldType": "QUESTION",
          "questionDisplayText": "string",
          "question": {
            "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
            "name": "string",
            "questionFormat": "CHECKBOX",
            "optionInfo": {
              "source": "MANUAL",
              "sourceMetadata": {
                "companyConfig": {}
              },
              "totalNumOptions": 0,
              "options": [
                {}
              ]
            },
            "isRequired": true,
            "isDisabled": true,
            "includeInItinerary": true,
            "customFieldLocations": [
              "POLICY_APPROVAL_EMAIL"
            ],
            "matchConditions": {
              "travelerConditions": {
                "workerTypes": [
                  null
                ],
                "countries": [
                  null
                ],
                "legalEntities": [
                  null
                ],
                "departments": [
                  null
                ],
                "costCenters": [
                  null
                ],
                "offices": [
                  null
                ]
              },
              "travelTypes": [
                "AIR"
              ],
              "travelRegionTypes": [
                "DOMESTIC"
              ],
              "tripUsageTypes": [
                "STANDARD"
              ]
            },
            "questionType": {
              "preSearchQuestionType": "PURPOSE_OF_TRIP",
              "preCheckoutQuestionType": "OOP_REASON_CODE"
            }
          }
        }
      ],
      "preBookQuestionResponseId": "string"
    },
    "preSearchAnswers": {
      "answers": [
        {
          "entityId": "string",
          "userInput": "string",
          "itemIds": [
            0
          ],
          "answers": [
            {
              "item": "string",
              "value": "string",
              "description": "string"
            }
          ],
          "customFieldType": "QUESTION",
          "questionDisplayText": "string",
          "question": {
            "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
            "name": "string",
            "questionFormat": "CHECKBOX",
            "optionInfo": {
              "source": "MANUAL",
              "sourceMetadata": {
                "companyConfig": {}
              },
              "totalNumOptions": 0,
              "options": [
                {}
              ]
            },
            "isRequired": true,
            "isDisabled": true,
            "includeInItinerary": true,
            "customFieldLocations": [
              "POLICY_APPROVAL_EMAIL"
            ],
            "matchConditions": {
              "travelerConditions": {
                "workerTypes": [
                  null
                ],
                "countries": [
                  null
                ],
                "legalEntities": [
                  null
                ],
                "departments": [
                  null
                ],
                "costCenters": [
                  null
                ],
                "offices": [
                  null
                ]
              },
              "travelTypes": [
                "AIR"
              ],
              "travelRegionTypes": [
                "DOMESTIC"
              ],
              "tripUsageTypes": [
                "STANDARD"
              ]
            },
            "questionType": {
              "preSearchQuestionType": "PURPOSE_OF_TRIP",
              "preCheckoutQuestionType": "OOP_REASON_CODE"
            }
          }
        }
      ],
      "userEntitiesResponseId": "string"
    },
    "postPaymentVerificationInfo": {
      "paymentKey": "string",
      "postStripeVerificationInfo": {
        "paymentMethodId": "pm_1HzKDPI3bT9GUjvoUkRQooN3"
      }
    },
    "isPreAuthApprovalRequired": false,
    "customFieldV3Responses": [
      {
        "fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
        "fieldName": "string",
        "armId": "0fd508db-63ff-4444-bfb1-b89c43061433",
        "includeLocations": [
          "APPROVAL_EMAILS"
        ],
        "selectedOptions": [
          {
            "name": "string",
            "translatedName": "string",
            "description": "string",
            "translatedDescription": "string",
            "additionalUserInput": "string",
            "additionalInfos": [
              "string"
            ],
            "additionalInfoConfigs": [
              {
                "type": "VARIABLE",
                "name": "LLF"
              }
            ],
            "optionId": "dee15a0e-f1fe-4cd8-88ac-c090810707f8"
          }
        ]
      }
    ],
    "manualRemarks": [
      {
        "sabre": {
          "type": "GENERAL",
          "text": "PREF ALLIANCES 1-ONE WORLD/AA",
          "legIndex": 1,
          "flightIndex": 0
        }
      }
    ],
    "isTmcMoRForPayment": false,
    "tripData": {
      "approverEmail": "string",
      "approverName": "string",
      "hardApprovalRequired": true,
      "outOfPolicy": true,
      "policyId": "string",
      "policyVersion": 0,
      "tripId": {
        "id": "2783425534"
      }
    },
    "ccPostVerificationUrl": "string",
    "holdInfo": {
      "holdStatus": "NOT_REQUESTED"
    },
    "groupBookingInfo": {
      "groupBookingInfoPerPax": [
        {
          "userOrgId": {
            "organizationAgencyId": {
              "id": "string"
            },
            "organizationId": {
              "id": "string"
            },
            "userId": {
              "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
            },
            "tmcInfo": {
              "id": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              },
              "primaryServiceProviderTmc": {
                "tmcId": {}
              },
              "secondaryServiceProviderTmcs": [
                {}
              ],
              "partnerTmcId": {
                "id": "f49d00fe-1eda-4304-ba79-a980f565281d"
              }
            },
            "tmcBasicInfo": {
              "contractingTmc": {
                "id": {},
                "name": "string",
                "logo": {}
              },
              "bookingTmc": {
                "id": {},
                "name": "string",
                "logo": {}
              }
            }
          },
          "tripData": {
            "approverEmail": "string",
            "approverName": "string",
            "hardApprovalRequired": true,
            "outOfPolicy": true,
            "policyId": "string",
            "policyVersion": 0,
            "tripId": {
              "id": "2783425534"
            }
          },
          "preBookAnswers": {
            "answers": [
              {
                "entityId": "string",
                "userInput": "string",
                "itemIds": [
                  null
                ],
                "answers": [
                  null
                ],
                "customFieldType": "QUESTION",
                "questionDisplayText": "string",
                "question": {
                  "customFieldLocations": []
                }
              }
            ],
            "preBookQuestionResponseId": "string"
          },
          "customFieldV3Responses": [
            {
              "fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
              "fieldName": "string",
              "armId": "0fd508db-63ff-4444-bfb1-b89c43061433",
              "includeLocations": [
                "APPROVAL_EMAILS"
              ],
              "selectedOptions": [
                {
                  "additionalInfos": [],
                  "additionalInfoConfigs": []
                }
              ]
            }
          ]
        }
      ]
    },
    "waiveOffInfo": {
      "waiveOffInfoPerModules": [
        {
          "moduleId": "BOOKING",
          "waiveOffFeeReason": {
            "reasonCode": "WA05",
            "reason": "Customer goodwill"
          }
        }
      ]
    },
    "pnrId": "string"
  }'

Responses

OK

Bodyapplication/json
pnrIdstring

Spotnana PNR ID.

sourcePnrIdstring

Source PNR ID

pnrStatusstring

PNR status (for example success, approval pending)

Enum:"SUCCESS""APPROVAL_PENDING""CC_VERIFICATION_REQUIRED""PAYMENT_PENDING""CONFIRMATION_PENDING""ERROR"
createPnrApplicationInfoobject

Create PNR application info, will return warning or error if present

multiSourceBookingInfoArray of objects(MultiSourceBookingInfo)

Booking info for each leg in a multi-source booking.

ccVerificationUrlstring

If non-empty, the user must be redirected to this URL for credit card verification.

paymentVerificationInfoStripeVerificationInfoWrapper (object) or UrlVerificationInfoWrapper (object) or ThreeDSecure2VerificationInfoWrapper (object) or RazorpayVerificationInfoWrapper (object)(PaymentVerificationInfo)
One of:

Wrapper for stripe verification Info.

groupBookingInfoobject(AirCreatePnrResponseGroupBookingInfo)

Group booking information in the create PNR response.

Response
{ "pnrId": "string", "sourcePnrId": "string", "pnrStatus": "SUCCESS", "createPnrApplicationInfo": { "applicationWarning": [ … ] }, "multiSourceBookingInfo": [ { … } ], "ccVerificationUrl": "string", "paymentVerificationInfo": { "gatewayIdentifier": { … }, "paymentKey": "string", "stripeVerificationInfo": { … } }, "groupBookingInfo": { "groupBookingInfoPerPax": [ … ] } }