Calculate Booking Amount API

Description: Calculate booking amount

Path: /api/v2/reservation/calculateBookingAmount

Method: POST

Content Type/Accept Type: application/json

Request

Attributes

* = required

clientId*

string

Identity of client

timestamp*

timestamp

Current timestamp

hotelSn*

integer

Identity of hotel

roomTypeSn*

integer

Identity of room type

mode*

integer

Based on your select room. We use this type to calculate the price by normal room or flash sale room

Possible enum values: 1 = Normal 2 = Flash Sale

bookingType*

integer

Type of booking

Possible enum values: 1 = Hourly Booking 2 = Overnight Booking 3 = Daily Booking

checkInDatePlan*

string

Check-in date (user plan)

Format: YYYY-mm-dd

endDate*

string

Check-out date (user plan)

Format: YYYY-mm-dd

startTime

string

Required when choosing Hourly Booking

Format: HH:mm

endTime

string

Required when choosing Hourly Booking

Format: HH:mm

Example

Response

Attributes

roomPrice

integer

The room pricing

extraFee

integer

Additional amount if you’re booking at high demand time

totalDiscount

integer

The total discount amount from promotion such as flash sale, direct discount

totalAmount

integer

The total booking amount needs to be paid at once for this booking, including extra fee if you’re booking at high demand time. This does not include promotion such as flash sale, direct discount

amountFromUser

integer

The total booking amount needs to be paid from user

Example