@wix/auto_sdk_bookings_bookings 1.0.93 → 1.0.95

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.
@@ -11,10 +11,18 @@ interface ConfirmOrDeclineBookingSignature {
11
11
  *
12
12
  * ### eCommerce checkout restriction
13
13
  *
14
- * Call this method only when using a custom checkout page. Don't
15
- * call it when using a [Wix eCommerce checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/checkout/introduction).
16
- * In such cases, Wix automatically updates the booking status based on
17
- * the `paymentStatus` of the corresponding [Wix eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction).
14
+ * Call this method only when using a custom checkout page.
15
+ * Don't call it when using a [Wix eCommerce checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/checkout/introduction).
16
+ * In such cases, Wix Bookings automatically updates the booking status based on the `paymentStatus` of the corresponding [Wix eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction).
17
+ *
18
+ * ### When to call Confirm Booking or Decline Booking instead
19
+ *
20
+ * This method has specific limitations based on payment status and double booking conflicts.
21
+ * Use the alternative methods in these scenarios:
22
+ * + **To force confirm double-booked free bookings:** Call [Confirm Booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/confirm-booking).
23
+ * Confirm Or Decline Booking can't confirm double-booked free bookings.
24
+ * + **To decline bookings without double booking conflicts:** Call [Decline Booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/decline-booking).
25
+ * Confirm Or Decline Booking only declines bookings when both a double booking conflict exists and payment status is unpaid.
18
26
  *
19
27
  * ### New booking status
20
28
  *
@@ -415,6 +423,10 @@ interface CreateBookingSignature {
415
423
  *
416
424
  * The specified `selectedPaymentOption` indicates how the customer intends to pay, allowing for later changes to a different method supported by the service.
417
425
  *
426
+ * When the customer pays with a [Wix eCommerce checkout](https://dev.wix.com/docs/api-reference/business-solutions/e-commerce/purchase-flow/checkout/introduction), you must specify a `selectedPaymentOption`.
427
+ * Otherwise, the Create Booking call fails.
428
+ * For custom checkouts, you don't have to specify a `selectedPaymentOption`.
429
+ *
418
430
  * ### Payment status
419
431
  *
420
432
  * All bookings are created with `paymentStatus=UNDEFINED`, ignoring the payment status you specify.
@@ -567,6 +579,11 @@ interface ConfirmBookingSignature {
567
579
  * In such cases, Wix automatically updates the booking status based on
568
580
  * the `paymentStatus` of the corresponding [Wix eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction).
569
581
  *
582
+ * ### When to call Confirm Booking
583
+ *
584
+ * When using a custom checkout flow for free bookings, call this method to confirm bookings even when a double booking conflict exists.
585
+ * The alternative [Confirm or Decline Booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/confirm-or-decline-booking) method doesn't support confirming double-booked free bookings in this scenario.
586
+ *
570
587
  * ### When to call Confirm Or Decline Booking instead
571
588
  *
572
589
  * Confirm Booking doesn't check whether a slot or schedule is still available.
@@ -648,22 +665,24 @@ interface UpdateExtendedFieldsSignature {
648
665
  declare function declineBooking$1(httpClient: HttpClient): DeclineBookingSignature;
649
666
  interface DeclineBookingSignature {
650
667
  /**
651
- * Updates the booking status to `DECLINED` and updates the relevant session's
652
- * `participants.approvalStatus` to `DECLINED` without checking whether the relevant
653
- * slot or schedule is still available.
668
+ * Updates the booking status to `DECLINED` without checking whether the relevant slot or schedule is still available.
654
669
  *
655
670
  *
656
671
  * ### eCommerce checkout restriction
657
672
  *
658
- * Call this method only when using a custom checkout page. Don't
659
- * call it when using a [Wix eCommerce checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/checkout/introduction).
660
- * In such cases, Wix automatically updates the booking status based on
661
- * the `paymentStatus` of the corresponding [Wix eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction).
673
+ * Call this method only when using a custom checkout page.
674
+ * Don't call it when using a [Wix eCommerce checkout](https://dev.wix.com/docs/rest/business-solutions/e-commerce/checkout/introduction).
675
+ * In such cases, Wix Bookings automatically updates the booking status based on the `paymentStatus` of the corresponding [Wix eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction).
676
+ *
677
+ * ### When to call Decline Booking
678
+ *
679
+ * When using a custom checkout, call this method to decline bookings that don't have a double booking conflict.
680
+ * The alternative [Confirm or Decline Booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/confirm-or-decline-booking) method doesn't support this scenario.
662
681
  *
663
682
  * ### When to call Confirm Or Decline Booking instead
664
683
  *
665
- * The method doesn't check whether a slot or schedule is still available. For
666
- * these checks you can call [Confirm or Decline Booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/confirm-or-decline-booking).
684
+ * Decline Booking doesn't check whether a slot or schedule is still available.
685
+ * For these checks you can call [Confirm or Decline Booking](https://dev.wix.com/docs/rest/business-solutions/bookings/bookings/bookings-writer-v2/confirm-or-decline-booking).
667
686
  *
668
687
  * ### Original status validation
669
688
  *
@@ -771,10 +790,10 @@ interface UpdateNumberOfParticipantsSignature {
771
790
  declare function bulkCalculateAllowedActions$1(httpClient: HttpClient): BulkCalculateAllowedActionsSignature;
772
791
  interface BulkCalculateAllowedActionsSignature {
773
792
  /**
774
- * Checks whether you can [reschedule](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/reschedule-booking) or [cancel](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/cancel-booking) a list of bookings without using force resolution.
793
+ * Checks whether you can [reschedule](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/reschedule-booking) or [cancel](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/cancel-booking) a list of bookings without using [force resolution](https://dev.wix.com/docs/api-reference/business-solutions/bookings/bookings/bookings-writer-v2/sample-flows#force-resolution).
775
794
  *
776
795
  *
777
- * Call this method to determine which standard actions are available before attempting to modify bookings. If standard actions aren't available, you may need to use [force resolution](https://dev.wix.com/docs/rest/business-solutions/bookings/end-to-end-booking-flows/sample-flows#force-resolution) to override business rules and availability validation.
796
+ * Call this method to determine which standard actions are available before attempting to modify bookings. If standard actions aren't available, you may need to use force resolution to override business rules and availability validation.
778
797
  * @param - List of booking IDs to calculate allowed actions for.
779
798
  */
780
799
  (bookingIds: string[]): Promise<NonNullablePaths<BulkCalculateAllowedActionsResponse, `results` | `results.${number}.itemMetadata.originalIndex` | `results.${number}.itemMetadata.success` | `results.${number}.itemMetadata.error.code` | `results.${number}.itemMetadata.error.description` | `results.${number}.item.cancel` | `results.${number}.item.reschedule` | `bulkActionMetadata.totalSuccesses` | `bulkActionMetadata.totalFailures` | `bulkActionMetadata.undetailedFailures`, 6>>;