Search.../
  1. Home
  2. Getting Started
  3. Overview
Generate a test token to explore our APIs

List Sessions

Developer Preview

Returns sessions from the business calendar.
Query object support:

  • filter: supports
    • scheduleId: Optional.
    • from: query range start time. Required.
    • to: query range end time. Required.
    • tags: filter by list of tags
    • type: filter by session type
    • intervalIds: filter by list of interval ids
    • scheduleOwnerIds: the response will contain sessions with the given scheduleOwnerIds and sessions with affectedSchedules with the given scheduleOwnerIds.
    • transparency: when applied, the scheduleOwnerIds filter is required. In case the transparency = BUSY, the response will contain sessions with the given scheduleOwnerIds and sessions with affectedSchedules with the given scheduleOwnerIds where the owner's transparency is BUSY. When transparency = FREE, the response will contain only sessions and affectedSchedules with the given scheduleOwnerIds when the owner's transparency is FREE.
  • fields: supported.
  • paging: Paging is supported using the page token. For paging the results, i.e. with a page size of 10, set the query.paging.limit to a value of 10. The response will contain a value in the nextPageToken field. Pass this value in the pageToken field in the following calls and leave the query field empty.
  • fieldsets: not supported.

Query filter example:

{
"$and": [{
"scheduleId": "66a2674c-9267-4600-826e-f463957b9446" },
{ "from": "2019-02-17T13:08:43.000Z" },
{ "to": "2019-02-17T14:08:43.000Z" },
{ "tags": ["GROUP"]},
{ "type": "EVENT"},
{ "intervalIds": ["66a2674c-826e-4600-9267-f463957b9446"]},
{ "scheduleOwnerIds: ["66a2674c-9267-4600-826e-f463957b9446", "66a2674c-9267-4600-826e-f463957b9447"]}
]}
Copy Code

Permissions
This endpoint requires the Read Bookings Calendar, the Read Bookings Calendar - Including Participants, the Read Bookings - Including Participants or the Manage Bookings permission.

Authorization

This endpoint requires an authorization header - pass the access token from the OAuth installation flow.

POST

https://www.wixapis.com/bookings/v1/calendar/listSessions

Body Params

NAME
TYPE
DESCRIPTION
query

object

Partially supported. See description above.

pageToken

string

Response Object

NAME
TYPE
DESCRIPTION
sessions

Array<object>

Sessions on the calendar.

nextPageToken

string

Sessions paging response. Token for the next page of results

Status/Error Codes

The response will include an HTTP status code.

Was this helpful?

List Sessions by schedule owner id

List all sessions in the provided date-time range of all schedules with the provided owner id.

Request

curl

Copy Code
1curl -X POST \
2 'https://www.wixapis.com/bookings/v1/calendar/listSessions' \
3 -H "Content-Type: application/json" \
4 -H 'Authorization: <AUTH>' \
5 --data '{
6 "query": {
7 "filter": "{\"from\":\"2020-04-29T00:00:00.000Z\",\"to\":\"2020-05-04T00:00:00.00Z\",\"scheduleOwnerIds\": [\"e6b6108c-92bc-462b-937c-dab386909fd2\"]}"
8 }
9 }'

Response

json

1
2{"sessions": [
3 {
4 "id": "4jOkD28c0FrsNUSgzQzuLRkA2t1rv1FLTwquKmJyctoZm00vdeKFMyH4n9cCLtmQe8wvKBjRGhub7Y7cLdIExqh2iuWTcm8Ezhcej4vS7gdabMeRHIZtLf1Xq1o1EdwQ2v2gCUSuDqwUIfj0DFyUGWNBThpxqEHVWLKC6by49GVZaOmlNMHsJ00NTDf7VyZ0jyciRDw3Kg7xXXHCpWbZZSAJCvLBYKSd3VlgRJsiC8NjVEf8UBTqOZ3b9nw5yDe9z2JL6ObtlWSYl8K5rgKZXBCKKIo1jxCKTreB2dgEguqri8kgTOdBsGxNX5ijCmYSkoaLJYsV5onmWez",
5 "scheduleId": "5c7917e7-3987-425a-a79a-dc4ea3edb8bc",
6 "scheduleOwnerId": "e6b6108c-92bc-462b-937c-dab386909fd2",
7 "start": {
8 "timestamp": "2020-04-29T07:00:00Z",
9 "localDateTime": {
10 "year": 2020,
11 "monthOfYear": 4,
12 "dayOfMonth": 29,
13 "hourOfDay": 10,
14 "minutesOfHour": 0
15 },
16 "timeZone": "Asia/Jerusalem"
17 },
18 "end": {
19 "timestamp": "2020-04-29T15:00:00Z",
20 "localDateTime": {
21 "year": 2020,
22 "monthOfYear": 4,
23 "dayOfMonth": 29,
24 "hourOfDay": 18,
25 "minutesOfHour": 0
26 },
27 "timeZone": "Asia/Jerusalem"
28 },
29 "affectedSchedules": [],
30 "tags": [],
31 "notes": "",
32 "totalNumberOfParticipants": 0,
33 "participants": [],
34 "inheritedFields": [
35 "capacity",
36 "end",
37 "externalCalendarOverrides",
38 "location",
39 "rate",
40 "start",
41 "tags",
42 "title"
43 ],
44 "status": "CONFIRMED",
45 "recurringIntervalId": "abb697b7-5bbb-48bf-9083-5908cad7ebe6",
46 "type": "WORKING_HOURS"
47 },
48 {
49 "id": "4jOkD28c0FrsNUSgzQzuLRkA2t1rv1FLTwquKmJyctoZm00vdeKFMyH4n9cCLtmQe8wvKBjRGhub7Y7cLdIExqh2iuWTcm8Ezhcej4vS7gdabMeRHIZtLf1Xq1o1EdwQ2v2gCUSuDqwUIfj0DFyUGWOY8BqOhdfGYNpBkX4ImnMMDvTDcUao42syKma2W4s4fiZhOY6hjqE5xc13CcLry93pdaAPfWVd7SoNxhnxW5uZIeSaRz07otS3YIP9WboOAbWIlu74Ax8WkEOlCaIhuQRX0TFRzY77CWn4VScuVfI6Nc0i3Bh66vUtreNqgSKpuSwfPmJHyRr2AWr",
50 "scheduleId": "5c7917e7-3987-425a-a79a-dc4ea3edb8bc",
51 "scheduleOwnerId": "e6b6108c-92bc-462b-937c-dab386909fd2",
52 "start": {
53 "timestamp": "2020-04-29T15:00:00Z",
54 "localDateTime": {
55 "year": 2020,
56 "monthOfYear": 4,
57 "dayOfMonth": 29,
58 "hourOfDay": 9,
59 "minutesOfHour": 0
60 },
61 "timeZone": "America/Denver"
62 },
63 "end": {
64 "timestamp": "2020-04-30T00:00:00Z",
65 "localDateTime": {
66 "year": 2020,
67 "monthOfYear": 4,
68 "dayOfMonth": 29,
69 "hourOfDay": 18,
70 "minutesOfHour": 0
71 },
72 "timeZone": "America/Denver"
73 },
74 "affectedSchedules": [],
75 "tags": [],
76 "notes": "",
77 "totalNumberOfParticipants": 0,
78 "participants": [],
79 "inheritedFields": [
80 "capacity",
81 "end",
82 "externalCalendarOverrides",
83 "location",
84 "rate",
85 "start",
86 "tags",
87 "title"
88 ],
89 "status": "CONFIRMED",
90 "recurringIntervalId": "bf6363a5-f302-432a-adce-574f90adbffe",
91 "type": "WORKING_HOURS"
92 },
93 {
94 "id": "4jOkD28c0FrsNUSgzQzuLRkA2t1rv1FLTwquKmJyctoZm00vdeKFMyH4n9cCLtmQe8wvKBjRGhub7Y7cLdIExqh2iuWTcm8Ezhcej4vS7gdabMeRHIZtLf1Xq1o1EdwQ2v2gCUSuDqwUIfj0DFyUGWSZgwl3gKqmjCZUtIAmyo4jDXnAxu7AS66pLAF4I6gBn3NCkme1G5UQdXXiOtyZu4h8hgfop8a5Wko4cbtvEML1HRYIzUlpAKLN1DYVrsyhoeUV2vofC9vLednHRD72bJVs5XUmuhs7I7DmkeDPiDZmCtye5UJx9Usm1u8eT3npvjsXFOuKHdGx27x",
95 "scheduleId": "5c7917e7-3987-425a-a79a-dc4ea3edb8bc",
96 "scheduleOwnerId": "e6b6108c-92bc-462b-937c-dab386909fd2",
97 "start": {
98 "timestamp": "2020-04-30T16:00:00Z",
99 "localDateTime": {
100 "year": 2020,
101 "monthOfYear": 4,
102 "dayOfMonth": 30,
103 "hourOfDay": 10,
104 "minutesOfHour": 0
105 },
106 "timeZone": "America/Denver"
107 },
108 "end": {
109 "timestamp": "2020-05-01T00:00:00Z",
110 "localDateTime": {
111 "year": 2020,
112 "monthOfYear": 4,
113 "dayOfMonth": 30,
114 "hourOfDay": 18,
115 "minutesOfHour": 0
116 },
117 "timeZone": "America/Denver"
118 },
119 "affectedSchedules": [],
120 "tags": [],
121 "notes": "",
122 "totalNumberOfParticipants": 0,
123 "participants": [],
124 "inheritedFields": [
125 "capacity",
126 "end",
127 "externalCalendarOverrides",
128 "location",
129 "rate",
130 "start",
131 "tags",
132 "title"
133 ],
134 "status": "CONFIRMED",
135 "recurringIntervalId": "ed228bf4-0633-4000-bcfc-deec055b56ee",
136 "type": "WORKING_HOURS"
137 },
138 {
139 "id": "4jOkD28c0FrsNUSgzQzuLRkA2t1rv1FLTwquKmJyctoZm00vdeKFMyH4n9cCLtmQe8wvKBjRGhub7Y7cLdIExqh2iuWTcm8Ezhcej4vS7gdabMeRHIZtLf1Xq1o1EdwQ2v2gCUSuDqwUIfj0DFyUGWRE1SItMIUgo7r1RtlOvplxqGjPk3hq1899DqEadzZtQtSDM8oiRXGOJX48NEQmLsZgKnp37YHcJEmwi2PsifW4K0ecmWYfj6G20DqbH6djy5AaAt52McdBwsXcA4WKFWecBkkca8sLwK9dmvV3cH9Nf1F1YHLHJBD4VWM7zaD1nnka80Qn0921Li9",
140 "scheduleId": "5c7917e7-3987-425a-a79a-dc4ea3edb8bc",
141 "scheduleOwnerId": "e6b6108c-92bc-462b-937c-dab386909fd2",
142 "start": {
143 "timestamp": "2020-05-01T15:00:00Z",
144 "localDateTime": {
145 "year": 2020,
146 "monthOfYear": 5,
147 "dayOfMonth": 1,
148 "hourOfDay": 9,
149 "minutesOfHour": 0
150 },
151 "timeZone": "America/Denver"
152 },
153 "end": {
154 "timestamp": "2020-05-02T00:00:00Z",
155 "localDateTime": {
156 "year": 2020,
157 "monthOfYear": 5,
158 "dayOfMonth": 1,
159 "hourOfDay": 18,
160 "minutesOfHour": 0
161 },
162 "timeZone": "America/Denver"
163 },
164 "affectedSchedules": [],
165 "tags": [],
166 "notes": "",
167 "totalNumberOfParticipants": 0,
168 "participants": [],
169 "inheritedFields": [
170 "capacity",
171 "end",
172 "externalCalendarOverrides",
173 "location",
174 "rate",
175 "start",
176 "tags",
177 "title"
178 ],
179 "status": "CONFIRMED",
180 "recurringIntervalId": "dcc12d4e-5faa-400b-8678-782736701dd6",
181 "type": "WORKING_HOURS"
182 },
183 {
184 "id": "4jOkD28c0FrsNUSgzQzuLRkA2t1rv1FLTwquKmJyctoZm00vdeKFMyH4n9cCLtmQe8wvKBjRGhub7Y7cLdIExqh2iuWTcm8Ezhcej4vS7gdabMeRHIZtLf1Xq1o1EdwQ2v2gCUSuDqwUIfj0DFyUGWPsEU5d5hD9HZnU1Ax68LS8P0Iv1JpB0d0BN71lBbzP4fWBYZ83evjXcJ5Q9kX7ncGMEJwpue0hign9PVNFfpJF89LoZpiREWV9JQe7iloRgH0bYjQR8hZJX1wLY6vrJEv7iNqLWCCoA5a4pnGWXfpav8mkRrAFFiYE2N9j341344SFD3mgKlOn7Lp",
185 "scheduleId": "5c7917e7-3987-425a-a79a-dc4ea3edb8bc",
186 "scheduleOwnerId": "e6b6108c-92bc-462b-937c-dab386909fd2",
187 "start": {
188 "timestamp": "2020-05-02T15:00:00Z",
189 "localDateTime": {
190 "year": 2020,
191 "monthOfYear": 5,
192 "dayOfMonth": 2,
193 "hourOfDay": 9,
194 "minutesOfHour": 0
195 },
196 "timeZone": "America/Denver"
197 },
198 "end": {
199 "timestamp": "2020-05-03T00:00:00Z",
200 "localDateTime": {
201 "year": 2020,
202 "monthOfYear": 5,
203 "dayOfMonth": 2,
204 "hourOfDay": 18,
205 "minutesOfHour": 0
206 },
207 "timeZone": "America/Denver"
208 },
209 "affectedSchedules": [],
210 "tags": [],
211 "notes": "",
212 "totalNumberOfParticipants": 0,
213 "participants": [],
214 "inheritedFields": [
215 "capacity",
216 "end",
217 "externalCalendarOverrides",
218 "location",
219 "rate",
220 "start",
221 "tags",
222 "title"
223 ],
224 "status": "CONFIRMED",
225 "recurringIntervalId": "cb5d558f-292b-4a1a-bcc4-34071b2fa33f",
226 "type": "WORKING_HOURS"
227 },
228 {
229 "id": "4jOkD28c0FrsNUSgzQzuLRkA2t1rv1FLTwquKmJyctoZm00vdeKFMyH4n9cCLtmQe8wvKBjRGhub7Y7cLdIExqh2iuWTcm8Ezhcej4vS7gdabMeRHIZtLf1Xq1o1EdwQ2v2gCUSuDqwUIfj0DFyUGWTvkMRw8ssHvKoFKzgwAyrxBylCoDZ1baZzEHOM2llX0Dvylej7EaKncKSCLwkGJwVoQi2Dn7tCb479SzDd8xDyTZm60ubghG4e6w69nYcA8KkcNRZzaqCNpMgyAdfbClvRlCRphHskYAjBi4GxTdGIzhGKOgyMHQ7HqGzXDoBKjwdUatNVV8gl10H",
230 "scheduleId": "5c7917e7-3987-425a-a79a-dc4ea3edb8bc",
231 "scheduleOwnerId": "e6b6108c-92bc-462b-937c-dab386909fd2",
232 "start": {
233 "timestamp": "2020-05-03T15:00:00Z",
234 "localDateTime": {
235 "year": 2020,
236 "monthOfYear": 5,
237 "dayOfMonth": 3,
238 "hourOfDay": 9,
239 "minutesOfHour": 0
240 },
241 "timeZone": "America/Denver"
242 },
243 "end": {
244 "timestamp": "2020-05-04T00:00:00Z",
245 "localDateTime": {
246 "year": 2020,
247 "monthOfYear": 5,
248 "dayOfMonth": 3,
249 "hourOfDay": 18,
250 "minutesOfHour": 0
251 },
252 "timeZone": "America/Denver"
253 },
254 "affectedSchedules": [],
255 "tags": [],
256 "notes": "",
257 "totalNumberOfParticipants": 0,
258 "participants": [],
259 "inheritedFields": [
260 "capacity",
261 "end",
262 "externalCalendarOverrides",
263 "location",
264 "rate",
265 "start",
266 "tags",
267 "title"
268 ],
269 "status": "CONFIRMED",
270 "recurringIntervalId": "ff0c6adf-3560-43ec-a5b1-d70dfc9e9429",
271 "type": "WORKING_HOURS"
272 }
273]}
List Sessions
List Sessions with pagination - first page
List Sessions with pagination - second page