Edit booking

 

Edit Customer

Use case : Edit details about the customer that booked, such as name, contact details, etc.

POST /booking.json/update-customer/{bookingConfirmationCode}

 

In the body of the POST request, supply a JSON representation of the customer details. All the fields are optional, so just specify the ones you actually want to update.

Request

{
	"email": "John.Doe@example.com",
	"firstName": "John",
	"lastName": "Doe",
	"nationality": "IS",
	"sex": "m",
	"dateOfBirth": "2018-01-01",
	"phoneNumber": "+1 555 555555",
	"phoneNumberCountryCode": "US",
	"address": "123 Some st",
	"postCode": "234234",
	"state": "WA",
	"place": "Seattle",
	"country": "USA",
	"organization": "Some Inc.",
	"passportId": "AB123",
	"passportExpDay": "30",
	"passportExpMonth": "12",
	"passportExpYear": "2030"
}

Edit Booking info

Use case : Edit booking details such as external booking reference, payment details, etc.

POST /booking.json/edit

 

Request

[
  // modify external booking reference for booking
  {
    "type": "EditBookingExternalRefAction",
    "confirmationCode": "AB-123",
    "externalBookingReference": "New external booking reference"
  },

  // add a CASH payment to a booking
    {
        "type": "AddBookingPaymentAction",
        "bookingId": 123,
        "payment": {
            "amount": 35,
            "paymentType": "CASH"
        }
    },

  // add a CARD payment to a booking
    {
        "type": "AddBookingPaymentAction",
        "bookingId": 123,
        "payment": {
            "amount": 35,
            "paymentType": "POINT_OF_SALE"
            "cardNumber": "***********5063" // optional
        }
    },
  // add a VOUCHER from an external system to a booking
    {
        "type": "AddBookingPaymentAction",
        "bookingId": 123,
        "payment": {
            "amount": 35,
            "paymentType": "VOUCHER"
        }
    },

  // add a CASH refund to a booking
  // supports POINT_OF_SALE and VOUCHER as well
    {
        "type": "RefundBookingPaymentAction",
        "bookingId": 123,
				"payment": {
            "amount": -15,
            "paymentType": "CASH"
        }
    }
]

Edit Product Booking

Use case : Edit product booking details such as passengers, date, time, discount, etc.

POST /booking.json/edit

 

The post body should contain a list of the actions to be applied to the bookings. Each action references a booking, so you can in fact edit multiple bookings in a single call.

The edit actions will be executed within a single transaction, in the order they appear in the JSON list.

 
[
  // modify pick up for activity booking
  {
    "type": "ActivityPickupAction",
    "activityBookingId": 123,
    "pickup": true,
    "pickupPlaceId": 234,
    "description": "description here",
    "roomNumber": "101"
  },
 
  // modify drop off for activity booking
  {
    "type": "ActivityDropOffAction",
    "activityBookingId": 123,
    "dropOff": true,
    "dropOffPlaceId": 234,
    "description": "description of the place"
  },
 
  // add extra booking to an activity pricing category booking
  {
    "type": "AddActivityExtraBookingAction",
    "activityBookingId": 123,
    "pricingCategoryBookingId": 345,
    "extraId": 456,
    "unitCount": 1
  },
 
  // remove extra booking from an activity pricing category booking
  {
    "type": "RemoveActivityExtraBookingAction",
    "activityBookingId": 123,
    "pricingCategoryBookingId": 345,
    "extraBookingId": 567
  },
 
  // edit extra booking on an activity pricing category booking
  {
    "type": "EditActivityExtraBookingAction",
    "activityBookingId": 123,
    "pricingCategoryBookingId": 345,
    "extraBookingId": 456,
    "unitCount": 1
  },
	// update discount % for an activity booking
  {
    "type": "EditActivityDiscountAction",
    "activityBookingId": 123,
    "discountPercentage": 10,
    "applyToExtras": true,
    "applyToPickupAndDropoff": false
  },

  // add participant to an activity booking
  {
    "type": "AddParticipantAction",
    "activityBookingId": 123,
    "pricingCategoryBooking": {
      "pricingCategoryId": 111,
      "age": 12,
      "leadPassenger": true,
      "passengerInfo": {
          "firstName": "Jane",
          "lastName": "Smith"
      },
      "extras": [
        {
          "extraId": 222,
          "unitCount": 1,
          "answers": [{
                "name": "extra-info",
                "answers": [{
                    "type": "extra-question",
                    "answer": "Large",
                    "questionId": 333
                }]
            }
          ]
        }
      ]
    }
  },
 
  // remove participant from an activity booking
  {
    "type": "RemoveParticipantAction",
    "activityBookingId": 123,
    "pricingCategoryBookingId": 345
	},
 
  // edit a participant (pricing category booking)
  {
    "type": "EditParticipantAction",
    "activityBookingId": 123,
    "pricingCategoryBookingId": 345,
    "pricingCategoryBooking": {
      "passengerInfo": {
          "firstName": "Jane",
          "lastName": "Smith"
      },
      "age": 10
    }
  },
 
  // modify the date for an activity booking
  {
    "type": "ActivityChangeDateAction",
    "activityBookingId": 123,
    "date": "2016-05-15",
    "startTimeId": 999,
    "flexOption": "Afternoon departure"
  },
  // Edit answer
  {
    "type": "EditAnswerAction",
    "answerId": 123,
    "answer": "Vegetarian"
  },
 
  // Remove answer
  {
    "type": "RemoveAnswerAction",
    "answerId": 123
  }
]
 
Did this answer your question?
😞
😐
🤩