@wix/bookings 1.0.498 → 1.0.500

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/bookings",
3
- "version": "1.0.498",
3
+ "version": "1.0.500",
4
4
  "publishConfig": {
5
5
  "registry": "https://registry.npmjs.org/",
6
6
  "access": "public"
@@ -21,23 +21,23 @@
21
21
  "type-bundles"
22
22
  ],
23
23
  "dependencies": {
24
- "@wix/bookings_attendance": "1.0.57",
24
+ "@wix/bookings_attendance": "1.0.58",
25
25
  "@wix/bookings_availability-calendar": "1.0.46",
26
26
  "@wix/bookings_availability-time-slots": "1.0.37",
27
27
  "@wix/bookings_booking-fees": "1.0.11",
28
28
  "@wix/bookings_booking-policies": "1.0.9",
29
29
  "@wix/bookings_booking-policy-snapshots": "1.0.7",
30
- "@wix/bookings_bookings": "1.0.71",
30
+ "@wix/bookings_bookings": "1.0.72",
31
31
  "@wix/bookings_categories": "1.0.44",
32
- "@wix/bookings_extended-bookings": "1.0.58",
32
+ "@wix/bookings_extended-bookings": "1.0.60",
33
33
  "@wix/bookings_external-calendars": "1.0.41",
34
34
  "@wix/bookings_multi-service-availability-time-slots": "1.0.36",
35
- "@wix/bookings_pricing": "1.0.46",
35
+ "@wix/bookings_pricing": "1.0.47",
36
36
  "@wix/bookings_resource-types": "1.0.15",
37
37
  "@wix/bookings_resources": "1.0.56",
38
38
  "@wix/bookings_service-categories": "1.0.0",
39
- "@wix/bookings_service-options-and-variants": "1.0.56",
40
- "@wix/bookings_services": "1.0.80",
39
+ "@wix/bookings_service-options-and-variants": "1.0.57",
40
+ "@wix/bookings_services": "1.0.81",
41
41
  "@wix/bookings_staff-members": "1.0.17"
42
42
  },
43
43
  "devDependencies": {
@@ -63,5 +63,5 @@
63
63
  "fqdn": ""
64
64
  }
65
65
  },
66
- "falconPackageHash": "a44e8fd56eefb52a33fca8ca2669bb7a24ccde4abdc310c425ea4b8e"
66
+ "falconPackageHash": "cf46d18004d8f6969db3117993dd2284a7e69d0664ffa5b041df88ca"
67
67
  }
@@ -5138,7 +5138,6 @@ interface ServiceOptionsAndVariants {
5138
5138
  interface ServiceOption extends ServiceOptionOptionSpecificDataOneOf {
5139
5139
  /** Details about the custom option. Available only for `CUSTOM` options. */
5140
5140
  customData?: CustomServiceOption;
5141
- durationData?: DurationServiceOption;
5142
5141
  /** ID of the service option. */
5143
5142
  _id?: string;
5144
5143
  /** Type of the service option. */
@@ -5148,7 +5147,6 @@ interface ServiceOption extends ServiceOptionOptionSpecificDataOneOf {
5148
5147
  interface ServiceOptionOptionSpecificDataOneOf {
5149
5148
  /** Details about the custom option. Available only for `CUSTOM` options. */
5150
5149
  customData?: CustomServiceOption;
5151
- durationData?: DurationServiceOption;
5152
5150
  }
5153
5151
  declare enum ServiceOptionType {
5154
5152
  UNKNOWN = "UNKNOWN",
@@ -5198,8 +5196,6 @@ interface ServiceChoice$3 extends ServiceChoiceChoiceOneOf$3 {
5198
5196
  * `availability.linkedSchedules`.
5199
5197
  */
5200
5198
  staffMemberId?: string;
5201
- /** Duration and an optional name */
5202
- duration?: Duration$4;
5203
5199
  /** ID of the service option. */
5204
5200
  optionId?: string;
5205
5201
  }
@@ -5214,8 +5210,6 @@ interface ServiceChoiceChoiceOneOf$3 {
5214
5210
  * `availability.linkedSchedules`.
5215
5211
  */
5216
5212
  staffMemberId?: string;
5217
- /** Duration and an optional name */
5218
- duration?: Duration$4;
5219
5213
  }
5220
5214
  interface Duration$4 {
5221
5215
  /**
@@ -6863,11 +6857,11 @@ interface ServiceOptionsAndVariantsCreatedEnvelope {
6863
6857
  entity: ServiceOptionsAndVariants;
6864
6858
  metadata: EventMetadata$7;
6865
6859
  }
6866
- interface ServiceOptionsAndVariantsUpdatedEnvelope {
6860
+ interface ServiceOptionsAndVariantsDeletedEnvelope {
6867
6861
  entity: ServiceOptionsAndVariants;
6868
6862
  metadata: EventMetadata$7;
6869
6863
  }
6870
- interface ServiceOptionsAndVariantsDeletedEnvelope {
6864
+ interface ServiceOptionsAndVariantsUpdatedEnvelope {
6871
6865
  entity: ServiceOptionsAndVariants;
6872
6866
  metadata: EventMetadata$7;
6873
6867
  }
@@ -7083,8 +7077,8 @@ interface QueryServiceOptionsAndVariantsSignature {
7083
7077
  (): ServiceOptionsAndVariantsListQueryBuilder;
7084
7078
  }
7085
7079
  declare const onServiceOptionsAndVariantsCreated$1: EventDefinition<ServiceOptionsAndVariantsCreatedEnvelope, "wix.bookings.catalog.v1.service_options_and_variants_created">;
7086
- declare const onServiceOptionsAndVariantsUpdated$1: EventDefinition<ServiceOptionsAndVariantsUpdatedEnvelope, "wix.bookings.catalog.v1.service_options_and_variants_updated">;
7087
7080
  declare const onServiceOptionsAndVariantsDeleted$1: EventDefinition<ServiceOptionsAndVariantsDeletedEnvelope, "wix.bookings.catalog.v1.service_options_and_variants_deleted">;
7081
+ declare const onServiceOptionsAndVariantsUpdated$1: EventDefinition<ServiceOptionsAndVariantsUpdatedEnvelope, "wix.bookings.catalog.v1.service_options_and_variants_updated">;
7088
7082
 
7089
7083
  declare function createEventModule$8<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
7090
7084
 
@@ -7100,14 +7094,14 @@ type _publicOnServiceOptionsAndVariantsCreatedType = typeof onServiceOptionsAndV
7100
7094
  /** */
7101
7095
  declare const onServiceOptionsAndVariantsCreated: ReturnType<typeof createEventModule$8<_publicOnServiceOptionsAndVariantsCreatedType>>;
7102
7096
 
7103
- type _publicOnServiceOptionsAndVariantsUpdatedType = typeof onServiceOptionsAndVariantsUpdated$1;
7104
- /** */
7105
- declare const onServiceOptionsAndVariantsUpdated: ReturnType<typeof createEventModule$8<_publicOnServiceOptionsAndVariantsUpdatedType>>;
7106
-
7107
7097
  type _publicOnServiceOptionsAndVariantsDeletedType = typeof onServiceOptionsAndVariantsDeleted$1;
7108
7098
  /** */
7109
7099
  declare const onServiceOptionsAndVariantsDeleted: ReturnType<typeof createEventModule$8<_publicOnServiceOptionsAndVariantsDeletedType>>;
7110
7100
 
7101
+ type _publicOnServiceOptionsAndVariantsUpdatedType = typeof onServiceOptionsAndVariantsUpdated$1;
7102
+ /** */
7103
+ declare const onServiceOptionsAndVariantsUpdated: ReturnType<typeof createEventModule$8<_publicOnServiceOptionsAndVariantsUpdatedType>>;
7104
+
7111
7105
  type context$d_CloneServiceOptionsAndVariantsRequest = CloneServiceOptionsAndVariantsRequest;
7112
7106
  type context$d_CloneServiceOptionsAndVariantsResponse = CloneServiceOptionsAndVariantsResponse;
7113
7107
  type context$d_CloneServiceOptionsAndVariantsResponseNonNullableFields = CloneServiceOptionsAndVariantsResponseNonNullableFields;
@@ -9222,7 +9216,6 @@ interface ServiceChoice$2 extends ServiceChoiceChoiceOneOf$2 {
9222
9216
  * Each choice may have a different price.
9223
9217
  */
9224
9218
  custom?: string;
9225
- duration?: Duration$3;
9226
9219
  /**
9227
9220
  * ID of the corresponding option for the choice. For example, the choice `child`
9228
9221
  * could correspond to the option `ageGroup`. In this case, `optionId` is the ID
@@ -9239,7 +9232,6 @@ interface ServiceChoiceChoiceOneOf$2 {
9239
9232
  * Each choice may have a different price.
9240
9233
  */
9241
9234
  custom?: string;
9242
- duration?: Duration$3;
9243
9235
  }
9244
9236
  interface Duration$3 {
9245
9237
  /**
@@ -9477,6 +9469,21 @@ interface QueryExtendedBookingsResponse {
9477
9469
  /** Paging metadata. */
9478
9470
  pagingMetadata?: PagingMetadataV2$2;
9479
9471
  }
9472
+ interface CountExtendedBookingsRequest {
9473
+ /**
9474
+ * Filter object in the following format:
9475
+ * `"filter" : {
9476
+ * "fieldName1": "value1",
9477
+ * "fieldName2":{"$operator":"value2"}
9478
+ * }`
9479
+ * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
9480
+ */
9481
+ filter?: Record<string, any> | null;
9482
+ }
9483
+ interface CountExtendedBookingsResponse {
9484
+ /** The number of bookings matching the given filter. */
9485
+ count?: number;
9486
+ }
9480
9487
  interface ServiceChoiceNonNullableFields$2 {
9481
9488
  custom: string;
9482
9489
  optionId: string;
@@ -9714,6 +9721,8 @@ type context$9_CommonPaging = CommonPaging;
9714
9721
  type context$9_CommonQueryV2 = CommonQueryV2;
9715
9722
  type context$9_CommonQueryV2PagingMethodOneOf = CommonQueryV2PagingMethodOneOf;
9716
9723
  type context$9_ConferencingDetails = ConferencingDetails;
9724
+ type context$9_CountExtendedBookingsRequest = CountExtendedBookingsRequest;
9725
+ type context$9_CountExtendedBookingsResponse = CountExtendedBookingsResponse;
9717
9726
  type context$9_ExtendedBooking = ExtendedBooking;
9718
9727
  type context$9_QueryExtendedBookingRequest = QueryExtendedBookingRequest;
9719
9728
  type context$9_QueryExtendedBookingResponse = QueryExtendedBookingResponse;
@@ -9726,7 +9735,7 @@ type context$9_QueryOptions = QueryOptions;
9726
9735
  declare const context$9_query: typeof query;
9727
9736
  declare const context$9_queryExtendedBookings: typeof queryExtendedBookings;
9728
9737
  declare namespace context$9 {
9729
- export { Actor$2 as Actor, type Address$5 as Address, type AddressLocation$4 as AddressLocation, type AddressStreetOneOf$4 as AddressStreetOneOf, type AllowedActions$1 as AllowedActions, type Attendance$1 as Attendance, AttendanceStatus$1 as AttendanceStatus, type BookedEntity$2 as BookedEntity, type BookedEntityItemOneOf$2 as BookedEntityItemOneOf, type BookedResource$2 as BookedResource, type BookedSchedule$2 as BookedSchedule, type BookedSlot$2 as BookedSlot, type Booking$2 as Booking, type context$9_BookingFeeDetails as BookingFeeDetails, context$9_BookingFeeStatus as BookingFeeStatus, type BookingParticipantsInfoOneOf$2 as BookingParticipantsInfoOneOf, type BookingPolicySettings$1 as BookingPolicySettings, type BookingSource$2 as BookingSource, BookingStatus$2 as BookingStatus, type context$9_CommonPaging as CommonPaging, type context$9_CommonQueryV2 as CommonQueryV2, type context$9_CommonQueryV2PagingMethodOneOf as CommonQueryV2PagingMethodOneOf, type context$9_ConferencingDetails as ConferencingDetails, type ContactDetails$2 as ContactDetails, type CursorPaging$7 as CursorPaging, type Cursors$7 as Cursors, type CustomFormField$2 as CustomFormField, type Duration$3 as Duration, type context$9_ExtendedBooking as ExtendedBooking, type ExtendedFields$7 as ExtendedFields, type FlowControlSettings$2 as FlowControlSettings, type IdentificationData$9 as IdentificationData, type IdentificationDataIdOneOf$9 as IdentificationDataIdOneOf, IdentityType$3 as IdentityType, type Location$4 as Location, LocationType$4 as LocationType, type MultiServiceBookingInfo$2 as MultiServiceBookingInfo, MultiServiceBookingType$2 as MultiServiceBookingType, type Paging$3 as Paging, type PagingMetadataV2$2 as PagingMetadataV2, type ParticipantChoices$2 as ParticipantChoices, type ParticipantNotification$5 as ParticipantNotification, PaymentStatus$2 as PaymentStatus, Platform$2 as Platform, type context$9_QueryExtendedBookingRequest as QueryExtendedBookingRequest, type context$9_QueryExtendedBookingResponse as QueryExtendedBookingResponse, type context$9_QueryExtendedBookingResponseNonNullableFields as QueryExtendedBookingResponseNonNullableFields, type context$9_QueryExtendedBookingsOptions as QueryExtendedBookingsOptions, type context$9_QueryExtendedBookingsRequest as QueryExtendedBookingsRequest, type context$9_QueryExtendedBookingsResponse as QueryExtendedBookingsResponse, type context$9_QueryExtendedBookingsResponseNonNullableFields as QueryExtendedBookingsResponseNonNullableFields, type context$9_QueryOptions as QueryOptions, type QueryV2$3 as QueryV2, type QueryV2PagingMethodOneOf$3 as QueryV2PagingMethodOneOf, SelectedPaymentOption$2 as SelectedPaymentOption, type ServiceChoice$2 as ServiceChoice, type ServiceChoiceChoiceOneOf$2 as ServiceChoiceChoiceOneOf, type ServiceChoices$2 as ServiceChoices, SortOrder$7 as SortOrder, type Sorting$7 as Sorting, type StreetAddress$4 as StreetAddress, type Subdivision$4 as Subdivision, ValueType$2 as ValueType, context$9_query as query, context$9_queryExtendedBookings as queryExtendedBookings };
9738
+ export { Actor$2 as Actor, type Address$5 as Address, type AddressLocation$4 as AddressLocation, type AddressStreetOneOf$4 as AddressStreetOneOf, type AllowedActions$1 as AllowedActions, type Attendance$1 as Attendance, AttendanceStatus$1 as AttendanceStatus, type BookedEntity$2 as BookedEntity, type BookedEntityItemOneOf$2 as BookedEntityItemOneOf, type BookedResource$2 as BookedResource, type BookedSchedule$2 as BookedSchedule, type BookedSlot$2 as BookedSlot, type Booking$2 as Booking, type context$9_BookingFeeDetails as BookingFeeDetails, context$9_BookingFeeStatus as BookingFeeStatus, type BookingParticipantsInfoOneOf$2 as BookingParticipantsInfoOneOf, type BookingPolicySettings$1 as BookingPolicySettings, type BookingSource$2 as BookingSource, BookingStatus$2 as BookingStatus, type context$9_CommonPaging as CommonPaging, type context$9_CommonQueryV2 as CommonQueryV2, type context$9_CommonQueryV2PagingMethodOneOf as CommonQueryV2PagingMethodOneOf, type context$9_ConferencingDetails as ConferencingDetails, type ContactDetails$2 as ContactDetails, type context$9_CountExtendedBookingsRequest as CountExtendedBookingsRequest, type context$9_CountExtendedBookingsResponse as CountExtendedBookingsResponse, type CursorPaging$7 as CursorPaging, type Cursors$7 as Cursors, type CustomFormField$2 as CustomFormField, type Duration$3 as Duration, type context$9_ExtendedBooking as ExtendedBooking, type ExtendedFields$7 as ExtendedFields, type FlowControlSettings$2 as FlowControlSettings, type IdentificationData$9 as IdentificationData, type IdentificationDataIdOneOf$9 as IdentificationDataIdOneOf, IdentityType$3 as IdentityType, type Location$4 as Location, LocationType$4 as LocationType, type MultiServiceBookingInfo$2 as MultiServiceBookingInfo, MultiServiceBookingType$2 as MultiServiceBookingType, type Paging$3 as Paging, type PagingMetadataV2$2 as PagingMetadataV2, type ParticipantChoices$2 as ParticipantChoices, type ParticipantNotification$5 as ParticipantNotification, PaymentStatus$2 as PaymentStatus, Platform$2 as Platform, type context$9_QueryExtendedBookingRequest as QueryExtendedBookingRequest, type context$9_QueryExtendedBookingResponse as QueryExtendedBookingResponse, type context$9_QueryExtendedBookingResponseNonNullableFields as QueryExtendedBookingResponseNonNullableFields, type context$9_QueryExtendedBookingsOptions as QueryExtendedBookingsOptions, type context$9_QueryExtendedBookingsRequest as QueryExtendedBookingsRequest, type context$9_QueryExtendedBookingsResponse as QueryExtendedBookingsResponse, type context$9_QueryExtendedBookingsResponseNonNullableFields as QueryExtendedBookingsResponseNonNullableFields, type context$9_QueryOptions as QueryOptions, type QueryV2$3 as QueryV2, type QueryV2PagingMethodOneOf$3 as QueryV2PagingMethodOneOf, SelectedPaymentOption$2 as SelectedPaymentOption, type ServiceChoice$2 as ServiceChoice, type ServiceChoiceChoiceOneOf$2 as ServiceChoiceChoiceOneOf, type ServiceChoices$2 as ServiceChoices, SortOrder$7 as SortOrder, type Sorting$7 as Sorting, type StreetAddress$4 as StreetAddress, type Subdivision$4 as Subdivision, ValueType$2 as ValueType, context$9_query as query, context$9_queryExtendedBookings as queryExtendedBookings };
9730
9739
  }
9731
9740
 
9732
9741
  /**
@@ -12753,16 +12762,6 @@ interface V2Schedule {
12753
12762
  availabilityConstraints?: V2AvailabilityConstraints;
12754
12763
  }
12755
12764
  interface V2AvailabilityConstraints {
12756
- /**
12757
- * A calculated list of all available durations for a service.
12758
- *
12759
- * If the service payment is of typed `Varied` with `Duration` option, this list will contain the durations of the variants.
12760
- * The durations order will reflect the order of the variants.
12761
- *
12762
- * For any other type of service or payment this list will mirror the durations specified in `session_durations`.
12763
- * @readonly
12764
- */
12765
- durations?: Duration$2[];
12766
12765
  /**
12767
12766
  * A list of durations for sessions, in minutes.
12768
12767
  *
@@ -15930,11 +15929,11 @@ interface ServiceCreatedEnvelope {
15930
15929
  entity: Service;
15931
15930
  metadata: EventMetadata$3;
15932
15931
  }
15933
- interface ServiceUpdatedEnvelope {
15932
+ interface ServiceDeletedEnvelope {
15934
15933
  entity: Service;
15935
15934
  metadata: EventMetadata$3;
15936
15935
  }
15937
- interface ServiceDeletedEnvelope {
15936
+ interface ServiceUpdatedEnvelope {
15938
15937
  entity: Service;
15939
15938
  metadata: EventMetadata$3;
15940
15939
  }
@@ -16410,8 +16409,8 @@ interface CloneServiceSignature {
16410
16409
  (sourceServiceId: string, options?: CloneServiceOptions | undefined): Promise<CloneServiceResponse & CloneServiceResponseNonNullableFields>;
16411
16410
  }
16412
16411
  declare const onServiceCreated$1: EventDefinition<ServiceCreatedEnvelope, "wix.bookings.services.v2.service_created">;
16413
- declare const onServiceUpdated$1: EventDefinition<ServiceUpdatedEnvelope, "wix.bookings.services.v2.service_updated">;
16414
16412
  declare const onServiceDeleted$1: EventDefinition<ServiceDeletedEnvelope, "wix.bookings.services.v2.service_deleted">;
16413
+ declare const onServiceUpdated$1: EventDefinition<ServiceUpdatedEnvelope, "wix.bookings.services.v2.service_updated">;
16415
16414
 
16416
16415
  declare function createEventModule$4<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
16417
16416
 
@@ -16440,14 +16439,14 @@ type _publicOnServiceCreatedType = typeof onServiceCreated$1;
16440
16439
  /** */
16441
16440
  declare const onServiceCreated: ReturnType<typeof createEventModule$4<_publicOnServiceCreatedType>>;
16442
16441
 
16443
- type _publicOnServiceUpdatedType = typeof onServiceUpdated$1;
16444
- /** */
16445
- declare const onServiceUpdated: ReturnType<typeof createEventModule$4<_publicOnServiceUpdatedType>>;
16446
-
16447
16442
  type _publicOnServiceDeletedType = typeof onServiceDeleted$1;
16448
16443
  /** */
16449
16444
  declare const onServiceDeleted: ReturnType<typeof createEventModule$4<_publicOnServiceDeletedType>>;
16450
16445
 
16446
+ type _publicOnServiceUpdatedType = typeof onServiceUpdated$1;
16447
+ /** */
16448
+ declare const onServiceUpdated: ReturnType<typeof createEventModule$4<_publicOnServiceUpdatedType>>;
16449
+
16451
16450
  type context$6_Action = Action;
16452
16451
  declare const context$6_Action: typeof Action;
16453
16452
  type context$6_Aggregation = Aggregation;
@@ -21128,20 +21127,20 @@ declare namespace context$3 {
21128
21127
  }
21129
21128
 
21130
21129
  /**
21131
- * The `Attendance` object represents the attendance information
21130
+ * The `attendance` object represents the attendance information
21132
21131
  * for a booked session, such as:
21133
21132
  *
21134
21133
  * + Did anyone attend the session?
21135
21134
  * + How many people attended the session?
21136
21135
  *
21137
- * The number of session `Attendance` objects available depends on the booking type:
21138
- * + Appointment bookings have 1 `Attendance` object per appointment session.
21139
- * + Class bookings have 1 `Attendance` object for each session of the class. The number of sessions for a class is defined in Schedule and Sessions [`schedule.capacity`](https://dev.wix.com/api/rest/wix-bookings/schedules-and-sessions/schedule/schedule-object) property.
21140
- * + Course bookings have an `Attendance` object for each session of the course. For example, if there are 12 sessions in a course, there are 12 `Attendance` objects. The number of sessions for a class is defined in Schedule and Sessions [`schedule.capacity`](https://dev.wix.com/api/rest/wix-bookings/schedules-and-sessions/schedule/schedule-object) property.
21136
+ * The number of session `attendance` objects available depends on the booking type:
21137
+ * + Appointment bookings have 1 `attendance` object per appointment session.
21138
+ * + Class bookings have 1 `attendance` object for each session of the class. The number of sessions for a class is defined in Schedule and Sessions `schedule.capacity` property.
21139
+ * + Course bookings have an `attendance` object for each session of the course. For example, if there are 12 sessions in a course, there are 12 `attendance` objects. The number of sessions for a class is defined in Schedule and Sessions `schedule.capacity` property.
21141
21140
  */
21142
21141
  interface Attendance {
21143
21142
  /**
21144
- * ID of the `Attendance` object.
21143
+ * ID of the `attendance` object.
21145
21144
  * @readonly
21146
21145
  */
21147
21146
  _id?: string | null;
@@ -21171,30 +21170,31 @@ declare enum AttendanceStatus {
21171
21170
  NOT_ATTENDED = "NOT_ATTENDED"
21172
21171
  }
21173
21172
  interface GetAttendanceRequest {
21174
- /** ID of the object that contains the attendance information that you want to retrieve. */
21173
+ /** ID of the attendance object to retrieve. */
21175
21174
  attendanceId: string;
21176
21175
  }
21177
21176
  interface GetAttendanceResponse {
21178
- /** The retrieved attendance information for the booked session. */
21177
+ /** Retrieved attendance. */
21179
21178
  attendance?: Attendance;
21180
21179
  }
21181
21180
  interface SetAttendanceRequest {
21182
- /** The attendance information for a booked session that you want to create or update. */
21181
+ /** Attendance to create or update. */
21183
21182
  attendance: Attendance;
21184
21183
  /** Information about whether to send a message to a customer after their attendance was set. */
21185
21184
  participantNotification?: ParticipantNotification$2;
21186
21185
  }
21187
21186
  interface ParticipantNotification$2 {
21188
21187
  /**
21189
- * Whether to send the message about the changes to the customer.
21190
- * Default is false.
21188
+ * Specify whether to send the message about the changes to the customer.
21189
+ *
21190
+ * Default: `false`
21191
21191
  */
21192
21192
  notifyParticipants?: boolean | null;
21193
21193
  /** Optional custom message to send to the participants about the changes to the booking. */
21194
21194
  message?: string | null;
21195
21195
  }
21196
21196
  interface SetAttendanceResponse {
21197
- /** The created or updated attendance information for the booked session. */
21197
+ /** Created or updated attendance. */
21198
21198
  attendance?: Attendance;
21199
21199
  }
21200
21200
  interface AttendanceMarkedAsNotAttended {
@@ -21205,23 +21205,25 @@ interface AttendanceMarkedAsNotAttended {
21205
21205
  }
21206
21206
  interface BulkSetAttendanceRequest {
21207
21207
  returnFullEntity?: boolean;
21208
- /** The attendance information for a booked sessions that you want to create or update. Min size 1. */
21208
+ /** List of attendance details for booking sessions to create or update. */
21209
21209
  attendanceDetails?: AttendanceDetails[];
21210
21210
  }
21211
21211
  interface AttendanceDetails {
21212
- /** The created or updated attendance information for the booked session. */
21212
+ /** Created or updated attendance information for a booking session. */
21213
21213
  attendance?: Attendance;
21214
- /** Information about whether to send a message to a customer after their attendance was set. */
21214
+ /** Information about whether to send a message to the customer after their attendance was set. */
21215
21215
  participantNotification?: ParticipantNotification$2;
21216
21216
  }
21217
21217
  interface BulkSetAttendanceResponse {
21218
- /** The created or updated attendance information for the booked sessions. */
21218
+ /** List of created or updated `attendance` objects. */
21219
21219
  results?: BulkAttendanceResult[];
21220
- /** Total successes and failures of the bulk set attendance action. */
21220
+ /** Information about the total number of successes and failures for the Bulk Set Attendance call. */
21221
21221
  bulkActionMetadata?: BulkActionMetadata$1;
21222
21222
  }
21223
21223
  interface BulkAttendanceResult {
21224
+ /** Created or updated `attendance` object. */
21224
21225
  item?: Attendance;
21226
+ /** Metadata for the created or updated `attendance` object. */
21225
21227
  itemMetadata?: ItemMetadata$1;
21226
21228
  }
21227
21229
  interface ItemMetadata$1 {
@@ -21319,9 +21321,9 @@ interface CursorPaging$1 {
21319
21321
  }
21320
21322
  /** List of objects that contain attendance information. */
21321
21323
  interface QueryAttendanceResponse {
21322
- /** List of objects that contain attendance information for a booked session. */
21324
+ /** List of `attendance` objects that contain attendance information for a booked session. */
21323
21325
  attendances?: Attendance[];
21324
- /** Details on the paged set of results returned. */
21326
+ /** Metadata for the paged set of results. */
21325
21327
  pagingMetadata?: CursorPagingMetadata;
21326
21328
  }
21327
21329
  /** This is the preferred message for cursor-paging enabled services */
@@ -21496,7 +21498,7 @@ interface SetAttendanceOptions {
21496
21498
  }
21497
21499
  interface BulkSetAttendanceOptions {
21498
21500
  returnFullEntity?: boolean;
21499
- /** The attendance information for a booked sessions that you want to create or update. Min size 1. */
21501
+ /** List of attendance details for booking sessions to create or update. */
21500
21502
  attendanceDetails?: AttendanceDetails[];
21501
21503
  }
21502
21504
  interface QueryCursorResult {
@@ -21568,79 +21570,76 @@ interface AttendancesQueryBuilder {
21568
21570
  declare function getAttendance$1(httpClient: HttpClient): GetAttendanceSignature;
21569
21571
  interface GetAttendanceSignature {
21570
21572
  /**
21571
- * Retrieves attendance information by ID.
21572
- * @param - ID of the object that contains the attendance information that you want to retrieve.
21573
- * @returns The retrieved attendance information for the booked session.
21573
+ * Retrieves attendance information.
21574
+ * @param - ID of the attendance object to retrieve.
21575
+ * @returns Retrieved attendance.
21574
21576
  */
21575
21577
  (attendanceId: string): Promise<Attendance & AttendanceNonNullableFields>;
21576
21578
  }
21577
21579
  declare function setAttendance$1(httpClient: HttpClient): SetAttendanceSignature;
21578
21580
  interface SetAttendanceSignature {
21579
21581
  /**
21580
- * Sets information about whether a booking's session was attended. This information
21581
- * is saved in an `Attendance` object.
21582
+ * Sets or updates attendance information for a booking session. This
21583
+ * information is stored in an `attendance` object.
21582
21584
  *
21585
+ * If an `attendance` object already exists for the session, it's updated.
21586
+ * Otherwise, a new object is created.
21583
21587
  *
21584
- * If attendance was already set, meaning the `Attendance` object already exists, the
21585
- * existing attendance information is updated. Otherwise, a new `Attendance` object
21586
- * is created.
21588
+ * By default, `numberOfAttendees` is set to `1`, but you can specify a higher
21589
+ * number if multiple participants attended. Do not set `numberOfAttendees` to
21590
+ * `0` to indicate no attendance, instead specify `{"status": "NOT_ATTENDED"}`.
21587
21591
  *
21588
- * By default, the number
21589
- * of attendees is set to `1`, but you can set a number to greater than `1` if multiple
21590
- * participants attended. Do not set to `0` to indicate that no one attended the session.
21591
- * Instead, set the `status` field to `NOT_ATTENDED`.
21592
+ * Validation guidelines:
21592
21593
  *
21593
- * > __Note:__ Make sure your code validates that:
21594
- * > + There is no mismatch between `numberOfAttendees` and `attendanceStatus` to make sure, for example, that `attendanceStatus` is not `NOT_ATTENDED` while `numberOfAttendees` is `5`.
21595
- * > + The attendance's `numberOfAttendees` and the booking's `numberOfParticipants` correspond. For example, the number of attendees usually should not exceed the booking's intended number of participants (unless perhaps you allow walk-ins that did not sign up in advance).
21596
- * @param - The attendance information for a booked session that you want to create or update.
21594
+ * + The call succeeds for mismatches between `numberOfAttendees`
21595
+ * and `status`. For example, make sure that your code doesn't specify
21596
+ * `{"status": "NOT_ATTENDED"}` with `{"numberOfAttendees": 5}`.
21597
+ * + The API also allows `numberOfAttendees` to exceed the booking's
21598
+ * `numberOfParticipants`. Use higher values only when scenarios like
21599
+ * walk-ins justify the exception.
21600
+ * @param - Attendance to create or update.
21601
+ * @param - Options to use when setting an attendance.
21597
21602
  */
21598
21603
  (attendance: Attendance, options?: SetAttendanceOptions | undefined): Promise<SetAttendanceResponse & SetAttendanceResponseNonNullableFields>;
21599
21604
  }
21600
21605
  declare function bulkSetAttendance$1(httpClient: HttpClient): BulkSetAttendanceSignature;
21601
21606
  interface BulkSetAttendanceSignature {
21602
21607
  /**
21603
- * Sets information about whether a booking's session was attended for multiple bookings
21608
+ * Sets or updates attendance information for multiple booking sessions.
21604
21609
  *
21605
21610
  *
21606
- * See [SetAttendance](https://dev.wix.com/docs/rest/api-reference/wix-bookings/attendance/set-attendance) documentation for more information.
21611
+ * Refer to Set Attendance for detailed behavior of individual attendance
21612
+ * entries.
21607
21613
  *
21608
- * If any of the attendance list required fields were not passed on the request or if the caller doesn't have the required permissions to set the attendance, the call fails.
21609
- * If the request contains attendance info for unavailable sessions, the call completes successfully but the attendance info for the unavailable sessions are not created and are not considered as failures in the response.
21614
+ * The call fails entirely if any entry in `attendanceDetails` is missing a
21615
+ * required field.
21616
+ *
21617
+ * If attendance details are provided for a non-existent session, the call
21618
+ * succeeds for valid sessions while marking the unavailable session as a
21619
+ * failure in the response.
21620
+ * @param - Options to use when setting multiple attendances in bulk.
21610
21621
  */
21611
21622
  (options?: BulkSetAttendanceOptions | undefined): Promise<BulkSetAttendanceResponse & BulkSetAttendanceResponseNonNullableFields>;
21612
21623
  }
21613
21624
  declare function queryAttendance$1(httpClient: HttpClient): QueryAttendanceSignature;
21614
21625
  interface QueryAttendanceSignature {
21615
21626
  /**
21616
- * Retrieves attendance information for booked sessions, given the provided paging, filtering, and sorting.
21617
- *
21627
+ * Creates a query to retrieve a list of attendances.
21618
21628
  *
21619
- * When querying attendance information, you can query from the perspective of:
21620
- * + **A booking.** Specify a booking ID to retrieve attendance information
21621
- * for all sessions related to that booking.
21622
- * + **A session.** Specify a session ID to retrieve attendance information
21623
- * for all bookings related to that session.
21629
+ * The `queryAttendances()` function builds a query to retrieve a list of attendances and returns a `AttendancesQueryBuilder` object.
21624
21630
  *
21625
- * For example, query by a course's `bookingId` and `status = "NOT_ATTENDED"` to
21626
- * retrieve the attendance of a given participant in a course. For example, this query
21627
- * helps you determine if a participant booked the course
21628
- * but did not attend most of its sessions, taking away spots for other potential participants.
21631
+ * The returned object contains the query definition, which is typically used to call the query using the [find()](https://dev.wix.com/docs/sdk/backend-modules/bookings/attendance/attendances-query-builder/find) function.
21629
21632
  *
21630
- * Query Attendance runs with the following defaults, which you can override:
21633
+ * You can refine the query by chaining `AttendancesQueryBuilder` functions onto the query. `AttendancesQueryBuilder` functions enable you to sort, filter, and control the results that `queryAttendances()` returns.
21631
21634
  *
21632
- * - `id` sorted in `ASC` order
21633
- * - `cursorPaging.limit` is `50`
21635
+ * `queryAttendances()` uses the following `AttendancesQueryBuilder` default values that you can override:
21634
21636
  *
21635
- * For field support, see [supported filters](https://dev.wix.com/api/rest/wix-bookings/attendance/supported-filters).
21637
+ * + `limit` is `50`.
21638
+ * + Sorted by `id` in ascending order.
21636
21639
  *
21637
- * > __Notes__:
21638
- * > + Another way to retrieve attendance information is to call Bookings Reader V2's [Query Extended Bookings](https://dev.wix.com/api/rest/wix-bookings/bookings-reader-v2/query-extended-bookings) with `withBookingAttendanceDetails` as `true`.
21639
- * > + Up to 100 results can be returned per request.
21640
- * > + Only 1 filter is supported per query. If you define multiple filters in the same query, only the first is processed.
21640
+ * The functions that are chained to `queryAttendances()` are applied in the order they are called. For example, if you apply `ascending("status")` and then `ascending("numberOfAttendees")`, the results are sorted first by the `"status"`, and then, if there are multiple results with the same `"status"`, the items are sorted by `"numberOfAttendees"`.
21641
21641
  *
21642
- * To learn about working with query endpoints, see
21643
- * [API Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language).
21642
+ * The following `AttendancesQueryBuilder` functions are supported for the `queryAttendances()` function. For a full description of the tip settings object, see the object returned for the [items](https://dev.wix.com/docs/sdk/backend-modules/bookings/attendance/attendances-query-result/items) property in `AttendancesQueryResult`.
21644
21643
  */
21645
21644
  (): AttendancesQueryBuilder;
21646
21645
  }
@@ -22174,7 +22173,6 @@ interface ServiceChoice$1 extends ServiceChoiceChoiceOneOf$1 {
22174
22173
  * Each choice may have a different price.
22175
22174
  */
22176
22175
  custom?: string;
22177
- duration?: Duration$1;
22178
22176
  /**
22179
22177
  * ID of the corresponding option for the choice. For example, the choice `child`
22180
22178
  * could correspond to the option `ageGroup`. In this case, `optionId` is the ID
@@ -22191,7 +22189,6 @@ interface ServiceChoiceChoiceOneOf$1 {
22191
22189
  * Each choice may have a different price.
22192
22190
  */
22193
22191
  custom?: string;
22194
- duration?: Duration$1;
22195
22192
  }
22196
22193
  interface Duration$1 {
22197
22194
  /**
@@ -24271,30 +24268,30 @@ interface EventMetadata extends BaseEventMetadata {
24271
24268
  */
24272
24269
  entityEventSequence?: string | null;
24273
24270
  }
24274
- interface BookingCreatedEnvelope {
24275
- entity: Booking$1;
24276
- metadata: EventMetadata;
24277
- }
24278
- interface BookingRescheduledEnvelope {
24279
- data: BookingRescheduled;
24280
- metadata: EventMetadata;
24281
- }
24282
24271
  interface BookingCanceledEnvelope {
24283
24272
  data: BookingCanceled;
24284
24273
  metadata: EventMetadata;
24285
24274
  }
24286
- interface BookingUpdatedEnvelope {
24287
- entity: Booking$1;
24288
- metadata: EventMetadata;
24289
- }
24290
24275
  interface BookingConfirmedEnvelope {
24291
24276
  data: BookingConfirmed;
24292
24277
  metadata: EventMetadata;
24293
24278
  }
24279
+ interface BookingCreatedEnvelope {
24280
+ entity: Booking$1;
24281
+ metadata: EventMetadata;
24282
+ }
24294
24283
  interface BookingDeclinedEnvelope {
24295
24284
  data: BookingDeclined;
24296
24285
  metadata: EventMetadata;
24297
24286
  }
24287
+ interface BookingRescheduledEnvelope {
24288
+ data: BookingRescheduled;
24289
+ metadata: EventMetadata;
24290
+ }
24291
+ interface BookingUpdatedEnvelope {
24292
+ entity: Booking$1;
24293
+ metadata: EventMetadata;
24294
+ }
24298
24295
  interface BookingNumberOfParticipantsUpdatedEnvelope {
24299
24296
  data: NumberOfParticipantsUpdated;
24300
24297
  metadata: EventMetadata;
@@ -24950,12 +24947,12 @@ interface ConfirmOrDeclineBookingSignature {
24950
24947
  */
24951
24948
  (bookingId: string, options?: ConfirmOrDeclineBookingOptions | undefined): Promise<ConfirmOrDeclineBookingResponse & ConfirmOrDeclineBookingResponseNonNullableFields>;
24952
24949
  }
24953
- declare const onBookingCreated$1: EventDefinition<BookingCreatedEnvelope, "wix.bookings.v2.booking_created">;
24954
- declare const onBookingRescheduled$1: EventDefinition<BookingRescheduledEnvelope, "wix.bookings.v2.booking_rescheduled">;
24955
24950
  declare const onBookingCanceled$1: EventDefinition<BookingCanceledEnvelope, "wix.bookings.v2.booking_canceled">;
24956
- declare const onBookingUpdated$1: EventDefinition<BookingUpdatedEnvelope, "wix.bookings.v2.booking_updated">;
24957
24951
  declare const onBookingConfirmed$1: EventDefinition<BookingConfirmedEnvelope, "wix.bookings.v2.booking_confirmed">;
24952
+ declare const onBookingCreated$1: EventDefinition<BookingCreatedEnvelope, "wix.bookings.v2.booking_created">;
24958
24953
  declare const onBookingDeclined$1: EventDefinition<BookingDeclinedEnvelope, "wix.bookings.v2.booking_declined">;
24954
+ declare const onBookingRescheduled$1: EventDefinition<BookingRescheduledEnvelope, "wix.bookings.v2.booking_rescheduled">;
24955
+ declare const onBookingUpdated$1: EventDefinition<BookingUpdatedEnvelope, "wix.bookings.v2.booking_updated">;
24959
24956
  declare const onBookingNumberOfParticipantsUpdated$1: EventDefinition<BookingNumberOfParticipantsUpdatedEnvelope, "wix.bookings.v2.booking_number_of_participants_updated">;
24960
24957
 
24961
24958
  declare function createEventModule<T extends EventDefinition<any, string>>(eventDefinition: T): BuildEventDefinition<T> & T;
@@ -24982,40 +24979,40 @@ declare const cancelBooking: MaybeContext<BuildRESTFunction<typeof cancelBooking
24982
24979
  declare const updateNumberOfParticipants: MaybeContext<BuildRESTFunction<typeof updateNumberOfParticipants$1> & typeof updateNumberOfParticipants$1>;
24983
24980
  declare const confirmOrDeclineBooking: MaybeContext<BuildRESTFunction<typeof confirmOrDeclineBooking$1> & typeof confirmOrDeclineBooking$1>;
24984
24981
 
24985
- type _publicOnBookingCreatedType = typeof onBookingCreated$1;
24986
- /**
24987
- * Triggered when a booking is created.
24988
- */
24989
- declare const onBookingCreated: ReturnType<typeof createEventModule<_publicOnBookingCreatedType>>;
24990
-
24991
- type _publicOnBookingRescheduledType = typeof onBookingRescheduled$1;
24992
- /**
24993
- * Triggered when a booking is rescheduled.
24994
- */
24995
- declare const onBookingRescheduled: ReturnType<typeof createEventModule<_publicOnBookingRescheduledType>>;
24996
-
24997
24982
  type _publicOnBookingCanceledType = typeof onBookingCanceled$1;
24998
24983
  /**
24999
24984
  * Triggered when a booking is canceled.
25000
24985
  */
25001
24986
  declare const onBookingCanceled: ReturnType<typeof createEventModule<_publicOnBookingCanceledType>>;
25002
24987
 
25003
- type _publicOnBookingUpdatedType = typeof onBookingUpdated$1;
25004
- /** */
25005
- declare const onBookingUpdated: ReturnType<typeof createEventModule<_publicOnBookingUpdatedType>>;
25006
-
25007
24988
  type _publicOnBookingConfirmedType = typeof onBookingConfirmed$1;
25008
24989
  /**
25009
24990
  * Triggered when a booking is confirmed.
25010
24991
  */
25011
24992
  declare const onBookingConfirmed: ReturnType<typeof createEventModule<_publicOnBookingConfirmedType>>;
25012
24993
 
24994
+ type _publicOnBookingCreatedType = typeof onBookingCreated$1;
24995
+ /**
24996
+ * Triggered when a booking is created.
24997
+ */
24998
+ declare const onBookingCreated: ReturnType<typeof createEventModule<_publicOnBookingCreatedType>>;
24999
+
25013
25000
  type _publicOnBookingDeclinedType = typeof onBookingDeclined$1;
25014
25001
  /**
25015
25002
  * Triggered when a booking is declined.
25016
25003
  */
25017
25004
  declare const onBookingDeclined: ReturnType<typeof createEventModule<_publicOnBookingDeclinedType>>;
25018
25005
 
25006
+ type _publicOnBookingRescheduledType = typeof onBookingRescheduled$1;
25007
+ /**
25008
+ * Triggered when a booking is rescheduled.
25009
+ */
25010
+ declare const onBookingRescheduled: ReturnType<typeof createEventModule<_publicOnBookingRescheduledType>>;
25011
+
25012
+ type _publicOnBookingUpdatedType = typeof onBookingUpdated$1;
25013
+ /** */
25014
+ declare const onBookingUpdated: ReturnType<typeof createEventModule<_publicOnBookingUpdatedType>>;
25015
+
25019
25016
  type _publicOnBookingNumberOfParticipantsUpdatedType = typeof onBookingNumberOfParticipantsUpdated$1;
25020
25017
  /**
25021
25018
  * Triggered when the number of participants is updated.
@@ -25375,7 +25372,6 @@ interface ServiceChoice extends ServiceChoiceChoiceOneOf {
25375
25372
  * Each choice may have a different price.
25376
25373
  */
25377
25374
  custom?: string;
25378
- duration?: Duration;
25379
25375
  /**
25380
25376
  * ID of the corresponding option for the choice. For example, the choice `child`
25381
25377
  * could correspond to the option `ageGroup`. In this case, `optionId` is the ID
@@ -25392,7 +25388,6 @@ interface ServiceChoiceChoiceOneOf {
25392
25388
  * Each choice may have a different price.
25393
25389
  */
25394
25390
  custom?: string;
25395
- duration?: Duration;
25396
25391
  }
25397
25392
  interface Duration {
25398
25393
  /**