Skip to content

Commit

Permalink
added booking-specific wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
joshdoman committed Feb 21, 2019
1 parent b874233 commit 0666659
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions penn/studyspaces.py
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,18 @@ def get_reservations(self, email, date):
raise APIError("Server Error: {}".format(error))
return resp.json()

def get_reservations_for_booking_ids(self, booking_ids):
"""Gets booking information for a given list of booking ids.
:param booking_ids: a booking id or a list of room ids (comma separated).
:type booking_ids: string
"""
try:
resp = self._request("GET", "/1.1/space/booking/{}".format(booking_ids))
except resp.exceptions.HTTPError as error:
raise APIError("Server Error: {}".format(error))
return resp.json()

def get_room_info(self, room_ids):
"""Gets room information for a given list of ids.
Expand Down

0 comments on commit 0666659

Please sign in to comment.