-
Notifications
You must be signed in to change notification settings - Fork 1
/
bookeo.json
5153 lines (5153 loc) · 161 KB
/
bookeo.json
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
{
"openapi": "3.0.0",
"info": {
"title": "Bookeo",
"version": "v2",
"x-logo": {
"url": "http://logo.clearbit.com/bookeo.com"
}
},
"paths": {
"/availability/matchingslots": {
"post": {
"summary": "Find available slots matching given search parameters",
"description": "Create a search for available slots that match the given search parameters.\n Note that there are two different searches possible, /availability/slots and /availability/matchingslots (this endpoint).\n The former simply shows the number of available seats for each available slot. The latter (this one) takes as input the participant numbers, and shows the slots that are available for those numbers, and an estimate of the price.\n Parameters include product code, number of people and options.\n The successful response also contains a \"Location\" HTTP header, which can be invoked to navigate the results of the search.",
"tags": [
"Availability"
],
"parameters": [
{
"name": "itemsPerPage",
"description": ".\nmaximum: 300",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"maximum": 300,
"default": "50"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MatchingSlotsSearchParameters"
}
}
},
"required": true
},
"responses": {
"201": {
"description": "The search was created successfully. The HTTP header \"Location\" contains the URI to use to access the results. It will point to /availability/matchingslots/{pageNavigationToken} .",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MatchingSlotList"
}
}
}
}
}
}
},
"/availability/matchingslots/{pageNavigationToken}": {
"get": {
"summary": "Navigate results of a matching slots search",
"tags": [
"Availability"
],
"parameters": [
{
"name": "pageNavigationToken",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "pageNumber",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"default": "1"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/MatchingSlotList"
}
}
}
}
}
}
},
"/availability/slots": {
"get": {
"summary": "Get information about the availability of products",
"description": "Performs a basic search to find available slots and number of seats in each.\n Note that there are two different searches possible, /availability/slots (this endpoint) and /availability/matchingslots .\n The former simply shows the number of available seats for each available slot. The latter takes as input the participant numbers, and shows the slots that are available for those numbers, and an estimate of the price.\n /availability/slots cannot be used for products of type flexibleTime . For those products, use /availability/matchingslots .",
"tags": [
"Availability"
],
"parameters": [
{
"name": "productId",
"description": "the product id (see /settings/products). If not provided, all products of type \"fixed\" or \"fixedCourse\" will be included in the result. If no productId is provided, products that are not bookable by customers wil not be included in the result. If productId is provided, the product must be of type \"fixed\" or \"fixedCourse\". For products of type \"flexibleTime\", use /availability/matchingslots instead.",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "startTime",
"description": "the start time to search from. Required unless pageNavigationToken is used.",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "endTime",
"description": "the end time to search to. Required unless pageNavigationToken is used. The maximum date range in a single call is 31 days.",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "itemsPerPage",
"description": ".\nmaximum: 300",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"maximum": 300,
"default": "50"
}
},
{
"name": "pageNavigationToken",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "pageNumber",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"default": "1"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/SlotList"
}
}
}
}
}
}
},
"/bookings": {
"get": {
"summary": "Retrieve bookings",
"description": "Retrieve existing bookings\n The result is limited by the permissions of the apiKey.\n \n\n It is possible to filter by time booked and/or time of the last change.\n To filter by time booked, the parameters startTime and endTime are required.\n To filter by last time changed, the parameters lastUpdatedStartTime and lastUpdatedEndTime are required.\n It is possible to filter by both at the same time. At least one of the two filters must be used.\n \n\n It is further possible to filter by product id.\n \n\n Do not use this method to periodically poll for new/changed bookings. Use webhooks (see API general documentation) instead.",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "startTime",
"description": "if specified, only include bookings that start on or after this time. If specified, endTime must be specified as well.",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "endTime",
"description": "if specified, only include bookings that start on or before this time. If specified, startTime must be specified as well. The maximum allowed interval is 31 days.",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "lastUpdatedStartTime",
"description": "if specified, only include bookings that were last changed (or created) on or after this time. If specified, lastUpdatedEndTime must be specified as well.",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "lastUpdatedEndTime",
"description": "if specified, only include bookings that were last changed (or created) on or before this time. If specified, lastUpdatedStartTime must be specified as well. The maximum allowed interval is 31 days.",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "productId",
"description": "if not specified, include bookings for all products. If specified, include only bookings for this product",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "includeCanceled",
"description": "if true, canceled bookings are included. If false, only bookings that are not canceled are included",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "false"
}
},
{
"name": "expandCustomer",
"description": "if true, the full details of the customer are included (provided the application has read permission over the customer)",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "false"
}
},
{
"name": "expandParticipants",
"description": "if true, full details of the participants are included (provided the application has read permission over the participant)",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "false"
}
},
{
"name": "itemsPerPage",
"description": "maximum: 100",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"maximum": 100,
"default": "50"
}
},
{
"name": "pageNavigationToken",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "pageNumber",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"default": "1"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/BookingsList"
}
}
}
}
}
},
"post": {
"summary": "Create a new booking",
"description": "When creating a booking for a product of type \"fixed\" or \"fixedCourse\", the eventId is required. eventIds are obtained by calling /availability/slots or /availability/matchingSlots .\n When creating a booking for a product of type \"flexibleTime\", you can either specify the eventId or the startTime (in which case you can optionally specify the endTime. If no endTime is specified, Bookeo will automatically calculate the duration based on the options chosen)",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "previousHoldId",
"description": "if specified, deletes the hold with the given id",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "notifyUsers",
"description": "whether to send a notification email (and possibly SMS, depending on settings) to eligible users",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "notifyCustomer",
"description": "whether to send a confirmation email to the customer",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "sendCustomerReminders",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "sendCustomerThankyou",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "mode",
"description": "if present and set to \"backend\", treats the operation as if it was done by a manager. This relaxes some constraints such as when is it possible to change a booking, participants limits for the booking, booking limits (time in advance), and so on.",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"requestBody": {
"$ref": "#/components/requestBodies/Booking"
},
"responses": {
"201": {
"description": "The resource was created successfully. The HTTP response contains a Location header whose value is the resource URI."
}
}
}
},
"/bookings/{bookingNumber}": {
"get": {
"summary": "Retrieve a booking",
"description": "Retrieve a booking by its booking number",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "bookingNumber",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "expandCustomer",
"description": "if true, the full details of the customer are included (provided the application has read permission over the customer)",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "false"
}
},
{
"name": "expandParticipants",
"description": "if true, full details of the participants are included (provided the application has read permission over the participant)",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "false"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Booking"
}
}
}
}
}
},
"put": {
"summary": "Update an existing booking",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "bookingNumber",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "notifyUsers",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "notifyCustomer",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "mode",
"description": "if present and set to \"backend\", treats the operation as if it was done by a manager. This relaxes some constraints such as when is it possible to change a booking, participants limits for the booking, booking limits (time in advance), and so on.",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"requestBody": {
"$ref": "#/components/requestBodies/Booking"
},
"responses": {
"200": {
"description": "The resource was updated successfully."
}
}
},
"delete": {
"summary": "Cancel a booking",
"description": "Cancel a booking. Cancelled bookings remain in the system, but no longer show up in the calendar or take up seats.",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "bookingNumber",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "notifyUsers",
"description": "if true, notification emails and SMS are sent to authorized users",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "notifyCustomer",
"description": "if true, a notification email is sent to the customer",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "applyCancellationPolicy",
"description": "if true, the default cancellation policy is applied. This may cause a charge on the credit card on file, if a cancellation fee is due",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "trackInCustomerHistory",
"description": "if true, the cancellation will be tracked in the customer's stats",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "cancelRemainingSeries",
"description": "if true, and this booking is part of a recurring series, all following bookings will be cancelled as well",
"required": false,
"in": "query",
"schema": {
"type": "boolean"
}
},
{
"name": "reason",
"description": "an optional reason that explains why the booking was cancelled",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"204": {
"description": "The resource was deleted successfully."
}
}
}
},
"/bookings/{bookingNumber}/customer": {
"get": {
"summary": "Retrieve the customer associated with a booking",
"description": "Retrieve the customer associated with a booking.",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "bookingNumber",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "This is a custom successful response description.\n over multiple lines.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Customer"
}
}
}
}
}
}
},
"/bookings/{bookingNumber}/payments": {
"get": {
"summary": "Get the payments received for a booking",
"description": "Get a list of all payments received for a booking. Only payments for which the apiKey has at least read permission will be included",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "bookingNumber",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "itemsPerPage",
"description": ".\nmaximum: 100",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"maximum": 100,
"default": "50"
}
},
{
"name": "pageNavigationToken",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "pageNumber",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"default": "1"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/PaymentsList"
}
}
}
}
}
},
"post": {
"summary": "Add a payment to a booking",
"description": "Create a payment record associated with a booking",
"tags": [
"Bookings"
],
"parameters": [
{
"name": "bookingNumber",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"requestBody": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Payment"
}
}
},
"required": true
},
"responses": {
"201": {
"description": "The resource was created successfully. The HTTP response contains a Location header whose value is the resource URI."
}
}
}
},
"/customers": {
"get": {
"summary": "Retrieve customers",
"description": "Get a list of customers.",
"tags": [
"Customers"
],
"parameters": [
{
"name": "currentMembers",
"description": "if true, include customers that are current members. this is the default",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "true"
}
},
{
"name": "currentNonMembers",
"description": "if true, include customers that are not current members. this is the default",
"required": false,
"in": "query",
"schema": {
"type": "boolean",
"default": "true"
}
},
{
"name": "createdSince",
"description": "if present, only include customers created since the given time",
"required": false,
"in": "query",
"schema": {
"type": "string",
"format": "date-time"
}
},
{
"name": "searchField",
"description": "a field on which to apply the search filter. Used only if searchText is specified",
"required": false,
"in": "query",
"schema": {
"type": "string",
"enum": [
"name",
"firstName",
"lastName",
"emailAddress"
],
"default": "name"
}
},
{
"name": "searchText",
"description": "the text to search for. If not present, all customers are returned",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "itemsPerPage",
"description": "number of items per page.\nmaximum: 100",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"maximum": 100,
"default": "50"
}
},
{
"name": "pageNavigationToken",
"description": "if present, continues navigation after a previous call. pageNavigationToken is included in the response of the first call, if there are more results than itemsPerPage",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "pageNumber",
"description": "if present, and pageNavigationToken is present, indicates what page to navigate to. Ignored unless pageNavigationToken is present",
"required": false,
"in": "query",
"schema": {
"type": "integer",
"format": "int32",
"default": "1"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/CustomersList"
}
}
}
}
}
},
"post": {
"summary": "Create a new customer.",
"description": "Create a new customer.\n Please note there is a limit to the number of customers that can be imported in Bookeo. Bookeo is primarily a booking system, not a CRM.",
"tags": [
"Customers"
],
"requestBody": {
"$ref": "#/components/requestBodies/Customer"
},
"responses": {
"201": {
"description": "The resource was created successfully. The HTTP response contains a Location header whose value is the resource URI."
}
},
"parameters": [
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"description": "API Key",
"required": true
}
]
}
},
"/customers/{customerid}/linkedpeople/{id}": {
"get": {
"summary": "Retrieve a person linked to a customer",
"tags": [
"Customers"
],
"parameters": [
{
"name": "customerid",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "id",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],
"responses": {
"200": {
"description": "The call was completed successfully.",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/LinkedPerson"
}
}
}
}
}
},
"put": {
"summary": "Update the details of a person linked to a customer",
"tags": [
"Customers"
],
"parameters": [
{
"name": "customerid",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"name": "id",
"required": true,
"in": "path",
"schema": {
"type": "string"
}
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "apiKey",
"required": true,
"description": "API Key"
}
],