Event API (v2)

Download OpenAPI specification:Download

Events

APIs to create and manage events.

Create event

This endpoint creates an event.

SecurityBearer
Request
Request Body schema: application/json
name
required
string

Name of the event

description
string

Description of the event

Array of objects (Document)

Documents attached for an event

object (DateTimeLocal)

Local date and time represented in the ISO 8601 standard.

object (DateTimeLocal)

Local date and time represented in the ISO 8601 standard.

required
object (EventLocation)

Location for an event

Array of objects (UserId)

Contacts for the event

Array of AirBookingGuidelineWrapper (object) or HotelBookingGuidelineWrapper (object) or CarBookingGuidelineWrapper (object) or RailBookingGuidelineWrapper (object) (EventBookingGuideline)

A list of booking guideline for the event.

allowedBookingTypes
Array of strings (EventAllowedBookingType)

Allowed booking types for the event group

Items Enum: "AIR" "HOTEL" "CAR" "RAIL"
externalId
string

External Id for the event

Array of objects (CustomFieldResponse)

List of custom field responses for the event.

parentEventId
string

Optional parent event's id.

object (CompanyId)

Company id

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events
Request samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "documents": [
    ],
  • "startDateTime": {
    },
  • "endDateTime": {
    },
  • "location": {
    },
  • "contacts": [
    ],
  • "bookingGuidelines": [
    ],
  • "allowedBookingTypes": [
    ],
  • "externalId": "qwert123",
  • "eventCustomFieldResponses": [
    ],
  • "parentEventId": "56789012",
  • "companyId": {
    }
}
Response samples
application/json
{
  • "id": "string"
}

Get event

This endpoint gets event details for a given event ID.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Responses
200

OK

401

Unauthorized

403

Forbidden

404

The specified resource was not found.

get/v2/events/{eventId}
Request samples
Response samples
application/json
{
  • "event": {
    }
}

Delete draft event

This endpoint deletes an event in draft state.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Responses
200

OK

401

Unauthorized

403

Forbidden

404

The specified resource was not found.

delete/v2/events/{eventId}
Request samples
Response samples
application/json
{
  • "debugIdentifier": "string",
  • "errorMessages": [
    ]
}

Get event by external ID.

This endpoint gets event details for a given event's external ID. External IDs are unique within an org.

SecurityBearer
Request
query Parameters
externalId
required
string

External ID

Example: externalId=6926658168
companyId
required
string <uuid>

Company ID

Example: companyId=f49d00fe-1eda-4304-ba79-a980f565281d
Responses
200

OK

401

Unauthorized

403

Forbidden

404

The specified resource was not found.

get/v2/events/read-by-external-id
Request samples
Response samples
application/json
{
  • "event": {
    }
}

Add travelers to an event

This endpoint adds travelers to an event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
Array of objects (UserId)
Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/travelers/add
Request samples
application/json
{
  • "userIds": [
    ]
}
Response samples
application/json
{
  • "addedUserIds": [
    ]
}

Remove travelers from an event

This endpoint removes travelers from an event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
Array of objects (UserId) [ 1 .. 10 ] items
Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/travelers/remove
Request samples
application/json
{
  • "userIds": [
    ]
}
Response samples
application/json
{
  • "removedUserIds": [
    ]
}

List events

This endpoint lists events.

SecurityBearer
Request
Request Body schema: application/json
listEventType
string

Type of events

Enum: "UPCOMING" "PAST_OR_COMPLETED" "CANCELLED_EVENT"
Array of EventUserFilterWrapper (object) or EventStatusFilterWrapper (object) or EventNameFilterWrapper (object) or EventDateRangeFilterWrapper (object) or EventCompanyFilterWrapper (object) (EventFilter)

List events filters

offset
integer >= 0
Default: 0

Indicates from where in the list of events the server should start.

limit
integer <= 100
Default: 10

Maximum number of results to be fetched for the query.

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/list
Request samples
application/json
{
  • "listEventType": "UPCOMING",
  • "filters": [
    ],
  • "offset": 2,
  • "limit": 2
}
Response samples
application/json
{
  • "events": [
    ],
  • "paginationParams": {
    }
}

Publish event

This endpoint publishes an event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/publish
Request samples
Response samples
application/json
{
  • "id": "string"
}

Update event basic information

This endpoint allows updating basic event information.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
name
required
string

Name of the event

description
string

Description of the event

Array of objects (Document)

Documents attached for an event

object (DateTimeLocal)

Local date and time represented in the ISO 8601 standard.

object (DateTimeLocal)

Local date and time represented in the ISO 8601 standard.

required
object (EventLocation)

Location for an event

Array of objects (UserId)

Contacts for the event

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/edit-basic-info
Request samples
application/json
{
  • "name": "string",
  • "description": "string",
  • "documents": [
    ],
  • "startDateTime": {
    },
  • "endDateTime": {
    },
  • "location": {
    },
  • "contacts": [
    ]
}
Response samples
application/json
{
  • "id": "string"
}

Update event booking guidelines

This endpoint updates the booking guidelines for an event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
required
Array of AirBookingGuidelineWrapper (object) or HotelBookingGuidelineWrapper (object) or CarBookingGuidelineWrapper (object) or RailBookingGuidelineWrapper (object) (EventBookingGuideline)

A list of booking guideline for the event.

allowedBookingTypes
Array of strings (EventAllowedBookingType)

Allowed booking types for the event group

Items Enum: "AIR" "HOTEL" "CAR" "RAIL"
Array of objects (PaymentAccessMapping)

Mappings i.e. access level, travel type information etc.

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/edit-booking-guidelines
Request samples
application/json
{
  • "bookingGuidelines": [
    ],
  • "allowedBookingTypes": [
    ],
  • "paymentMappings": [
    ]
}
Response samples
application/json
{
  • "id": "string"
}

Set traveler's rsvp state and response for the event

This endpoint sets traveler's rsvp and response for the event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
travelerId
required
string <uuid>

Traveler User ID

Example: f49d00fe-1eda-4304-ba79-a980f565281d
Request Body schema: application/json
eventRsvpState
string (EventRsvpState)

Allowed event rsvp states for a user

Enum: "ADDED" "INVITED" "INVITE_ACCEPTED" "INVITE_DECLINED" "REMOVED"
object (EventRsvpResponse)

Event rsvp response

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/travelers/{travelerId}/rsvp
Request samples
application/json
{
  • "eventRsvpState": "ADDED",
  • "eventRsvpResponse": {
    }
}
Response samples
application/json
{
  • "debugIdentifier": "string",
  • "errorMessages": [
    ]
}

Get traveler's rsvp state and response for the event

This endpoint gets traveler's rsvp and response for the event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
travelerId
required
string <uuid>

Traveler User ID

Example: f49d00fe-1eda-4304-ba79-a980f565281d
Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

get/v2/events/{eventId}/travelers/{travelerId}/rsvp
Request samples
Response samples
application/json
{
  • "userId": {
    },
  • "eventRsvpState": "ADDED",
  • "eventRsvpResponse": {
    },
  • "invitedAt": {
    },
  • "airBookingStatus": "BOOKED",
  • "railBookingStatus": "BOOKED",
  • "carBookingStatus": "BOOKED",
  • "hotelBookingStatus": "BOOKED"
}

Send invite to all or some travellers of the event

This endpoint sends invite to all or some travellers of an event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
Array of objects (UserId)
Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/invite/send
Request samples
application/json
{
  • "userIds": [
    ]
}
Response samples
application/json
{
  • "debugIdentifier": "string",
  • "errorMessages": [
    ]
}

Test invite for the event

This endpoint tests an invite for an event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/invite/test
Request samples
Response samples
application/json
{
  • "debugIdentifier": "string",
  • "errorMessages": [
    ]
}

Get Event Summaries

This endpoint gets event summaries

SecurityBearer
Request
Request Body schema: application/json
object (UserId)

User id

object (CompanyId)

Company id

tripIds
Array of strings

List of Spotnana trip IDs

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/summaries
Request samples
application/json
{
  • "userId": {
    },
  • "companyId": {
    },
  • "tripIds": [
    ]
}
Response samples
application/json
{
  • "tripEventSummaries": [
    ]
}

Get Events allowed Payment Sources

This endpoint gets the list of payment sources that can be used for Events.

SecurityBearer
Request
query Parameters
userId
required
string <uuid>

ID of the Event Creator

Example: userId=f49d00fe-1eda-4304-ba79-a980f565281d
Responses
200

OK

401

Unauthorized

403

Forbidden

404

The specified resource was not found.

get/v2/events/payment-sources
Request samples
Response samples
application/json
{
  • "paymentSources": [
    ]
}

Cancel published event

This endpoint cancels a published event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Responses
200

OK

401

Unauthorized

403

Forbidden

404

The specified resource was not found.

post/v2/events/{eventId}/cancel
Request samples
Response samples
application/json
{
  • "debugIdentifier": "string",
  • "errorMessages": [
    ]
}

Retrieve paginated travelers' list alongwith respective rsvp & tripids for an Event.

This endpoint retrieves the paginated list of travelers of a specific event.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
offset
integer >= 0
Default: 0

Indicates from where in the list of travelers the server should start.

limit
integer [ 0 .. 100 ]
Default: 10

Maximum number of results to be fetched for the query.

Array of objects (EventTravelerFilter)

Filters for event travelers

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

post/v2/events/{eventId}/travelers-list
Request samples
application/json
{
  • "offset": 2,
  • "limit": 2,
  • "filters": [
    ]
}
Response samples
application/json
{
  • "travelerEventInfos": [
    ],
  • "userGroupInfo": {
    },
  • "paginationParams": {
    }
}

Update event's custom field responses.

This endpoint updates the event's custom field responses.

SecurityBearer
Request
path Parameters
eventId
required
string

Event ID

Example: 6926658168
Request Body schema: application/json
required
Array of objects (CustomFieldResponse)

List of custom field responses for an event.

Responses
200

OK

400

Bad request

401

Unauthorized

403

Forbidden

put/v2/events/{eventId}/custom-field-responses
Request samples
application/json
{
  • "eventCustomFieldResponses": [
    ]
}
Response samples
application/json
{
  • "debugIdentifier": "string",
  • "errorMessages": [
    ]
}
Copyright © 2020-2024 Spotnana Technology, Inc.