Get started
API Endpoint
https://apiservices.bookingwhizz.com
The Loyalty Integration with Bookingwhizz CRM offers hoteliers a powerful tool to enhance guest experiences, increase retention, and drive repeat bookings. By seamlessly incorporating a loyalty program into the CRM, hoteliers can track guest behavior, preferences, and history to create personalized reward programs. This integration enables automated reward point accrual and redemption during bookings, delivering tailored promotions and offers directly to loyal customers. With real-time data insights, hoteliers can foster stronger relationships with guests, encourage direct bookings, and increase brand loyalty. The system is fully customizable, allowing for unique loyalty tiers, exclusive perks, and targeted campaigns. Boost your hotel's engagement, revenue, and guest satisfaction with Bookingwhizz CRM's Loyalty Integration.
To use this API, you need an Partner API key. Please contact us at support@bookingwhizz.com to get your own API key.
Member Login
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/member/login \
-H 'Partner-Api-Key=your_api_key' \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'email=john.doe@gmail.com' \
--data 'password=abc@1234'
The Loyalty Member Login API allows registered loyalty program members to authenticate and receive a user token. This token is used to access additional APIs, such as retrieving member details, checking available points, and redeeming points.
To Login Member you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/member/login
Result example :
{
"data": {
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJodHRwczpcL1wvYXBpc2VydmljZXMuYm9va2luZ3doaXp6LmNvbSIsImlkIjo2MywiZW1haWwiOiJoYXJpc0Bib29raW5nd2hpenouY28iLCJwaG9uZSI6bnVsbCwic3RhdHVzIjoxLCJtZW1iZXJDb2RlIjo4Njc5MzU2MCwiaWF0IjoiMjAyMy0xMS0wMVQwOTo0NToyMy4wMDAwMDBaIiwiZXhwIjozNjAwfQ==.00093ef477bb8f0694d599adee458d6694ee261d4257a3f8e0169cd870b22ed1",
"tokenType": "Bearer",
"directToken": "00093ef477bb8f0694d599adee458d6694ee261d4257a3f8e0169cd870b22ed1",
"expiredAt": 3600
},
"message": "Success",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | header | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
QUERY PARAMETERS
| Field | Type | Description |
|---|---|---|
| String | (required) The email address associated with the user. This is typically used for user authentication or account identification | |
| password | String | (required) The user's password used for authentication. This field is required for login |
Get Member Detail
# Here is a curl example
curl \
-X GET "https://apiservices.bookingwhizz.com/api/member" \
-H "Authorization: Bearer your_access_token" \
-H "Partner-Api-Key: your_partner_key" \
The Member details API retrieves comprehensive information about a registered loyalty program member. This endpoint is accessed using a valid bearer token obtained from the member login API. It provides details essential for understanding the member's account status, loyalty tier, point balance, and personal information.
To member details you need to make a GET call to the following url :
https://apiservices.bookingwhizz.com/api/member
Result example :
{
"data": {
"tier": "Silver",
"memberCode": 86793560,
"title": null,
"name": "Haris Ali",
"email": "haris@bookingwhizz.co",
"phoneNumber": "",
"birthDate": null,
"address": null,
"country": null,
"city": null,
"totalPointBalance": "8218.99",
"registerDate": "2023-09-19 12:11:25",
"directDiscount": {
"discountValue": 0,
"discountType": "percent"
},
"isActive": true
},
"message": "Success get member information",
"statusCode": "SUCCESS_LOGIN",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | string | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
| Authorization | string | (required) A secure token issued to authenticated loyalty members, allowing access to protected resources such as member details. The token confirms the user's identity and authorizes the request. This token is obtained from the /login API, with the parameter name being accessToken |
Get Point Value
# Here is a curl example
curl \
-X GET "https://apiservices.bookingwhizz.com/api/member" \
-H "Authorization: Bearer your_access_token" \
-H "Partner-Api-Key: your_partner_key" \
The /api/redemption/pointValue API retrieves the monetary value of loyalty points within the redemption program. This endpoint provides essential information for members and partners, helping them understand the conversion rate of loyalty points to currency
To point value you need to make a GET call to the following url :
https://apiservices.bookingwhizz.com/api/redemption/pointValue
Result example :
{
"data": {
"settings": {
"pointValue": "0.10"
}
},
"message": "Success",
"statusCode": "SUCCESS_GET_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | string | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
| Authorization | string | (required) A secure token issued to authenticated loyalty members, allowing access to protected resources such as member details. The token confirms the user's identity and authorizes the request. This token is obtained from the /login API, with the parameter name being accessToken |
Point Redeem
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/redemption \
-H "Authorization: Bearer your_access_token" \
-H "Partner-Api-Key: your_partner_key" \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'bookingId=RS240105020' \
--data 'hotelCode=13989' \
--data 'hotel=Maple Grand Hotel' \
--data 'memberCode=12345678' \
--data 'burnDate=2024-01-05 09:35:25' \
--data 'pointValue=3' \
--data 'pointRedemption=10' \
--data 'amountRedemption=30' \
--data 'subTotal=49.5' \
--data 'grandTotal=19.5' \
--data 'remarks="Cut 30 Points for USD 3"' \
The /api/redemption API processes a loyalty point redemption request, allowing members to use their accumulated points to reduce the total cost of a transaction, such as booking a hotel stay or making a purchase. This API returns detailed information about the redemption, including the booking details, point usage, and the final amount after applying the points.
Additionally, the API returns a reference number, which helps in tracking the transaction within the BookingWhizz loyalty system. This reference number is crucial for identifying and managing redemption-related transactions.
To Login Member you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/redemption
Result example :
{
"data": {
"bookingId": "RS240105020",
"hotelCode": "13989",
"hotel": "Sample Hotel",
"memberCode": "12345678",
"burnDate": "2024-01-05 09:35:25",
"pointValue": "3",
"pointRedemption": "10.0",
"amountRedemption": "30",
"subTotal": "49.5",
"grandTotal": "19.5",
"remarks": "Cut 30 Points for USD 3"
},
"referenceNumber": "1stiobgw-2jgx-ihd9-wa0w-jltvnc9fza9e",
"message": "Success redeem point value",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | string | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
| Authorization | string | (required) A secure token issued to authenticated loyalty members, allowing access to protected resources such as member details. The token confirms the user's identity and authorizes the request. This token is obtained from the /login API, with the parameter name being accessToken |
QUERY PARAMETERS
| Field | Type | Description |
|---|---|---|
| bookingId | String | (required) The unique identifier for the booking or transaction related to the redemption. |
| hotelCode | String | (required) A unique code identifying the hotel where the redemption was made. |
| hotel | String | (required) The name of the hotel where the redemption took place. |
| memberCode | String | (required) A unique code identifying the hotel where the redemption was made. |
| burnDate | String | (optional) The date and time when the loyalty points were redeemed. |
| pointValue | float | (optional) The number of points required for the redemption value. |
| pointRedemption | float | (required) The total number of points redeemed for this transaction. |
| amountRedemption | float | (required) The dollar amount equivalent to the points redeemed. |
| subTotal | String | (required) The subtotal amount before applying the points redemption. |
| grandTotal | String | (required) The final total after points have been applied to the transaction. |
| remarks | String | (required) A note explaining the details of the redemption (e.g., how many points were used and for what amount). |
| hotelCode | String | (required) A unique code identifying the hotel where the redemption was made. |
Member Register
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/member/register \
-H "Partner-Api-Key: your_partner_key" \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'title=Mr' \
--data 'email=jhon.doe@gmail.com' \
--data 'firstName=Jhon' \
--data 'lastName=Doe' \
--data 'password=JhonDoe@123' \
--data 'dob=1990-11-25' \
--data 'phoneNumber=04235234123' \
--data 'address=ABC Area, XYZ Road' \
--data 'mobileCode=+92' \
--data 'countryCode=PK'
The /api/member/register API enables the registration of new loyalty program members, allowing them to authenticate and obtain a user token. This token grants access to additional APIs, including retrieving member details, checking point balances, and redeeming points.
To Register Member you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/member/register
Result example :
{
"data": {
"title": "Mr",
"email": "jhon.doe@gmail.com",
"firstName": "Jhon",
"lastName": "Doe",
"password": "JhonDoe@123",
"dob": "1990-11-25",
"phoneNumber": "04235234123",
"address": "ABC Area, XYZ Road",
"mobileCode": "+92",
"countryCode": "PK"
},
"message": "Success Registration",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | string | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
QUERY PARAMETERS
| Field | Type | Description |
|---|---|---|
| title | String | (required) Titles like Mr. (Mister), Mrs. (Missus), and Ms. (Miss) are used before a person's surname or full name as a sign of respect or formality. |
| String | (required) The email address associated with the user. This is typically used for user authentication or account identification. | |
| password | String | (required) The user's password used for authentication. This field must contains.
|
| firstName | String | (required) The given name of the user, typically used for personal identification (e.g., "John" in "John Doe"). |
| lastName | String | (required) The family name of the user, often used for formal identification (e.g., "Doe" in "John Doe"). |
| dob | date | (required) The user's birth date in a standardized format (e.g., "YYYY-MM-DD"). |
| phoneNumber | Number | (required) The user's contact number in an international or standardized format without country code (e.g., 123-456-7890). |
| mobileCode | String | (required) The country-specific dialing code (e.g., +92 for Pakistan, +966 for the Saudi Arabia). |
| countryCode | String | (required) A standardized two-letter ("PK", "SA") code representing a user's country. |
| address | Optional | (required) The user's physical location details, including street, city, state, postal code, and country. |
Password Reset
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/member/passwordReset \
-H "Partner-Api-Key: your_partner_key" \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'email=jhon.doe@gmail.com' \
This /api/member/passwordReset API initiates the password reset process for a registered member. When a valid email address is provided, the system sends a password reset email to that address. The email contains instructions and a secure link that allows the user to reset their password.
To Reset Password you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/member/passwordReset
Result example :
{
"data": {
"email": "jhon.doe@gmail.com"
},
"message": "Password Reset Email Send",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | string | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
QUERY PARAMETERS
| Field | Type | Description |
|---|---|---|
| String | (required) The email address associated with the user. This is typically used for user authentication or account identification. |
GET MEMBERSHIP TIER
# Here is a curl example
curl \
-X GET https://apiservices.bookingwhizz.com/api/membershipTiers \
-H "Partner-Api-Key: your_partner_key" \
-H "Content-Type: application/x-www-form-urlencoded" \
This /api/membershipTiers API retrieves a list of all membership tiers configured in the system. Each membership tier includes its unique identifier and name.
To get membership tier you need to make a GET call to the following url :
https://apiservices.bookingwhizz.com/api/membershipTiers
Result example :
{
"data": [
{
"Id": 1,
"Name": "Basic"
},
{
"Id": 2,
"Name": "Silver"
},
{
"Id": 3,
"Name": "Gold"
},
{
"Id": 4,
"Name": "Platinum"
}
],
"message": "Success get tiers information",
"statusCode": "SUCCESS_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | string | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
Member OTP Login
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/member/code/send \
-H 'Partner-Api-Key=your_api_key' \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'email=john.doe@gmail.com'
The Loyalty Member Login API enables registered members of the loyalty program to securely authenticate using a one-time password (OTP) sent via email. Upon successful verification, the member receives a secure user token, which is required for accessing additional member-specific APIs
To Get OTP you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/member/code/send
Result example :
{
"data": {
"email": "john.doe@gmail.com",
},
"message": "Success",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | header | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
QUERY PARAMETERS
| Field | Type | Description |
|---|---|---|
| String | (required) The email address associated with the user. This is typically used for user authentication or account identification |
Member OTP Check
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/member/code/check \
-H 'Partner-Api-Key=your_api_key' \
-H "Content-Type: application/x-www-form-urlencoded" \
--data 'email=john.doe@gmail.com' \
--data 'code=123456'
The Check OTP API is used to verify the one-time password (OTP) sent to a member's registered email address during the login process. This endpoint validates the OTP entered by the member and, upon successful verification, issues a secure user token.
To Check OTP you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/member/code/check
Result example :
{
"data": {
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJodHRwczpcL1wvYXBpc2VydmljZXMuYm9va2luZ3doaXp6LmNvbSIsImlkIjo2MywiZW1haWwiOiJoYXJpc0Bib29raW5nd2hpenouY28iLCJwaG9uZSI6bnVsbCwic3RhdHVzIjoxLCJtZW1iZXJDb2RlIjo4Njc5MzU2MCwiaWF0IjoiMjAyMy0xMS0wMVQwOTo0NToyMy4wMDAwMDBaIiwiZXhwIjozNjAwfQ==.00093ef477bb8f0694d599adee458d6694ee261d4257a3f8e0169cd870b22ed1",
"tokenType": "Bearer",
"directToken": "00093ef477bb8f0694d599adee458d6694ee261d4257a3f8e0169cd870b22ed1",
"expiredAt": 3600
},
"message": "Success",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | header | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
QUERY PARAMETERS
| Field | Type | Description |
|---|---|---|
| String | (required) The email address associated with the user. This is typically used for user authentication or account identification | |
| code | Number | (required) A 6-digit code sent via email to verify the user's identity during login. |
Member Logout
# Here is a curl example
curl \
-X POST https://apiservices.bookingwhizz.com/api/member/logout \
-H "Authorization: Bearer your_access_token" \
-H 'Partner-Api-Key=your_api_key' \
-H "Content-Type: application/x-www-form-urlencoded" \
The Member Logout API allows an authenticated loyalty program member to securely log out by invalidating their user token. This ensures the termination of the current session and prevents unauthorized access to member-specific APIs.
To Logout Member you need to make a POST call to the following url :
https://apiservices.bookingwhizz.com/api/member/logout
Result example :
{
"data": {
"email": "john.doe@gmail.com",
},
"message": "Success",
"statusCode": "SUCCESS_POST_REQUEST",
"status": true
}
HEADER
| Field | Type | Description |
|---|---|---|
| Partner-Api-Key | header | (required) A unique key provided to authorized partners to authenticate and identify API requests. This key is used to validate that the request is coming from a trusted partner. |
| Authorization | string | (required) A secure token issued to authenticated loyalty members, allowing access to protected resources such as member details. The token confirms the user's identity and authorizes the request. This token is obtained from the /login API, with the parameter name being accessToken |
Errors
The BW Loyalty API uses the following error codes:
| Error Code | Meaning |
|---|---|
| ERROR_UNDEFINED | The value of the request parameter is not valid. |
| ERROR_UNDEFINED | The email of the request parameter already exists |
| ERROR_UNDEFINED | The value of the parameter you have provided is not valid. |
| ERROR_VALIDATION | The request cannot be validated. |
| INFO_DATA_NOT_FOUND | The data was not found. |