Connect API (Incoming)
Connect is a generic framework from Wetu for integrating Tour Operator Software (TOS) systems. Specifically; it simplifies many of the common problems with converting bookings or quotes from a TOS into Wetu. Using a TOS and Wetu together gives the best of both worlds - easy, accurate quoting and operational management capabilities from the TOS and high quality, compelling sales and travel materials from Wetu (along with direct access to travel supplier content).
Converting a booking from a TOS to Wetu requires mapping a TOS's data structures into a format Wetu understands; mapping supplier representations from the TOS to their equivalent identities in Wetu and resolving any ambiguities in a booking (overlapping accommodation; inconsistent dates or durations; own arrangement gaps; "generic" accommodation or services; etc). The Connect API simplifies an integration by taking responsibility for the majority of those tasks.
Getting Started
To integrate with Wetu using the Connect API; your integration will need to be registered with Wetu. Please fill out and submit the below linked form to begin. Once registered; you will receive a test key for your integration.
Technical Details
The Connect API consists of three REST endpoints. Messages to and from the endpoints are JSON objects.
- Bookings
- A booking is a specific quote or booking by a client. A booking has at least a reference, a name and one or more services.
- https://wetu.com/Connect/API/Bookings/KEY
- Read bookings by sending a GET request (returns array of Booking)
- Update / add bookings by sending a POST or PUT request (Booking)
- Schema: https://wetu.com/Connect/API/BookingsSchema
- Mappings
- A mapping is a conversion between a service or supplier in the TOS to an equivalent in Wetu. A wide range of mappings are supported by Wetu. The API is used to load services ahead of time; the operator is then able to use a Wetu interface to perform the mapping process.
- https://wetu.com/Connect/API/Mappings/KEY
- Read existing mappings by sending a GET request (returns array of Mapping)
- Schema: https://wetu.com/Connect/API/MappingsSchema
- Locations
- A location is a pickup or dropoff point.
- https://wetu.com/Connect/API/Locations/KEY
- Read existing locations by sending a GET request (returns array of Location)
- Update / add locations by sending a POST or PUT request (Location)
- Schema: https://wetu.com/Connect/API/LocationsSchema
Data Formats
Note: JSON does not specify a format for dates. This API uses strings containing an ISO8601 formatted date. This is the default for most JSON serialization libraries.
- Booking
- Name (string) - label for this booking
- Reference (string) - unique identifier for this booking
- TravelDate (date) (optional) - date of travel for this booking
- CreatedDate (date) (read-only) - date this booking was created in Wetu
- LastUpdatedDate (date) (read-only) - date this booking was last updated in Wetu (at present, both LastUpdatedDate and CreatedDate will have the same value)
- BookingStatus (string) (optional) - code or description of current booking status (e.g. quote / confirmed)
- ConsultantEmail (string) - email address of consultant creating this booking
- Agent (string) (optional) - identifier of the agent a booking is for; used to automatically match to a Wetu identity
- Status (string) (readonly) - status of a booking in Wetu; i.e. whether it has been converted into an itinerary
- CurrentIdentifier (string) (readonly) - identifier of the booking in Wetu; can be used to construct URLs to view or create printable documentation
- CurrentMobileCode (string) (readonly) - short code for loading a booking; allowing guests access to the Wetu app, TravelKey (only available for selected plans)
- Introduction (string) (optional) - summary or introduction for this booking; supports limited HTML markup
- Price (string) (optional) - price information for this booking; supports limited HTML markup
- Included (string) (optional) - text describing price inclusions; supports limited HTML markup
- Excluded (string) (optional) - text describing price exclusions; supports limited HTML markup
- Terms (string) (optional) - text describing booking specific terms and conditions; supports limited HTML markup
- Language (string) (optional) - ISO 639-1 language code for this booking; defaults to "en" if not specified
- Travellers (array of Traveller) (optional) - list of names and details for guests on the booking
- Services (array of Service) - list of services comprising this booking
- Mapping
- SystemId (string) - unique identifier for this service line / supplier
- Name (string) - label for this service
- Description (string) (optional) - description or additional detail for this service
- Comment (string) (optional) - further information on this service
- SupportedMappings (array of string) (optional) - optional restricted set of supported mapping types for this service; for example to ensure that a flight is only handled as travel and not as an accommodation
- MappedAs (string) (optional) - current state of the mapping; can be used to clear an existing mapping when updating by setting this to "Unmapped"
- ContentEntityId (int) (readonly) - id of the mapped supplier in Wetu
- Basis (string) (optional) - accommodation only; meal basis of the service; will override a mapped default basis if provided with a booking
- ContentEntityItemId (string) (readonly) - a secondary id related to ContentEntityId; used to identify a room or a "sub-service" at a supplier
- Component (string) (readonly) - an itinerary identifier used by Day Tour, Multi-Day Tour and Component mappings
- Highlight (bool) (optional) - flags an activity or day tour as a trip highlight
- TravelMode (string) (readonly) - indicates the mode of travel (e.g. Scheduled Flight or Transfer)
- TravelModeLabel (string) (readonly) - indicates a specific variant of the TravelMode (e..g Private)
- Daily (bool) (optional) - flags an Included service as being day specific instead of trip specific
- Traveller
- Type (string) (optional) - Child or Adult
- Title (string) (optional) - title (e.g. Mr) of the traveller
- Name (string) - name of the traveller
- Age (int) (optional) - age of the traveller
- Location
- SystemId (string) - unique identifier for this location
- Name (string) - name / label for this location
- Description (string) (optional) - further information for this location
- Address (string) (optional) - address of the location
- ContentEntityId (int) (readonly) - id of the mapped location in Wetu
- Service (extends Mapping)
- Date (date) - date for this service
- EndDate (date) - end date for this service; usually only different than date above for accommodation (check-out), overnight travel or car hire
- Note (string) (optional) - text to be added to daily notes; supports limited HTML markup
- Included (string) (optional) - included text to be added to daily included notes; supports limited HTML markup
- ExpertTips (string) (optional) - text to be added to daily expert tips; supports limited HTML markup
- StartTime (string) (optional) - time for the service; supports formats such as 12:00, 12h00, 12.00, 1200, 11.00 AM, 11:00 PM or 11.00 a.m.
- EndTime (string) (optional) - end time for the service; as above
- ReferenceCodes (array of string) (optional) - reference codes or ticket numbers for the service
- Sequence (int) (optional) - a sequence (for the day) for the service; used to order a clients day plan and notes
- Adults (int) (optional) - number of adult guests; used for accommodation
- Children (int) (optional) - number of child guests; used for accommodation
- Rooms (int) (optional) - number of rooms booked for the accommodation
- RoomName (string) (optional) - the name of the room booked for an accommodation
- RoomType (string) (optional) - the occupancy configuration of the room booked for an accommodation
- Agency (string) (optional) - the agency providing a travel or car hire service
- Vehicle (string) (optional) - the type of vehicle or flight number of a travel service or car hire
- Class (string) (optional) - the class of travel service or car hire
- StartLocation (Location) (optional) - the start location for a travel service or pickup location for car hire
- EndLocation (Location) (optional) - the end location for a travel service or dropoff location for car hire
Specific notes for Accommodation: Accommodation are broken down to the level of supplier + room type + room basis. If multiple rooms of distinct types or basis are booked; multiple accommodation service lines should be provided. Wetu will reassemble a consolidated picture of the booking. Wetu is able to assemble consecutive nights at the same accommodation into one booking (e.g. 3 single night service lines will be combined into a single 3 night stay; similarly a 4 night stay and a 3 night stay will be combined).
Specific notes for Travel: Overnight travel (where the Date and EndDate do not match) will be detected and handled automatically.
Examples
Request to Add a booking
{ "Reference": "REF", "TravelDate": "2018-06-01T00:00:00.000Z", "Introduction": "Tour introduction", "Language": "en", "ConsultantEmail": "example@email.com", "Price": "price available on request", "Agent": "AGENT REF", "BookingStatus": "Booked", "Name": "Example Traveller Itinerary", "LastUpdatedDate": "2018-01-02T00:00:00.000Z", "Travellers": [{ "Age": 36, "Type": "Adult", "Name": "Jon Example", "Title": "Mr" }], "Services": [{ "SystemId": "AIRFLIGHT", "Name": "Scheduled Flight", "Date": "2018-06-01T00:00:00.000Z", "EndDate": "2018-06-01T00:00:00.000Z", "StartTime": "06h00", "EndTime": "13h00", "Agency": "Example Airline", "Vehicle": "EX-117", "StartLocation": { "SystemId": "LHR", "Name": "London Heathrow" }, "EndLocation": { "SystemId": "CPT", "Name": "Cape Town International Airport" } }, { "SystemId": "TRANSFER", "Name": "Complimentary Transfer", "Date": "2018-06-01T00:00:00.000Z", "EndDate": "2018-06-01T00:00:00.000Z", "StartTime": "13h30", "Agency": "Example Transfers", "StartLocation": { "SystemId": "CPT", "Name": "Cape Town International Airport" }, "EndLocation": { "SystemId": "HOTEL-01", "Name": "Cape Town International Airport" } }, { "SystemId": "HOTEL-01", "Name": "Example Hotel", "Description": "Luxury Room", "Comment": "Full Board", "Note": "Enjoy your 3 night stay at Example Hotel!", "Date": "2018-06-01T00:00:00.000Z", "EndDate": "2018-06-04T00:00:00.000Z", "ReferenceCodes": ["REF-01"], "Adults": 1, "RoomName": "Luxury Room" }, { "SystemId": "TOUR", "Name": "Example Tour", "Description": "Full Day Example Tour", "Date": "2018-06-02T00:00:00.000Z", "EndDate": "2018-06-02T00:00:00.000Z", "Highlight": true } ] }