Query
query BusinessHoursSchedule($businessHoursScheduleId: ID!) {
businessHoursSchedule(businessHoursScheduleId: $businessHoursScheduleId) {
id
name
slots {
timezone {
name
}
weekday
opensAt
closesAt
}
createdAt {
unixTimestamp
iso8601
}
createdBy {
__typename
... on UserActor {
userId
user {
__typename
}
}
}
updatedAt {
unixTimestamp
iso8601
}
}
}Variables
{
"businessHoursScheduleId": "id"
}Response
{
"data": {
"businessHoursSchedule": {
"id": "id",
"name": "string",
"slots": [
{
"timezone": {
"name": "string"
},
"weekday": "MONDAY",
"opensAt": "string",
"closesAt": "string"
}
],
"createdAt": {
"unixTimestamp": "string",
"iso8601": "string"
},
"createdBy": {
"__typename": "UserActor",
"userId": "id",
"user": {
"__typename": "User"
}
},
"updatedAt": {
"unixTimestamp": "string",
"iso8601": "string"
}
}
}
}Queries
businessHoursSchedule
Fetches a single business hours schedule by its ID, or null if no schedule with that ID exists. Requires the businessHours:read permission.
QUERY
businessHoursSchedule(businessHoursScheduleId: ID!): BusinessHoursScheduleArguments
businessHoursScheduleId
ID!
required
Returns
id
ID!
name
String!
Human-readable name, unique within the workspace.
slots
The slots that make up this schedule. Overlapping and adjacent slots are merged, and the list is sorted by timezone then weekday.
createdAt
createdBy
updatedAt
updatedBy
Query
query BusinessHoursSchedule($businessHoursScheduleId: ID!) {
businessHoursSchedule(businessHoursScheduleId: $businessHoursScheduleId) {
id
name
slots {
timezone {
name
}
weekday
opensAt
closesAt
}
createdAt {
unixTimestamp
iso8601
}
createdBy {
__typename
... on UserActor {
userId
user {
__typename
}
}
}
updatedAt {
unixTimestamp
iso8601
}
}
}Variables
{
"businessHoursScheduleId": "id"
}Response
{
"data": {
"businessHoursSchedule": {
"id": "id",
"name": "string",
"slots": [
{
"timezone": {
"name": "string"
},
"weekday": "MONDAY",
"opensAt": "string",
"closesAt": "string"
}
],
"createdAt": {
"unixTimestamp": "string",
"iso8601": "string"
},
"createdBy": {
"__typename": "UserActor",
"userId": "id",
"user": {
"__typename": "User"
}
},
"updatedAt": {
"unixTimestamp": "string",
"iso8601": "string"
}
}
}
}Was this page helpful?

