WSD Reservable V2 API
The Workplace Service Delivery (WSD) Reservable V2 API provides endpoints to retrieve details of a reservable, an entity that can be reserved, such as a workplace location, from a ServiceNow instance.
The WSD Reservable V2 API is a new version of the WSD Reservable API. The WSD Reservable V2 API fetches details of all reservable space(s) on the WSD Portal that you select while making a reservation. The original WSD Reservable API version used a GET call but limited the sys_ID path parameter to 35 characters. The new WSD Reservable V2 API version is a POST call and takes all the sys_ids in the request body to avoid character limitations.
To access this API, the caller must have the sn_wsd_core.workplace_user role.
This API runs in the sn_wsd_rsv namespace. To access this API, the Workplace Reservation Management (sn_wsd_rsv) plugin must be activated.
For additional information on Workplace Reservation Management, see Workplace Reservation Management.
WSD Reservable V2 API - POST /sn_wsd_rsv/v2/reservable/list_reservables
Returns the details for one or more specified reservables.
URL format
Default URL: POST api/sn_wsd_rsv/v2/reservable/list_reservables
Supported request parameters
| Name | Description |
|---|---|
| api_version | Required. Version of the endpoint to access. Specify v2 to employ this API, otherwise using v1 employs the default version of the WSD Reservable API. Data type: String |
| Name | Description |
|---|---|
| None |
| Name | Description |
|---|---|
| include_flexible_services | Flag that indicates whether to return the flexible services associated with the reservable in to the response. A flexible service is an additional provision available with a reservable workplace item when a reservation is made. For example, Classroom style - Rows of tables arranged with all participants facing towards the front of the room. For additional information on flexible services, see Create a flexible service. Valid values:
Data type: Boolean Default: false |
| include_standard_services | Flag that indicates whether to return the standard services information in the response. This information is located in the Standard Service [sn_wsd_rsv_standard_service]
table. A standard service describes basic provisions available with a reservable workplace item when the reservation is made, such as white boards, additional monitors, and similar services. For additional information on standard services, see Standard services. Valid values:
Data type: Boolean Default: false |
| include_reservable_purposes | Optional. Flag that indicates whether to return the purpose associated with the reservable. Valid values:
Data type: Boolean Default: false |
| include_layouts | Flag that indicates whether to return the location layout information in the response. Location layout information include such things as capacity, max capacity, preparation, and clean up duration. Valid values:
Data type: Boolean Default: false Table: Location Layout [sn_wsd_rsv_m2m_location_layout] |
| reservable_module_sys_id | Required. Sys_id of the reservable module, for example: desk, meeting room, etc. A reservable module groups similar types of workplace items. For additional information on reservable modules, see Configure a reservable module. Data type: String Default: Empty value Table: Reservable Module [sn_wsd_rsv_reservable_module] |
| reservation_start_time | Reservation start time to validate the lead time of extra services. Format: UTC format, yyyy-MM-dd HH:mm:ss Data type: String |
| space_sys_ids | Required. Comma-separated sys_ids of selected spaces. Data type: String Default: Empty value |
Headers
The following request and response headers apply to this HTTP action only, or apply to this action in a distinct way. For a list of general headers used in the REST API, see Supported REST API headers.
| Header | Description |
|---|---|
| Accept | Data format of the response
body. Supported types: application/json or
application/xml.
Default: application/json |
| Content-Type | Data format of the response body. Only supports application/json. |
| Header | Description |
|---|---|
| None |
Status codes
The following status codes apply to this HTTP action. For a list of possible status codes used in the REST API, see REST API HTTP response codes.
| Status code | Description |
|---|---|
| 200 | Successful. The request was successfully processed. |
| 404 | Could not find reservables. Look for the WSD Core Spaces [sn_wsd_core_spaces] table and verify the space record is present. |
| 500 | Error occurred! Unable to retrieve reservables. This is a server error. Contact system administration. |
Response body parameters
| Name | Description |
|---|---|
| result | Details on each matching reservable. Data type: Array of Objects |
| result.allow_invitees | Flag that indicates whether employees are able to add invitees to the reservation. Valid values:
Data type: Boolean |
| result.area | Area where the reservable is located. Data type: Object Table: Area [sn_wsd_core_area] |
| result.area.display_value | Display value for the area. Data type: String |
| result.area.sys_id | Sys_id of the associated area record. Data type: String |
| result.building | Building where the reservable is located. Data type: Object Table: Building [sn_wsd_core_building] |
| result.building.display_value | Display value for the building. Data type: String |
| result.building.sys_id | Sys_id of the associated building record. Data type: String |
| result.building.timezone | Details of the time zone for the building. Data type: Object |
| result.building.timezone.display_value | Display value of the time zone
in which the associated building resides. Data type: String |
| result.building.timezone.value | Internal value of the time zone in
which the associated building resides. Data type: String |
| result.campus | Campus where the reservable is located. Data type: Object Table: Campus [sn_wsd_core_campus] |
| result.campus.display_value | Display value for the campus. Data type: String |
| result.campus.sys_id | Sys_id of the associated campus record. Data type: String |
| result.capacity | Number of people that the reservable can accommodate. Data type: Number |
| result.description | Description of the reservable. Data type: String |
| result.display_number_of_attendees | Flag that indicates whether users can specify the number of attendees in the reservation. Valid values:
Data type: Boolean |
| result.display_on_behalf_of | Flag that indicates whether reservations can be made on behalf of someone else. Valid values:
Data type: Boolean |
| result.display_sensitivity | Flag that indicates whether users can set the sensitivity of the reservation, such as normal or private. Valid values:
Data type: Boolean |
| result.email | Email address associated with the reservable. Data type: String |
| result.employee_override_privacy | Flag that indicates whether users can override the privacy setting for the associated reservable. For additional information on these privacy settings, see Location privacy settings and impact. Valid values:
|
| result.enable_group_reservations | Flag that indicates whether users can make a group reservation. Valid values:
Data type: Boolean |
| result.enable_reservation_privacy | Flag that indicates the default setting for reservation privacy. For additional information on these privacy settings, see Location privacy settings and impact. Possible values:
Data type: Boolean |
| result.external_id | External ID of the reservable. Data type: String |
| result.flexible_services | Populated only if the include_flexible_services parameter is set to true and the workplace case management plugin is installed. Description of the flexible services associated with the reservables.
There can be a parent flexible service, and several child flexible services. Data type: Array of Objects Table: Workplace Service Item [sn_wsd_case_workplace_service_item] |
| result.flexible_services.additional_text | Text to prompt user to select additional flexible services. Data type: String |
| result.flexible_services.allow_only_single_service_item_selection | Flag that indicates whether users can select only one service item among the group of flexible services within a reservation. Valid values:
Data type: Boolean |
| result.flexible_services.category | Category of the flexible services. Data type: String |
| result.flexible_services.currency_code | Currency code used to calculate the amount of currency when ordering flexible services. Data type: String |
| result.flexible_services.flexible_service | Flexible services corresponding to a parent flexible service. Data type: Array of Objects Table: Workplace Service Item [sn_wsd_case_workplace_service_item] |
| result.flexible_services.flexible_service.flexible_service | Details of each flexible service corresponding to a parent flexible service. Data type: Array of Objects |
| result.flexible_services.flexible_service.flexible_service.additional_text | Text used to prompt a user to select additional flexible services. Data type: String |
| result.flexible_services.flexible_service.flexible_service.capacity_enabled | Flag that indicates whether the capacity of the room should appear in the reservation. If this is set to true, quantity_enabled will always be false. Valid values:
Data type: Boolean |
| result.flexible_services.flexible_service.flexible_service.category | Category of the flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.category_label | Category label of flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.cleanup_duration | Amount of time it takes to clean up or remove the service added to the reservable. Data type: Number Unit: Milliseconds |
| result.flexible_services.flexible_service.flexible_service.image | Link to the image of the flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.max_capacity | Maximum number of occupants that the reservable can accommodate. Data type: Number |
| result.flexible_services.flexible_service.flexible_service.name | Name of flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.preparation_duration | Amount of time it takes to add the service to the reservable. Data type: String Unit: Milliseconds |
| result.flexible_services.flexible_service.flexible_service.price_per_unit | Details of the cost of adding the flexible service to the reservable. Data type: Object |
| result.flexible_services.flexible_service.flexible_service.price_per_unit.code | Currency code to use when calculating the cost, such as GBP or USD. Data type: String |
| result.flexible_services.flexible_service.flexible_service.price_per_unit.value | Cost for each unit of the flexible service in the currency defined in the code parameter. Data type: String |
| result.flexible_services.flexible_service.flexible_service.quantity_enabled | Flag that indicates whether the quantity field should appear in the reservation. If this is set to true, capacity_enabled will always be false. Valid values:
Data type: Boolean |
| result.flexible_services.flexible_service.flexible_service.quantity_required | Flag that indicates whether the quantity is required. Valid values:
Data type: Boolean |
result.flexible_services.flexible_service.flexible_service.short_description |
Brief description of the flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.sub_category | Sub-category name of the flexible service, such as chair_layout. Data type: String |
| result.flexible_services.flexible_service.flexible_service.sub_category_label | Sub-category label of the flexible service, such as Chair layout. Data type: String |
| result.flexible_services.flexible_service.flexible_service.sub_title | Sub-title name of the child flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.sys_id | Sys_id of flexible service. Data type: String |
| result.flexible_services.flexible_service.flexible_service.text | Text used to prompt a user to select flexible services. Data type: String |
| result.flexible_services.flexible_service.flexible_service.title | Details for the titles to use when adding and editing the child flexible service in the UI. Data type: Object |
| result.flexible_services.flexible_service.flexible_service.title.add | Title used when adding a child flexible service in the UI. Data type: String |
| result.flexible_services.flexible_service.flexible_service.title.edit | Title used when editing a child flexible service in the UI. Data type: String |
| result.flexible_services.flexible_service.label | Flexible service label. Data type: String |
| result.flexible_services.flexible_service.sub_category | Sub-category of the parent flexible services, such as additional chair. Data type: String |
| result.flexible_services.flexible_service.sub_title | Sub-title name of the parent flexible service. Data type: String |
| result.flexible_services.flexible_service.text | Text used to prompt a user to select a parent flexible services. Data type: String |
| result.flexible_services.flexible_service.title | Details for the titles to use when adding and editing the parent flexible service in the UI. Data type: Object |
| result.flexible_services.flexible_service.title.add | Title used when adding a parent flexible service in the UI. Data type: String |
| result.flexible_services.flexible_service.title.edit | Title used when editing a parent flexible service in the UI. Data type: String |
| result.floor | Details about the floor on which the reservable is located. Data type: Object Table: Floor [sn_wsd_core_floor] |
| result.floor.display_value | Display number of the floor on which the reservable resides, such as 12. Data type: String |
| result.floor.sys_id | Sys_id of the associated record. Data type: String Table: Floor [sn_wsd_core_floor] |
| result.image | Details about an image that represents the associated reservable. Data type: Object Table: Images [db_image] |
| result.image.link | Link to an image that represents the reservable. Data type: String |
| result.image.sys_id | Sys_id of the associated image record. Data type: String Table: Images [db_image] |
| result.is_reservable | Flag that indicates whether the flexible service can be reserved. Valid values:
Data type: Boolean |
| results.layouts | Only populated if the include_layouts parameter is set to
true. List of the layouts associated with the reservable. Data type: Array of Objects
|
| result.layouts.capacity | Number of people that will attend the
meeting. Data type: Number |
| result.layouts.cleanup_duration | Amount of time it takes to clean the reservable for this layout. Data type: Number Unit: Milliseconds |
| result.layouts.image | Details about an image that represents the layout for the associated reservable. Data type: Object Table: Images [db_image] |
| result.layouts.image.link | Link to an image that represents the layout for this reservable. Data type: String Table: Images [db_image] |
| result.layouts.image.sys_id | Sys_id of the associated image
record. Data type: String |
| result.layouts.is_default | Flag that indicates whether the associated layout is the default for the reservable. Valid values:
Data type: Boolean |
| result.layouts.max_capacity | Maximum number of people that the layout associated with the reservable can
accommodate. Data type: Number |
| result.layouts.name | Name of the location layout. Data type: String |
| result.layouts.preparation_duration | Amount of time it takes to prepare the associated location layout. Data type: Number Unit: Milliseconds |
| result.layouts.short_description | Brief description of the location layout. Data type: String |
| result.layouts.sys_id | Sys_id of the location layout. Data type: String Table: Layout [sn_wsd_rsv_layout] |
| result.location_type | Details about the type of location of the reservable, such as workplace/desk, cafe, or gym. Data type: Object Table: Space Type [sn_wsd_core_space_type] |
| result.location_type.display_value | Display value of the location type. Data type: String |
| result.location_type.sys_id | Sys_id of the associated record. Data type: String Table: Space Type [sn_wsd_core_space_type] |
| result.meetingProviders | Details about the virtual meeting providers associated with the reservable. Data type: Array of Objects Table: Virtual Meeting Provider [sn_wsd_rsv_virtual_meeting_provider] |
| result.meetingProviders.display_value | Display value of the virtual provider's name. Data type: String |
| result.meetingProviders.value | Actual value for the virtual provider's name in the record. Data type: String |
| result.moduleType | Reservable module associated with the reservable, such as desks or meeting room. Data type: String |
| result.name | Name of the reservable. Data type: String |
| result.number | Unique identifier of the reservable. This value is more
human readable than the sys_id. Data type: String |
| result.order | Order number for the reservable. Data type: Number |
| result.require_approval | Flag that indicates whether reserving the reservable requires an approval. Possible values:
Data type: Boolean |
| result.requires_check_in | Flag that indicates whether the reservable requires the user to check in. Valid values:
Data type: Boolean |
| result.require_subject | Flag that indicates whether the user must enter a subject when making the reservation. Valid values:
Data type: Boolean |
| result.reservable_quantity | Maximum number of times the associated
reservable can be reserved for the same time. This value is used when assigning
neighborhood spaces to an area. Data type: Integer |
| result.site | Details about the site where the reservable resides. Data type: Object Table: Site [sn_wsd_core_site] |
| result.site.display_value | Display value of the site. Data type: String |
| result.standard_services | Only populated if the include_standard_services parameter is set to true. Associated standard services, such as flip chart, projector screen, and whiteboard and markers. Data type: Array of Objects
|
| result.standard_services.font_awesome_icon | Name of the thumbnail icon associated with the standard service. Data type: String |
| result.standard_services.name | Name of the standard service. Data type: String |
| result.standard_services.short_description | Brief description of the standard service. Data type: String |
| result.standard_services.sys_id | Sys_id of the standard service record. Data type: String Table: Standard Service [sn_wsd_rsv_standard_service] |
| result.site.sys_id | Sys_id of the associated site record. Data type: String Table: Site [sn_wsd_core_site] |
| result.tableName | Name of the table in which the reservable record resides. Data type: String |
| result.title | Title of the reservable. Data type: String |
| result.type | Type of a reservable, such as location. Data type: String |
cURL request
The following code example shows how to call this endpoint to return details about the specified reservables.
curl "http://instance.servicenow.com/api/sn_wsd_rsv/v2/reservable/list_reservables" \
--request POST \
--header "Accept:application/json" \
--header "Content-Type:application/json" \
--data "{\"space_sys_ids\":\"3ed3139977220110b3d7be377b5a99d1\",\"reservable_module_sys_id\":\"c31241cedb7650106c731dcd13961917\",\"include_flexible_services\":true,\"include_standard_services\":true,\"include_reservable_purposes\":true,\"include_layouts\":false}" \
--user 'username:'password'
Response body. This example returns details about all the reservables listed in the request body.
{
"result": [
{
"sys_id": "3ed3139977220110b3d7be377b5a99d1",
"external_id": "447b9dfb475a011064062782846d4382",
"wsd_email": null,
"name": "A263",
"title": "A263",
"description": null,
"image": null,
"number": "ROOM0000181",
"site": {
"sys_id": "b35f47ffdba05010f342a0da4b961998",
"display_value": "Italy"
},
"campus": {
"sys_id": "87831b1977220110b3d7be377b5a9946",
"display_value": ""
},
"building": {
"sys_id": "dea39b1977220110b3d7be377b5a9955",
"display_value": "",
"timezone": {
"value": "",
"displayValue": ""
}
},
"floor": {
"sys_id": "68d31f5977220110b3d7be377b5a991b",
"display_value": ""
},
"area": null,
"capacity": "17",
"reservable_quantity": "1",
"location_type": {
"sys_id": "20713b83eb512010b89bfdfc9c522899",
"display_value": "Room"
},
"order": null,
"requires_check_in": null,
"is_reservable": "1",
"type": "location",
"moduleType": "Meeting rooms",
"meetingProviders": [],
"require_subject": true,
"allow_invitees": false,
"display_number_of_attendees": false,
"display_on_behalf_of": true,
"display_sensitivity": true,
"enable_group_reservations": false,
"allow_reservation_message": false,
"warn_employee_for_duplicate_reservation": false,
"enable_reservation_privacy": false,
"employee_override_privacy": false,
"tableName": "sn_wsd_core_room",
"require_approval": false,
"flexible_services": [
{
"allow_only_single_service_item_selection": true,
"category": "50723fbf07100110c9b36b6e0ad300b4",
"label": "Space arrangement",
"description": "This is a service to request a different space configuration as part of a reservation.",
"sub_category": "chair_layout",
"title": {
"edit": "Update Space arrangement for A263",
"add": "Add Space arrangement for A263"
},
"sub_title": "Add a space arrangement item to get started",
"text": "Select space arrangement item",
"additional_text": "Select another space arrangement item",
"currency_code": "GBP",
"flexible_service": [
{
"sub_category": "chair_layout",
"label": "Chair layout",
"flexible_service": [
{
"sys_id": "e2ecf7b307500110c9b36b6e0ad30033",
"name": "Classroom Style",
"short_description": "Rows of tables arranged with all participants facing towards the front of the room",
"category": "50723fbf07100110c9b36b6e0ad300b4",
"category_label": "Space arrangement",
"sub_category": "chair_layout",
"sub_category_label": "Chair layout",
"image": "08d6ff68d5122110fa9b1500c1d696c5.iix",
"quantity_enabled": false,
"quantity_required": false,
"capacity_enabled": true,
"max_capacity": "",
"preparation_duration": "1970-01-01 00:15:00",
"cleanup_duration": "1970-01-01 00:15:00",
"price_per_unit": {
"value": 0,
"code": "GBP"
},
"title": {
"edit": "Update Space arrangement for A263",
"add": "Add Space arrangement for A263"
},
"sub_title": "Add a space arrangement item to get started",
"text": "Select space arrangement item",
"additional_text": "Select another space arrangement item"
},
{
"sys_id": "1cf33fff07100110c9b36b6e0ad30077",
"name": "Banquet Rounds",
"short_description": "Round tables arranged throughout the room. Participants are seated around the entire perimeter of each table",
"category": "50723fbf07100110c9b36b6e0ad300b4",
"category_label": "Space arrangement",
"sub_category": "chair_layout",
"sub_category_label": "Chair layout",
"image": "cdc67720d5522110fa9b1500c1d69636.iix",
"quantity_enabled": false,
"quantity_required": false,
"capacity_enabled": true,
"max_capacity": "",
"preparation_duration": "1970-01-01 00:15:00",
"cleanup_duration": "1970-01-01 00:15:00",
"price_per_unit": {
"value": 0,
"code": "GBP"
},
"title": {
"edit": "Update Space arrangement for A263",
"add": "Add Space arrangement for A263"
},
"sub_title": "Add a space arrangement item to get started",
"text": "Select space arrangement item",
"additional_text": "Select another space arrangement item"
},
{
"sys_id": "21e2c08407600110c9b36b6e0ad3007c",
"name": "Theater Style",
"short_description": "Rows of chairs (no tables) arranged with all participants facing towards the front of the room",
"category": "50723fbf07100110c9b36b6e0ad300b4",
"category_label": "Space arrangement",
"sub_category": "chair_layout",
"sub_category_label": "Chair layout",
"image": "f3d67fa4d5122110fa9b1500c1d6968b.iix",
"quantity_enabled": false,
"quantity_required": false,
"capacity_enabled": true,
"max_capacity": "",
"preparation_duration": "1970-01-01 00:15:00",
"cleanup_duration": "1970-01-01 00:15:00",
"price_per_unit": {
"value": 0,
"code": "GBP"
},
"title": {
"edit": "Update Space arrangement for A263",
"add": "Add Space arrangement for A263"
},
"sub_title": "Add a space arrangement item to get started",
"text": "Select space arrangement item",
"additional_text": "Select another space arrangement item"
}
]
}
]
},
{
"allow_only_single_service_item_selection": false,
"category": "c9ab1c89c3500110547e3810a840dd41",
"label": "Catering",
"description": "This is a service to request catering as part of a reservation.",
"sub_category": "drinks",
"title": {
"edit": "Update Catering for A263",
"add": "Add Catering for A263"
},
"sub_title": "Add a catering item to get started",
"text": "Select catering item",
"additional_text": "Select another catering item",
"currency_code": "GBP",
"flexible_service": [
{
"sub_category": "drinks",
"label": "Drinks",
"flexible_service": [
{
"sys_id": "48d72985c3900110547e3810a840dd7d",
"name": "Champagne",
"short_description": "",
"category": "c9ab1c89c3500110547e3810a840dd41",
"category_label": "Catering",
"sub_category": "drinks",
"sub_category_label": "Drinks",
"image": "",
"quantity_enabled": true,
"quantity_required": false,
"capacity_enabled": false,
"max_capacity": "",
"preparation_duration": 0,
"cleanup_duration": 0,
"price_per_unit": {
"value": 0,
"code": "GBP"
},
"title": {
"edit": "Update Catering for A263",
"add": "Add Catering for A263"
},
"sub_title": "Add a catering item to get started",
"text": "Select catering item",
"additional_text": "Select another catering item"
}
]
}
]
}
],
"standard_services": [],
"reservable_purposes": []
}
]
}