Room Sales Data

This API provides you sales information for rooms for a specific period. The API can return data in JSON formats. The web service responds to HTTP POST requests.

End Point URL

Note: You need set Authcode in Header.

Header

Content-Type: application/json; AUTH_CODE: XXXXXXXXXXXXXXXXX

Parameter

NameData TypeDescription Example
request_type *VARCHAR(150)Use Keyword “get_sales_report”
hotel_id *INT(11)Unique Hotel codeXXXX
room_id *INT(20)List of room Ids (If a date range is same for all Room IDs then all Ids will be listed in a single block else separate block will be there for a different date range) 1234500000000001, 1234500000000002
from_date *DateStart date of calendar information is to be requested
Format: YYYY-MM-DD
2020-06-25
to_date *DateEnd date of calendar information is to be requested
Format: YYYY-MM-DD
2020-07-10

Request 

{   
"request_type": "get_sales_report",
    "body": {
        "hotel_id": "xxxx",
        "rooms": [{
            "room_id": ["1234500000000000001", "1234500000000000002"],
            "from_date": "2020-04-25",
            "to_date": "2020-05-08"
        }]
    }
}

Response

NameData TypeDescription Example
statusStringFailure or success of the request
Values: Success, Error
Success
data.hotel_idIntegerID of Hotelxxxx
data.hotel_nameStringName of HotelHotel Name
data.Report.*StringHere * means Room type ID1234500000000001
data.Report.*.room_nameStringName of RoomSuper Deluxe
data.Report.*.#StringHere # means Room CodeL01
data.Report.*.#.room_nightsIntegerTotal available rooms for the month.
7
data.Report.*.#.room_soldIntegerNo. of room sold only. (not included complimentary)5
data.Report.*.#.complementaryStringComplimentary
data.Report.*.#.occupancyIntegerOccupancy of room4
data.Report.*.#.adrStringAverage Daily rate950
data.Report.*.#.paxStringNo. of pax in Room4
data.Report.*.#.room_chargesLongRoom Charges85
data.Report.*.#.extra_chargesLongExtra Charged4
data.Report.*.#.channelStringChannel name & channel hotel codename_channelHotelCode (Which are mapped with this room type)Booking.com_11111
error_codeError code in case of failure105
error_messageError Message in case of failureInvalid Reservation ID

Success

{  "status": "success",
  "data": {
    "hotel_id": "xxxx",
    "hotel_name": "Hotel Name",
    "report": [
      {
        "1234500000000000001": {
          "106": {
            "room_nights": 14,
            "room_sold": 0,
            "complementary": 0,
            "occupancy": 0,
            "adr": 0,
            "pax": 0,
            "room_charges": 0,
            "extra_charges": 0,
            "channel": ""
          },
          "room_name": "Studio"
        }
      },
      {
        "1234500000000000002": {
          "107": {
            "room_nights": 14,
            "room_sold": 0,
            "complementary": 0,
            "occupancy": 0,
            "adr": 0,
            "pax": 0,
            "room_charges": 0,
            "extra_charges": 0,
            "channel": ""
          },
          "111": {
            "room_nights": 14,
            "room_sold": 0,
            "complementary": 0,
            "occupancy": 0,
            "adr": 0,
            "pax": 0,
            "room_charges": 0,
            "extra_charges": 0,
            "channel": ""
          },
          "112": {
            "room_nights": 14,
            "room_sold": 0,
            "complementary": 0,
            "occupancy": 0,
            "adr": 0,
            "pax": 0,
            "room_charges": 0,
            "extra_charges": 0,
            "channel": ""
          },
          "113": {
            "room_nights": 14,
            "room_sold": 0,
            "complementary": 0,
            "occupancy": 0,
            "adr": 0,
            "pax": 0,
            "room_charges": 0,
            "extra_charges": 0,
            "channel": ""
          },
          "room_name": "Double Bedroom Suite"
        }
      }
    ]
  }
}

Error Codes

Error CodeError Name
101Invalid Hotel Id
102Invalid Authentication
103Blank Request
104Invalid Request Format
105Missing Required Parameter
106Invalid Reservation ID
107Invalid Date Format
108Invalid Date Range
109Currently Data can be requested for max 15 days
110Invalid Room Id
111IP Address is not Authorised
112Invalid Request Method
113Hotel Code is not Active
114Invalid Room Code or not associated with supplied room ID
115Internal Problem

Click here to Register