react-native-purchases 4.5.3 → 5.0.0-beta.1

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/index.js CHANGED
@@ -16,6 +16,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
16
16
  var purchases_1 = __importDefault(require("./purchases"));
17
17
  exports.default = purchases_1.default;
18
18
  __exportStar(require("./errors"), exports);
19
- __exportStar(require("./purchaserInfo"), exports);
19
+ __exportStar(require("./customerInfo"), exports);
20
20
  __exportStar(require("./purchases"), exports);
21
21
  __exportStar(require("./offerings"), exports);
@@ -48,9 +48,13 @@ export declare enum INTRO_ELIGIBILITY_STATUS {
48
48
  /**
49
49
  * The user is eligible for a free trial or intro pricing for this product.
50
50
  */
51
- INTRO_ELIGIBILITY_STATUS_ELIGIBLE = 2
51
+ INTRO_ELIGIBILITY_STATUS_ELIGIBLE = 2,
52
+ /**
53
+ * There is no free trial or intro pricing for this product.
54
+ */
55
+ INTRO_ELIGIBILITY_STATUS_NO_INTRO_OFFER_EXISTS = 3
52
56
  }
53
- export interface PurchasesProduct {
57
+ export interface PurchasesStoreProduct {
54
58
  /**
55
59
  * Product Id.
56
60
  */
@@ -75,52 +79,16 @@ export interface PurchasesProduct {
75
79
  * Currency code for price and original price.
76
80
  */
77
81
  readonly currency_code: string;
78
- /**
79
- * @deprecated, use introPrice instead.
80
- *
81
- * Introductory price of a subscription in the local currency.
82
- */
83
- readonly intro_price: number | null;
84
- /**
85
- * @deprecated, use introPrice instead.
86
- *
87
- * Formatted introductory price of a subscription, including its currency sign, such as €3.99.
88
- */
89
- readonly intro_price_string: string | null;
90
- /**
91
- * @deprecated, use introPrice instead.
92
- *
93
- * Billing period of the introductory price, specified in ISO 8601 format.
94
- */
95
- readonly intro_price_period: string | null;
96
- /**
97
- * @deprecated, use introPrice instead.
98
- *
99
- * Number of subscription billing periods for which the user will be given the introductory price, such as 3.
100
- */
101
- readonly intro_price_cycles: number | null;
102
- /**
103
- * @deprecated, use introPrice instead.
104
- *
105
- * Unit for the billing period of the introductory price, can be DAY, WEEK, MONTH or YEAR.
106
- */
107
- readonly intro_price_period_unit: string | null;
108
- /**
109
- * @deprecated, use introPrice instead.
110
- *
111
- * Number of units for the billing period of the introductory price.
112
- */
113
- readonly intro_price_period_number_of_units: number | null;
114
82
  /**
115
83
  * Introductory price.
116
84
  */
117
- readonly introPrice: PurchasesIntroPrice | null;
85
+ readonly intro_price: PurchasesIntroPrice | null;
118
86
  /**
119
87
  * Collection of discount offers for a product. Null for Android.
120
88
  */
121
- readonly discounts: PurchasesDiscount[] | null;
89
+ readonly discounts: PurchasesStoreProductDiscount[] | null;
122
90
  }
123
- export interface PurchasesDiscount {
91
+ export interface PurchasesStoreProductDiscount {
124
92
  /**
125
93
  * Identifier of the discount.
126
94
  */
@@ -192,7 +160,7 @@ export interface PurchasesPackage {
192
160
  /**
193
161
  * Product assigned to this package.
194
162
  */
195
- readonly product: PurchasesProduct;
163
+ readonly product: PurchasesStoreProduct;
196
164
  /**
197
165
  * Offering this package belongs to.
198
166
  */
@@ -286,7 +254,7 @@ export interface IntroEligibility {
286
254
  */
287
255
  readonly description: string;
288
256
  }
289
- export interface PurchasesPaymentDiscount {
257
+ export interface PurchasesPromotionalOffer {
290
258
  readonly identifier: string;
291
259
  readonly keyIdentifier: string;
292
260
  readonly nonce: string;
package/dist/offerings.js CHANGED
@@ -54,6 +54,10 @@ var INTRO_ELIGIBILITY_STATUS;
54
54
  * The user is eligible for a free trial or intro pricing for this product.
55
55
  */
56
56
  INTRO_ELIGIBILITY_STATUS[INTRO_ELIGIBILITY_STATUS["INTRO_ELIGIBILITY_STATUS_ELIGIBLE"] = 2] = "INTRO_ELIGIBILITY_STATUS_ELIGIBLE";
57
+ /**
58
+ * There is no free trial or intro pricing for this product.
59
+ */
60
+ INTRO_ELIGIBILITY_STATUS[INTRO_ELIGIBILITY_STATUS["INTRO_ELIGIBILITY_STATUS_NO_INTRO_OFFER_EXISTS"] = 3] = "INTRO_ELIGIBILITY_STATUS_NO_INTRO_OFFER_EXISTS";
57
61
  })(INTRO_ELIGIBILITY_STATUS = exports.INTRO_ELIGIBILITY_STATUS || (exports.INTRO_ELIGIBILITY_STATUS = {}));
58
62
  var PRORATION_MODE;
59
63
  (function (PRORATION_MODE) {
@@ -1,25 +1,17 @@
1
1
  import { PURCHASES_ERROR_CODE, UninitializedPurchasesError } from "./errors";
2
- import { PurchaserInfo } from "./purchaserInfo";
3
- import { PRORATION_MODE, PACKAGE_TYPE, INTRO_ELIGIBILITY_STATUS, PurchasesOfferings, PurchasesProduct, UpgradeInfo, PurchasesPaymentDiscount, PurchasesPackage, IntroEligibility, PurchasesDiscount } from "./offerings";
2
+ import { CustomerInfo } from "./customerInfo";
3
+ import { PRORATION_MODE, PACKAGE_TYPE, INTRO_ELIGIBILITY_STATUS, PurchasesOfferings, PurchasesStoreProduct, UpgradeInfo, PurchasesPromotionalOffer, PurchasesPackage, IntroEligibility, PurchasesStoreProductDiscount } from "./offerings";
4
4
  /**
5
- * Listener used on updated purchaser info
6
- * @callback PurchaserInfoUpdateListener
7
- * @param {Object} purchaserInfo Object containing info for the purchaser
5
+ * Listener used on updated customer info
6
+ * @callback CustomerInfoUpdateListener
7
+ * @param {Object} customerInfo Object containing info for the customer
8
8
  */
9
- export declare type PurchaserInfoUpdateListener = (purchaserInfo: PurchaserInfo) => void;
9
+ export declare type CustomerInfoUpdateListener = (customerInfo: CustomerInfo) => void;
10
10
  export declare type ShouldPurchasePromoProductListener = (deferredPurchase: () => Promise<MakePurchaseResult>) => void;
11
- declare type MakePurchaseResult = {
11
+ export declare type MakePurchaseResult = {
12
12
  productIdentifier: string;
13
- purchaserInfo: PurchaserInfo;
13
+ customerInfo: CustomerInfo;
14
14
  };
15
- export declare enum ATTRIBUTION_NETWORK {
16
- APPLE_SEARCH_ADS = 0,
17
- ADJUST = 1,
18
- APPSFLYER = 2,
19
- BRANCH = 3,
20
- TENJIN = 4,
21
- FACEBOOK = 5
22
- }
23
15
  export declare enum PURCHASE_TYPE {
24
16
  /**
25
17
  * A type of SKU for in-app products.
@@ -62,29 +54,15 @@ export declare enum BILLING_FEATURE {
62
54
  */
63
55
  export interface LogInResult {
64
56
  /**
65
- * The Purchaser Info for the user.
57
+ * The Customer Info for the user.
66
58
  */
67
- readonly purchaserInfo: PurchaserInfo;
59
+ readonly customerInfo: CustomerInfo;
68
60
  /**
69
61
  * True if the call resulted in a new user getting created in the RevenueCat backend.
70
62
  */
71
63
  readonly created: boolean;
72
64
  }
73
65
  export default class Purchases {
74
- /**
75
- * Enum for attribution networks
76
- * @readonly
77
- * @enum {number}
78
- */
79
- static ATTRIBUTION_NETWORK: typeof ATTRIBUTION_NETWORK;
80
- /**
81
- * @deprecated use ATTRIBUTION_NETWORK instead
82
- *
83
- * Enum for attribution networks
84
- * @readonly
85
- * @enum {number}
86
- */
87
- static ATTRIBUTION_NETWORKS: typeof ATTRIBUTION_NETWORK;
88
66
  /**
89
67
  * Supported SKU types.
90
68
  * @readonly
@@ -128,12 +106,13 @@ export default class Purchases {
128
106
  * Sets up Purchases with your API key and an app user id.
129
107
  * @param {String} apiKey RevenueCat API Key. Needs to be a String
130
108
  * @param {String?} appUserID An optional unique id for identifying the user. Needs to be a string.
131
- * @param {boolean?} observerMode An optional boolean. Set this to TRUE if you have your own IAP implementation and want to use only RevenueCat's backend. Default is FALSE.
109
+ * @param {boolean} [observerMode=false] An optional boolean. Set this to TRUE if you have your own IAP implementation and want to use only RevenueCat's backend. Default is FALSE.
110
+ * @param {boolean} [usesStoreKit2IfAvailable=false] An optional boolean. iOS-only. Set this to TRUE to enable StoreKit2 on compatible devices.
132
111
  * @param {String?} userDefaultsSuiteName An optional string. iOS-only, will be ignored for Android.
133
112
  * Set this if you would like the RevenueCat SDK to store its preferences in a different NSUserDefaults suite, otherwise it will use standardUserDefaults.
134
113
  * Default is null, which will make the SDK use standardUserDefaults.
135
114
  */
136
- static setup(apiKey: string, appUserID?: string | null, observerMode?: boolean, userDefaultsSuiteName?: string): void;
115
+ static configure(apiKey: string, appUserID?: string | null, observerMode?: boolean, userDefaultsSuiteName?: string, usesStoreKit2IfAvailable?: boolean): void;
137
116
  /**
138
117
  * @deprecated, configure behavior through the RevenueCat dashboard instead.
139
118
  * If an user tries to purchase a product that is active on the current app store account,
@@ -157,16 +136,16 @@ export default class Purchases {
157
136
  */
158
137
  static setSimulatesAskToBuyInSandbox(simulatesAskToBuyInSandbox: boolean): Promise<void>;
159
138
  /**
160
- * Sets a function to be called on updated purchaser info
161
- * @param {PurchaserInfoUpdateListener} purchaserInfoUpdateListener PurchaserInfo update listener
139
+ * Sets a function to be called on updated customer info
140
+ * @param {CustomerInfoUpdateListener} customerInfoUpdateListener CustomerInfo update listener
162
141
  */
163
- static addPurchaserInfoUpdateListener(purchaserInfoUpdateListener: PurchaserInfoUpdateListener): void;
142
+ static addCustomerInfoUpdateListener(customerInfoUpdateListener: CustomerInfoUpdateListener): void;
164
143
  /**
165
- * Removes a given PurchaserInfoUpdateListener
166
- * @param {PurchaserInfoUpdateListener} listenerToRemove PurchaserInfoUpdateListener reference of the listener to remove
144
+ * Removes a given CustomerInfoUpdateListener
145
+ * @param {CustomerInfoUpdateListener} listenerToRemove CustomerInfoUpdateListener reference of the listener to remove
167
146
  * @returns {boolean} True if listener was removed, false otherwise
168
147
  */
169
- static removePurchaserInfoUpdateListener(listenerToRemove: PurchaserInfoUpdateListener): boolean;
148
+ static removeCustomerInfoUpdateListener(listenerToRemove: CustomerInfoUpdateListener): boolean;
170
149
  /**
171
150
  * Sets a function to be called on purchases initiated on the Apple App Store. This is only used in iOS.
172
151
  * @param {ShouldPurchasePromoProductListener} shouldPurchasePromoProductListener Called when a user initiates a
@@ -184,18 +163,6 @@ export default class Purchases {
184
163
  * @returns {boolean} True if listener was removed, false otherwise
185
164
  */
186
165
  static removeShouldPurchasePromoProductListener(listenerToRemove: ShouldPurchasePromoProductListener): boolean;
187
- /**
188
- * @deprecated, use set<NetworkId> methods instead.
189
- *
190
- * Add a dict of attribution information
191
- * @param {Dict} data Attribution data from AppsFlyer, Adjust, or Branch
192
- * @param {ATTRIBUTION_NETWORKS} network Which network, see Purchases.ATTRIBUTION_NETWORKS
193
- * @param {String?} networkUserId An optional unique id for identifying the user. Needs to be a string.
194
- * @returns {Promise<void>} The promise will be rejected if setup has not been called yet.
195
- */
196
- static addAttributionData(data: {
197
- [key: string]: any;
198
- }, network: ATTRIBUTION_NETWORK, networkUserId?: string): Promise<void>;
199
166
  /**
200
167
  * Gets the map of entitlements -> offerings -> products
201
168
  * @returns {Promise<PurchasesOfferings>} Promise of entitlements structure. The promise will be rejected if setup
@@ -206,12 +173,12 @@ export default class Purchases {
206
173
  * Fetch the product info
207
174
  * @param {String[]} productIdentifiers Array of product identifiers
208
175
  * @param {String} type Optional type of products to fetch, can be inapp or subs. Subs by default
209
- * @returns {Promise<PurchasesProduct[]>} A promise containing an array of products. The promise will be rejected
176
+ * @returns {Promise<PurchasesStoreProduct[]>} A promise containing an array of products. The promise will be rejected
210
177
  * if the products are not properly configured in RevenueCat or if there is another error retrieving them.
211
178
  * Rejections return an error code, and a userInfo object with more information. The promise will also be rejected
212
179
  * if setup has not been called yet.
213
180
  */
214
- static getProducts(productIdentifiers: string[], type?: PURCHASE_TYPE): Promise<PurchasesProduct[]>;
181
+ static getProducts(productIdentifiers: string[], type?: PURCHASE_TYPE): Promise<PurchasesStoreProduct[]>;
215
182
  /**
216
183
  * Make a purchase
217
184
  *
@@ -219,8 +186,8 @@ export default class Purchases {
219
186
  * @param {UpgradeInfo} upgradeInfo Android only. Optional UpgradeInfo you wish to upgrade from containing the oldSKU
220
187
  * and the optional prorationMode.
221
188
  * @param {String} type Optional type of product, can be inapp or subs. Subs by default
222
- * @returns {Promise<{ productIdentifier: string, purchaserInfo:PurchaserInfo }>} A promise of an object containing
223
- * a purchaser info object and a product identifier. Rejections return an error code,
189
+ * @returns {Promise<{ productIdentifier: string, customerInfo:CustomerInfo }>} A promise of an object containing
190
+ * a customer info object and a product identifier. Rejections return an error code,
224
191
  * a boolean indicating if the user cancelled the purchase, and an object with more information. The promise will
225
192
  * also be rejected if setup has not been called yet.
226
193
  */
@@ -228,22 +195,22 @@ export default class Purchases {
228
195
  /**
229
196
  * iOS only. Purchase a product applying a given discount.
230
197
  *
231
- * @param {PurchasesProduct} product The product you want to purchase
232
- * @param {PurchasesPaymentDiscount} discount Discount to apply to this package. Retrieve this discount using getPaymentDiscount.
233
- * @returns {Promise<{ productIdentifier: string, purchaserInfo:PurchaserInfo }>} A promise of an object containing
234
- * a purchaser info object and a product identifier. Rejections return an error code,
198
+ * @param {PurchasesStoreProduct} product The product you want to purchase
199
+ * @param {PurchasesPromotionalOffer} discount Discount to apply to this package. Retrieve this discount using getPromotionalOffer.
200
+ * @returns {Promise<{ productIdentifier: string, customerInfo:CustomerInfo }>} A promise of an object containing
201
+ * a customer info object and a product identifier. Rejections return an error code,
235
202
  * a boolean indicating if the user cancelled the purchase, and an object with more information. The promise will be
236
203
  * rejected if setup has not been called yet.
237
204
  */
238
- static purchaseDiscountedProduct(product: PurchasesProduct, discount: PurchasesPaymentDiscount): Promise<MakePurchaseResult>;
205
+ static purchaseDiscountedProduct(product: PurchasesStoreProduct, discount: PurchasesPromotionalOffer): Promise<MakePurchaseResult>;
239
206
  /**
240
207
  * Make a purchase
241
208
  *
242
209
  * @param {PurchasesPackage} aPackage The Package you wish to purchase. You can get the Packages by calling getOfferings
243
210
  * @param {UpgradeInfo} upgradeInfo Android only. Optional UpgradeInfo you wish to upgrade from containing the oldSKU
244
211
  * and the optional prorationMode.
245
- * @returns {Promise<{ productIdentifier: string, purchaserInfo: PurchaserInfo }>} A promise of an object containing
246
- * a purchaser info object and a product identifier. Rejections return an error code, a boolean indicating if the
212
+ * @returns {Promise<{ productIdentifier: string, customerInfo: CustomerInfo }>} A promise of an object containing
213
+ * a customer info object and a product identifier. Rejections return an error code, a boolean indicating if the
247
214
  * user cancelled the purchase, and an object with more information. The promise will be also be rejected if setup
248
215
  * has not been called yet.
249
216
  */
@@ -252,19 +219,19 @@ export default class Purchases {
252
219
  * iOS only. Purchase a package applying a given discount.
253
220
  *
254
221
  * @param {PurchasesPackage} aPackage The Package you wish to purchase. You can get the Packages by calling getOfferings
255
- * @param {PurchasesPaymentDiscount} discount Discount to apply to this package. Retrieve this discount using getPaymentDiscount.
256
- * @returns {Promise<{ productIdentifier: string, purchaserInfo: PurchaserInfo }>} A promise of an object containing
257
- * a purchaser info object and a product identifier. Rejections return an error code, a boolean indicating if the
222
+ * @param {PurchasesPromotionalOffer} discount Discount to apply to this package. Retrieve this discount using getPromotionalOffer.
223
+ * @returns {Promise<{ productIdentifier: string, customerInfo: CustomerInfo }>} A promise of an object containing
224
+ * a customer info object and a product identifier. Rejections return an error code, a boolean indicating if the
258
225
  * user cancelled the purchase, and an object with more information. The promise will be also be rejected if setup
259
226
  * has not been called yet.
260
227
  */
261
- static purchaseDiscountedPackage(aPackage: PurchasesPackage, discount: PurchasesPaymentDiscount): Promise<MakePurchaseResult>;
228
+ static purchaseDiscountedPackage(aPackage: PurchasesPackage, discount: PurchasesPromotionalOffer): Promise<MakePurchaseResult>;
262
229
  /**
263
230
  * Restores a user's previous purchases and links their appUserIDs to any user's also using those purchases.
264
- * @returns {Promise<PurchaserInfo>} A promise of a purchaser info object. Rejections return an error code, and an
231
+ * @returns {Promise<CustomerInfo>} A promise of a customer info object. Rejections return an error code, and an
265
232
  * userInfo object with more information. The promise will be also be rejected if setup has not been called yet.
266
233
  */
267
- static restoreTransactions(): Promise<PurchaserInfo>;
234
+ static restoreTransactions(): Promise<CustomerInfo>;
268
235
  /**
269
236
  * Get the appUserID
270
237
  * @returns {Promise<string>} The app user id in a promise
@@ -274,59 +241,30 @@ export default class Purchases {
274
241
  * This function will logIn the current user with an appUserID. Typically this would be used after a log in
275
242
  * to identify a user without calling configure.
276
243
  * @param {String} appUserID The appUserID that should be linked to the currently user
277
- * @returns {Promise<LogInResult>} A promise of an object that contains the purchaserInfo after logging in, as well
244
+ * @returns {Promise<LogInResult>} A promise of an object that contains the customerInfo after logging in, as well
278
245
  * as a boolean indicating whether the user has just been created for the first time in the RevenueCat backend. The
279
246
  * promise will be rejected if setup has not been called yet or if there's an issue logging in.
280
247
  */
281
248
  static logIn(appUserID: string): Promise<LogInResult>;
282
249
  /**
283
250
  * Logs out the Purchases client clearing the saved appUserID. This will generate a random user id and save it in the cache.
284
- * @returns {Promise<PurchaserInfo>} A promise of a purchaser info object. Rejections return an error code,
251
+ * @returns {Promise<CustomerInfo>} A promise of a customer info object. Rejections return an error code,
285
252
  * and a userInfo object with more information. The promise will be rejected if setup has not been called yet or if
286
253
  * there's an issue logging out.
287
254
  */
288
- static logOut(): Promise<PurchaserInfo>;
289
- /**
290
- * @deprecated, use logIn instead.
291
- * This function will alias two appUserIDs together.
292
- * @param {String} newAppUserID The new appUserID that should be linked to the currently identified appUserID.
293
- * Needs to be a string.
294
- * @returns {Promise<PurchaserInfo>} A promise of a purchaser info object. Rejections return an error code, and a
295
- * userInfo object with more information. The promise will be rejected if setup has not been called yet or if
296
- * there's an issue creating the alias.
297
- */
298
- static createAlias(newAppUserID: string): Promise<PurchaserInfo>;
299
- /**
300
- * @deprecated, use logIn instead.
301
- * This function will identify the current user with an appUserID. Typically this would be used after a logout to
302
- * identify a new user without calling configure
303
- * @param {String} newAppUserID The appUserID that should be linked to the currently user
304
- * @returns {Promise<PurchaserInfo>} A promise of a purchaser info object. Rejections return an error code, and an
305
- * userInfo object with more information. The promise will be rejected if setup has not been called yet or if
306
- * there's an issue identifying the user.
307
- */
308
- static identify(newAppUserID: string): Promise<PurchaserInfo>;
309
- /**
310
- * @deprecated, use logOut instead.
311
- * Resets the Purchases client clearing the saved appUserID. This will generate a random user id and save it in the
312
- * cache.
313
- * @returns {Promise<PurchaserInfo>} A promise of a purchaser info object. Rejections return an error code, and an
314
- * userInfo object with more information. The promise will be rejected if setup has not been called yet or if
315
- * there's an issue resetting the user.
316
- */
317
- static reset(): Promise<PurchaserInfo>;
255
+ static logOut(): Promise<CustomerInfo>;
318
256
  /**
319
257
  * Enables/Disables debugs logs
320
258
  * @param {boolean} enabled Enable or not debug logs
321
259
  */
322
260
  static setDebugLogsEnabled(enabled: boolean): Promise<void>;
323
261
  /**
324
- * Gets current purchaser info
325
- * @returns {Promise<PurchaserInfo>} A promise of a purchaser info object. Rejections return an error code, and an
262
+ * Gets current customer info
263
+ * @returns {Promise<CustomerInfo>} A promise of a customer info object. Rejections return an error code, and an
326
264
  * userInfo object with more information. The promise will be rejected if setup has not been called yet or if
327
- * there's an issue getting the purchaser information.
265
+ * there's an issue getting the customer information.
328
266
  */
329
- static getPurchaserInfo(): Promise<PurchaserInfo>;
267
+ static getCustomerInfo(): Promise<CustomerInfo>;
330
268
  /**
331
269
  * This method will send all the purchases to the RevenueCat backend. Call this when using your own implementation
332
270
  * for subscriptions anytime a sync is needed, like after a successful purchase.
@@ -366,28 +304,28 @@ export default class Purchases {
366
304
  [productId: string]: IntroEligibility;
367
305
  }>;
368
306
  /**
369
- * iOS only. Use this function to retrieve the `PurchasesPaymentDiscount` for a given `PurchasesPackage`.
307
+ * iOS only. Use this function to retrieve the `PurchasesPromotionalOffer` for a given `PurchasesPackage`.
370
308
  *
371
309
  * @param product The `PurchasesProduct` the user intends to purchase.
372
310
  * @param discount The `PurchasesDiscount` to apply to the product.
373
- * @returns { Promise<PurchasesPaymentDiscount> } Returns when the `PurchasesPaymentDiscount` is returned.
311
+ * @returns { Promise<PurchasesPromotionalOffer> } Returns when the `PurchasesPaymentDiscount` is returned.
374
312
  * Null is returned for Android and incompatible iOS versions. The promise will be rejected if setup has not been
375
313
  * called yet or if there's an error getting the payment discount.
376
314
  */
377
- static getPaymentDiscount(product: PurchasesProduct, discount: PurchasesDiscount): Promise<PurchasesPaymentDiscount | undefined>;
315
+ static getPromotionalOffer(product: PurchasesStoreProduct, discount: PurchasesStoreProductDiscount): Promise<PurchasesPromotionalOffer | undefined>;
378
316
  /**
379
- * Invalidates the cache for purchaser information.
317
+ * Invalidates the cache for customer information.
380
318
  *
381
319
  * Most apps will not need to use this method; invalidating the cache can leave your app in an invalid state.
382
- * Refer to https://docs.revenuecat.com/docs/purchaserinfo#section-get-user-information for more information on
320
+ * Refer to https://docs.revenuecat.com/docs/customer-info#section-get-user-information for more information on
383
321
  * using the cache properly.
384
322
  *
385
- * This is useful for cases where purchaser information might have been updated outside of the app, like if a
323
+ * This is useful for cases where customer information might have been updated outside of the app, like if a
386
324
  * promotional subscription is granted through the RevenueCat dashboard.
387
325
  * @returns {Promise<void>} The promise will be rejected if setup has not been called yet or there's an error
388
- * invalidating the purchaser info cache.
326
+ * invalidating the customer info cache.
389
327
  */
390
- static invalidatePurchaserInfoCache(): Promise<void>;
328
+ static invalidateCustomerInfoCache(): Promise<void>;
391
329
  /** iOS only. Presents a code redemption sheet, useful for redeeming offer codes
392
330
  * Refer to https://docs.revenuecat.com/docs/ios-subscription-offers#offer-codes for more information on how
393
331
  * to configure and use offer codes
@@ -565,9 +503,9 @@ export default class Purchases {
565
503
  * Note: Billing features are only relevant to Google Play Android users.
566
504
  * For other stores and platforms, billing features won't be checked.
567
505
  *
568
- * @param feature An array of feature types to check for support. Feature types must be one of
506
+ * @param features An array of feature types to check for support. Feature types must be one of
569
507
  * [BILLING_FEATURE]. By default, is an empty list and no specific feature support will be checked.
570
- * @returns {Promise<Boolean>} promise with boolean response. True if billing is supported, false otherwise.
508
+ * @returns {Promise<boolean>} promise with boolean response. True if billing is supported, false otherwise.
571
509
  */
572
510
  static canMakePayments(features?: BILLING_FEATURE[]): Promise<boolean>;
573
511
  /**
@@ -578,4 +516,3 @@ export default class Purchases {
578
516
  static isConfigured(): Promise<boolean>;
579
517
  private static throwIfNotConfigured;
580
518
  }
581
- export {};