Reserve with Google Dining Availability Guide: How to properly set party_size, spots_open, and spots_total

Parameter definitions

  • party_size: The party size that can be accommodated during this time slot. A restaurant can be associated with multiple Slots for the same time, each specifying a different party_size, if for instance 2, 3, or 4 people can be seated with a reservation
  • spots_open: The number of spots currently available for this availability entry
  • spots_total: The total number of spots that the merchant has for this configuration (including those that are not available)

These three parameters work together to build a digital representation of the floor plan. Party size is the number of people each table can hold (there will be an entry for every size a table can accommodate). Spots open and spots total are counts of how many tables can accommodate that party size.

Example empty floor plan

Imagine a restaurant with the following floor plan and no active bookings:

Figure 1: Floor plan with no active bookings

The values for party_size, spots_open, and spots_total would be:

party_size spots_open spots_total
4 3 3
5 3 3
6 4 4
7 1 1
8 1 1

The availability feed for one time slot at this merchant would look like:

JSON

{
  "availability": [
        {
          "spots_total": 3,
          "spots_open": 3,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 4
          }
        },
        {
          "spots_total": 3,
          "spots_open": 3,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 5
          }
        },
        {
          "spots_total": 4,
          "spots_open": 4,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 6
          }
        },
        {
          "spots_total": 1,
          "spots_open": 1,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 7
          }
        },
        {
          "spots_total": 1,
          "spots_open": 1,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 8
          }
        }
      ]
}

Example floor plan with a booking

Now imagine that one of the round tables was booked:

Figure 2: Floor plan with one active booking

The values for party_size, spots_open, and spots_total would now be:

party_size spots_open spots_total
4 2 3
5 2 3
6 3 4
7 1 1
8 1 1

JSON

{
  "availability": [
        {
          "spots_total": 3,
          "spots_open": 2,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 4
          }
        },
        {
          "spots_total": 3,
          "spots_open": 2,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 5
          }
        },
        {
          "spots_total": 4,
          "spots_open": 3,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 6
          }
        },
        {
          "spots_total": 1,
          "spots_open": 1,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 7
          }
        },
        {
          "spots_total": 1,
          "spots_open": 1,
          "duration_sec": 3600,
          "service_id": "1000",
          "start_sec": 1535806800,
          "merchant_id": "merch1",
          "resources": {
            "party_size": 8
          }
        }
      ]
}