Meeting Rooms and the Availability API

Tips for including meeting rooms in your availability queries

Meeting Rooms are treated as any another participant when using the Availability API. However there is a feature of the participants query element that is designed specifically to handle the querying requirements for meeting rooms. 

Often you'll have a list of potential meeting rooms that are suitable. Perhaps in terms of capacity or that they have certain tech available in them. So it doesn't matter which one is available, just that one is at the time the other participants are. This is where the 1 required element value comes in.

{
  "participants": [
    {
      "members": [
        { "sub": "acc_567236000909002" },
        { "sub": "acc_678347111010113" }
      ],
      "required": "all"
    },
    {
      "members": [
        { "sub": "res_567236734764002" },
        { "sub": "res_347634111010113" }
      ],
      "required": 1
    }
  ],
  "required_duration": { "minutes": 60 },
  "available_periods": [
    {
      "start": "2017-07-17T09:00:00Z",
      "end": "2017-07-17T18:00:00Z"
    },
    {
      "start": "2017-07-18T09:00:00Z",
      "end": "2017-07-18T18:00:00Z"
    }
  ]
}

In the above query we've added an additional participants descriptor that includes two meeting rooms res_567236734764002 and res_347634111010113  and a required value of 1

This indicates that any period returned should have one of more of those available. A response could look like the following.

{
  "available_periods": [
    {
      "start": "2017-07-17T09:00:00Z",
      "end": "2017-07-17T11:00:00Z",
      "participants": [
        { "sub": "acc_567236000909002" },
        { "sub": "acc_678347111010113" },
        { "sub": "res_567236734764002" }
      ]
    },
    {
      "start": "2017-07-18T11:00:00Z",
      "end": "2017-07-18T17:00:00Z",
      "participants": [
        { "sub": "acc_567236000909002" },
        { "sub": "acc_678347111010113" },
        { "sub": "res_567236734764002" },
        { "sub": "res_347634111010113" }
      ]
    }
  ]
}

In this example, only one meeting room is available during the first period but both are for the second period. Your application, or your user, can then decide which to book based on the appropriate rules or preferences.

Not just meeting rooms

Whilst this feature is useful for meeting rooms it's not limited to that. Any queryable person or resource can be added. If for example a developer interview needs one senior developer to attend then you can add a participant group of senior developers and then select whoever is available.