List places
Namespace: microsoft.graph
Important
APIs under the /beta
version in Microsoft Graph are subject to change. Use of these APIs in production applications is not supported. To determine whether an API is available in v1.0, use the Version selector.
Get a collection of the specified type of place objects defined in the tenant.
You can do the following for a given tenant:
- List all the rooms.
- List all the workspaces.
- List all the room lists.
- List rooms in a specific room list.
- List workspaces in a specific room list.
A place object can be one of the following types:
- A room, which includes rich properties such as an email address for the room, and accessibility, capacity, and device support.
- A workspace, which includes properties such as an email address for the workspace, and accessibility and capacity.
- A roomList, which includes an email address for the room list, and a navigation property to get the collection of room instances in the room list.
The room, workspace and roomList resources are derived from the place object.
By default, this operation returns up to 100 places per page.
Compared with the findRooms and findRoomLists functions, this operation returns a richer payload for rooms and room lists. For details about how they compare, see Using the places API.
This API is available in the following national cloud deployments.
Global service | US Government L4 | US Government L5 (DOD) | China operated by 21Vianet |
---|---|---|---|
✅ | ✅ | ✅ | ✅ |
Permissions
Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.
Permission type | Least privileged permissions | Higher privileged permissions |
---|---|---|
Delegated (work or school account) | Place.Read.All | Not available. |
Delegated (personal Microsoft account) | Not supported. | Not supported. |
Application | Place.Read.All | Not available. |
HTTP request
To get all the rooms in a tenant:
GET /places/microsoft.graph.room
To get all the workspaces in a tenant:
GET /places/microsoft.graph.workspace
To get all the room lists in a tenant:
GET /places/microsoft.graph.roomlist
To get all the rooms in the specified room list:
GET /places/{room-list-emailaddress}/microsoft.graph.roomlist/rooms
To get all the workspaces in the specified room list:
GET /places/{room-list-emailaddress}/microsoft.graph.roomlist/workspaces
Note: To get rooms or workspaces in a room list, you must specify the room list by its emailAddress property, not by its id.
Optional query parameters
This method supports the following query parameters to help customize the response:
$filter
$select
$top
$skip
$count=true
Use $top
to customize the page size. The default page size is 100.
For general information, see OData query parameters.
Request headers
Name | Description |
---|---|
Authorization | Bearer {token}. Required. Learn more about authentication and authorization. |
Request body
Don't supply a request body for this method.
Response
If successful, this method returns a 200 OK
response code and a collection of place objects in the response body.
Examples
Example 1: List all the rooms defined in the tenant
Request
The following example shows how to get all the room objects in the tenant.
GET https://graph.microsoft.com/beta/places/microsoft.graph.room
Response
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#places/microsoft.graph.room",
"value": [
{
"id": "3162F1E1-C4C0-604B-51D8-91DA78989EB1",
"emailAddress": "cf100@contoso.com",
"displayName": "Conf Room 100",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": {
"latitude": 47.640568390488626,
"longitude": -122.1293731033803
},
"phone": "000-000-0000",
"nickname": "Conf Room",
"label": "100",
"capacity": 50,
"building": "1",
"floorNumber": 1,
"isWheelChairAccessible": false,
"bookingType": "standard",
"tags": [
"bean bags"
],
"audioDeviceName": null,
"videoDeviceName": null,
"displayDeviceName": "surface hub",
"placeId": "080ed1a0-7b54-4995-85a5-eeec751786f5"
},
{
"id": "3162F1E1-C4C0-604B-51D8-91DA78970B97",
"emailAddress": "cf200@contoso.com",
"displayName": "Conf Room 200",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": {
"latitude": 47.640568390488625,
"longitude": -122.1293731033802
},
"phone": "000-000-0000",
"nickname": "Conf Room",
"label": "200",
"capacity": 40,
"building": "2",
"floorNumber": 2,
"isWheelChairAccessible": false,
"bookingType": "standard",
"tags": [
"benches",
"nice view"
],
"audioDeviceName": null,
"videoDeviceName": null,
"displayDeviceName": "surface hub",
"placeId": "282c6d10-f8d4-441e-9f7f-edd2e554f61d"
}
]
}
Example 2: List all the workspaces defined in the tenant
Request
The following example shows how to get all the workspaces objects in the tenant.
GET https://graph.microsoft.com/beta/places/microsoft.graph.workspace
Response
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#places/microsoft.graph.workspace",
"value": [
{
"id": "3162F1E1-C4C0-604B-51D8-91DA78989EB1",
"emailAddress": "ws100@contoso.com",
"displayName": "Workspace 100",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": {
"latitude": 47.640568390488626,
"longitude": -122.1293731033803
},
"phone": "000-000-0000",
"nickname": "Workspace",
"label": "100",
"capacity": 50,
"building": "1",
"floorNumber": 1,
"isWheelChairAccessible": false,
"tags": [
"bean bags"
],
"placeId": "357e8ddc-8af5-4c7c-bc38-ddb3bcfec0d9"
},
{
"id": "3162F1E1-C4C0-604B-51D8-91DA78970B97",
"emailAddress": "ws200@contoso.com",
"displayName": "Workspace 200",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": {
"latitude": 47.640568390488625,
"longitude": -122.1293731033802
},
"phone": "000-000-0000",
"nickname": "Workspace",
"label": "200",
"capacity": 40,
"building": "2",
"floorNumber": 2,
"isWheelChairAccessible": false,
"tags": [
"benches",
"nice view"
],
"placeId": "ca4e4ca8-4e92-4a83-afe4-5104c0ca1de3"
}
]
}
Example 3: List all the room lists defined in the tenant
Request
The following example shows how to get all the roomList objects in the tenant.
GET https://graph.microsoft.com/beta/places/microsoft.graph.roomlist
Response
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#places/microsoft.graph.roomList",
"value": [
{
"id": "DC404124-302A-92AA-F98D-7B4DEB0C1705",
"displayName": "Building 1",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": null,
"phone": null,
"emailAddress": "bldg1@contoso.com",
"placeId": "406bd1b2-237c-4710-bda2-8b7900d61b27"
},
{
"id": "DC404124-302A-92AA-F98D-7B4DEB0C1706",
"displayName": "Building 2",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": null,
"phone": null,
"emailAddress": "bldg2@contoso.com",
"placeId": "25709e2a-4c17-49ab-b591-1daf8d9b786d"
}
]
}
Example 4: List rooms contained in a room list
Request
The following example shows how to get a list of room objects contained in a roomList.
GET https://graph.microsoft.com/beta/places/bldg2@contoso.com/microsoft.graph.roomlist/rooms
Response
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#places('bldg2%40contoso.com')/microsoft.graph.roomList/rooms",
"value": [
{
"id": "3162F1E1-C4C0-604B-51D8-91DA78970B97",
"emailAddress": "cf200@contoso.com",
"displayName": "Conf Room 200",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": {
"latitude": 47.640568390488625,
"longitude": -122.1293731033802
},
"phone": "000-000-0000",
"nickname": "Conf Room",
"label": "200",
"capacity": 40,
"building": "2",
"floorNumber": 2,
"isWheelChairAccessible": false,
"bookingType": "standard",
"tags": [
"benches",
"nice view"
],
"audioDeviceName": null,
"videoDeviceName": null,
"displayDeviceName": "surface hub",
"placeId": "62cfc8cb-fc2b-4783-aeea-f9ce0f8e2904"
}
]
}
Example 5: List workspaces contained in a room list
Request
The following example shows how to get a list of workspace objects contained in a roomList.
GET https://graph.microsoft.com/beta/places/bldg2@contoso.com/microsoft.graph.roomlist/workspaces
Response
The following example shows the response.
Note: The response object shown here might be shortened for readability.
HTTP/1.1 200 OK
Content-type: application/json
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#places('bldg2%40contoso.com')/microsoft.graph.roomList/workspaces",
"value": [
{
"id": "3162F1E1-C4C0-604B-51D8-91DA78970B97",
"emailAddress": "ws200@contoso.com",
"displayName": "Workspace 200",
"address": {
"street": "4567 Main Street",
"city": "Buffalo",
"state": "NY",
"postalCode": "98052",
"countryOrRegion": "USA"
},
"geoCoordinates": {
"latitude": 47.640568390488625,
"longitude": -122.1293731033802
},
"phone": "000-000-0000",
"nickname": "Workspace",
"label": "200",
"capacity": 40,
"building": "2",
"floorNumber": 2,
"isWheelChairAccessible": false,
"tags": [
"benches",
"nice view"
],
"placeId": "ca4e4ca8-4e92-4a83-afe4-5104c0ca1de3"
}
]
}