APIs to create and manage event templates.
Allowed booking types for the event template
A list of booking guideline for the event.
List of custom field responses for an event.
Mappings i.e. access level, travel type information etc.
Company id
Allowed traveler types for the event
Policy associated with the event.
Whether the event bookings will be self served by the traveler or would be arranged by an agent for the traveler.
Apply travelers policy when it is less restrictive.
Email communication preferences based on bucket types.
Allow travelers to rsvp for the event
curl -i -X POST \
https://apis.spotnana.com/v2/event-templates \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "string",
"description": "string",
"location": {
"address": {
"addressLines": [
"Golden Gate Bridge"
],
"administrativeArea": "CA",
"administrativeAreaName": "California",
"description": "San Francisco Home",
"isDefault": true,
"languageCode": "en",
"locality": "San Francisco",
"locationCode": "LAX",
"organization": "Spotnana",
"postalCode": "94130",
"continentCode": "AF",
"recipients": [
"string"
],
"regionCode": "US",
"regionName": "America",
"revision": 1,
"sortingCode": "Jamaica",
"sublocality": "string",
"timezone": "America/Los_Angeles",
"coordinates": {
"latitude": 77.1025,
"longitude": 28.7041
}
},
"coordinates": {
"latitude": 77.1025,
"longitude": 28.7041
}
},
"allowedBookingTypes": [
"AIR"
],
"bookingGuidelines": [
{
"numGuestsAllowed": 1,
"airBookingGuideLine": {
"allowedAirports": [
{
"airportCode": "WRA",
"airportName": "Warder Airport",
"cityName": "Werder",
"countryName": "Ethiopia",
"countryCode": "ET",
"zoneName": "Africa/Addis_Ababa",
"stateCode": "CA"
}
],
"arrivalBookingWindow": {
"startDateTime": {
"iso8601": "2017-07-21T17:32"
},
"endDateTime": {
"iso8601": "2017-07-21T17:32"
}
},
"departureBookingWindow": {
"startDateTime": {
"iso8601": "2017-07-21T17:32"
},
"endDateTime": {
"iso8601": "2017-07-21T17:32"
}
},
"allowedFlightGuidelines": [
{
"allowedFlightType": "ROUND_TRIP",
"numberOfLegs": 2
}
]
}
}
],
"customFieldResponses": [
{
"customFieldId": "f49d00fe-1eda-4304-ba79-a980f565281d",
"responseItems": [
{
"response": "Leisure travel",
"additionalInput": "20"
}
],
"travelerAccess": "HIDDEN"
}
],
"customFieldV3Responses": [
{
"fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
"fieldName": "string",
"armId": "0fd508db-63ff-4444-bfb1-b89c43061433",
"readOnly": true,
"hidden": true,
"selectedOptions": [
{
"name": "string",
"description": "string",
"additionalUserInput": "string",
"additionalInfos": [
"string"
],
"additionalInfoConfigs": [
{
"type": "VARIABLE",
"name": "PUBLISHED_FARE"
}
]
}
]
}
],
"paymentMappings": [
{
"id": "f49d00fe-1eda-4304-ba79-a980f565281d",
"accessTypeAttributes": {
"travelTypeFilter": {
"travelTypes": [
{
"travelType": "AIR",
"isRequired": true,
"allowPostPaidBookings": false,
"metadata": {
"vendors": []
}
}
]
}
}
}
],
"companyId": {
"id": "f49d00fe-1eda-4304-ba79-a980f565281d"
},
"internalNotes": "Use travelers default as payment method.",
"referenceUsers": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
}
],
"travelerTypes": [
"EMPLOYEE"
],
"policyId": "f7b3b3b3-7b3b-4b3b-8b3b-3b3b3b3b3b3b",
"bookingStyle": "SELF_SERVE",
"externalId": "qwert123",
"allowTravelersPolicy": "ALLOWED",
"emailPreferences": {
"bucketTypes": [
"BOOKING_CONFIRMATIONS"
],
"isEnabled": false,
"toEmails": [
"example@email.com"
],
"ccEmails": [
"example@email.com"
],
"bccEmails": [
"example@email.com"
]
},
"allowTravelersToRsvp": "ALLOWED",
"tripOverrides": {
"legalEntity": {
"behavior": "OVERRIDE_ALLOWED",
"legalEntityRef": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string"
}
},
"costCenter": {
"behavior": "OVERRIDE_ALLOWED",
"costCenterRef": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string"
}
},
"department": {
"behavior": "OVERRIDE_ALLOWED",
"departmentRef": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string"
}
},
"userAttributes": [
{
"behavior": "OVERRIDE_ALLOWED",
"attribute": {
"fixedColumnName": "contingentType",
"value": "FSTV"
}
}
]
}
}'
curl -i -X GET \
https://apis.spotnana.com/v2/event-templates/6926658168 \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{ "eventTemplate": { "id": "string", "name": "string", "description": "string", "location": { … }, "paymentSources": [ … ], "companyId": { … }, "customFieldResponses": [ … ], "customFieldV3Responses": [ … ], "group": { … }, "externalId": "qwert123", "policyId": "f7b3b3b3-7b3b-4b3b-8b3b-3b3b3b3b3b3b" } }
curl -i -X DELETE \
https://apis.spotnana.com/v2/event-templates/6926658168 \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
Allowed traveler types for the event
Whether the event bookings will be self served by the traveler or would be arranged by an agent for the traveler.
Policy associated with the event.
Apply travelers policy when it is less restrictive.
Email communication preferences based on bucket types.
Allow travelers to rsvp for the event
curl -i -X POST \
https://apis.spotnana.com/v2/event-templates/6926658168/edit-basic-info \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"name": "string",
"description": "string",
"internalNotes": "string",
"referenceUsers": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"
}
],
"location": {
"address": {
"addressLines": [
"Golden Gate Bridge"
],
"administrativeArea": "CA",
"administrativeAreaName": "California",
"description": "San Francisco Home",
"isDefault": true,
"languageCode": "en",
"locality": "San Francisco",
"locationCode": "LAX",
"organization": "Spotnana",
"postalCode": "94130",
"continentCode": "AF",
"recipients": [
"string"
],
"regionCode": "US",
"regionName": "America",
"revision": 1,
"sortingCode": "Jamaica",
"sublocality": "string",
"timezone": "America/Los_Angeles",
"coordinates": {
"latitude": 77.1025,
"longitude": 28.7041
}
},
"coordinates": {
"latitude": 77.1025,
"longitude": 28.7041
}
},
"travelerTypes": [
"EMPLOYEE"
],
"bookingStyle": "SELF_SERVE",
"policyId": "f7b3b3b3-7b3b-4b3b-8b3b-3b3b3b3b3b3b",
"allowTravelersPolicy": "ALLOWED",
"emailPreferences": {
"bucketTypes": [
"BOOKING_CONFIRMATIONS"
],
"isEnabled": false,
"toEmails": [
"example@email.com"
],
"ccEmails": [
"example@email.com"
],
"bccEmails": [
"example@email.com"
]
},
"allowTravelersToRsvp": "ALLOWED",
"tripOverrides": {
"legalEntity": {
"behavior": "OVERRIDE_ALLOWED",
"legalEntityRef": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string"
}
},
"costCenter": {
"behavior": "OVERRIDE_ALLOWED",
"costCenterRef": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string"
}
},
"department": {
"behavior": "OVERRIDE_ALLOWED",
"departmentRef": {
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"name": "string"
}
},
"userAttributes": [
{
"behavior": "OVERRIDE_ALLOWED",
"attribute": {
"fixedColumnName": "contingentType",
"value": "FSTV"
}
}
]
}
}'
A list of booking guideline for the event.
Allowed booking types for the event template
Allowed payment configuration for the event template
curl -i -X POST \
https://apis.spotnana.com/v2/event-templates/6926658168/edit-booking-guidelines \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"bookingGuidelines": [
{
"numGuestsAllowed": 1,
"airBookingGuideLine": {
"allowedAirports": [
{
"airportCode": "WRA",
"airportName": "Warder Airport",
"cityName": "Werder",
"countryName": "Ethiopia",
"countryCode": "ET",
"zoneName": "Africa/Addis_Ababa",
"stateCode": "CA"
}
],
"arrivalBookingWindow": {
"startDateTime": {
"iso8601": "2017-07-21T17:32"
},
"endDateTime": {
"iso8601": "2017-07-21T17:32"
}
},
"departureBookingWindow": {
"startDateTime": {
"iso8601": "2017-07-21T17:32"
},
"endDateTime": {
"iso8601": "2017-07-21T17:32"
}
},
"allowedFlightGuidelines": [
{
"allowedFlightType": "ROUND_TRIP",
"numberOfLegs": 2
}
]
}
}
],
"allowedBookingTypes": [
"AIR"
],
"allowedPaymentConfig": [
{
"travelType": "AIR",
"paymentConfig": "TRAVELER_DEFAULT"
}
],
"paymentMappings": [
{
"id": "f49d00fe-1eda-4304-ba79-a980f565281d",
"accessTypeAttributes": {
"travelTypeFilter": {
"travelTypes": [
{
"travelType": "AIR",
"isRequired": true,
"allowPostPaidBookings": false,
"metadata": {
"vendors": []
}
}
]
}
}
}
]
}'
curl -i -X PUT \
https://apis.spotnana.com/v2/event-templates/6926658168/custom-field-responses \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"customFieldResponses": [
{
"customFieldId": "f49d00fe-1eda-4304-ba79-a980f565281d",
"responseItems": [
{
"response": "Leisure travel",
"additionalInput": "20"
}
],
"travelerAccess": "HIDDEN"
}
],
"customFieldV3Responses": [
{
"fieldId": "84922011-b03d-4966-bc95-c5b49bc2e342",
"fieldName": "string",
"armId": "0fd508db-63ff-4444-bfb1-b89c43061433",
"readOnly": true,
"hidden": true,
"selectedOptions": [
{
"name": "string",
"description": "string",
"additionalUserInput": "string",
"additionalInfos": [
"string"
],
"additionalInfoConfigs": [
{
"type": "VARIABLE",
"name": "PUBLISHED_FARE"
}
]
}
]
}
]
}'
List events filters
Indicates from where in the list of events the server should start.
curl -i -X POST \
https://apis.spotnana.com/v2/event-templates/list \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"filters": [
{
"companyFilter": {
"companyId": {
"id": "f49d00fe-1eda-4304-ba79-a980f565281d"
}
}
}
],
"offset": 2,
"limit": 2
}'
{ "eventTemplates": [ { … } ], "paginationParams": { "totalNumResults": 0 } }
curl -i -X GET \
'https://apis.spotnana.com/v2/event-templates/read-by-external-id?companyId=f49d00fe-1eda-4304-ba79-a980f565281d&externalId=6926658168' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>'
{ "eventTemplate": { "id": "string", "name": "string", "description": "string", "location": { … }, "paymentSources": [ … ], "companyId": { … }, "customFieldResponses": [ … ], "customFieldV3Responses": [ … ], "group": { … }, "externalId": "qwert123", "policyId": "f7b3b3b3-7b3b-4b3b-8b3b-3b3b3b3b3b3b" } }