Trip API (v2)

Download OpenAPI description
Languages
Servers
Staging URL
https://apis.spotnana.com/
Spotnana mock server
https://developer.spotnana.com/_mock/openapi/tripapi/

Trips

APIs to manage trips and PNRs.

Operations

Get trip

Request

This endpoint gets trip by ID.

Path
tripIdstringrequired

Identifier for trip.

Example: 2398199412
curl -i -X GET \
  https://apis.spotnana.com/v2/trips/2398199412 \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
tripIdstringrequired

Spotnana trip Id

Example: "6926658168"
tripNamestringrequired

Name of the trip

Example: "JFK SFO Trip"
tripDescriptionstring

Trip description

Example: "JFK SFO Business Trip"
applicationIdstring(uuid)

Application id used for the trip.

startDateobject(DateModel)

Date in ISO 8601 standard.

endDateobject(DateModel)

Date in ISO 8601 standard.

userIdobject(UserId)

The user Id of the traveler to whom the trip belongs to.

registrarUserIdobject(UserId)

The user Id of the registrar of the adhoc traveler.

Response
application/json
{ "tripId": "6926658168", "tripName": "JFK SFO Trip", "tripDescription": "JFK SFO Business Trip", "applicationId": "97ab27fa-30e2-43e3-92a3-160e80f4c0d5", "startDate": { "iso8601": "2017-07-21" }, "endDate": { "iso8601": "2017-07-21" }, "userId": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08" }, "registrarUserId": { "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08" } }

Update trip

Request

This endpoint updates trip by ID.

Path
tripIdstringrequired

Identifier for trip.

Example: 2398199412
Bodyapplication/json
tripIdstringrequired

Spotnana trip Id

Example: "6926658168"
tripNamestringrequired

Name of the trip

Example: "JFK SFO Trip"
tripDescriptionstring

Trip description

Example: "JFK SFO Business Trip"
curl -i -X PUT \
  https://apis.spotnana.com/v2/trips/2398199412 \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "tripId": "6926658168",
    "tripName": "JFK SFO Trip",
    "tripDescription": "JFK SFO Business Trip"
  }'

Responses

Updated Successfully

Response
No content

Get trip details

Request

This endpoint gets trip details for a given trip ID.

Path
tripIdstringrequired

Trip ID

Example: 6926658168
Query
refreshTypestring(RefreshType)

Refresh Type

Enum"REFRESH_TYPE_BLOCKING""REFRESH_TYPE_ASYNC""REFRESH_TYPE_DISABLED"
Example: refreshType=REFRESH_TYPE_BLOCKING
curl -i -X GET \
  'https://apis.spotnana.com/v3/trips/6926658168/detail?refreshType=REFRESH_TYPE_BLOCKING' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

OK

Bodyapplication/json
basicTripInfoobject(BasicTripInfo)required

Basic trip info

basicTripInfo.​tripIdstringrequired

Spotnana trip Id

Example: "6926658168"
basicTripInfo.​tripNamestringrequired

Name of the trip

Example: "JFK SFO Trip"
basicTripInfo.​tripDescriptionstring

Trip description

Example: "JFK SFO Business Trip"
basicTripInfo.​applicationIdstring(uuid)

Application id used for the trip.

basicTripInfo.​startDateobject(DateModel)

Date in ISO 8601 standard.

basicTripInfo.​endDateobject(DateModel)

Date in ISO 8601 standard.

basicTripInfo.​userIdobject(UserId)

The user Id of the traveler to whom the trip belongs to.

basicTripInfo.​registrarUserIdobject(UserId)

The user Id of the registrar of the adhoc traveler.

pnrsArray of objects(PnrDetailsResponseWithId)required
pnrs[].​pnrIdstring

Unique PNR ID

Example: "6926658168"
pnrs[].​dataobject(PnrData)

Pnr data with all information about a single booking containing one of Air, Hotel, Car, Rail, Limo or Miscellaneous PNR.

pendingShellPnrsArray of objects(PnrDetailsResponseWithId)
pendingManualFormPnrsArray of objects(PnrDetailsResponseWithId)
tripBookingStatusstring(UserFacingStatus)

User facing booking status

Enum"UNKNOWN_STATUS""PENDING_STATUS""CONFIRMED_STATUS""ACTIVE_STATUS""COMPLETED_STATUS""CANCELLED_STATUS""REFUNDED_STATUS""VOIDED_STATUS""PROCESSING_STATUS""UNCONFIRMED_STATUS"
eventSummaryobject(TravelerEventSummary)

Event summary for a traveler

simplePnrsArray of objects(SimplePnr)
additionalInfoobject(TripAdditionalInfo)

Additional information about the trip

tripPaymentInfoobject(TripPaymentInfo)

Payment info for a given trip. Fares of pending manual form and pending shell pnrs are not considered.

tripStatusstring(PnrBookingStatus)Deprecated

User facing status for this booking

Enum"PENDING""CONFIRMED""ACTIVE""COMPLETED""CANCELLED""REFUNDED""VOIDED""PROCESSING""UNCONFIRMED""AIRLINE_CONTROL"
Response
application/json
{ "basicTripInfo": { "tripId": "6926658168", "tripName": "JFK SFO Trip", "tripDescription": "JFK SFO Business Trip", "applicationId": "97ab27fa-30e2-43e3-92a3-160e80f4c0d5", "startDate": {}, "endDate": {}, "userId": {}, "registrarUserId": {} }, "pnrs": [ {} ], "pendingShellPnrs": [ {} ], "pendingManualFormPnrs": [ {} ], "tripStatus": "CONFIRMED", "tripBookingStatus": "PENDING_STATUS", "eventSummary": { "id": "12345", "type": "GENERIC", "name": "My event", "description": "This is an event description", "startDateTime": {}, "endDateTime": {}, "location": {}, "contacts": [], "documents": [], "bookingGuidelines": [], "allowedBookingTypes": [], "eventUserRsvp": {}, "contactInfoList": [], "companyId": {}, "runningStatus": "UPCOMING", "status": "DRAFT", "isRemovedParticipant": true }, "simplePnrs": [ {} ], "additionalInfo": { "vpayBillBack": "B" }, "tripPaymentInfo": { "totalFare": {}, "totalFareAmount": {}, "serviceFeeFareAmount": {} } }

Invoicing

Operations

Approval

Operations