@wix/bookings 1.0.37 → 1.0.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.d.ts +3 -2
- package/build/cjs/index.js +4 -3
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/src/bookings-calendar-v1-session.http.js +6 -0
- package/build/cjs/src/bookings-calendar-v1-session.http.js.map +1 -1
- package/build/cjs/src/bookings-calendar-v1-session.types.d.ts +1 -1
- package/build/cjs/src/bookings-calendar-v1-session.universal.d.ts +1 -1
- package/build/cjs/src/bookings-calendar-v2-session-view.http.d.ts +7 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.http.js +41 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.http.js.map +1 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.public.d.ts +4 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.public.js +25 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.public.js.map +1 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.types.d.ts +1143 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.types.js +141 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.types.js.map +1 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.universal.d.ts +1150 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.universal.js +236 -0
- package/build/cjs/src/bookings-calendar-v2-session-view.universal.js.map +1 -0
- package/build/cjs/src/bookings-services-v2-service.public.d.ts +1 -1
- package/build/cjs/src/bookings-services-v2-service.types.d.ts +73 -2
- package/build/cjs/src/bookings-services-v2-service.types.js.map +1 -1
- package/build/cjs/src/bookings-services-v2-service.universal.d.ts +73 -2
- package/build/cjs/src/bookings-services-v2-service.universal.js.map +1 -1
- package/build/es/index.d.ts +3 -2
- package/build/es/index.js +3 -2
- package/build/es/index.js.map +1 -1
- package/build/es/src/bookings-calendar-v1-session.http.js +6 -0
- package/build/es/src/bookings-calendar-v1-session.http.js.map +1 -1
- package/build/es/src/bookings-calendar-v1-session.types.d.ts +1 -1
- package/build/es/src/bookings-calendar-v1-session.universal.d.ts +1 -1
- package/build/es/src/bookings-calendar-v2-session-view.http.d.ts +7 -0
- package/build/es/src/bookings-calendar-v2-session-view.http.js +37 -0
- package/build/es/src/bookings-calendar-v2-session-view.http.js.map +1 -0
- package/build/es/src/bookings-calendar-v2-session-view.public.d.ts +4 -0
- package/build/es/src/bookings-calendar-v2-session-view.public.js +8 -0
- package/build/es/src/bookings-calendar-v2-session-view.public.js.map +1 -0
- package/build/es/src/bookings-calendar-v2-session-view.types.d.ts +1143 -0
- package/build/es/src/bookings-calendar-v2-session-view.types.js +138 -0
- package/build/es/src/bookings-calendar-v2-session-view.types.js.map +1 -0
- package/build/es/src/bookings-calendar-v2-session-view.universal.d.ts +1150 -0
- package/build/es/src/bookings-calendar-v2-session-view.universal.js +213 -0
- package/build/es/src/bookings-calendar-v2-session-view.universal.js.map +1 -0
- package/build/es/src/bookings-services-v2-service.public.d.ts +1 -1
- package/build/es/src/bookings-services-v2-service.types.d.ts +73 -2
- package/build/es/src/bookings-services-v2-service.types.js.map +1 -1
- package/build/es/src/bookings-services-v2-service.universal.d.ts +73 -2
- package/build/es/src/bookings-services-v2-service.universal.js.map +1 -1
- package/package.json +2 -2
|
@@ -0,0 +1,1150 @@
|
|
|
1
|
+
export declare const __debug: {
|
|
2
|
+
verboseLogging: {
|
|
3
|
+
on: () => boolean;
|
|
4
|
+
off: () => boolean;
|
|
5
|
+
};
|
|
6
|
+
};
|
|
7
|
+
export interface SessionView {
|
|
8
|
+
/**
|
|
9
|
+
* The view end date.
|
|
10
|
+
* @readonly
|
|
11
|
+
*/
|
|
12
|
+
endDate?: Date;
|
|
13
|
+
/** The number of days the view lasts into the future. */
|
|
14
|
+
futureDurationInDays?: number | null;
|
|
15
|
+
/** The view version. */
|
|
16
|
+
version?: number | null;
|
|
17
|
+
}
|
|
18
|
+
export interface SessionViewUpdated extends SessionViewUpdatedTypeOneOf {
|
|
19
|
+
/** Session has been added or updated within the view. */
|
|
20
|
+
sessionAddedOrUpdated?: SessionAddedOrUpdated;
|
|
21
|
+
/** Session has been removed from the view. */
|
|
22
|
+
sessionRemoved?: SessionRemoved;
|
|
23
|
+
}
|
|
24
|
+
/** @oneof */
|
|
25
|
+
export interface SessionViewUpdatedTypeOneOf {
|
|
26
|
+
/** Session has been added or updated within the view. */
|
|
27
|
+
sessionAddedOrUpdated?: SessionAddedOrUpdated;
|
|
28
|
+
/** Session has been removed from the view. */
|
|
29
|
+
sessionRemoved?: SessionRemoved;
|
|
30
|
+
}
|
|
31
|
+
export interface SessionAddedOrUpdated {
|
|
32
|
+
/** The session which was added or updated within the view. */
|
|
33
|
+
session?: Session;
|
|
34
|
+
/** The session previous affected schedule ids. */
|
|
35
|
+
previousAffectedScheduleIds?: string[] | null;
|
|
36
|
+
}
|
|
37
|
+
export interface Session {
|
|
38
|
+
/**
|
|
39
|
+
* Session ID.
|
|
40
|
+
* @readonly
|
|
41
|
+
*/
|
|
42
|
+
_id?: string | null;
|
|
43
|
+
/** ID of the schedule that the session belongs to. */
|
|
44
|
+
scheduleId?: string;
|
|
45
|
+
/**
|
|
46
|
+
* ID of the resource or service that the session's schedule belongs to.
|
|
47
|
+
* @readonly
|
|
48
|
+
*/
|
|
49
|
+
scheduleOwnerId?: string | null;
|
|
50
|
+
/** Original start date and time of the session in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)) format. */
|
|
51
|
+
originalStart?: Date;
|
|
52
|
+
/** An object specifying the start date and time of the session. If the session is a recurring session, `start` must contain a `localDateTime`. */
|
|
53
|
+
start?: CalendarDateTime;
|
|
54
|
+
/**
|
|
55
|
+
* An object specifying the end date and time of the session. The `end` time must be after the `start` time and be same type as `start`.
|
|
56
|
+
* If the session is a recurring session, `end` must contain a `localDateTime`.
|
|
57
|
+
*/
|
|
58
|
+
end?: CalendarDateTime;
|
|
59
|
+
/**
|
|
60
|
+
* An object specifying a list of schedules and the way each schedule's availability is affected by the session. For example, the schedule of an instructor is affected by sessions of the class that they instruct.
|
|
61
|
+
* The array is inherited from the schedule and can be overridden even if the session is a recurring session.
|
|
62
|
+
*/
|
|
63
|
+
affectedSchedules?: LinkedSchedule[];
|
|
64
|
+
/**
|
|
65
|
+
* Session title.
|
|
66
|
+
* The value is inherited from the schedule and can be overridden unless the session is a recurring session.
|
|
67
|
+
*/
|
|
68
|
+
title?: string | null;
|
|
69
|
+
/**
|
|
70
|
+
* Tags for the session.
|
|
71
|
+
* The value is inherited from the schedule and can be overridden unless the session is a recurring session.
|
|
72
|
+
*/
|
|
73
|
+
tags?: string[] | null;
|
|
74
|
+
/**
|
|
75
|
+
* An object describing the location where the session takes place.
|
|
76
|
+
* Defaults to the schedule location.
|
|
77
|
+
* For single sessions, `session.location.businessLocation` can only be provided for locations that are defined in the schedule using `schedule.location` or `schedule.availability.locations`.
|
|
78
|
+
*/
|
|
79
|
+
location?: Location;
|
|
80
|
+
/**
|
|
81
|
+
* Maximum number of participants that can be added to the session. Defaults to the schedule capacity.
|
|
82
|
+
* The value is inherited from the schedule and can be overridden unless the session is a recurring session.
|
|
83
|
+
*/
|
|
84
|
+
capacity?: number | null;
|
|
85
|
+
/**
|
|
86
|
+
* The price options offered for the session. Defaults to the schedule rate.
|
|
87
|
+
* The value is inherited from the schedule and can be overridden unless the session is a recurring session.
|
|
88
|
+
*/
|
|
89
|
+
rate?: Rate;
|
|
90
|
+
/**
|
|
91
|
+
* Time reserved after the session end time, derived from the schedule availability constraints and the time between slots. Read-only.
|
|
92
|
+
* If the session is a recurring session, this field must be empty.
|
|
93
|
+
*/
|
|
94
|
+
timeReservedAfter?: number | null;
|
|
95
|
+
/**
|
|
96
|
+
* Additional information about the session.
|
|
97
|
+
* Notes are not supported for recurring sessions.
|
|
98
|
+
*/
|
|
99
|
+
notes?: string;
|
|
100
|
+
/**
|
|
101
|
+
* The number of participants booked for the session. Read-only.
|
|
102
|
+
* Calculated as the sum of the party sizes.
|
|
103
|
+
* @readonly
|
|
104
|
+
*/
|
|
105
|
+
totalNumberOfParticipants?: number;
|
|
106
|
+
/**
|
|
107
|
+
* List of participants booked for the session.
|
|
108
|
+
* The list includes participants who have registered for this specific session, and participants who have registered for a schedule that includes this session.
|
|
109
|
+
* If the session is a recurring session, this field must be empty.
|
|
110
|
+
*/
|
|
111
|
+
participants?: Participant[];
|
|
112
|
+
/**
|
|
113
|
+
* A list of properties for which values were inherited from the schedule.
|
|
114
|
+
* This does not include participants that were inherited from the schedule.
|
|
115
|
+
* @readonly
|
|
116
|
+
*/
|
|
117
|
+
inheritedFields?: string[];
|
|
118
|
+
/**
|
|
119
|
+
* Title and description values to override session defaults when syncing to an external calendar.
|
|
120
|
+
* Learn more about [syncing calendars](https://support.wix.com/en/article/wix-bookings-important-information-about-syncing-google-calendars-with-wix-bookings).
|
|
121
|
+
* The value is inherited from the schedule and can be overridden unless the session is a recurring session.
|
|
122
|
+
*/
|
|
123
|
+
externalCalendarOverrides?: ExternalCalendarOverrides;
|
|
124
|
+
/**
|
|
125
|
+
* Session status.
|
|
126
|
+
* <!--ONLY:VELO
|
|
127
|
+
* One of:
|
|
128
|
+
* - `"CONFIRMED"` Default value.
|
|
129
|
+
* - `"CANCELLED"` The session was deleted.
|
|
130
|
+
* <!--END:ONLY:VELO-->
|
|
131
|
+
* @readonly
|
|
132
|
+
*/
|
|
133
|
+
status?: Status;
|
|
134
|
+
/**
|
|
135
|
+
* Recurring interval ID. Defined when a session will be a recurring session. read-only. Optional.
|
|
136
|
+
* For exmaple, when creating a class service with recurring sessions, you add a recurrence rule to create recurring sessions.
|
|
137
|
+
* This field is omitted for single sessions or instances of recurring sessions.
|
|
138
|
+
* Specified when the session was originally generated from a schedule recurring interval.
|
|
139
|
+
* Deprecated. Use `recurringSessionId`.
|
|
140
|
+
* @readonly
|
|
141
|
+
*/
|
|
142
|
+
recurringIntervalId?: string | null;
|
|
143
|
+
/**
|
|
144
|
+
* The ID of the recurring session if this session is an instance of a recurrence. Use this ID to update the recurrence and all of the instances.
|
|
145
|
+
* @readonly
|
|
146
|
+
*/
|
|
147
|
+
recurringSessionId?: string | null;
|
|
148
|
+
/**
|
|
149
|
+
* Session type.
|
|
150
|
+
* <!--ONLY:VELO
|
|
151
|
+
* One of:
|
|
152
|
+
* - `"EVENT"` Reserved period of time on the schedule. For example, an appointment, class, course, or blocked time. Events are visible in the Dashboard in the Bookings app's [Booking Calendar](https://support.wix.com/en/article/wix-bookings-about-the-wix-bookings-calendar) page.
|
|
153
|
+
* - `"WORKING_HOURS"` Placeholder for available time on a resource’s schedule.
|
|
154
|
+
* <!--END:ONLY:VELO-->
|
|
155
|
+
*/
|
|
156
|
+
type?: SessionType;
|
|
157
|
+
/**
|
|
158
|
+
* A conference created for the session according to the details set in the schedule's conference provider information.
|
|
159
|
+
* If the session is a recurring session, this field is inherited from the schedule.
|
|
160
|
+
*/
|
|
161
|
+
calendarConference?: CalendarConference;
|
|
162
|
+
/**
|
|
163
|
+
* A string representing a recurrence rule (RRULE) for a recurring session, as defined in [iCalendar RFC 5545](https://icalendar.org/iCalendar-RFC-5545/3-3-10-recurrence-rule.html).
|
|
164
|
+
* If the session is an instance of a recurrence pattern, the `instanceOfRecurrence` property will be contain the recurrence rule and this property will be empty.
|
|
165
|
+
* The RRULE defines a rule for repeating a session.
|
|
166
|
+
* Supported parameters are:
|
|
167
|
+
*
|
|
168
|
+
* |Keyword|Description|Supported values|
|
|
169
|
+
* |--|--|---|
|
|
170
|
+
* |`FREQ`|The frequency at which the session is recurs. Required.|`WEEKLY`|
|
|
171
|
+
* |`INTERVAL`|How often, in terms of `FREQ`, the session recurs. Default is 1. Optional.|
|
|
172
|
+
* |`UNTIL`|The UTC end date and time of the recurrence. Optional.|
|
|
173
|
+
* |`BYDAY`|Day of the week when the event should recur. Required.|One of: `MO`, `TU`, `WE`, `TH`, `FR`, `SA`, `SU`|
|
|
174
|
+
*
|
|
175
|
+
*
|
|
176
|
+
* For example, a session that repeats every second week on a Monday until January 7, 2022 at 8 AM:
|
|
177
|
+
* `"FREQ=WEEKLY;INTERVAL=2;BYDAY=MO;UNTIL=20220107T080000Z"`
|
|
178
|
+
*
|
|
179
|
+
* <!--ORIGINAL COMMENTS:
|
|
180
|
+
* `FREQ` — The frequency with which the session should be repeated (such as DAILY or WEEKLY).
|
|
181
|
+
* Supported `WEEKLY` value is supported.
|
|
182
|
+
* INTERVAL — Works together with FREQ to specify how often the session should be repeated. For example, FREQ=WEEKLY;INTERVAL=2 means once every two weeks. Optional. Default value is 1.
|
|
183
|
+
* COUNT — The number of times this event should be repeated. Not yet supported.
|
|
184
|
+
* UNTIL — The UTC date & time until which the session should be repeated. This parameter is optional. When it is not specified, the event repeats forever.
|
|
185
|
+
* The format is a short ISO date, followed by 'T' and a short time with seconds and without milliseconds, terminated by the UTC designator 'Z'. For example, until Jan. 19th 2018 at 7:00 AM: 'UNTIL=20180119T070000Z'.
|
|
186
|
+
* BYDAY - The days of the week when the event should be repeated. Currently, only a single day is supported. This parameter is mandatory.
|
|
187
|
+
* Possible values are: MO, TU, WE, TH, FR, SA, SU
|
|
188
|
+
* Note that DTSTART and DTEND lines are not allowed in this field; session start and end times are specified in the start and end fields.
|
|
189
|
+
* **Example**: FREQ=WEEKLY;INTERVAL=2;BYDAY=MO;UNTIL=20200427T070000Z
|
|
190
|
+
* ORIGINAL COMMENTS-->
|
|
191
|
+
*/
|
|
192
|
+
recurrence?: string | null;
|
|
193
|
+
/**
|
|
194
|
+
* A string representing a recurrence rule (RRULE) if the session is an instance of a recurrence pattern.
|
|
195
|
+
* Empty when the session is not an instance of a recurrence rule, or if the session defines a recurrence pattern, and `recurrence` is not empty.
|
|
196
|
+
* @readonly
|
|
197
|
+
*/
|
|
198
|
+
instanceOfRecurrence?: string | null;
|
|
199
|
+
/**
|
|
200
|
+
* The session version.
|
|
201
|
+
* Composed by the schedule, session and participants versions.
|
|
202
|
+
* @readonly
|
|
203
|
+
*/
|
|
204
|
+
version?: SessionVersion;
|
|
205
|
+
}
|
|
206
|
+
export interface CalendarDateTime {
|
|
207
|
+
/**
|
|
208
|
+
* UTC date-time in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601#Coordinated_Universal_Time_(UTC)) format. If a time zone offset is specified, the time is converted to UTC. For example, if you specify `new Date('2021-01-06T16:00:00.000-07:00')`, the stored value will be `"2021-01-06T23:00:00.000Z"`.
|
|
209
|
+
* Required if `localDateTime` is not specified.
|
|
210
|
+
* If `localDateTime` is specified, `timestamp` is calculated as `localDateTime`, using the business's time zone.
|
|
211
|
+
*/
|
|
212
|
+
timestamp?: Date;
|
|
213
|
+
/** An object containing the local date and time for the business's time zone. */
|
|
214
|
+
localDateTime?: LocalDateTime;
|
|
215
|
+
/**
|
|
216
|
+
* The time zone. Optional. Derived from the schedule's time zone.
|
|
217
|
+
* In case this field is associated with recurring session, this field is empty.
|
|
218
|
+
* @readonly
|
|
219
|
+
*/
|
|
220
|
+
timeZone?: string | null;
|
|
221
|
+
}
|
|
222
|
+
export interface LocalDateTime {
|
|
223
|
+
/** Year. 4-digit format. */
|
|
224
|
+
year?: number | null;
|
|
225
|
+
/** Month number, from 1-12. */
|
|
226
|
+
monthOfYear?: number | null;
|
|
227
|
+
/** Day of the month, from 1-31. */
|
|
228
|
+
dayOfMonth?: number | null;
|
|
229
|
+
/** Hour of the day in 24-hour format, from 0-23. */
|
|
230
|
+
hourOfDay?: number | null;
|
|
231
|
+
/** Minute, from 0-59. */
|
|
232
|
+
minutesOfHour?: number | null;
|
|
233
|
+
}
|
|
234
|
+
export interface LinkedSchedule {
|
|
235
|
+
/** Schedule ID. */
|
|
236
|
+
scheduleId?: string;
|
|
237
|
+
/**
|
|
238
|
+
* Sets this schedule's availability for the duration of the linked schedule's sessions. Default is `"BUSY"`.
|
|
239
|
+
* <!--ONLY:REST-->
|
|
240
|
+
* If set to `"BUSY"`, this schedule cannot have any available slots during the linked schedule's sessions.
|
|
241
|
+
* If set to `"FREE"`, this schedule can have available slots during the linked schedule's sessions.
|
|
242
|
+
* <!--END:ONLY:REST-->
|
|
243
|
+
*
|
|
244
|
+
* <!--ONLY:VELO
|
|
245
|
+
* One of:
|
|
246
|
+
* - `"FREE"` This schedule can have available slots during the linked schedule's sessions.
|
|
247
|
+
* - `"BUSY"` This schedule cannot have any available slots during the linked schedule's sessions.
|
|
248
|
+
* <!--END:ONLY:VELO-->
|
|
249
|
+
*/
|
|
250
|
+
transparency?: Transparency;
|
|
251
|
+
/**
|
|
252
|
+
* Owner ID, of the linked schedule.
|
|
253
|
+
* @readonly
|
|
254
|
+
*/
|
|
255
|
+
scheduleOwnerId?: string;
|
|
256
|
+
}
|
|
257
|
+
export declare enum Transparency {
|
|
258
|
+
UNDEFINED = "UNDEFINED",
|
|
259
|
+
/** The schedule can have available slots during the session. */
|
|
260
|
+
FREE = "FREE",
|
|
261
|
+
/** The schedule cannot have available slots during the session. Default value. */
|
|
262
|
+
BUSY = "BUSY"
|
|
263
|
+
}
|
|
264
|
+
export interface Location {
|
|
265
|
+
/**
|
|
266
|
+
* Location type.
|
|
267
|
+
* One of:
|
|
268
|
+
* - `"OWNER_BUSINESS"` The business address as set in the site’s general settings.
|
|
269
|
+
* - `"OWNER_CUSTOM"` The address as set when creating the service.
|
|
270
|
+
* - `"CUSTOM"` The address set for the individual session.
|
|
271
|
+
*/
|
|
272
|
+
locationType?: LocationType;
|
|
273
|
+
/** Free text address used when locationType is `OWNER_CUSTOM`. */
|
|
274
|
+
address?: string | null;
|
|
275
|
+
/** Custom address, used when locationType is `"OWNER_CUSTOM"`. Might be used when locationType is `"CUSTOM"` in case the owner sets a custom address for the session which is different from the default. */
|
|
276
|
+
customAddress?: Address;
|
|
277
|
+
/**
|
|
278
|
+
* Valid when `locationType` is `OWNER_BUSINESS`. Defaults to the business's location.
|
|
279
|
+
*
|
|
280
|
+
* `businessSchedule` is not supported by Wix Bookings
|
|
281
|
+
*/
|
|
282
|
+
businessLocation?: LocationsLocation;
|
|
283
|
+
}
|
|
284
|
+
export declare enum LocationType {
|
|
285
|
+
UNDEFINED = "UNDEFINED",
|
|
286
|
+
OWNER_BUSINESS = "OWNER_BUSINESS",
|
|
287
|
+
OWNER_CUSTOM = "OWNER_CUSTOM",
|
|
288
|
+
CUSTOM = "CUSTOM"
|
|
289
|
+
}
|
|
290
|
+
/** Physical address */
|
|
291
|
+
export interface Address extends AddressStreetOneOf {
|
|
292
|
+
/** Country code. */
|
|
293
|
+
country?: string | null;
|
|
294
|
+
/** Subdivision. Usually state, region, prefecture or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */
|
|
295
|
+
subdivision?: string | null;
|
|
296
|
+
/** City name. */
|
|
297
|
+
city?: string | null;
|
|
298
|
+
/** Zip/postal code. */
|
|
299
|
+
postalCode?: string | null;
|
|
300
|
+
/** Free text providing more detailed address info. Usually contains Apt, Suite, and Floor. */
|
|
301
|
+
addressLine2?: string | null;
|
|
302
|
+
/** A string containing the full address of this location. */
|
|
303
|
+
formattedAddress?: string | null;
|
|
304
|
+
/** Free text to help find the address. */
|
|
305
|
+
hint?: string | null;
|
|
306
|
+
/** Coordinates of the physical address. */
|
|
307
|
+
geocode?: AddressLocation;
|
|
308
|
+
/** Country full name. */
|
|
309
|
+
countryFullname?: string | null;
|
|
310
|
+
/** Multi-level subdivisions from top to bottom. */
|
|
311
|
+
subdivisions?: Subdivision[];
|
|
312
|
+
/** Street name, number and apartment number. */
|
|
313
|
+
streetAddress?: StreetAddress;
|
|
314
|
+
/** Main address line, usually street and number, as free text. */
|
|
315
|
+
addressLine?: string | null;
|
|
316
|
+
}
|
|
317
|
+
/** @oneof */
|
|
318
|
+
export interface AddressStreetOneOf {
|
|
319
|
+
/** Street name, number and apartment number. */
|
|
320
|
+
streetAddress?: StreetAddress;
|
|
321
|
+
/** Main address line, usually street and number, as free text. */
|
|
322
|
+
addressLine?: string | null;
|
|
323
|
+
}
|
|
324
|
+
export interface StreetAddress {
|
|
325
|
+
/** Street number. */
|
|
326
|
+
number?: string;
|
|
327
|
+
/** Street name. */
|
|
328
|
+
name?: string;
|
|
329
|
+
/** Apartment number. */
|
|
330
|
+
apt?: string;
|
|
331
|
+
}
|
|
332
|
+
export interface AddressLocation {
|
|
333
|
+
/** Address latitude. */
|
|
334
|
+
latitude?: number | null;
|
|
335
|
+
/** Address longitude. */
|
|
336
|
+
longitude?: number | null;
|
|
337
|
+
}
|
|
338
|
+
export interface Subdivision {
|
|
339
|
+
/** Subdivision code. Usually state, region, prefecture or province code, according to [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2). */
|
|
340
|
+
code?: string;
|
|
341
|
+
/** Subdivision full name. */
|
|
342
|
+
name?: string;
|
|
343
|
+
}
|
|
344
|
+
export interface LocationsLocation {
|
|
345
|
+
/**
|
|
346
|
+
* Location ID.
|
|
347
|
+
* @readonly
|
|
348
|
+
*/
|
|
349
|
+
_id?: string | null;
|
|
350
|
+
/** Location name. */
|
|
351
|
+
name?: string;
|
|
352
|
+
/** Location description. */
|
|
353
|
+
description?: string | null;
|
|
354
|
+
/**
|
|
355
|
+
* Whether this is the default location. There can only be one default location per site. The default location can't be archived.
|
|
356
|
+
* @readonly
|
|
357
|
+
*/
|
|
358
|
+
default?: boolean;
|
|
359
|
+
/**
|
|
360
|
+
* Location status. Defaults to `ACTIVE`.
|
|
361
|
+
* __Note:__ [Archiving a location](https://dev.wix.com/api/rest/business-info/locations/archive-location)
|
|
362
|
+
* doesn't affect the location's status. `INACTIVE` is currently not supported.
|
|
363
|
+
*/
|
|
364
|
+
status?: LocationStatus;
|
|
365
|
+
/** Location type. **Note:** Currently not supported. */
|
|
366
|
+
locationType?: LocationsLocationType;
|
|
367
|
+
/** Fax number. */
|
|
368
|
+
fax?: string | null;
|
|
369
|
+
/** Timezone in `America/New_York` format. */
|
|
370
|
+
timeZone?: string | null;
|
|
371
|
+
/** Email address. */
|
|
372
|
+
email?: string | null;
|
|
373
|
+
/** Phone number. */
|
|
374
|
+
phone?: string | null;
|
|
375
|
+
/** Address. */
|
|
376
|
+
address?: LocationsAddress;
|
|
377
|
+
/**
|
|
378
|
+
* Business schedule. Array of weekly recurring time periods when the location is open for business. Limited to 100 time periods.
|
|
379
|
+
*
|
|
380
|
+
* __Note:__ Not supported by Wix Bookings.
|
|
381
|
+
*/
|
|
382
|
+
businessSchedule?: BusinessSchedule;
|
|
383
|
+
/**
|
|
384
|
+
* Revision number, which increments by 1 each time the location is updated.
|
|
385
|
+
* To prevent conflicting changes, the existing revision must be used when updating a location.
|
|
386
|
+
*/
|
|
387
|
+
revision?: string | null;
|
|
388
|
+
/**
|
|
389
|
+
* Whether the location is archived. Archived locations can't be updated.
|
|
390
|
+
* __Note:__ [Archiving a location](https://dev.wix.com/api/rest/business-info/locations/archive-location)
|
|
391
|
+
* doesn't affect its `status`.
|
|
392
|
+
* @readonly
|
|
393
|
+
*/
|
|
394
|
+
archived?: boolean;
|
|
395
|
+
}
|
|
396
|
+
/** For future use */
|
|
397
|
+
export declare enum LocationStatus {
|
|
398
|
+
ACTIVE = "ACTIVE",
|
|
399
|
+
INACTIVE = "INACTIVE"
|
|
400
|
+
}
|
|
401
|
+
/** For future use */
|
|
402
|
+
export declare enum LocationsLocationType {
|
|
403
|
+
UNKNOWN = "UNKNOWN",
|
|
404
|
+
BRANCH = "BRANCH",
|
|
405
|
+
OFFICES = "OFFICES",
|
|
406
|
+
RECEPTION = "RECEPTION",
|
|
407
|
+
HEADQUARTERS = "HEADQUARTERS"
|
|
408
|
+
}
|
|
409
|
+
export interface LocationsAddress {
|
|
410
|
+
/** 2-letter country code in an [ISO-3166 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format. */
|
|
411
|
+
country?: string | null;
|
|
412
|
+
/** Code for a subdivision (such as state, prefecture, or province) in [ISO 3166-2](https://en.wikipedia.org/wiki/ISO_3166-2) format. */
|
|
413
|
+
subdivision?: string | null;
|
|
414
|
+
/** City name. */
|
|
415
|
+
city?: string | null;
|
|
416
|
+
/** Postal or zip code. */
|
|
417
|
+
postalCode?: string | null;
|
|
418
|
+
/** Street address. Includes street name, number, and apartment number in separate fields. */
|
|
419
|
+
streetAddress?: LocationsStreetAddress;
|
|
420
|
+
}
|
|
421
|
+
/** Street address. Includes street name, number, and apartment number in separate fields. */
|
|
422
|
+
export interface LocationsStreetAddress {
|
|
423
|
+
/** Street number. */
|
|
424
|
+
number?: string;
|
|
425
|
+
/** Street name. */
|
|
426
|
+
name?: string;
|
|
427
|
+
/** Apartment number. */
|
|
428
|
+
apt?: string;
|
|
429
|
+
}
|
|
430
|
+
/** Address Geolocation */
|
|
431
|
+
export interface LocationsAddressLocation {
|
|
432
|
+
/** Latitude of the location. Must be between -90 and 90. */
|
|
433
|
+
latitude?: number | null;
|
|
434
|
+
/** Longitude of the location. Must be between -180 and 180. */
|
|
435
|
+
longitude?: number | null;
|
|
436
|
+
}
|
|
437
|
+
/** Business schedule. Regular and exceptional time periods when the business is open or the service is available. */
|
|
438
|
+
export interface BusinessSchedule {
|
|
439
|
+
/** Weekly recurring time periods when the business is regularly open or the service is available. Limited to 100 time periods. */
|
|
440
|
+
periods?: TimePeriod[];
|
|
441
|
+
/** Exceptions to the business's regular hours. The business can be open or closed during the exception. */
|
|
442
|
+
specialHourPeriod?: SpecialHourPeriod[];
|
|
443
|
+
}
|
|
444
|
+
/** Weekly recurring time periods when the business is regularly open or the service is available. */
|
|
445
|
+
export interface TimePeriod {
|
|
446
|
+
/** Day of the week the period starts on. */
|
|
447
|
+
openDay?: DayOfWeek;
|
|
448
|
+
/**
|
|
449
|
+
* Time the period starts in 24-hour [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) extended format. Valid values are `00:00` to `24:00`, where `24:00` represents
|
|
450
|
+
* midnight at the end of the specified day.
|
|
451
|
+
*/
|
|
452
|
+
openTime?: string;
|
|
453
|
+
/** Day of the week the period ends on. */
|
|
454
|
+
closeDay?: DayOfWeek;
|
|
455
|
+
/**
|
|
456
|
+
* Time the period ends in 24-hour [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) extended format. Valid values are `00:00` to `24:00`, where `24:00` represents
|
|
457
|
+
* midnight at the end of the specified day.
|
|
458
|
+
*
|
|
459
|
+
* __Note:__ If `openDay` and `closeDay` specify the same day of the week `closeTime` must be later than `openTime`.
|
|
460
|
+
*/
|
|
461
|
+
closeTime?: string;
|
|
462
|
+
}
|
|
463
|
+
/** Enumerates the days of the week. */
|
|
464
|
+
export declare enum DayOfWeek {
|
|
465
|
+
MONDAY = "MONDAY",
|
|
466
|
+
TUESDAY = "TUESDAY",
|
|
467
|
+
WEDNESDAY = "WEDNESDAY",
|
|
468
|
+
THURSDAY = "THURSDAY",
|
|
469
|
+
FRIDAY = "FRIDAY",
|
|
470
|
+
SATURDAY = "SATURDAY",
|
|
471
|
+
SUNDAY = "SUNDAY"
|
|
472
|
+
}
|
|
473
|
+
/** Exception to the business's regular hours. The business can be open or closed during the exception. */
|
|
474
|
+
export interface SpecialHourPeriod {
|
|
475
|
+
/** Start date and time of the exception in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format and [Coordinated Universal Time (UTC)](https://en.wikipedia.org/wiki/Coordinated_Universal_Time). */
|
|
476
|
+
startDate?: string;
|
|
477
|
+
/** End date and time of the exception in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format and [Coordinated Universal Time (UTC)](https://en.wikipedia.org/wiki/Coordinated_Universal_Time). */
|
|
478
|
+
endDate?: string;
|
|
479
|
+
/**
|
|
480
|
+
* Whether the business is closed (or the service is not available) during the exception.
|
|
481
|
+
*
|
|
482
|
+
* Default: `true`.
|
|
483
|
+
*/
|
|
484
|
+
isClosed?: boolean;
|
|
485
|
+
/** Additional info about the exception. For example, "We close earlier on New Year's Eve." */
|
|
486
|
+
comment?: string;
|
|
487
|
+
}
|
|
488
|
+
export interface Rate {
|
|
489
|
+
/**
|
|
490
|
+
* Mapping between a named price option, for example, adult or child prices, and the price, currency, and down payment amount.
|
|
491
|
+
* When present in an update request, the `default_varied_price` is ignored to support backward compatibility.
|
|
492
|
+
*/
|
|
493
|
+
labeledPriceOptions?: Record<string, Price>;
|
|
494
|
+
/**
|
|
495
|
+
* Textual price information used when **Price Per Session** is set to **Custom Price** in the app's service details page.
|
|
496
|
+
* When present in an update request, the `default_varied_price` is ignored to support backward compatibility.
|
|
497
|
+
*/
|
|
498
|
+
priceText?: string | null;
|
|
499
|
+
}
|
|
500
|
+
export interface Price {
|
|
501
|
+
/** Required payment amount. */
|
|
502
|
+
amount?: string;
|
|
503
|
+
/** Currency in which the amount is quoted. */
|
|
504
|
+
currency?: string;
|
|
505
|
+
/** Amount of a down payment or deposit as part of the transaction. */
|
|
506
|
+
downPayAmount?: string;
|
|
507
|
+
}
|
|
508
|
+
export interface Participant {
|
|
509
|
+
/** Participant ID. Currently represents the booking.id. */
|
|
510
|
+
_id?: string;
|
|
511
|
+
/** Contact ID. */
|
|
512
|
+
contactId?: string | null;
|
|
513
|
+
/** Participant's name. */
|
|
514
|
+
name?: string | null;
|
|
515
|
+
/** Participant's phone number. */
|
|
516
|
+
phone?: string | null;
|
|
517
|
+
/** Participant's email address. */
|
|
518
|
+
email?: string | null;
|
|
519
|
+
/** Group or party size. The number of people attending. Defaults to 0. Maximum is 250. */
|
|
520
|
+
partySize?: number;
|
|
521
|
+
/**
|
|
522
|
+
* Approval status for the participant.
|
|
523
|
+
* <!-- Commented out untill updateParticipant is exposed Generally the same status as the booking, unless updated using the `updateParticipant()` API. Defaults to `"UNDEFINED"`.-->
|
|
524
|
+
* <!--ONLY:VELO
|
|
525
|
+
* One of:
|
|
526
|
+
* - `"PENDING"` Pending business approval.
|
|
527
|
+
* - `"APPROVED"` Approved by the business.
|
|
528
|
+
* - `"DECLINED"` Declined by the business.
|
|
529
|
+
* <!--END:ONLY:VELO-->
|
|
530
|
+
*/
|
|
531
|
+
approvalStatus?: ApprovalStatus;
|
|
532
|
+
/**
|
|
533
|
+
* Whether the participant was inherited from the schedule, as opposed to being booked directly to the session.
|
|
534
|
+
* @readonly
|
|
535
|
+
*/
|
|
536
|
+
inherited?: boolean;
|
|
537
|
+
}
|
|
538
|
+
export declare enum ApprovalStatus {
|
|
539
|
+
/** Default. */
|
|
540
|
+
UNDEFINED = "UNDEFINED",
|
|
541
|
+
/** Pending business approval. */
|
|
542
|
+
PENDING = "PENDING",
|
|
543
|
+
/** Approved by the business. */
|
|
544
|
+
APPROVED = "APPROVED",
|
|
545
|
+
/** Declined by the business. */
|
|
546
|
+
DECLINED = "DECLINED"
|
|
547
|
+
}
|
|
548
|
+
export interface ExternalCalendarInfo {
|
|
549
|
+
/** The external calendar type (e.g. Google Calendar, iCal, etc). */
|
|
550
|
+
calendarType?: CalendarType;
|
|
551
|
+
}
|
|
552
|
+
export declare enum CalendarType {
|
|
553
|
+
UNDEFINED = "UNDEFINED",
|
|
554
|
+
GOOGLE = "GOOGLE",
|
|
555
|
+
I_CAL = "I_CAL",
|
|
556
|
+
/** Use `MICROSOFT` instead. */
|
|
557
|
+
OUTLOOK = "OUTLOOK",
|
|
558
|
+
/** Use `MICROSOFT` instead. */
|
|
559
|
+
OFFICE_365 = "OFFICE_365",
|
|
560
|
+
MICROSOFT = "MICROSOFT",
|
|
561
|
+
OTHER = "OTHER"
|
|
562
|
+
}
|
|
563
|
+
export interface ExternalCalendarOverrides {
|
|
564
|
+
/** Synced title of the external calendar event. */
|
|
565
|
+
title?: string | null;
|
|
566
|
+
/** Synced description of the external calendar event. */
|
|
567
|
+
description?: string | null;
|
|
568
|
+
}
|
|
569
|
+
export declare enum Status {
|
|
570
|
+
UNDEFINED = "UNDEFINED",
|
|
571
|
+
/** The session is confirmed. Default status. */
|
|
572
|
+
CONFIRMED = "CONFIRMED",
|
|
573
|
+
/**
|
|
574
|
+
* The session is cancelled.
|
|
575
|
+
* A cancelled session can be the cancellation of a recurring session that should no longer be displayed or a deleted single session.
|
|
576
|
+
* The ListSessions returns cancelled sessions only if 'includeDelete' flag is set to true.
|
|
577
|
+
*/
|
|
578
|
+
CANCELLED = "CANCELLED"
|
|
579
|
+
}
|
|
580
|
+
export declare enum SessionType {
|
|
581
|
+
UNDEFINED = "UNDEFINED",
|
|
582
|
+
/**
|
|
583
|
+
* The session creates an event on the calendar for the owner of the schedule that the session belongs to.
|
|
584
|
+
* Default type.
|
|
585
|
+
*/
|
|
586
|
+
EVENT = "EVENT",
|
|
587
|
+
/** The session represents a resource's available working hours. */
|
|
588
|
+
WORKING_HOURS = "WORKING_HOURS",
|
|
589
|
+
/** Deprecated. please use WORKING_HOURS */
|
|
590
|
+
TIME_AVAILABILITY = "TIME_AVAILABILITY",
|
|
591
|
+
/** Deprecated. The session represents a resource's available hours. please use WORKING_HOURS */
|
|
592
|
+
AVAILABILITY = "AVAILABILITY"
|
|
593
|
+
}
|
|
594
|
+
export interface CalendarConference {
|
|
595
|
+
/** Wix Calendar conference ID. */
|
|
596
|
+
_id?: string;
|
|
597
|
+
/** Conference meeting ID in the provider's conferencing system. */
|
|
598
|
+
externalId?: string;
|
|
599
|
+
/** Conference provider ID. */
|
|
600
|
+
providerId?: string;
|
|
601
|
+
/** URL used by the host to start the conference. */
|
|
602
|
+
hostUrl?: string;
|
|
603
|
+
/** URL used by a guest to join the conference. */
|
|
604
|
+
guestUrl?: string;
|
|
605
|
+
/** Password to join the conference. */
|
|
606
|
+
password?: string | null;
|
|
607
|
+
/** Conference description. */
|
|
608
|
+
description?: string | null;
|
|
609
|
+
/**
|
|
610
|
+
* Conference type.
|
|
611
|
+
* <!--ONLY:VELO
|
|
612
|
+
* One of:
|
|
613
|
+
* - `"ONLINE_MEETING_PROVIDER"` API-generated online meeting.
|
|
614
|
+
* - `"CUSTOM"` User-defined meeting.
|
|
615
|
+
* <!--END:ONLY:VELO-->
|
|
616
|
+
*/
|
|
617
|
+
conferenceType?: ConferenceType;
|
|
618
|
+
/** ID of the account owner in the video conferencing service. */
|
|
619
|
+
accountOwnerId?: string | null;
|
|
620
|
+
}
|
|
621
|
+
export declare enum ConferenceType {
|
|
622
|
+
UNDEFINED = "UNDEFINED",
|
|
623
|
+
/** API-generated online meeting. */
|
|
624
|
+
ONLINE_MEETING_PROVIDER = "ONLINE_MEETING_PROVIDER",
|
|
625
|
+
/** User-defined meeting. */
|
|
626
|
+
CUSTOM = "CUSTOM"
|
|
627
|
+
}
|
|
628
|
+
export interface SessionVersion {
|
|
629
|
+
/** Incremental version number, which is updated on each change to the session or on changes affecting the session. */
|
|
630
|
+
number?: string | null;
|
|
631
|
+
}
|
|
632
|
+
export interface SessionRemoved {
|
|
633
|
+
/** The removed session id. */
|
|
634
|
+
sessionId?: string | null;
|
|
635
|
+
/** The schedule id of the removed session. */
|
|
636
|
+
scheduleId?: string | null;
|
|
637
|
+
/** The affected schedule ids of the removed session. */
|
|
638
|
+
affectedScheduleIds?: string[] | null;
|
|
639
|
+
/** The session version number. */
|
|
640
|
+
sessionVersionNumber?: string | null;
|
|
641
|
+
}
|
|
642
|
+
export interface SessionViewExtended {
|
|
643
|
+
/** The extended session view end date. */
|
|
644
|
+
extendedSessionViewEndDate?: Date;
|
|
645
|
+
}
|
|
646
|
+
export interface FeedEvent extends FeedEventTypeOneOf {
|
|
647
|
+
/** Session has been added or updated within the feed window. */
|
|
648
|
+
sessionAddedOrUpdated?: SessionAddedOrUpdated;
|
|
649
|
+
/** Session has been removed from the feed. */
|
|
650
|
+
sessionRemoved?: SessionRemoved;
|
|
651
|
+
/** The feed window has been extended. */
|
|
652
|
+
windowExtended?: WindowExtended;
|
|
653
|
+
}
|
|
654
|
+
/** @oneof */
|
|
655
|
+
export interface FeedEventTypeOneOf {
|
|
656
|
+
/** Session has been added or updated within the feed window. */
|
|
657
|
+
sessionAddedOrUpdated?: SessionAddedOrUpdated;
|
|
658
|
+
/** Session has been removed from the feed. */
|
|
659
|
+
sessionRemoved?: SessionRemoved;
|
|
660
|
+
/** The feed window has been extended. */
|
|
661
|
+
windowExtended?: WindowExtended;
|
|
662
|
+
}
|
|
663
|
+
export interface WindowExtended {
|
|
664
|
+
/** The updated window end date. */
|
|
665
|
+
windowEndDate?: Date;
|
|
666
|
+
}
|
|
667
|
+
/** Deprecated. Please use `window_extended` instead. */
|
|
668
|
+
export interface WindowMoved {
|
|
669
|
+
/** The updated window edge. */
|
|
670
|
+
edge?: Date;
|
|
671
|
+
/** The window version. */
|
|
672
|
+
windowVersion?: number | null;
|
|
673
|
+
}
|
|
674
|
+
export interface GetSessionViewRequest {
|
|
675
|
+
}
|
|
676
|
+
export interface GetSessionViewResponse {
|
|
677
|
+
/** The sessions view. */
|
|
678
|
+
sessionView?: SessionView;
|
|
679
|
+
}
|
|
680
|
+
export interface ExtendSessionViewRequest {
|
|
681
|
+
/**
|
|
682
|
+
* The number of days the view lasts into the future.
|
|
683
|
+
* Must be greater than the current value.
|
|
684
|
+
*/
|
|
685
|
+
futureDurationInDays?: number | null;
|
|
686
|
+
}
|
|
687
|
+
export interface ExtendSessionViewResponse {
|
|
688
|
+
/** The updated sessions view. */
|
|
689
|
+
sessionView?: SessionView;
|
|
690
|
+
}
|
|
691
|
+
export interface ReplayRequest {
|
|
692
|
+
/** The replay id. Required. */
|
|
693
|
+
replayId?: string | null;
|
|
694
|
+
/** The date to replay sessions from. Required. */
|
|
695
|
+
from?: Date;
|
|
696
|
+
/** Filter by either `session.schedule_id` or `session.affectedSchedules[*].scheduleId`. Optional. */
|
|
697
|
+
affectedScheduleId?: string | null;
|
|
698
|
+
}
|
|
699
|
+
export interface ReplayResponse {
|
|
700
|
+
/** The feed window. */
|
|
701
|
+
window?: Window;
|
|
702
|
+
}
|
|
703
|
+
export interface Window {
|
|
704
|
+
/**
|
|
705
|
+
* The window end date.
|
|
706
|
+
* @readonly
|
|
707
|
+
*/
|
|
708
|
+
endDate?: Date;
|
|
709
|
+
/** The number of days the window lasts into the future. */
|
|
710
|
+
futureDurationInDays?: number | null;
|
|
711
|
+
/** The window version. */
|
|
712
|
+
version?: number | null;
|
|
713
|
+
}
|
|
714
|
+
export interface FeedReplayEvent extends FeedReplayEventTypeOneOf {
|
|
715
|
+
replayId?: string | null;
|
|
716
|
+
/** Session has been added within the feed window. */
|
|
717
|
+
sessionAdded?: SessionAdded;
|
|
718
|
+
/** Sessions replay completed. */
|
|
719
|
+
replayCompleted?: ReplayCompleted;
|
|
720
|
+
}
|
|
721
|
+
/** @oneof */
|
|
722
|
+
export interface FeedReplayEventTypeOneOf {
|
|
723
|
+
/** Session has been added within the feed window. */
|
|
724
|
+
sessionAdded?: SessionAdded;
|
|
725
|
+
/** Sessions replay completed. */
|
|
726
|
+
replayCompleted?: ReplayCompleted;
|
|
727
|
+
}
|
|
728
|
+
export interface SessionAdded {
|
|
729
|
+
/** The session which was added within the feed window. */
|
|
730
|
+
session?: Session;
|
|
731
|
+
}
|
|
732
|
+
export interface ReplayCompleted {
|
|
733
|
+
/** The (minimum) number of sessions that were replayed. */
|
|
734
|
+
totalSessions?: number | null;
|
|
735
|
+
}
|
|
736
|
+
export interface ScheduleNotification extends ScheduleNotificationEventOneOf {
|
|
737
|
+
preserveFutureSessionsWithParticipants?: boolean | null;
|
|
738
|
+
/** Whether to notify participants about changed sessions. deprecated, use participant_notification */
|
|
739
|
+
notifyParticipants?: boolean;
|
|
740
|
+
/** site properties. Optional. Given in create schedule notification. */
|
|
741
|
+
siteProperties?: SitePropertiesOnScheduleCreation;
|
|
742
|
+
instanceId?: string;
|
|
743
|
+
scheduleCreated?: ScheduleCreated;
|
|
744
|
+
scheduleUpdated?: ScheduleUpdated;
|
|
745
|
+
scheduleCancelled?: ScheduleCancelled;
|
|
746
|
+
sessionCreated?: SessionCreated;
|
|
747
|
+
sessionUpdated?: SessionUpdated;
|
|
748
|
+
sessionCancelled?: SessionCancelled;
|
|
749
|
+
availabilityPolicyUpdated?: AvailabilityPolicyUpdated;
|
|
750
|
+
intervalSplit?: IntervalSplit;
|
|
751
|
+
recurringSessionSplit?: RecurringSessionSplit;
|
|
752
|
+
/** Inspect `schedule.scheduleOwnerUserId` on `scheduleUpdated` instead. */
|
|
753
|
+
scheduleUnassignedFromUser?: ScheduleUnassignedFromUser;
|
|
754
|
+
/** supported only for schedule migration apis. */
|
|
755
|
+
multipleSessionsCreated?: MultipleSessionsCreated;
|
|
756
|
+
/** supported only for schedule migration apis. */
|
|
757
|
+
migrationEvent?: MigrationEvent;
|
|
758
|
+
}
|
|
759
|
+
/** @oneof */
|
|
760
|
+
export interface ScheduleNotificationEventOneOf {
|
|
761
|
+
scheduleCreated?: ScheduleCreated;
|
|
762
|
+
scheduleUpdated?: ScheduleUpdated;
|
|
763
|
+
scheduleCancelled?: ScheduleCancelled;
|
|
764
|
+
sessionCreated?: SessionCreated;
|
|
765
|
+
sessionUpdated?: SessionUpdated;
|
|
766
|
+
sessionCancelled?: SessionCancelled;
|
|
767
|
+
availabilityPolicyUpdated?: AvailabilityPolicyUpdated;
|
|
768
|
+
intervalSplit?: IntervalSplit;
|
|
769
|
+
recurringSessionSplit?: RecurringSessionSplit;
|
|
770
|
+
/** Inspect `schedule.scheduleOwnerUserId` on `scheduleUpdated` instead. */
|
|
771
|
+
scheduleUnassignedFromUser?: ScheduleUnassignedFromUser;
|
|
772
|
+
/** supported only for schedule migration apis. */
|
|
773
|
+
multipleSessionsCreated?: MultipleSessionsCreated;
|
|
774
|
+
/** supported only for schedule migration apis. */
|
|
775
|
+
migrationEvent?: MigrationEvent;
|
|
776
|
+
}
|
|
777
|
+
export interface ScheduleCreated {
|
|
778
|
+
schedule?: Schedule;
|
|
779
|
+
}
|
|
780
|
+
export interface Schedule {
|
|
781
|
+
/** Schedule ID. */
|
|
782
|
+
_id?: string;
|
|
783
|
+
/** ID of the schedule's owner entity. This may be a resource ID or a service ID. */
|
|
784
|
+
scheduleOwnerId?: string | null;
|
|
785
|
+
timeZone?: string | null;
|
|
786
|
+
/**
|
|
787
|
+
* Specifies the intervals for the sessions calculation. Optional. e.g. when creating class service you can add
|
|
788
|
+
* pattern for recurring intervals, these intervals can be returned as schedule's sessions or available slots if
|
|
789
|
+
* there are no other availability calculation constraints and the capacity is bigger then the current total number of sessions' participants.
|
|
790
|
+
*/
|
|
791
|
+
intervals?: RecurringInterval[];
|
|
792
|
+
/** Default title for the schedule's sessions. Maximum length: 6000 characters. */
|
|
793
|
+
title?: string | null;
|
|
794
|
+
/**
|
|
795
|
+
* Tags for grouping schedules. These tags are the default tags for the schedule's sessions.
|
|
796
|
+
* The Wix Bookings app uses the following predefined tags to set schedule type: `"INDIVIDUAL"`, `"GROUP"`, and `"COURSE"`. Once the schedule type is set using these tags, you cannot update it. In addition to the app's tags, you can create and update your own tags.
|
|
797
|
+
*/
|
|
798
|
+
tags?: string[] | null;
|
|
799
|
+
/** Default location for the schedule's sessions. */
|
|
800
|
+
location?: Location;
|
|
801
|
+
/**
|
|
802
|
+
* Maximum number of participants that can be added to the schedule's sessions.
|
|
803
|
+
* Must be at most `1` for schedule whose availability is affected by another schedule. E.g, appointment schedules of the Wix Bookings app.
|
|
804
|
+
*/
|
|
805
|
+
capacity?: number | null;
|
|
806
|
+
/** Price options offered when booking this schedule's slots. Default is no rate. */
|
|
807
|
+
rate?: Rate;
|
|
808
|
+
/**
|
|
809
|
+
* An object describing how to calculate the schedule's availability.
|
|
810
|
+
* An empty object indicates that the schedule is not available for booking.
|
|
811
|
+
*/
|
|
812
|
+
availability?: Availability;
|
|
813
|
+
/**
|
|
814
|
+
* Number of participants registered to sessions in this schedule, calculated as the sum of the party sizes.
|
|
815
|
+
* @readonly
|
|
816
|
+
*/
|
|
817
|
+
totalNumberOfParticipants?: number;
|
|
818
|
+
/**
|
|
819
|
+
* Participants currently registered to sessions in this schedule.
|
|
820
|
+
* Participants who are registered in the schedule are automatically registered to any session that is created for the schedule.
|
|
821
|
+
* @readonly
|
|
822
|
+
*/
|
|
823
|
+
participants?: Participant[];
|
|
824
|
+
/**
|
|
825
|
+
* Title and description values to override session defaults when syncing to an external calendar.
|
|
826
|
+
* Learn more about [syncing calendars](https://support.wix.com/en/article/wix-bookings-important-information-about-syncing-google-calendars-with-wix-bookings).
|
|
827
|
+
*/
|
|
828
|
+
externalCalendarOverrides?: ExternalCalendarOverrides;
|
|
829
|
+
/**
|
|
830
|
+
* Schedule status.
|
|
831
|
+
* @readonly
|
|
832
|
+
*/
|
|
833
|
+
status?: ScheduleStatus;
|
|
834
|
+
/**
|
|
835
|
+
* Schedule creation date.
|
|
836
|
+
* @readonly
|
|
837
|
+
*/
|
|
838
|
+
created?: Date;
|
|
839
|
+
/**
|
|
840
|
+
* Schedule last update date.
|
|
841
|
+
* @readonly
|
|
842
|
+
*/
|
|
843
|
+
updated?: Date;
|
|
844
|
+
/**
|
|
845
|
+
* Schedule version number, updated each time the schedule is updated.
|
|
846
|
+
* @readonly
|
|
847
|
+
*/
|
|
848
|
+
version?: number;
|
|
849
|
+
/**
|
|
850
|
+
* Fields which were inherited from the Business Info page under Settings in the Dashboard.
|
|
851
|
+
* @readonly
|
|
852
|
+
*/
|
|
853
|
+
inheritedFields?: string[];
|
|
854
|
+
/** Conferencing Provider. A schedule with a conferencing provider will use to provider information to create a conference on the provider's system when a session is created on the schedule or on one of its linked schedule's. */
|
|
855
|
+
conferenceProvider?: ConferenceProvider;
|
|
856
|
+
/** A conference created for the schedule. This is used when a participant is added to a schedule. */
|
|
857
|
+
calendarConference?: CalendarConference;
|
|
858
|
+
}
|
|
859
|
+
export interface RecurringInterval {
|
|
860
|
+
/**
|
|
861
|
+
* The recurring interval identifier.
|
|
862
|
+
* @readonly
|
|
863
|
+
*/
|
|
864
|
+
_id?: string;
|
|
865
|
+
/** The start time of the recurring interval. Required. */
|
|
866
|
+
start?: Date;
|
|
867
|
+
/** The end time of the recurring interval. Optional. Empty value indicates that there is no end time. */
|
|
868
|
+
end?: Date;
|
|
869
|
+
/** The interval rules. The day, hour and minutes the interval is recurring. */
|
|
870
|
+
interval?: Interval;
|
|
871
|
+
/** The frequency of the interval. Optional. The default is frequency with the default repetition. */
|
|
872
|
+
frequency?: Frequency;
|
|
873
|
+
/** Specifies the list of linked schedules and the way this link affects the corresponding schedules' availability. Can be calculated from the schedule or overridden on the recurring interval. */
|
|
874
|
+
affectedSchedules?: LinkedSchedule[];
|
|
875
|
+
/**
|
|
876
|
+
* The type of recurring interval.
|
|
877
|
+
* <!--ONLY:VELO
|
|
878
|
+
* One of:
|
|
879
|
+
* - `"UNDEFINED"` The default value. Sessions for this interval will be of type EVENT.
|
|
880
|
+
* - `"EVENT"` A recurring interval of events.
|
|
881
|
+
* - `"WORKING_HOURS"` A recurring interval for availability.
|
|
882
|
+
* <!--END:ONLY:VELO-->
|
|
883
|
+
*/
|
|
884
|
+
intervalType?: RecurringIntervalType;
|
|
885
|
+
}
|
|
886
|
+
export interface Interval {
|
|
887
|
+
/** The day the interval accrue. Optional. The default is the day of the recurring interval's start time. */
|
|
888
|
+
daysOfWeek?: Day;
|
|
889
|
+
/** The hour of the day the interval accrue. must be consistent with the Interval start time. Options. The default is 0. minimum: 0, maximum: 23. */
|
|
890
|
+
hourOfDay?: number | null;
|
|
891
|
+
/** The minutes of hour the interval accrue. must be consistent with the Interval end time. Options. The default is 0. minimum: 0, maximum: 59. */
|
|
892
|
+
minuteOfHour?: number | null;
|
|
893
|
+
/** The duration of the interval in minutes. Required. Part of the session end time calculation. minimum: 1, maximum: 86400. */
|
|
894
|
+
duration?: number;
|
|
895
|
+
}
|
|
896
|
+
export declare enum Day {
|
|
897
|
+
/** Undefined. */
|
|
898
|
+
UNDEFINED = "UNDEFINED",
|
|
899
|
+
/** Monday. */
|
|
900
|
+
MON = "MON",
|
|
901
|
+
/** Tuesday. */
|
|
902
|
+
TUE = "TUE",
|
|
903
|
+
/** Wednesday. */
|
|
904
|
+
WED = "WED",
|
|
905
|
+
/** Thursday. */
|
|
906
|
+
THU = "THU",
|
|
907
|
+
/** Friday. */
|
|
908
|
+
FRI = "FRI",
|
|
909
|
+
/** Saturday. */
|
|
910
|
+
SAT = "SAT",
|
|
911
|
+
/** Sunday. */
|
|
912
|
+
SUN = "SUN"
|
|
913
|
+
}
|
|
914
|
+
export interface Frequency {
|
|
915
|
+
/** The frequency of the recurrence in weeks. i.e. when this value is 4, the interval occurs every 4 weeks. Optional. The default is 1. minimum: 1, maximum: 52. */
|
|
916
|
+
repetition?: number | null;
|
|
917
|
+
}
|
|
918
|
+
export declare enum RecurringIntervalType {
|
|
919
|
+
/** The default value. Sessions for this interval will be of type EVENT. */
|
|
920
|
+
UNDEFINED = "UNDEFINED",
|
|
921
|
+
/** A recurring interval of events */
|
|
922
|
+
EVENT = "EVENT",
|
|
923
|
+
/** Deprecated */
|
|
924
|
+
TIME_AVAILABILITY = "TIME_AVAILABILITY",
|
|
925
|
+
/** A recurring interval for availability */
|
|
926
|
+
AVAILABILITY = "AVAILABILITY"
|
|
927
|
+
}
|
|
928
|
+
/**
|
|
929
|
+
* <!-- Needs updating when recurrence has been tested
|
|
930
|
+
* Schedule's availability calculation is executed by the schedule's available intervals and this additional information.
|
|
931
|
+
* Schedule's available intervals are recurring intervals (defined in the schedule) minus sessions that has no more spots for bookings (including time between_slots), or schedule's sessions with open spots for bookings.-->
|
|
932
|
+
*/
|
|
933
|
+
export interface Availability {
|
|
934
|
+
/** Date and time the schedule starts to be available for booking. */
|
|
935
|
+
start?: Date;
|
|
936
|
+
/** Date and time the schedule stops being available for booking. No value indicates no end time. */
|
|
937
|
+
end?: Date;
|
|
938
|
+
/** Other schedules that impact the availability calculation. Relevant only when there are availability constraints. */
|
|
939
|
+
linkedSchedules?: LinkedSchedule[];
|
|
940
|
+
/** Constraints for calculating the schedule's availability. */
|
|
941
|
+
constraints?: AvailabilityConstraints;
|
|
942
|
+
}
|
|
943
|
+
/** Describes how to calculate the specific slots that are available for booking. */
|
|
944
|
+
export interface AvailabilityConstraints {
|
|
945
|
+
/**
|
|
946
|
+
* A list of duration options for slots, in minutes. Minimum value for a duration is 1.
|
|
947
|
+
* The availability calculation generates slots with these durations, where there is no conflict with existing sessions or other availability constraints.
|
|
948
|
+
*/
|
|
949
|
+
slotDurations?: number[];
|
|
950
|
+
/**
|
|
951
|
+
* The number of minutes between the `end` of one slot, and the `start` of the next.
|
|
952
|
+
* Minimum value is 0, maximum value is 120.
|
|
953
|
+
*/
|
|
954
|
+
timeBetweenSlots?: number;
|
|
955
|
+
/**
|
|
956
|
+
* Specify how to split the slots in intervals of minutes.
|
|
957
|
+
* This value indicates the time between available slots' start time. e.g., from 5 minute slots (3:00, 3:05, 3:15) and 1 hour slots (3:00, 4:00, 5:00).
|
|
958
|
+
* Optional. The default is the first duration in slot_durations field.
|
|
959
|
+
* Deprecated. Use the `split_slots_interval.value_in_minutes`.
|
|
960
|
+
*/
|
|
961
|
+
splitInterval?: number | null;
|
|
962
|
+
/**
|
|
963
|
+
* An object defining the time between available slots' start times. For example, a slot with slots_split_interval=5 can start every 5 minutes. The default is the slot duration.
|
|
964
|
+
* @readonly
|
|
965
|
+
*/
|
|
966
|
+
slotsSplitInterval?: SplitInterval;
|
|
967
|
+
}
|
|
968
|
+
/** The time between available slots' start times. For example, For 5 minute slots, 3:00, 3:05, 3:15 etc. For 1 hour slots, 3:00, 4:00, 5:00 etc. */
|
|
969
|
+
export interface SplitInterval {
|
|
970
|
+
/**
|
|
971
|
+
* Whether the slot duration is used as the split interval value.
|
|
972
|
+
* If `same_as_duration` is `true`, the `value_in_minutes` is the sum of the first duration in
|
|
973
|
+
* `schedule.availabilityConstraints.SlotDurations` field, and `schedule.availabilityConstraints.TimeBetweenSlots` field.
|
|
974
|
+
*/
|
|
975
|
+
sameAsDuration?: boolean | null;
|
|
976
|
+
/** Number of minutes between available slots' start times when `same_as_duration` is `false`. */
|
|
977
|
+
valueInMinutes?: number | null;
|
|
978
|
+
}
|
|
979
|
+
export declare enum ScheduleStatus {
|
|
980
|
+
UNDEFINED = "UNDEFINED",
|
|
981
|
+
/** The default value when the schedule is created. */
|
|
982
|
+
CREATED = "CREATED",
|
|
983
|
+
/** The schedule has been canceled. */
|
|
984
|
+
CANCELLED = "CANCELLED"
|
|
985
|
+
}
|
|
986
|
+
export interface Version {
|
|
987
|
+
/** Schedule version number, updated each time the schedule is updated. */
|
|
988
|
+
scheduleVersion?: number | null;
|
|
989
|
+
/** Participants version number, updated each time the schedule participants are updated. */
|
|
990
|
+
participantsVersion?: number | null;
|
|
991
|
+
}
|
|
992
|
+
export interface ConferenceProvider {
|
|
993
|
+
/** Conferencing provider ID */
|
|
994
|
+
providerId?: string;
|
|
995
|
+
}
|
|
996
|
+
export interface ScheduleUpdated {
|
|
997
|
+
/** The old schedule before the update. */
|
|
998
|
+
oldSchedule?: Schedule;
|
|
999
|
+
/** The new schedule after the update. */
|
|
1000
|
+
newSchedule?: Schedule;
|
|
1001
|
+
/**
|
|
1002
|
+
* Recurring sessions updated event. If this field is given, the reason for the schedule updated event was
|
|
1003
|
+
* updating at least one of the given schedule's recurring sessions.
|
|
1004
|
+
* This event is triggered by create/update/delete recurring session apis.
|
|
1005
|
+
*/
|
|
1006
|
+
recurringSessions?: RecurringSessionsUpdated;
|
|
1007
|
+
/** Whether to notify participants about the change and an optional custom message */
|
|
1008
|
+
participantNotification?: ParticipantNotification;
|
|
1009
|
+
/**
|
|
1010
|
+
* Whether this notification was created as a result of an anonymization request, such as GDPR.
|
|
1011
|
+
* An anonymized participant will have the following details:
|
|
1012
|
+
* name = "deleted"
|
|
1013
|
+
* phone = "deleted"
|
|
1014
|
+
* email = "deleted@deleted.com"
|
|
1015
|
+
*/
|
|
1016
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
1017
|
+
}
|
|
1018
|
+
export interface RecurringSessionsUpdated {
|
|
1019
|
+
/** Old schedule's recurring session list. */
|
|
1020
|
+
oldRecurringSessions?: Session[];
|
|
1021
|
+
/** New schedule's recurring session list. */
|
|
1022
|
+
newRecurringSessions?: Session[];
|
|
1023
|
+
}
|
|
1024
|
+
export interface ParticipantNotification {
|
|
1025
|
+
/**
|
|
1026
|
+
* Whether to send the message about the changes to the customer.
|
|
1027
|
+
*
|
|
1028
|
+
* Default: `false`
|
|
1029
|
+
*/
|
|
1030
|
+
notifyParticipants?: boolean;
|
|
1031
|
+
/** Custom message to send to the participants about the changes to the booking. */
|
|
1032
|
+
message?: string | null;
|
|
1033
|
+
}
|
|
1034
|
+
export interface ScheduleCancelled {
|
|
1035
|
+
schedule?: Schedule;
|
|
1036
|
+
/** Whether to notify participants about the change and an optional custom message */
|
|
1037
|
+
participantNotification?: ParticipantNotification;
|
|
1038
|
+
oldSchedule?: Schedule;
|
|
1039
|
+
}
|
|
1040
|
+
export interface SessionCreated {
|
|
1041
|
+
session?: Session;
|
|
1042
|
+
}
|
|
1043
|
+
export interface SessionUpdated {
|
|
1044
|
+
oldSession?: Session;
|
|
1045
|
+
newSession?: Session;
|
|
1046
|
+
/** Whether to notify participants about the change and an optional custom message */
|
|
1047
|
+
participantNotification?: ParticipantNotification;
|
|
1048
|
+
/**
|
|
1049
|
+
* Whether this notification was created as a result of an anonymization request, such as GDPR.
|
|
1050
|
+
* An anonymized participant will have the following details:
|
|
1051
|
+
* name = "deleted"
|
|
1052
|
+
* phone = "deleted"
|
|
1053
|
+
* email = "deleted@deleted.com"
|
|
1054
|
+
*/
|
|
1055
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
1056
|
+
}
|
|
1057
|
+
export interface SessionCancelled {
|
|
1058
|
+
session?: Session;
|
|
1059
|
+
/** Whether to notify participants about the change and an optional custom message */
|
|
1060
|
+
participantNotification?: ParticipantNotification;
|
|
1061
|
+
}
|
|
1062
|
+
export interface AvailabilityPolicyUpdated {
|
|
1063
|
+
availabilityPolicy?: AvailabilityPolicy;
|
|
1064
|
+
}
|
|
1065
|
+
/** Availability policy applied to all site schedules. */
|
|
1066
|
+
export interface AvailabilityPolicy {
|
|
1067
|
+
/** Specify how to split the schedule slots in intervals of minutes. */
|
|
1068
|
+
splitInterval?: SplitInterval;
|
|
1069
|
+
}
|
|
1070
|
+
export interface IntervalSplit {
|
|
1071
|
+
scheduleId?: string;
|
|
1072
|
+
intervals?: RecurringInterval[];
|
|
1073
|
+
newScheduleVersion?: number | null;
|
|
1074
|
+
oldScheduleVersion?: number | null;
|
|
1075
|
+
}
|
|
1076
|
+
export interface RecurringSessionSplit {
|
|
1077
|
+
scheduleId?: string;
|
|
1078
|
+
recurringSessions?: Session[];
|
|
1079
|
+
newScheduleVersion?: number | null;
|
|
1080
|
+
oldScheduleVersion?: number | null;
|
|
1081
|
+
}
|
|
1082
|
+
/** Schedule unassigned from user. */
|
|
1083
|
+
export interface ScheduleUnassignedFromUser {
|
|
1084
|
+
/** The Wix user id. */
|
|
1085
|
+
userId?: string | null;
|
|
1086
|
+
/** The schedule that was unassigned from the user. */
|
|
1087
|
+
schedule?: Schedule;
|
|
1088
|
+
}
|
|
1089
|
+
export interface MultipleSessionsCreated {
|
|
1090
|
+
schedulesWithSessions?: ScheduleWithSessions[];
|
|
1091
|
+
}
|
|
1092
|
+
export interface ScheduleWithSessions {
|
|
1093
|
+
schedule?: Schedule;
|
|
1094
|
+
siteProperties?: SitePropertiesOnScheduleCreation;
|
|
1095
|
+
sessions?: Session[];
|
|
1096
|
+
}
|
|
1097
|
+
export interface SitePropertiesOnScheduleCreation {
|
|
1098
|
+
/** The global time zone value. */
|
|
1099
|
+
timeZone?: string | null;
|
|
1100
|
+
}
|
|
1101
|
+
export interface MigrationEvent {
|
|
1102
|
+
migrationData?: MigrationData;
|
|
1103
|
+
}
|
|
1104
|
+
export interface MigrationData {
|
|
1105
|
+
businessId?: string | null;
|
|
1106
|
+
staffs?: StaffData[];
|
|
1107
|
+
}
|
|
1108
|
+
export interface StaffData {
|
|
1109
|
+
resourceId?: string;
|
|
1110
|
+
syncRequestEmail?: string;
|
|
1111
|
+
refreshToken?: string;
|
|
1112
|
+
}
|
|
1113
|
+
export interface Empty {
|
|
1114
|
+
}
|
|
1115
|
+
export interface Task {
|
|
1116
|
+
key?: TaskKey;
|
|
1117
|
+
executeAt?: Date;
|
|
1118
|
+
payload?: string | null;
|
|
1119
|
+
}
|
|
1120
|
+
export interface TaskKey {
|
|
1121
|
+
appId?: string;
|
|
1122
|
+
instanceId?: string;
|
|
1123
|
+
subjectId?: string | null;
|
|
1124
|
+
}
|
|
1125
|
+
export interface TaskAction extends TaskActionActionOneOf {
|
|
1126
|
+
complete?: Complete;
|
|
1127
|
+
cancel?: Cancel;
|
|
1128
|
+
reschedule?: Reschedule;
|
|
1129
|
+
}
|
|
1130
|
+
/** @oneof */
|
|
1131
|
+
export interface TaskActionActionOneOf {
|
|
1132
|
+
complete?: Complete;
|
|
1133
|
+
cancel?: Cancel;
|
|
1134
|
+
reschedule?: Reschedule;
|
|
1135
|
+
}
|
|
1136
|
+
export interface Complete {
|
|
1137
|
+
}
|
|
1138
|
+
export interface Cancel {
|
|
1139
|
+
}
|
|
1140
|
+
export interface Reschedule {
|
|
1141
|
+
executeAt?: Date;
|
|
1142
|
+
payload?: string | null;
|
|
1143
|
+
}
|
|
1144
|
+
/**
|
|
1145
|
+
* Gets the sessions view information.
|
|
1146
|
+
* E.g. the current view end date, or the future duration in days the view should strive for.
|
|
1147
|
+
* @public
|
|
1148
|
+
* @documentationMaturity preview
|
|
1149
|
+
*/
|
|
1150
|
+
export declare function getSessionView(): Promise<GetSessionViewResponse>;
|