APIs to manage trips and PNRs.
Type of cancellation to be performed. For the NO_REFUND, FULL_REFUND and FULL_CREDIT cancellation types, if no cancellationDetails are provided, we assume the entire PNR is being canceled. If the cancellation type is FULL_CREDIT, we will also assume the credits created will have 0 penalty and an expiry date of 1 year from the issue date of the ticket.
List of object to be cancelled and their associated refund details.
curl -i -X POST \
https://apis.spotnana.com/v3/trips/6926658168/pnrs/6926658168/cancel \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"cancellationType": "FULL_REFUND",
"cancellationDetails": [
{
"cancelObjectDetail": {
"cancelObjectType": "PNR",
"cancelObjectId": "string",
"vendorCancellationId": "string"
},
"refundInfo": [
{
"refundType": "CREDIT",
"amount": {
"base": {
"amount": 510,
"currencyCode": "GBP",
"convertedAmount": 715.42,
"convertedCurrency": "USD",
"otherCoinage": [
{}
]
},
"tax": {
"amount": 510,
"currencyCode": "GBP",
"convertedAmount": 715.42,
"convertedCurrency": "USD",
"otherCoinage": [
{}
]
}
},
"fop": {
"type": "CARD",
"card": {
"id": "34d536b6-f8ff-11eb-9a61-0242ac180002",
"type": "CREDIT",
"company": "VISA",
"name": "Harrison Schwartz",
"address": {
"addressLines": [],
"recipients": []
},
"number": "4111111111111111",
"expiryMonth": 1,
"expiryYear": 2010,
"cvv": "012",
"label": "Label amex",
"currency": "USD",
"externalId": "bxt_RNGsNfzgJDaTstKIKqK4xEuhGYAnMdYK8T40",
"vaultId": "34d536b6-f8ff-11eb-9a61-0242ac180002",
"expiry": {},
"ownershipLabel": "CORPORATE"
},
"additionalInfo": "string",
"accessType": {
"accessType": "UNKNOWN_TYPE",
"entityIds": [
null
],
"entities": [
null
]
},
"paymentMethod": "BREX_POINTS",
"paymentMetadata": {
"customPaymentMethodMetadata": {
"brexBudgetMetadata": {}
},
"vendorProgramPaymentMetadata": {},
"virtualCardMetadata": {},
"cardMetadata": {}
},
"paymentSourceType": "CARD"
},
"expiryDate": {
"iso8601": "2017-07-21"
}
}
]
}
],
"bookingEmailInfo": {
"disableEmail": true
}
}'
curl -i -X GET \
https://apis.spotnana.com/v2/trips/2398199412/booker-email/akanksha@spotnana.com/partner-info \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{ "tripId": "6926658168", "partnerInfo": { "partnerInfoType": "BUDGET", "partnerInfoDetails": { … } } }
curl -i -X GET \
https://apis.spotnana.com/v2/trips/1234567890/pnrs/6926658168/cancellation-details \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{ "pnrId": "1234567890", "tripId": "2345678901", "cancellationDetails": { "air": { … } } }