-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathGetUpcomingOpenClosedTimes.graphql
32 lines (31 loc) · 1.19 KB
/
GetUpcomingOpenClosedTimes.graphql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# Query the next series of open/closed hours for a place, in order to present
# information whether the venue is open, closed, opening soon, closing soon,
# etc.
query getUpcomingOpenClosedTimes($placeId: ID!) {
# Use the place() operation
place(id: $placeId) {
# Access the opening hours (where specified)
hours {
# Access the next window that the place is open. Supports selecting a
# series of Open/Closed hours and can be used to let users know when
# a venue will be open/closed next.
intervals(first: 2) {
# First node is the current state, second node is the upcoming change
# of status.
nodes {
# Times from/to as ISO-8601 string, or formatted using the Unicode
# Technical Standard #35 Date Field Symbols
from(format: "EEE, MMM d, h:mm a")
to(format: "EEE, MMM d, h:mm a")
# Create a relative expression (in X minutes/hours etc) based on a
# a supplied relative to ISO 8601, or null (for now)
relative: from(relativeTo: null)
# Status Open/Closed
status
# Any comments attached to the opening hours
comment
}
}
}
}
}