Pike13 For Developers
Get Started
Authentication
Core API
Reporting API
Webhooks API
Announcements

Core API Documentation

Room

Rooms (also called calendar resources) are spaces such as studios, courts, or pool lanes that events and appointments can be scheduled in. These endpoints return 404 unless rooms are enabled for the business. The same endpoints are also available at /api/v2/desk/calendar_resources.

Desk Only

GET /api/v2/desk/rooms

Lists the business's rooms in display order, along with the room categories.

Show curl example

REQUEST
$ curl https://mybiz.pike13.com/api/v2/desk/rooms \
  -H "Authorization: Bearer XXXXXXXXXXXXXXX"

RESPONSE
{
  "calendar_resources": [
    {
      "id": 1,
      "name": "Studio A",
      "description": "Large studio with sprung floor",
      "position": 1,
      "calendar_resource_category_id": 1,
      "location_id": 1,
      "service_ids": [
        4,
        7
      ],
      "allow_staff_hours_overbook": false,
      "allow_staff_capacity_overbook": false,
      "availability": {
        "allow_to_book": true,
        "capacity": 8,
        "room_booking_length": 60,
        "start_interval": 30,
        "before_time": 0,
        "after_time": 15,
        "show_remaining_spaces": false,
        "available_from": "08:00",
        "available_to": "20:00"
      }
    },
    {
      "id": 2,
      "name": "Pool Lane 1",
      "description": null,
      "position": 2,
      "calendar_resource_category_id": 2,
      "location_id": 1,
      "service_ids": [
        9
      ],
      "allow_staff_hours_overbook": false,
      "allow_staff_capacity_overbook": true,
      "availability": {
        "allow_to_book": false
      }
    }
  ],
  "categories": [
    {
      "id": 1,
      "name": "Studios",
      "position": 1,
      "description": null
    },
    {
      "id": 2,
      "name": "Pool",
      "position": 2,
      "description": null
    }
  ]
}

GET /api/v2/desk/rooms/:id

Returns the details of a room.

Show curl example

REQUEST
$ curl https://mybiz.pike13.com/api/v2/desk/rooms/1 \
  -H "Authorization: Bearer XXXXXXXXXXXXXXX"

RESPONSE
{
  "calendar_resources": [
    {
      "id": 1,
      "name": "Studio A",
      "description": "Large studio with sprung floor",
      "position": 1,
      "calendar_resource_category_id": 1,
      "location_id": 1,
      "service_ids": [
        4,
        7
      ],
      "allow_staff_hours_overbook": false,
      "allow_staff_capacity_overbook": false,
      "availability": {
        "allow_to_book": true,
        "capacity": 8,
        "room_booking_length": 60,
        "start_interval": 30,
        "before_time": 0,
        "after_time": 15,
        "show_remaining_spaces": false,
        "available_from": "08:00",
        "available_to": "20:00"
      }
    }
  ]
}

Attributes

idintegerThe id of the room.
namestringThe name of the room.
descriptionstringThe description of the room.
positionintegerThe display order of the room.
calendar_resource_category_idintegerThe id of the room's category, or null.
location_idintegerThe id of the room's location, or null.
service_idsarrayThe ids of the services that can use the room.
allow_staff_hours_overbookbooleanWhether staff can book the room outside its available hours.
allow_staff_capacity_overbookbooleanWhether staff can book the room beyond its capacity.
availabilityobject

Online room booking settings.

allow_to_bookbooleanWhether the room can be booked as a room booking. Null if room booking has never been set up for the room. The remaining attributes are only present when this is true.
capacityintegerThe maximum number of people in the room.
room_booking_lengthintegerThe length of a room booking, in minutes.
start_intervalintegerThe interval between booking start times, in minutes.
before_timeintegerBuffer time before each booking, in minutes.
after_timeintegerBuffer time after each booking, in minutes.
show_remaining_spacesbooleanWhether remaining spaces are shown to clients.
available_fromstringThe earliest time of day the room can be booked, or null if hours are not restricted. Formatted as HH:MM (24-hour) in the business's local time.
available_tostringThe latest time of day the room can be booked, or null if hours are not restricted. Formatted as HH:MM (24-hour) in the business's local time.

Categories

The list response also includes categories, each with an id, name, position, and description.