react-native-purchases 8.3.0 → 8.4.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.
@@ -29,7 +29,7 @@ android {
29
29
  minSdkVersion getExtOrIntegerDefault('minSdkVersion')
30
30
  targetSdkVersion getExtOrIntegerDefault('targetSdkVersion')
31
31
  versionCode 1
32
- versionName '8.3.0'
32
+ versionName '8.4.0'
33
33
  }
34
34
 
35
35
  buildTypes {
@@ -47,7 +47,7 @@ public class RNPurchasesModule extends ReactContextBaseJavaModule implements Upd
47
47
  private static final String CUSTOMER_INFO_UPDATED = "Purchases-CustomerInfoUpdated";
48
48
  private static final String LOG_HANDLER_EVENT = "Purchases-LogHandlerEvent";
49
49
  public static final String PLATFORM_NAME = "react-native";
50
- public static final String PLUGIN_VERSION = "8.3.0";
50
+ public static final String PLUGIN_VERSION = "8.4.0";
51
51
 
52
52
  private final ReactApplicationContext reactContext;
53
53
 
@@ -391,6 +391,16 @@ public class RNPurchasesModule extends ReactContextBaseJavaModule implements Upd
391
391
  SubscriberAttributesKt.setFirebaseAppInstanceID(firebaseAppInstanceId);
392
392
  }
393
393
 
394
+ @ReactMethod
395
+ public void setTenjinAnalyticsInstallationID(String tenjinAnalyticsInstallationID) {
396
+ SubscriberAttributesKt.setTenjinAnalyticsInstallationID(tenjinAnalyticsInstallationID);
397
+ }
398
+
399
+ @ReactMethod
400
+ public void setKochavaDeviceID(String kochavaDeviceID) {
401
+ SubscriberAttributesKt.setKochavaDeviceID(kochavaDeviceID);
402
+ }
403
+
394
404
  @ReactMethod
395
405
  public void setOnesignalID(String onesignalID) {
396
406
  SubscriberAttributesKt.setOnesignalID(onesignalID);
@@ -609,6 +609,24 @@ export default class Purchases {
609
609
  * setting the Firebase App Instance ID.
610
610
  */
611
611
  static setFirebaseAppInstanceID(firebaseAppInstanceID: string | null): Promise<void>;
612
+ /**
613
+ * Subscriber attribute associated with the Tenjin Analytics Installation ID for the user.
614
+ * Required for the RevenueCat Tenjin integration.
615
+ *
616
+ * @param tenjinAnalyticsInstallationID Tenjin analytics installation ID to use in the Tenjin integration. Empty String or null will delete the subscriber attribute.
617
+ * @returns {Promise<void>} The promise will be rejected if configure has not been called yet or if there's an error
618
+ * setting the Tenjin Analytics Installation ID.
619
+ */
620
+ static setTenjinAnalyticsInstallationID(tenjinAnalyticsInstallationID: string | null): Promise<void>;
621
+ /**
622
+ * Subscriber attribute associated with the Kochava Device ID for the user.
623
+ * Required for the RevenueCat Kochava integration.
624
+ *
625
+ * @param kochavaDeviceID Kochava device ID to use in the Kochava integration. Empty String or null will delete the subscriber attribute.
626
+ * @returns {Promise<void>} The promise will be rejected if configure has not been called yet or if there's an error
627
+ * setting the Kochava Device ID.
628
+ */
629
+ static setKochavaDeviceID(kochavaDeviceID: string | null): Promise<void>;
612
630
  /**
613
631
  * Subscriber attribute associated with the OneSignal Player Id for the user
614
632
  * Required for the RevenueCat OneSignal integration
package/dist/purchases.js CHANGED
@@ -1248,6 +1248,48 @@ var Purchases = /** @class */ (function () {
1248
1248
  });
1249
1249
  });
1250
1250
  };
1251
+ /**
1252
+ * Subscriber attribute associated with the Tenjin Analytics Installation ID for the user.
1253
+ * Required for the RevenueCat Tenjin integration.
1254
+ *
1255
+ * @param tenjinAnalyticsInstallationID Tenjin analytics installation ID to use in the Tenjin integration. Empty String or null will delete the subscriber attribute.
1256
+ * @returns {Promise<void>} The promise will be rejected if configure has not been called yet or if there's an error
1257
+ * setting the Tenjin Analytics Installation ID.
1258
+ */
1259
+ Purchases.setTenjinAnalyticsInstallationID = function (tenjinAnalyticsInstallationID) {
1260
+ return __awaiter(this, void 0, void 0, function () {
1261
+ return __generator(this, function (_a) {
1262
+ switch (_a.label) {
1263
+ case 0: return [4 /*yield*/, Purchases.throwIfNotConfigured()];
1264
+ case 1:
1265
+ _a.sent();
1266
+ RNPurchases.setTenjinAnalyticsInstallationID(tenjinAnalyticsInstallationID);
1267
+ return [2 /*return*/];
1268
+ }
1269
+ });
1270
+ });
1271
+ };
1272
+ /**
1273
+ * Subscriber attribute associated with the Kochava Device ID for the user.
1274
+ * Required for the RevenueCat Kochava integration.
1275
+ *
1276
+ * @param kochavaDeviceID Kochava device ID to use in the Kochava integration. Empty String or null will delete the subscriber attribute.
1277
+ * @returns {Promise<void>} The promise will be rejected if configure has not been called yet or if there's an error
1278
+ * setting the Kochava Device ID.
1279
+ */
1280
+ Purchases.setKochavaDeviceID = function (kochavaDeviceID) {
1281
+ return __awaiter(this, void 0, void 0, function () {
1282
+ return __generator(this, function (_a) {
1283
+ switch (_a.label) {
1284
+ case 0: return [4 /*yield*/, Purchases.throwIfNotConfigured()];
1285
+ case 1:
1286
+ _a.sent();
1287
+ RNPurchases.setKochavaDeviceID(kochavaDeviceID);
1288
+ return [2 /*return*/];
1289
+ }
1290
+ });
1291
+ });
1292
+ };
1251
1293
  /**
1252
1294
  * Subscriber attribute associated with the OneSignal Player Id for the user
1253
1295
  * Required for the RevenueCat OneSignal integration
package/ios/RNPurchases.m CHANGED
@@ -363,6 +363,14 @@ RCT_EXPORT_METHOD(setFirebaseAppInstanceID:(NSString *)firebaseAppInstanceId) {
363
363
  [RCCommonFunctionality setFirebaseAppInstanceID:firebaseAppInstanceId];
364
364
  }
365
365
 
366
+ RCT_EXPORT_METHOD(setTenjinAnalyticsInstallationID:(NSString *)tenjinAnalyticsInstallationID) {
367
+ [RCCommonFunctionality setTenjinAnalyticsInstallationID:tenjinAnalyticsInstallationID];
368
+ }
369
+
370
+ RCT_EXPORT_METHOD(setKochavaDeviceID:(NSString *)kochavaDeviceID) {
371
+ [RCCommonFunctionality setKochavaDeviceID:kochavaDeviceID];
372
+ }
373
+
366
374
  RCT_EXPORT_METHOD(setOnesignalID:(NSString *)onesignalID) {
367
375
  [RCCommonFunctionality setOnesignalID:onesignalID];
368
376
  }
@@ -564,7 +572,7 @@ readyForPromotedProduct:(RCStoreProduct *)product
564
572
  }
565
573
 
566
574
  - (NSString *)platformFlavorVersion {
567
- return @"8.3.0";
575
+ return @"8.4.0";
568
576
  }
569
577
 
570
578
  @end
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "react-native-purchases",
3
3
  "title": "React Native Purchases",
4
- "version": "8.3.0",
4
+ "version": "8.4.0",
5
5
  "description": "React Native in-app purchases and subscriptions made easy. Supports iOS and Android. ",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",