Service Location
These are the endpoints that are available under the /serviceLocation path, which lists all the service availability your business offers by location.
Endpoint | Description |
---|---|
GET /serviceLocation/service/{reasonId} | Returns all serviceLocation objects for the specified reason in array form - these objects describe the locations, days and hours that this service has availability. |
POST /serviceLocation/service/{reasonId} | Creates a new set of serviceLocation availability objects for the specified service or updates an existing set of serviceLocation availability objects for a service. Request body/payload: Must pass an array of serviceLocation availability objects in the request body/payload. For these calls, you need to pass a serviceLocation object with all required fields and any fields you want to set or update filled in the body of the payload. We have an example of a serviceLocation object in the responses section below and have indicated the required fields in the object values table at the bottom of this page. |
There are no parameters included with serviceLocation calls.
Level 1/Location array table:
Property name | Type | Required | Description |
---|---|---|---|
description | string | Yes | Displays as the location name of the specified service location. |
haslevel2 | boolean | Indicates whether or not the specified service location has level 2 service availability set up. | |
level2 | array | Provides an array of 7 objects that represent the days of the week that can be selected to further refine service availability by location. Definitions of properties within an object on this array are defined in the table labeled "Level 2/Days array table" below. | |
locationId | integer | Yes | Displays as the location ID of the specified service location. |
selected | boolean | Indicates whether or not the specified location has service availability. |
Level 2/Days array table:
Property Name | Type | Required | Description |
---|---|---|---|
day | string | Displays as a string representation of the specified day of the week. | |
dayOfWeek | integer | Displays as an integer representation of the specified day of the week, where 0 = Sunday, 1 = Monday, ..., 6 = Saturday. | |
hasLevel3 | boolean | Indicates whether or not the specified service location has level 3 service availability set up. | |
level3 | array | Provides an array of objects that represent different times of the day that can be selected to further refine service availability by location. Definitions of properties within an object on this array are defined in the table labeled "Level 3/Times array table" below. | |
selected | boolean | Indicates whether or not this locations offers service availability on the specified day of the week. |
Level 3/Times array table:
Property Name | Type | Required | Description |
---|---|---|---|
endDate | integer | Displays as what is set as the end date of the specified set times of service availability in milliseconds elapsed since January 1, 1970 00:00:00 UTC form. | |
endTime | integer | Displays as what is set as the end time of the specified set times of service availability using military time. | |
hasLevel4 | boolean | Indicates whether the specified time for the specified day for the specified location has a date range that applies to it. If this is set to true, then it would be expected that at least the startDate property on this level has been filled in with a value. | |
startDate | integer | Displays as what is set as the start date of the specified set times of service availability in milliseconds elapsed since January 1, 1970 00:00:00 UTC form. | |
startTime | integer | Displays as what is set as the start time of the specified set times of service availability using military time. |