Add-ons: Adding Amenities to a Booking
Add Ons are amenities that can be added on to hotel bookings during the checkout process.
Add-ons let you bundle additional amenities with hotel bookings. They add ons are passed as part of the prebook process so their cost can be integrated into the total price. This guide will walk through adding Uber vouchers or eSim cards to a purchase.
Listing Amentities
We currently have a partnership with Uber enabling us to offer Uber vouchers via the API for those travelers looking to secure transportation.
We also partner with eSimply to provide eSIM data options for travelers outside their normal mobile data networks.
Both Uber Ride vouchers and eSim purchases offer multiple options for users to choose from. Uber vouchers are available in $10 increments from $10 to $100 while eSIM options will vary by country so they require an API call to get the available offerings. Be aware that both add-ons are non-refundable.
⭐️ Note: Only USD values are currently supported, so you will need to do a conversion in the UI for other currency options.
Uber vouchers
Since Uber vouchers are always an increment of $10 up to $100 USD they can be integrated fairly simply. Once users have a way to select the value of the voucher they wish to purchase that value can then be passed to the prebook step so it is included in the price.
⭐️ Note: You can call the prebook step with the same rate multiple times, so if you have already made a prebook call and then the user wants an add-on, just recall prebook with the new criteria and the payment total will be adjusted while keeping the orginal room rate.
To add the uber addon, pass it to the prebook step using an addons
array. Below you can see an example of the format. The addon
tpye is "uber", you set the value
to the increment chosen, and for now the only supported currency
is "USD".
{
"addons": [
{
"addon": "uber",
"value": 20,
"currency": "USD"
}
],
"voucherCode":"Discount20",
"usePaymentSdk": false,
"offerId": "//clipped offerId"
}
eSIM add-ons
Since eSIM options and pricing vary by country, this add-on requires making an additional API call to get the prices and data options for the country of stay.
Use this endpoint http://api.dev.liteapi.travel/v3.0/addons/esimply/packages/{Country Code}
where `{Country Code} is the two letter code for the country of stay.
For example http://api.dev.liteapi.travel/v3.0/addons/esimply/packages/ES
would be used for getting the eSIM options in Spain. This will return a list of valid eSIM packages for the region the will look like the example JSON below.
{
"code": "SUCCESS",
"data": [
{
"package_id": 1,
"name": "1 GB",
"data_size_mb": 1024,
"validity_days": 7,
"provider_id": 2,
"provider_package_id": 11993,
"external_package_id": "2fa31794-5b30-4ecd-9314-2053c95a0ab2|USA|1",
"calculated_price": 6,
"rn": 1,
"currency": "USD"
},
{
"package_id": 2,
"name": "2 GB",
"data_size_mb": 2048,
"validity_days": 14,
"provider_id": 2,
"provider_package_id": 11994,
"external_package_id": "8d01a88a-c277-4f0a-82c3-4d511ed12f15|USA|2",
"calculated_price": 11,
"rn": 1,
"currency": "USD"
},
...
]
}
These packages are the options you can make available for purchase with the booking. It might look something like this:
In addition to the data returned from the endpoint, you will need collect a start_date
and end_date
for the activation range. This should usually cover at least a day before and after the stay.
To add the esimply addon set the addon
to "esimply", for the value
use the calculated_price
returned from the chosen package, for currency
only "USD" is currently supported. Then pass the addonDetails
object fields. The package_id
is the package chosen, and the destination_code
will be the country code. Last add the start_date
and end_date
for activation.
{
"addon": "esimply",
"value": 6.00,
"currency": "USD",
"addonDetails": {
"package_id": 1,
"destination_code": "ES",
"start_date": "2024-12-05",
"end_date": "2024-12-10"
}
}
They can be combined together, so for example a prebook with a voucher and eSIM could look like this:
{
"addons": [
{
"addon": "uber",
"value": 20,
"currency": "USD"
},
{
"addon": "esimply",
"value": 20.00,
"currency": "USD",
"addonDetails": {
"package_id": 1,
"destination_code": "ES",
"start_date": "2025-12-15",
"end_date": "2025-12-22"
}
}
],
"voucherCode":"Discount20",
"usePaymentSdk": false,
"offerId": "_use an updated offerId_"
}
This will add a section to the prebook response for addons. Here is an example of what that would look like:
"addonsRequest": [
{
"addon": "uber",
"value": 20,
"currency": "USD"
},
{
"addon": "esimply",
"value": 29.99,
"currency": "USD",
"addonDetails": {
"package_id": 1,
"destination_code": "ES",
"start_date": "2025-12-15",
"end_date": "2025-12-22",
"cart_key": "VPNKDUYTYGKYOYAQWWSBRXTHVAIJQL"
}
}
]
Nothing special needs to be done on the book step, the prebook already setup the addons and embedded that data in the prebookId
so pass the prebook ID as normal to the book step and youll get back a response detailing all the information needed to make use of the vouchers.
"addons": [
{
"addon": "esimply",
"originalValue": 29.99,
"originalCurrency": "USD",
"addonVoucherCode": "LPA:1$lpa.airalo.com$TEST-416670944217",
"status": "SUCCESS",
"message": "eSimply addon processed for booking: DRRxpTvcK",
"addonDetails": {
"esimply": {
"orderId": 2200,
"purchases": [
{
"esimId": 0,
"packageName": "",
"dataSizeMb": 0,
"remainingData": 0,
"destinationCode": "",
"price": 6,
"iccid": "894000000000036358",
"qrCode": "LPA:1$lpa.airalo.com$TEST-416670944217",
"smdpAddress": "",
"activationCode": "",
"esimProviderId": 0,
"externalPackageId": "",
"validityDays": 0,
"flag": "https://esimply-destinations-flags.s3.us-west-1.amazonaws.com/es.svg",
"createdAt": null,
"destinationName": "",
"startDate": null,
"endDate": null,
"packageId": 0
}
]
}
}
},
{
"addon": "uber",
"value": 20,
"currency": "USD",
"originalValue": 20,
"originalCurrency": "USD",
"expiryDate": "2025-11-19",
"addonVoucherCode": "https://r.uber.com/rHzo59shpHn",
"addonVoucherId": 263,
"status": "SUCCESS"
}
],
Use the qrCode
to generate a QR code that the user can scan to activate theur eSIM.
The uber voucher will return an addonVoucherCode
which is a unique URL for the user to activate their Uber Voucher.
These should usually be added to whatever booking voucher and confirmation materials are sent to the booker.
Updated 5 days ago