Is there an API to get the list of all rooms under a building with its availability status (Available / Not Available).

Alkondan Chockalinga Mooppanar 26 Reputation points Microsoft Employee
2022-05-04T05:50:40.147+00:00

We are from MS Recruit engineering team. In our page - we have the following requirement.

  1. User selects any building in Microsoft. [Request Payload]
  2. Our page should display the list of meeting rooms in the building along with its availability status. [Response]

Something similar to outlook's room finder.
198698-image.png

Is there any Graph APIs that we can leverage to get these details. If it is achievable in a single API call - it would be

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,331 questions
0 comments No comments
{count} votes

Accepted answer
  1. JanardhanaVedham-MSFT 3,536 Reputation points
    2022-05-04T08:17:43.217+00:00

    Hi @Alkondan Chockalinga Mooppanar ,

    You can use below Microsoft Graph API to get list of meeting rooms of a building and rooms availbility status. Building or Room list must have an associated email address to use the below Graph API.

    1. Find Rooms API gets the emailAddress objects that represent all the meeting rooms in the user's tenant or in a specific room list. Tenants can organize meeting rooms into room lists. In this API, each meeting room and room list is represented by an emailAddress instance. You can get all the room lists in the tenant, get all the rooms in the tenant, or get all the rooms in a specific room list. You can get up to the first 100 rooms in the tenant.

    To get all the rooms in the tenant:

    GET /me/findRooms  
    GET /users/{id}/findRooms  
    

    To get all the rooms in a specific room list of the tenant's:

    GET /me/findRooms(RoomList='{room_list_emailAddress}')  
    GET /users/{id}/findRooms(RoomList='{room_list_emailAddress}')  
    

    Note : Currently Find Rooms Graph API is only avialable in Beta. APIs under the /beta version in Microsoft Graph are subject to change. Use of these APIs in production applications is not supported.

    2.Get free/busy schedule API gets the free/busy availability information for a collection of users, distributions lists, or resources (rooms or equipment) for a specified time period. The example in this documentation explains how to get rooms availability status for one or more rooms.

    POST /me/calendar/getSchedule   
    POST /users/{id|userPrincipalName}/calendar/getSchedule  
    

    References :
    https://learn.microsoft.com/en-us/graph/api/user-findrooms?view=graph-rest-beta&tabs=http
    https://learn.microsoft.com/en-us/graph/api/user-findroomlists?view=graph-rest-beta&tabs=http
    https://learn.microsoft.com/en-us/graph/api/calendar-getschedule?view=graph-rest-1.0&tabs=http
    https://learn.microsoft.com/en-us/graph/api/calendar-getschedule?view=graph-rest-1.0&tabs=http#example

    Hope this helps.

    If the answer is helpful to you, please click "Accept Answer" and kindly upvote it. If you have additional questions about this answer, please click "Comment".

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Kwiatkowski, Constantin 1 Reputation point
    2022-06-18T06:47:49.943+00:00

    Hi there,

    please add to your comment that you refer to the Graph beta API. Please provide guidance to resolve the issue with the version 1.0. Thanks!

    0 comments No comments