@wix/himalaya-cli 0.1372.0 → 0.1374.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.
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/_types/core/sdk/iap/src/wix-payments-contract.d.ts +8 -2
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/iap-checkout.mjs +10 -1
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/iap.mjs +12 -1
- package/dist/authoring-runtime/node_modules/@wix/himalaya/dist/screens.mjs +10 -1
- package/dist/cli.mjs +219 -76
- package/dist/preview-assets.generated.bin +0 -0
- package/guides/himi-json-output.md +22 -0
- package/guides/iap-products.md +40 -5
- package/guides/sdk-reference.json +14 -2
- package/package.json +2 -2
- package/template-icons/base44-fitness.png +0 -0
|
@@ -49,13 +49,19 @@ export declare const STORES_ITEM_PAYMENT_ENABLED = false;
|
|
|
49
49
|
/** StartItemPayment's CatalogReference: the purchases catalog sells a Stores product under its product
|
|
50
50
|
* id (eCom's `catalogItemId`). One-time unlocks only, whatever the backend also accepts. */
|
|
51
51
|
export declare const STORES_PRODUCT_SALE_RULE: AppleSaleRule;
|
|
52
|
+
/** Off until a member's plan order, its cashier item id and Sandbox fulfillment are proven live.
|
|
53
|
+
* Recurring and time-limited plans stay outside this rule; their Billing lifecycle is unfinished. */
|
|
54
|
+
export declare const PRICING_PLAN_APPLE_SALES_ENABLED = false;
|
|
52
55
|
/**
|
|
53
56
|
* The one definition `himi store iap connect` writes mappings by and the mapping source reads them by,
|
|
54
57
|
* keyed by catalog kind. wix-iap StartPayment maps the cashier order's single item id, and Online
|
|
55
58
|
* Programs builds that order with the program id as the item id; programs are one-time unlocks.
|
|
56
|
-
* Wix Stores
|
|
57
|
-
* established yet, so their items keep their own commerce.
|
|
59
|
+
* Wix Stores and one-time unlimited Pricing Plans join only with their independent switches.
|
|
58
60
|
*/
|
|
61
|
+
export declare function appleSaleRules(options?: {
|
|
62
|
+
storesItemPaymentEnabled?: boolean;
|
|
63
|
+
pricingPlanAppleSalesEnabled?: boolean;
|
|
64
|
+
}): Readonly<Record<string, AppleSaleRule>>;
|
|
59
65
|
export declare const APPLE_SALE_RULES: Readonly<Record<string, AppleSaleRule>>;
|
|
60
66
|
/** Captured when a protected call starts. The native bridge checks it and never puts it on
|
|
61
67
|
* the HTTP request. */
|
|
@@ -688,7 +688,16 @@ var HIMALAYA_SERVE_IAP_ROUTE = { prefix: "/himalaya-serve/v1/iap" };
|
|
|
688
688
|
var STORES_ITEM_PAYMENT_ENABLED = false;
|
|
689
689
|
var STORES_PRODUCT_SALE_RULE = { appProductId: (id) => id, productType: "NON_CONSUMABLE" };
|
|
690
690
|
var ONLINE_PROGRAM_SALE_RULE = { appProductId: (id) => id, productType: "NON_CONSUMABLE" };
|
|
691
|
-
var
|
|
691
|
+
var PRICING_PLAN_APPLE_SALES_ENABLED = false;
|
|
692
|
+
var PRICING_PLAN_SALE_RULE = { appProductId: (id) => id, productType: "NON_CONSUMABLE" };
|
|
693
|
+
function appleSaleRules(options = {}) {
|
|
694
|
+
return {
|
|
695
|
+
onlineProgram: ONLINE_PROGRAM_SALE_RULE,
|
|
696
|
+
...options.storesItemPaymentEnabled ?? STORES_ITEM_PAYMENT_ENABLED ? { storesProduct: STORES_PRODUCT_SALE_RULE } : {},
|
|
697
|
+
...options.pricingPlanAppleSalesEnabled ?? PRICING_PLAN_APPLE_SALES_ENABLED ? { pricingPlan: PRICING_PLAN_SALE_RULE } : {}
|
|
698
|
+
};
|
|
699
|
+
}
|
|
700
|
+
var APPLE_SALE_RULES = appleSaleRules();
|
|
692
701
|
|
|
693
702
|
// ../../core/sdk/iap/src/mapping-source.ts
|
|
694
703
|
function iapMappingSource() {
|
|
@@ -666,7 +666,16 @@ var HIMALAYA_SERVE_IAP_ROUTE = { prefix: "/himalaya-serve/v1/iap" };
|
|
|
666
666
|
var STORES_ITEM_PAYMENT_ENABLED = false;
|
|
667
667
|
var STORES_PRODUCT_SALE_RULE = { appProductId: (id) => id, productType: "NON_CONSUMABLE" };
|
|
668
668
|
var ONLINE_PROGRAM_SALE_RULE = { appProductId: (id) => id, productType: "NON_CONSUMABLE" };
|
|
669
|
-
var
|
|
669
|
+
var PRICING_PLAN_APPLE_SALES_ENABLED = false;
|
|
670
|
+
var PRICING_PLAN_SALE_RULE = { appProductId: (id) => id, productType: "NON_CONSUMABLE" };
|
|
671
|
+
function appleSaleRules(options = {}) {
|
|
672
|
+
return {
|
|
673
|
+
onlineProgram: ONLINE_PROGRAM_SALE_RULE,
|
|
674
|
+
...options.storesItemPaymentEnabled ?? STORES_ITEM_PAYMENT_ENABLED ? { storesProduct: STORES_PRODUCT_SALE_RULE } : {},
|
|
675
|
+
...options.pricingPlanAppleSalesEnabled ?? PRICING_PLAN_APPLE_SALES_ENABLED ? { pricingPlan: PRICING_PLAN_SALE_RULE } : {}
|
|
676
|
+
};
|
|
677
|
+
}
|
|
678
|
+
var APPLE_SALE_RULES = appleSaleRules();
|
|
670
679
|
|
|
671
680
|
// ../../core/sdk/iap/src/mapping-source.ts
|
|
672
681
|
function iapMappingSource() {
|
|
@@ -1469,9 +1478,11 @@ export {
|
|
|
1469
1478
|
IAP_CATALOG_KINDS,
|
|
1470
1479
|
MAX_AUTOMATIC_ATTEMPTS,
|
|
1471
1480
|
MAX_RETRY_DELAY_MS,
|
|
1481
|
+
PRICING_PLAN_APPLE_SALES_ENABLED,
|
|
1472
1482
|
STORES_ITEM_PAYMENT_ENABLED,
|
|
1473
1483
|
STORES_PRODUCT_SALE_RULE,
|
|
1474
1484
|
appleManagedStore,
|
|
1485
|
+
appleSaleRules,
|
|
1475
1486
|
consume,
|
|
1476
1487
|
createHostSession,
|
|
1477
1488
|
createIapCatalogPricing,
|
|
@@ -941,7 +941,16 @@ var HIMALAYA_SERVE_IAP_ROUTE = { prefix: "/himalaya-serve/v1/iap" };
|
|
|
941
941
|
var STORES_ITEM_PAYMENT_ENABLED = false;
|
|
942
942
|
var STORES_PRODUCT_SALE_RULE = { appProductId: (id2) => id2, productType: "NON_CONSUMABLE" };
|
|
943
943
|
var ONLINE_PROGRAM_SALE_RULE = { appProductId: (id2) => id2, productType: "NON_CONSUMABLE" };
|
|
944
|
-
var
|
|
944
|
+
var PRICING_PLAN_APPLE_SALES_ENABLED = false;
|
|
945
|
+
var PRICING_PLAN_SALE_RULE = { appProductId: (id2) => id2, productType: "NON_CONSUMABLE" };
|
|
946
|
+
function appleSaleRules(options = {}) {
|
|
947
|
+
return {
|
|
948
|
+
onlineProgram: ONLINE_PROGRAM_SALE_RULE,
|
|
949
|
+
...options.storesItemPaymentEnabled ?? STORES_ITEM_PAYMENT_ENABLED ? { storesProduct: STORES_PRODUCT_SALE_RULE } : {},
|
|
950
|
+
...options.pricingPlanAppleSalesEnabled ?? PRICING_PLAN_APPLE_SALES_ENABLED ? { pricingPlan: PRICING_PLAN_SALE_RULE } : {}
|
|
951
|
+
};
|
|
952
|
+
}
|
|
953
|
+
var APPLE_SALE_RULES = appleSaleRules();
|
|
945
954
|
|
|
946
955
|
// ../../core/sdk/iap/src/mapping-source.ts
|
|
947
956
|
function iapMappingSource() {
|