@wix/himalaya-cli 0.2004.0 → 0.2005.0

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.
Files changed (127) hide show
  1. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk/bookings-v2/src/extensions.d.ts +33 -0
  2. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk/stores-v1/src/extensions.d.ts +1 -0
  3. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk/stores-v1/src/options.d.ts +4 -1
  4. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk/stores-v1/src/product-details.d.ts +58 -0
  5. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/_shared/types.generated.d.ts +2336 -26
  6. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/addOns.generated.d.ts +169 -0
  7. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/attendance.generated.d.ts +150 -0
  8. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/attributeDefinition.generated.d.ts +124 -0
  9. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/attributeValue.generated.d.ts +107 -0
  10. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/availabilityCalendar.generated.d.ts +66 -0
  11. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/availabilityTimeSlots.generated.d.ts +115 -0
  12. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/bookingFees.generated.d.ts +82 -0
  13. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/bookingPolicies.generated.d.ts +174 -0
  14. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/bookingPolicySnapshots.generated.d.ts +54 -0
  15. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/bookings.generated.d.ts +732 -0
  16. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/bookingsSettings.generated.d.ts +54 -0
  17. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/catalogSearch.generated.d.ts +158 -0
  18. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/categories.generated.d.ts +74 -0
  19. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/categoriesV2.generated.d.ts +122 -0
  20. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/eventTimeSlots.generated.d.ts +76 -0
  21. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/extendedBookings.generated.d.ts +239 -0
  22. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/externalCalendars.generated.d.ts +229 -0
  23. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/index.generated.d.ts +28 -0
  24. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/multiServiceAvailabilityTimeSlots.generated.d.ts +97 -0
  25. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/pricing.generated.d.ts +138 -0
  26. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/relatedProducts.generated.d.ts +78 -0
  27. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/resourceTypes.generated.d.ts +109 -0
  28. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/resources.generated.d.ts +210 -0
  29. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/serviceOptionsAndVariants.generated.d.ts +194 -0
  30. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/services.generated.d.ts +642 -0
  31. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/staffMemberSettings.generated.d.ts +46 -0
  32. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/staffMembers.generated.d.ts +399 -0
  33. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/bookings/timeSlotsConfiguration.generated.d.ts +93 -0
  34. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/conferencing.generated.d.ts +200 -0
  35. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/eventViews.generated.d.ts +20 -0
  36. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/events.generated.d.ts +355 -0
  37. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/index.generated.d.ts +6 -0
  38. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/participations.generated.d.ts +98 -0
  39. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/scheduleTimeFrames.generated.d.ts +45 -0
  40. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/calendar/schedules.generated.d.ts +123 -0
  41. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/comments/categories.generated.d.ts +15 -7
  42. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/comments/comments.generated.d.ts +32 -2
  43. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/comments/contentRevisions.generated.d.ts +27 -2
  44. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/comments/widgets.generated.d.ts +20 -13
  45. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/abandonedCheckouts.generated.d.ts +215 -0
  46. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/backInStockNotifications.generated.d.ts +148 -0
  47. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/backInStockSettings.generated.d.ts +56 -0
  48. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/cart.generated.d.ts +380 -0
  49. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/cartV2.generated.d.ts +529 -0
  50. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/checkout.generated.d.ts +461 -0
  51. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/checkoutContent.generated.d.ts +27 -0
  52. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/checkoutSettings.generated.d.ts +137 -0
  53. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/checkoutTemplates.generated.d.ts +189 -0
  54. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/contactTaxDetails.generated.d.ts +185 -0
  55. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/currencies.generated.d.ts +62 -0
  56. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/currentCart.generated.d.ts +326 -0
  57. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/currentCartV2.generated.d.ts +442 -0
  58. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/deliveryProfile.generated.d.ts +399 -0
  59. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/deliverySolutions.generated.d.ts +110 -0
  60. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/discountRules.generated.d.ts +186 -0
  61. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/discountsCustomTrigger.generated.d.ts +22 -0
  62. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/draftOrders.generated.d.ts +877 -0
  63. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/draftSubscriptionContracts.generated.d.ts +301 -0
  64. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/ecommerceSettings.generated.d.ts +24 -0
  65. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/giftVouchers.generated.d.ts +73 -0
  66. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/index.generated.d.ts +45 -0
  67. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/localDeliveryOptions.generated.d.ts +99 -0
  68. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/manualTaxMappings.generated.d.ts +207 -0
  69. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/orderBilling.generated.d.ts +399 -0
  70. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/orderFulfillments.generated.d.ts +137 -0
  71. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/orderInvoices.generated.d.ts +80 -0
  72. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/orderPaymentRequests.generated.d.ts +171 -0
  73. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/orderTransactions.generated.d.ts +167 -0
  74. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/orders.generated.d.ts +695 -0
  75. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/ordersSettings.generated.d.ts +39 -0
  76. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/recommendations.generated.d.ts +57 -0
  77. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/shippingOptions.generated.d.ts +144 -0
  78. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/shippoConfigurations.generated.d.ts +178 -0
  79. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/subscriptionContracts.generated.d.ts +209 -0
  80. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/taxCalculation.generated.d.ts +115 -0
  81. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/taxExemptGroups.generated.d.ts +218 -0
  82. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/taxGroups.generated.d.ts +140 -0
  83. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/taxRegions.generated.d.ts +126 -0
  84. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/taxSettings.generated.d.ts +38 -0
  85. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/tipSettings.generated.d.ts +116 -0
  86. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/tippableStaff.generated.d.ts +28 -0
  87. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/tips.generated.d.ts +221 -0
  88. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/totalsCalculator.generated.d.ts +141 -0
  89. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/ecom/wishlists.generated.d.ts +57 -0
  90. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/index.generated.d.ts +7 -0
  91. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/orders.generated.d.ts +368 -0
  92. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/planBenefits.generated.d.ts +94 -0
  93. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/plans.generated.d.ts +235 -0
  94. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/plansV3.generated.d.ts +266 -0
  95. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/pricingPlansSettings.generated.d.ts +48 -0
  96. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/pricing-plans/pricingVariantCategories.generated.d.ts +92 -0
  97. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/brandsV3.generated.d.ts +211 -0
  98. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/catalogImportsV3.generated.d.ts +382 -0
  99. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/catalogVersioning.generated.d.ts +17 -0
  100. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/collections.generated.d.ts +52 -0
  101. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/customizationsV3.generated.d.ts +292 -0
  102. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/index.generated.d.ts +18 -0
  103. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/infoSectionsV3.generated.d.ts +306 -0
  104. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/inventory.generated.d.ts +126 -0
  105. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/inventoryItemsV3.generated.d.ts +389 -0
  106. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/productGroupsV3.generated.d.ts +282 -0
  107. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/products.generated.d.ts +678 -0
  108. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/productsV3.generated.d.ts +1069 -0
  109. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/promotionsV3.generated.d.ts +232 -0
  110. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/readOnlyVariantsV3.generated.d.ts +93 -0
  111. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/ribbonsV3.generated.d.ts +211 -0
  112. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/storesLocationsV3.generated.d.ts +60 -0
  113. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/subscriptionOptions.generated.d.ts +223 -0
  114. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/stdlib/wix-sdk-auto/stores/wishlist.generated.d.ts +37 -0
  115. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/screens.mjs +2 -2
  116. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-bookings.mjs +1036 -4
  117. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-calendar.mjs +286 -0
  118. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-comments.mjs +23 -2
  119. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-ecom.mjs +1663 -0
  120. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-pricing-plans.mjs +336 -0
  121. package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/wix-stores.mjs +1029 -11
  122. package/dist/authoring-runtime/node_modules/@wix/himalaya/package.json +8 -4
  123. package/dist/cli.mjs +8 -8
  124. package/guides/importable-sdks.md +1 -0
  125. package/guides/sdk-reference.json +15672 -8927
  126. package/guides/wix-api-usage.md +28 -0
  127. package/package.json +2 -2
@@ -1,3 +1,9 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __export = (target, all) => {
3
+ for (var name in all)
4
+ __defProp(target, name, { get: all[name], enumerable: true });
5
+ };
6
+
1
7
  // ../../stdlib/wix-sdk/pricing-plans/src/index.ts
2
8
  function wixCall(method, path, body, readOptions) {
3
9
  if (!globalThis.himalaya?.wixApi) {
@@ -67,6 +73,330 @@ function getOnlineOrderPreview(planId, couponCode) {
67
73
  function createOnlineOrder(planId, couponCode) {
68
74
  return wixCall("POST", "/pricing-plans/v2/checkout/orders/online", couponCode ? { planId, couponCode } : { planId });
69
75
  }
76
+
77
+ // ../../stdlib/wix-sdk-auto/pricing-plans/orders.generated.ts
78
+ var orders_generated_exports = {};
79
+ __export(orders_generated_exports, {
80
+ cancelOrder: () => cancelOrder,
81
+ createOfflineOrder: () => createOfflineOrder,
82
+ createOnlineOrder: () => createOnlineOrder2,
83
+ getOfflineOrderPreview: () => getOfflineOrderPreview,
84
+ getOnlineOrderPreview: () => getOnlineOrderPreview2,
85
+ getPricePreview: () => getPricePreview,
86
+ managementGetOrder: () => managementGetOrder,
87
+ managementListOrders: () => managementListOrders,
88
+ markAsPaid: () => markAsPaid,
89
+ memberGetOrder: () => memberGetOrder,
90
+ memberListOrders: () => memberListOrders,
91
+ pauseOrder: () => pauseOrder,
92
+ postponeEndDate: () => postponeEndDate,
93
+ requestCancellation: () => requestCancellation2,
94
+ resumeOrder: () => resumeOrder
95
+ });
96
+
97
+ // ../../stdlib/wix-sdk-auto/_shared/runtime.generated.ts
98
+ function wixQueryPath(path, req) {
99
+ const parts = [];
100
+ const pair = (key, value) => {
101
+ parts.push(`${encodeURIComponent(key)}=${encodeURIComponent(String(value))}`);
102
+ };
103
+ const add = (key, value) => {
104
+ if (value === void 0 || value === null) return;
105
+ if (Array.isArray(value)) {
106
+ for (const item of value) {
107
+ if (item === void 0 || item === null || typeof item === "object") continue;
108
+ pair(key, item);
109
+ }
110
+ return;
111
+ }
112
+ if (typeof value === "object") {
113
+ for (const [k, v] of Object.entries(value)) add(`${key}.${k}`, v);
114
+ return;
115
+ }
116
+ pair(key, value);
117
+ };
118
+ for (const [key, value] of Object.entries(req ?? {})) add(key, value);
119
+ return parts.length > 0 ? `${path}?${parts.join("&")}` : path;
120
+ }
121
+ function readField(req, field) {
122
+ let value = req;
123
+ for (const key of field.split(".")) {
124
+ if (value === null || typeof value !== "object") return void 0;
125
+ value = value[key];
126
+ }
127
+ return value;
128
+ }
129
+ function restFieldMasks(req) {
130
+ if (req === null || typeof req !== "object") return req;
131
+ if (Array.isArray(req)) {
132
+ let changed = false;
133
+ const items = req.map((item) => {
134
+ const next = restFieldMasks(item);
135
+ if (next !== item) changed = true;
136
+ return next;
137
+ });
138
+ return changed ? items : req;
139
+ }
140
+ let out;
141
+ for (const [key, value] of Object.entries(req)) {
142
+ let next = value;
143
+ if ((key === "fieldMask" || key === "mask") && Array.isArray(value) && value.every((v) => typeof v === "string")) next = value.join(",");
144
+ else if (value !== null && typeof value === "object") next = restFieldMasks(value);
145
+ if (next !== value) (out ?? (out = { ...req }))[key] = next;
146
+ }
147
+ return out ?? req;
148
+ }
149
+ function withoutFields(req, fields) {
150
+ if (fields.length === 0 || req === null || typeof req !== "object") return req;
151
+ const out = { ...req };
152
+ for (const field of fields) {
153
+ const dot = field.indexOf(".");
154
+ const head = dot < 0 ? field : field.slice(0, dot);
155
+ if (!(head in out)) continue;
156
+ if (dot < 0) delete out[head];
157
+ else out[head] = withoutFields(out[head], [field.slice(dot + 1)]);
158
+ }
159
+ return out;
160
+ }
161
+ function wixCall2(verb, template, req, opts, route = {}) {
162
+ return send(verb, template, req, opts, route, false);
163
+ }
164
+ function send(verb, template, req, opts, route, queue) {
165
+ const api = globalThis.himalaya?.wixApi;
166
+ if (!api) return Promise.reject(new Error("@himalaya/wix-*: host did not install the wixApi bridge"));
167
+ const fields = route.pathFields ?? [];
168
+ let path;
169
+ try {
170
+ let i = 0;
171
+ path = template.replace(/\{[^}]+\}/g, () => {
172
+ const field = fields[i++];
173
+ const value = field === void 0 ? void 0 : readField(req, field);
174
+ if (value === void 0 || value === null || value === "") {
175
+ throw new Error(`${verb} ${template}: request field ${field ?? "(unmapped)"} is required`);
176
+ }
177
+ return encodeURIComponent(String(value));
178
+ });
179
+ } catch (err) {
180
+ return Promise.reject(err);
181
+ }
182
+ const site = opts?.site?.trim();
183
+ const headers = site ? { "wix-site-id": site } : void 0;
184
+ const wire = restFieldMasks(req);
185
+ const target = route.query ? wixQueryPath(path, withoutFields(wire, fields)) : path;
186
+ const body = route.query ? void 0 : wire;
187
+ const readShaped = verb === "GET" || verb === "HEAD" || verb === "POST" && /\/(query|query-cursor|search|list|count)(?:\?|$)/i.test(target.split("#")[0]);
188
+ if (readShaped && (opts?.cache || opts?.onCacheResult)) {
189
+ if (!api.read) return Promise.reject(new Error("READ_LIFECYCLE_UNSUPPORTED: update the Himalaya runtime"));
190
+ return api.read(verb, target, body, headers, { cache: opts.cache ?? "default" }).then((result) => {
191
+ opts.onCacheResult?.(result.cache);
192
+ return result.data;
193
+ });
194
+ }
195
+ if (opts?.cache === "only-if-cached") return Promise.reject(new Error("OFFLINE_CACHE_MISS"));
196
+ if (!queue) return api.call(verb, target, body, headers);
197
+ if (!api.offline) return api.call(verb, target, body, headers).then((value) => ({ status: "sent", value }));
198
+ return api.call(verb, target, body, headers, { offline: "queue" });
199
+ }
200
+
201
+ // ../../stdlib/wix-sdk-auto/pricing-plans/orders.generated.ts
202
+ function cancelOrder(req, opts) {
203
+ return wixCall2("POST", "/pricing-plans/v2/orders/{id}/cancel", req, opts, { pathFields: ["id"] });
204
+ }
205
+ function createOfflineOrder(req = {}, opts) {
206
+ return wixCall2("POST", "/pricing-plans/v2/checkout/orders/offline", req, opts);
207
+ }
208
+ function createOnlineOrder2(req = {}, opts) {
209
+ return wixCall2("POST", "/pricing-plans/v2/checkout/orders/online", req, opts);
210
+ }
211
+ function getOfflineOrderPreview(req = {}, opts) {
212
+ return wixCall2("POST", "/pricing-plans/v2/checkout/orders/preview-offline", req, opts);
213
+ }
214
+ function getOnlineOrderPreview2(req = {}, opts) {
215
+ return wixCall2("POST", "/pricing-plans/v2/checkout/orders/preview-online", req, opts);
216
+ }
217
+ function getPricePreview(req = {}, opts) {
218
+ return wixCall2("POST", "/pricing-plans/v2/checkout/orders/price-preview", req, opts);
219
+ }
220
+ function managementGetOrder(req, opts) {
221
+ return wixCall2("GET", "/pricing-plans/v2/orders/{id}", req, opts, { pathFields: ["id"], query: true });
222
+ }
223
+ function managementListOrders(req = {}, opts) {
224
+ return wixCall2("GET", "/pricing-plans/v2/orders", req, opts, { query: true });
225
+ }
226
+ function markAsPaid(req, opts) {
227
+ return wixCall2("POST", "/pricing-plans/v2/orders/{id}/mark-as-paid", req, opts, { pathFields: ["id"] });
228
+ }
229
+ function memberGetOrder(req, opts) {
230
+ return wixCall2("GET", "/pricing-plans/v2/member/orders/{id}", req, opts, { pathFields: ["id"], query: true });
231
+ }
232
+ function memberListOrders(req = {}, opts) {
233
+ return wixCall2("GET", "/pricing-plans/v2/member/orders", req, opts, { query: true });
234
+ }
235
+ function pauseOrder(req, opts) {
236
+ return wixCall2("POST", "/pricing-plans/v2/orders/{id}/pause", req, opts, { pathFields: ["id"] });
237
+ }
238
+ function postponeEndDate(req, opts) {
239
+ return wixCall2("PATCH", "/pricing-plans/v2/orders/{id}", req, opts, { pathFields: ["id"] });
240
+ }
241
+ function requestCancellation2(req, opts) {
242
+ return wixCall2("POST", "/pricing-plans/v2/member/orders/{id}/cancel", req, opts, { pathFields: ["id"] });
243
+ }
244
+ function resumeOrder(req, opts) {
245
+ return wixCall2("POST", "/pricing-plans/v2/orders/{id}/resume", req, opts, { pathFields: ["id"] });
246
+ }
247
+
248
+ // ../../stdlib/wix-sdk-auto/pricing-plans/planBenefits.generated.ts
249
+ var planBenefits_generated_exports = {};
250
+ __export(planBenefits_generated_exports, {
251
+ listPlansByItemIdentifier: () => listPlansByItemIdentifier
252
+ });
253
+ function listPlansByItemIdentifier(req = {}, opts) {
254
+ return wixCall2("POST", "/pricing-plan-benefits/v3/plan-benefits/list-plans-by-item-identifier", req, opts);
255
+ }
256
+
257
+ // ../../stdlib/wix-sdk-auto/pricing-plans/plans.generated.ts
258
+ var plans_generated_exports = {};
259
+ __export(plans_generated_exports, {
260
+ archivePlan: () => archivePlan2,
261
+ clearPrimary: () => clearPrimary,
262
+ createPlan: () => createPlan,
263
+ getPlan: () => getPlan2,
264
+ getPlanStats: () => getPlanStats,
265
+ listPlans: () => listPlans2,
266
+ listPublicPlans: () => listPublicPlans2,
267
+ makePlanPrimary: () => makePlanPrimary,
268
+ queryPublicPlans: () => queryPublicPlans,
269
+ setPlanVisibility: () => setPlanVisibility2,
270
+ updatePlan: () => updatePlan
271
+ });
272
+ function archivePlan2(req, opts) {
273
+ return wixCall2("POST", "/pricing-plans/v2/plans/{id}/archive", req, opts, { pathFields: ["id"] });
274
+ }
275
+ function clearPrimary(req = {}, opts) {
276
+ return wixCall2("POST", "/pricing-plans/v2/plans/clear-primary", req, opts);
277
+ }
278
+ function createPlan(req = {}, opts) {
279
+ return wixCall2("POST", "/pricing-plans/v2/plans", req, opts);
280
+ }
281
+ function getPlan2(req, opts) {
282
+ return wixCall2("GET", "/pricing-plans/v2/plans/{id}", req, opts, { pathFields: ["id"], query: true });
283
+ }
284
+ function getPlanStats(req = {}, opts) {
285
+ return wixCall2("GET", "/pricing-plans/v2/plans/stats", req, opts, { query: true });
286
+ }
287
+ function listPlans2(req = {}, opts) {
288
+ return wixCall2("GET", "/pricing-plans/v2/plans", req, opts, { query: true });
289
+ }
290
+ function listPublicPlans2(req = {}, opts) {
291
+ return wixCall2("GET", "/pricing-plans/v2/plans/public", req, opts, { query: true });
292
+ }
293
+ function makePlanPrimary(req, opts) {
294
+ return wixCall2("POST", "/pricing-plans/v2/plans/{id}/make-primary", req, opts, { pathFields: ["id"] });
295
+ }
296
+ function queryPublicPlans(req = {}, opts) {
297
+ return wixCall2("POST", "/pricing-plans/v2/plans/public/query", req, opts);
298
+ }
299
+ function setPlanVisibility2(req, opts) {
300
+ return wixCall2("PUT", "/pricing-plans/v2/plans/{id}/visibility", req, opts, { pathFields: ["id"] });
301
+ }
302
+ function updatePlan(req, opts) {
303
+ return wixCall2("PATCH", "/pricing-plans/v2/plans/{planId}", req, opts, { pathFields: ["plan.id"] });
304
+ }
305
+
306
+ // ../../stdlib/wix-sdk-auto/pricing-plans/plansV3.generated.ts
307
+ var plansV3_generated_exports = {};
308
+ __export(plansV3_generated_exports, {
309
+ bulkUpdatePlanTags: () => bulkUpdatePlanTags,
310
+ bulkUpdatePlanTagsByFilter: () => bulkUpdatePlanTagsByFilter,
311
+ bulkUpdatePlans: () => bulkUpdatePlans,
312
+ countPlans: () => countPlans,
313
+ createPlan: () => createPlan2,
314
+ deletePlan: () => deletePlan,
315
+ getPlan: () => getPlan3,
316
+ getPlanConfigurationConstraints: () => getPlanConfigurationConstraints,
317
+ getPlanPreview: () => getPlanPreview,
318
+ listPlanPreviews: () => listPlanPreviews,
319
+ queryPlans: () => queryPlans,
320
+ searchPlans: () => searchPlans,
321
+ updatePlan: () => updatePlan2
322
+ });
323
+ function bulkUpdatePlanTags(req = {}, opts) {
324
+ return wixCall2("POST", "/pricing-plans/v3/bulk/plans/update-tags", req, opts);
325
+ }
326
+ function bulkUpdatePlanTagsByFilter(req = {}, opts) {
327
+ return wixCall2("POST", "/pricing-plans/v3/bulk/plans/update-tags-by-filter", req, opts);
328
+ }
329
+ function bulkUpdatePlans(req = {}, opts) {
330
+ return wixCall2("POST", "/pricing-plans/v3/bulk/plans/update", req, opts);
331
+ }
332
+ function countPlans(req = {}, opts) {
333
+ return wixCall2("POST", "/pricing-plans/v3/plans/count", req, opts);
334
+ }
335
+ function createPlan2(req = {}, opts) {
336
+ return wixCall2("POST", "/pricing-plans/v3/plans", req, opts);
337
+ }
338
+ function deletePlan(req, opts) {
339
+ return wixCall2("DELETE", "/pricing-plans/v3/plans/{planId}", req, opts, { pathFields: ["planId"], query: true });
340
+ }
341
+ function getPlan3(req, opts) {
342
+ return wixCall2("GET", "/pricing-plans/v3/plans/{planId}", req, opts, { pathFields: ["planId"], query: true });
343
+ }
344
+ function getPlanConfigurationConstraints(req = {}, opts) {
345
+ return wixCall2("GET", "/pricing-plans/ecom-integration/v3/plan-configuration-constraints", req, opts, { query: true });
346
+ }
347
+ function getPlanPreview(req = {}, opts) {
348
+ return wixCall2("GET", "/pricing-plans/ecom-integration/v3/plan-preview", req, opts, { query: true });
349
+ }
350
+ function listPlanPreviews(req = {}, opts) {
351
+ return wixCall2("POST", "/pricing-plans/ecom-integration/v3/plan-preview/previews", req, opts);
352
+ }
353
+ function queryPlans(req = {}, opts) {
354
+ return wixCall2("POST", "/pricing-plans/v3/plans/query", req, opts);
355
+ }
356
+ function searchPlans(req = {}, opts) {
357
+ return wixCall2("POST", "/pricing-plans/v3/plans/search", req, opts);
358
+ }
359
+ function updatePlan2(req, opts) {
360
+ return wixCall2("PATCH", "/pricing-plans/v3/plans/{planId}", req, opts, { pathFields: ["plan.id"] });
361
+ }
362
+
363
+ // ../../stdlib/wix-sdk-auto/pricing-plans/pricingPlansSettings.generated.ts
364
+ var pricingPlansSettings_generated_exports = {};
365
+ __export(pricingPlansSettings_generated_exports, {
366
+ getPricingPlansSettings: () => getPricingPlansSettings,
367
+ updatePricingPlansSettings: () => updatePricingPlansSettings
368
+ });
369
+ function getPricingPlansSettings(req = {}, opts) {
370
+ return wixCall2("GET", "/pricing-plans/settings/v1/pricing-plans-settings", req, opts, { query: true });
371
+ }
372
+ function updatePricingPlansSettings(req = {}, opts) {
373
+ return wixCall2("PATCH", "/pricing-plans/settings/v1/pricing-plans-settings", req, opts);
374
+ }
375
+
376
+ // ../../stdlib/wix-sdk-auto/pricing-plans/pricingVariantCategories.generated.ts
377
+ var pricingVariantCategories_generated_exports = {};
378
+ __export(pricingVariantCategories_generated_exports, {
379
+ createPricingVariantCategory: () => createPricingVariantCategory,
380
+ deletePricingVariantCategory: () => deletePricingVariantCategory,
381
+ getPricingVariantCategory: () => getPricingVariantCategory,
382
+ queryPricingVariantCategories: () => queryPricingVariantCategories,
383
+ updatePricingVariantCategory: () => updatePricingVariantCategory
384
+ });
385
+ function createPricingVariantCategory(req = {}, opts) {
386
+ return wixCall2("POST", "/_api/pricing-variant-categories/v3/pricing-variant-categories", req, opts);
387
+ }
388
+ function deletePricingVariantCategory(req, opts) {
389
+ return wixCall2("DELETE", "/_api/pricing-variant-categories/v3/pricing-variant-categories/{pricingVariantCategoryId}", req, opts, { pathFields: ["pricingVariantCategoryId"], query: true });
390
+ }
391
+ function getPricingVariantCategory(req, opts) {
392
+ return wixCall2("GET", "/_api/pricing-variant-categories/v3/pricing-variant-categories/{pricingVariantCategoryId}", req, opts, { pathFields: ["pricingVariantCategoryId"], query: true });
393
+ }
394
+ function queryPricingVariantCategories(req = {}, opts) {
395
+ return wixCall2("POST", "/_api/pricing-variant-categories/v3/pricing-variant-categories/query", req, opts);
396
+ }
397
+ function updatePricingVariantCategory(req, opts) {
398
+ return wixCall2("PATCH", "/_api/pricing-variant-categories/v3/pricing-variant-categories/{pricingVariantCategoryId}", req, opts, { pathFields: ["pricingVariantCategory.id"] });
399
+ }
70
400
  export {
71
401
  archivePlan,
72
402
  cancelPlanOrder,
@@ -79,7 +409,13 @@ export {
79
409
  listPlanOrders,
80
410
  listPlans,
81
411
  listPublicPlans,
412
+ orders_generated_exports as orders,
82
413
  pausePlanOrder,
414
+ planBenefits_generated_exports as planBenefits,
415
+ plans_generated_exports as plans,
416
+ plansV3_generated_exports as plansV3,
417
+ pricingPlansSettings_generated_exports as pricingPlansSettings,
418
+ pricingVariantCategories_generated_exports as pricingVariantCategories,
83
419
  requestCancellation,
84
420
  resumePlanOrder,
85
421
  setPlanVisibility