@adapty/core 3.15.0 → 3.17.0-dev.5c4a161bbdfb513a2e64d0216dcdc7abc56efecc

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.d.cts CHANGED
@@ -142,6 +142,115 @@ declare class LogContext {
142
142
 
143
143
  //#endregion
144
144
  //#region src/types/error.d.ts
145
+ declare const ErrorCodeMapping: Readonly<{
146
+ /**
147
+ * System StoreKit codes
148
+ */
149
+ 0: "unknown";
150
+ /**
151
+ * Client is not allowed to make a request, etc.
152
+ */
153
+ 1: "clientInvalid";
154
+ /**
155
+ * Invalid purchase identifier, etc.
156
+ */
157
+ 3: "paymentInvalid";
158
+ /**
159
+ * This device is not allowed to make the payment.
160
+ */
161
+ 4: "paymentNotAllowed";
162
+ /**
163
+ * Product is not available in the current storefront.
164
+ */
165
+ 5: "storeProductNotAvailable";
166
+ /**
167
+ * User has not allowed access to cloud service information.
168
+ */
169
+ 6: "cloudServicePermissionDenied";
170
+ /**
171
+ * The device could not connect to the network.
172
+ */
173
+ 7: "cloudServiceNetworkConnectionFailed";
174
+ /**
175
+ * User has revoked permission to use this cloud service.
176
+ */
177
+ 8: "cloudServiceRevoked";
178
+ /**
179
+ * The user needs to acknowledge Apple's privacy policy.
180
+ */
181
+ 9: "privacyAcknowledgementRequired";
182
+ /**
183
+ * The app is attempting to use SKPayment's requestData property,
184
+ * but does not have the appropriate entitlement.
185
+ */
186
+ 10: "unauthorizedRequestData";
187
+ /**
188
+ * The specified subscription offer identifier is not valid.
189
+ */
190
+ 11: "invalidOfferIdentifier";
191
+ /**
192
+ * The cryptographic signature provided is not valid.
193
+ */
194
+ 12: "invalidSignature";
195
+ /**
196
+ * One or more parameters from SKPaymentDiscount is missing.
197
+ */
198
+ 13: "missingOfferParams";
199
+ 14: "invalidOfferPrice";
200
+ /**
201
+ * Custom Android codes.
202
+ */
203
+ 20: "adaptyNotInitialized";
204
+ 22: "productNotFound";
205
+ 24: "currentSubscriptionToUpdateNotFoundInHistory";
206
+ 97: "billingServiceTimeout";
207
+ 98: "featureNotSupported";
208
+ 99: "billingServiceDisconnected";
209
+ 102: "billingServiceUnavailable";
210
+ 103: "billingUnavailable";
211
+ 105: "developerError";
212
+ 106: "billingError";
213
+ 107: "itemAlreadyOwned";
214
+ 108: "itemNotOwned";
215
+ 112: "billingNetworkError";
216
+ 1000: "noProductIDsFound";
217
+ 1002: "productRequestFailed";
218
+ /**
219
+ * In-App Purchases are not allowed on this device.
220
+ */
221
+ 1003: "cantMakePayments";
222
+ 1004: "noPurchasesToRestore";
223
+ 1005: "cantReadReceipt";
224
+ 1006: "productPurchaseFailed";
225
+ 1010: "refreshReceiptFailed";
226
+ 1011: "receiveRestoredTransactionsFailed";
227
+ /**
228
+ * You need to be authenticated to perform requests.
229
+ */
230
+ 2002: "notActivated";
231
+ 2003: "badRequest";
232
+ 2004: "serverError";
233
+ 2005: "networkFailed";
234
+ 2006: "decodingFailed";
235
+ 2009: "encodingFailed";
236
+ 3000: "analyticsDisabled";
237
+ /**
238
+ * Wrong parameter was passed.
239
+ */
240
+ 3001: "wrongParam";
241
+ /**
242
+ * It is not possible to call `.activate` method more than once.
243
+ */
244
+ 3005: "activateOnceError";
245
+ /**
246
+ * The user profile was changed during the operation.
247
+ */
248
+ 3006: "profileWasChanged";
249
+ 3007: "unsupportedData";
250
+ 3100: "persistingDataError";
251
+ 3101: "fetchTimeoutError";
252
+ 9000: "operationInterrupted";
253
+ }>;
145
254
  declare const ErrorCode: Readonly<{
146
255
  /**
147
256
  * System StoreKit codes
@@ -251,13 +360,62 @@ declare const ErrorCode: Readonly<{
251
360
  3101: "fetchTimeoutError";
252
361
  9000: "operationInterrupted";
253
362
  }>;
254
- type ErrorCode = keyof typeof ErrorCode;
363
+ type ErrorCode = keyof typeof ErrorCodeMapping;
364
+ declare const ErrorCodeName: Readonly<{
365
+ readonly unknown: 0;
366
+ readonly clientInvalid: 1;
367
+ readonly paymentInvalid: 3;
368
+ readonly paymentNotAllowed: 4;
369
+ readonly storeProductNotAvailable: 5;
370
+ readonly cloudServicePermissionDenied: 6;
371
+ readonly cloudServiceNetworkConnectionFailed: 7;
372
+ readonly cloudServiceRevoked: 8;
373
+ readonly privacyAcknowledgementRequired: 9;
374
+ readonly unauthorizedRequestData: 10;
375
+ readonly invalidOfferIdentifier: 11;
376
+ readonly invalidSignature: 12;
377
+ readonly missingOfferParams: 13;
378
+ readonly invalidOfferPrice: 14;
379
+ readonly adaptyNotInitialized: 20;
380
+ readonly productNotFound: 22;
381
+ readonly currentSubscriptionToUpdateNotFoundInHistory: 24;
382
+ readonly billingServiceTimeout: 97;
383
+ readonly featureNotSupported: 98;
384
+ readonly billingServiceDisconnected: 99;
385
+ readonly billingServiceUnavailable: 102;
386
+ readonly billingUnavailable: 103;
387
+ readonly developerError: 105;
388
+ readonly billingError: 106;
389
+ readonly itemAlreadyOwned: 107;
390
+ readonly itemNotOwned: 108;
391
+ readonly billingNetworkError: 112;
392
+ readonly noProductIDsFound: 1000;
393
+ readonly productRequestFailed: 1002;
394
+ readonly cantMakePayments: 1003;
395
+ readonly noPurchasesToRestore: 1004;
396
+ readonly cantReadReceipt: 1005;
397
+ readonly productPurchaseFailed: 1006;
398
+ readonly refreshReceiptFailed: 1010;
399
+ readonly receiveRestoredTransactionsFailed: 1011;
400
+ readonly notActivated: 2002;
401
+ readonly badRequest: 2003;
402
+ readonly serverError: 2004;
403
+ readonly networkFailed: 2005;
404
+ readonly decodingFailed: 2006;
405
+ readonly encodingFailed: 2009;
406
+ readonly analyticsDisabled: 3000;
407
+ readonly wrongParam: 3001;
408
+ readonly activateOnceError: 3005;
409
+ readonly profileWasChanged: 3006;
410
+ readonly unsupportedData: 3007;
411
+ readonly persistingDataError: 3100;
412
+ readonly fetchTimeoutError: 3101;
413
+ readonly operationInterrupted: 9000;
414
+ }>;
415
+ type ErrorCodeName = keyof typeof ErrorCodeName;
255
416
  declare function getErrorCode(error: (typeof ErrorCode)[ErrorCode]): ErrorCode | undefined;
256
- declare function getErrorPrompt(code: ErrorCode): (typeof ErrorCode)[ErrorCode];
257
-
258
- //#endregion
417
+ declare function getErrorPrompt(code: ErrorCode): (typeof ErrorCode)[ErrorCode]; //#endregion
259
418
  //#region src/adapty-error.d.ts
260
- //# sourceMappingURL=error.d.ts.map
261
419
  interface AdaptyErrorInput {
262
420
  adaptyCode: ErrorCode;
263
421
  message: string;
@@ -421,7 +579,7 @@ interface AdaptyOnboarding {
421
579
  version?: number;
422
580
  payloadData?: string;
423
581
  requestLocale: string;
424
- onboardingBuilder?: AdaptyOnboardingBuilder;
582
+ onboardingBuilder: AdaptyOnboardingBuilder;
425
583
  }
426
584
  interface AdaptyPlacement {
427
585
  /**
@@ -1149,7 +1307,15 @@ interface EventHandlers {
1149
1307
  */
1150
1308
  onLoadingProductsFailed: (error: AdaptyError) => EventHandlerResult;
1151
1309
  onCustomAction: (actionId: string) => EventHandlerResult;
1152
- onUrlPress: (url: string) => EventHandlerResult;
1310
+ /**
1311
+ * Called when the user taps a URL/link inside the paywall.
1312
+ *
1313
+ * @param url - URL to open
1314
+ * @param openIn - How the URL was configured to open in the dashboard:
1315
+ * `'browser_in_app'` — in-app browser (e.g. `WKWebView` / `Custom Tabs`)
1316
+ * `'browser_out_app'` (default) — external browser (e.g. `Linking.openURL`)
1317
+ */
1318
+ onUrlPress: (url: string, openIn: WebPresentation) => EventHandlerResult;
1153
1319
  }
1154
1320
  interface OnboardingEventHandlers {
1155
1321
  onClose: (actionId: string, meta: AdaptyUiOnboardingMeta) => EventHandlerResult;
@@ -1727,6 +1893,26 @@ interface components {
1727
1893
  }, {
1728
1894
  success: components['defs']['AdaptyUI.PaywallView'];
1729
1895
  }]>;
1896
+ 'AdaptyUICreateOnboardingView.Request': {
1897
+ method: 'adapty_ui_create_onboarding_view';
1898
+ onboarding: components['defs']['AdaptyOnboarding'];
1899
+ external_urls_presentation?: components['defs']['AdaptyWebPresentation'];
1900
+ };
1901
+ 'AdaptyUICreateOnboardingView.Response': OneOf<[{
1902
+ error: components['defs']['AdaptyError'];
1903
+ }, {
1904
+ success: components['defs']['AdaptyUI.OnboardingView'];
1905
+ }]>;
1906
+ 'AdaptyUIDismissOnboardingView.Request': {
1907
+ method: 'adapty_ui_dismiss_onboarding_view';
1908
+ id: string;
1909
+ destroy?: boolean;
1910
+ };
1911
+ 'AdaptyUIDismissOnboardingView.Response': OneOf<[{
1912
+ error: components['defs']['AdaptyError'];
1913
+ }, {
1914
+ success: true;
1915
+ }]>;
1730
1916
  'AdaptyUIDismissPaywallView.Request': {
1731
1917
  method: 'adapty_ui_dismiss_paywall_view';
1732
1918
  id: string;
@@ -1737,6 +1923,16 @@ interface components {
1737
1923
  }, {
1738
1924
  success: true;
1739
1925
  }]>;
1926
+ 'AdaptyUIPresentOnboardingView.Request': {
1927
+ method: 'adapty_ui_present_onboarding_view';
1928
+ id: string;
1929
+ ios_presentation_style?: components['defs']['AdaptyUI.IOSPresentationStyle'];
1930
+ };
1931
+ 'AdaptyUIPresentOnboardingView.Response': OneOf<[{
1932
+ error: components['defs']['AdaptyError'];
1933
+ }, {
1934
+ success: true;
1935
+ }]>;
1740
1936
  'AdaptyUIPresentPaywallView.Request': {
1741
1937
  method: 'adapty_ui_present_paywall_view';
1742
1938
  id: string;
@@ -1757,35 +1953,28 @@ interface components {
1757
1953
  }, {
1758
1954
  success: components['defs']['AdaptyUI.DialogActionType'];
1759
1955
  }]>;
1760
- 'AdaptyUICreateOnboardingView.Request': {
1761
- method: 'adapty_ui_create_onboarding_view';
1762
- onboarding: components['defs']['AdaptyOnboarding'];
1763
- external_urls_presentation?: components['defs']['AdaptyWebPresentation'];
1764
- };
1765
- 'AdaptyUICreateOnboardingView.Response': OneOf<[{
1766
- error: components['defs']['AdaptyError'];
1767
- }, {
1768
- success: components['defs']['AdaptyUI.OnboardingView'];
1769
- }]>;
1770
- 'AdaptyUIDismissOnboardingView.Request': {
1771
- method: 'adapty_ui_dismiss_onboarding_view';
1772
- id: string;
1773
- destroy?: boolean;
1956
+ 'GetOnboarding.Request': {
1957
+ method: 'get_onboarding';
1958
+ placement_id: string;
1959
+ locale?: components['defs']['AdaptyLocale'];
1960
+ fetch_policy?: components['defs']['AdaptyPlacementFetchPolicy'];
1961
+ load_timeout?: number;
1774
1962
  };
1775
- 'AdaptyUIDismissOnboardingView.Response': OneOf<[{
1963
+ 'GetOnboarding.Response': OneOf<[{
1776
1964
  error: components['defs']['AdaptyError'];
1777
1965
  }, {
1778
- success: true;
1966
+ success: components['defs']['AdaptyOnboarding'];
1779
1967
  }]>;
1780
- 'AdaptyUIPresentOnboardingView.Request': {
1781
- method: 'adapty_ui_present_onboarding_view';
1782
- id: string;
1783
- ios_presentation_style?: components['defs']['AdaptyUI.IOSPresentationStyle'];
1968
+ 'GetOnboardingForDefaultAudience.Request': {
1969
+ method: 'get_onboarding_for_default_audience';
1970
+ placement_id: string;
1971
+ locale?: components['defs']['AdaptyLocale'];
1972
+ fetch_policy?: components['defs']['AdaptyPlacementFetchPolicy'];
1784
1973
  };
1785
- 'AdaptyUIPresentOnboardingView.Response': OneOf<[{
1974
+ 'GetOnboardingForDefaultAudience.Response': OneOf<[{
1786
1975
  error: components['defs']['AdaptyError'];
1787
1976
  }, {
1788
- success: true;
1977
+ success: components['defs']['AdaptyOnboarding'];
1789
1978
  }]>;
1790
1979
  'GetPaywall.Request': {
1791
1980
  method: 'get_paywall';
@@ -1819,29 +2008,6 @@ interface components {
1819
2008
  }, {
1820
2009
  success: components['defs']['AdaptyPaywallProduct.Response'][];
1821
2010
  }]>;
1822
- 'GetOnboarding.Request': {
1823
- method: 'get_onboarding';
1824
- placement_id: string;
1825
- locale?: components['defs']['AdaptyLocale'];
1826
- fetch_policy?: components['defs']['AdaptyPlacementFetchPolicy'];
1827
- load_timeout?: number;
1828
- };
1829
- 'GetOnboarding.Response': OneOf<[{
1830
- error: components['defs']['AdaptyError'];
1831
- }, {
1832
- success: components['defs']['AdaptyOnboarding'];
1833
- }]>;
1834
- 'GetOnboardingForDefaultAudience.Request': {
1835
- method: 'get_onboarding_for_default_audience';
1836
- placement_id: string;
1837
- locale?: components['defs']['AdaptyLocale'];
1838
- fetch_policy?: components['defs']['AdaptyPlacementFetchPolicy'];
1839
- };
1840
- 'GetOnboardingForDefaultAudience.Response': OneOf<[{
1841
- error: components['defs']['AdaptyError'];
1842
- }, {
1843
- success: components['defs']['AdaptyOnboarding'];
1844
- }]>;
1845
2011
  'GetProfile.Request': {
1846
2012
  method: 'get_profile';
1847
2013
  };
@@ -1906,25 +2072,24 @@ interface components {
1906
2072
  }, {
1907
2073
  success: components['defs']['AdaptyPurchaseResult'];
1908
2074
  }]>;
1909
- 'OpenWebPaywall.Request': OneOf<[{
2075
+ 'OpenWebPaywall.Request': {
1910
2076
  method: 'open_web_paywall';
1911
- product: components['defs']['AdaptyPaywallProduct.Request'];
1912
2077
  open_in?: components['defs']['AdaptyWebPresentation'];
2078
+ } & OneOf<[{
2079
+ product: components['defs']['AdaptyPaywallProduct.Request'];
1913
2080
  }, {
1914
- method: 'open_web_paywall';
1915
2081
  paywall: components['defs']['AdaptyPaywall'];
1916
- open_in?: components['defs']['AdaptyWebPresentation'];
1917
2082
  }]>;
1918
2083
  'OpenWebPaywall.Response': OneOf<[{
1919
2084
  error: components['defs']['AdaptyError'];
1920
2085
  }, {
1921
2086
  success: true;
1922
2087
  }]>;
1923
- 'CreateWebPaywallUrl.Request': OneOf<[{
2088
+ 'CreateWebPaywallUrl.Request': {
1924
2089
  method: 'create_web_paywall_url';
2090
+ } & OneOf<[{
1925
2091
  product: components['defs']['AdaptyPaywallProduct.Request'];
1926
2092
  }, {
1927
- method: 'create_web_paywall_url';
1928
2093
  paywall: components['defs']['AdaptyPaywall'];
1929
2094
  }]>;
1930
2095
  'CreateWebPaywallUrl.Response': OneOf<[{
@@ -1932,6 +2097,14 @@ interface components {
1932
2097
  }, {
1933
2098
  success: string;
1934
2099
  }]>;
2100
+ 'GetCurrentInstallationStatus.Request': {
2101
+ method: 'get_current_installation_status';
2102
+ };
2103
+ 'GetCurrentInstallationStatus.Response': OneOf<[{
2104
+ error: components['defs']['AdaptyError'];
2105
+ }, {
2106
+ success: components['defs']['AdaptyInstallationStatus'];
2107
+ }]>;
1935
2108
  'PresentCodeRedemptionSheet.Request': {
1936
2109
  method: 'present_code_redemption_sheet';
1937
2110
  };
@@ -1940,8 +2113,8 @@ interface components {
1940
2113
  };
1941
2114
  'ReportTransaction.Request': {
1942
2115
  method: 'report_transaction';
1943
- transaction_id: string;
1944
2116
  variation_id?: string;
2117
+ transaction_id: string;
1945
2118
  };
1946
2119
  'ReportTransaction.Response': OneOf<[{
1947
2120
  error: components['defs']['AdaptyError'];
@@ -1962,14 +2135,6 @@ interface components {
1962
2135
  'GetSDKVersion.Response': {
1963
2136
  success: string;
1964
2137
  };
1965
- 'GetCurrentInstallationStatus.Request': {
1966
- method: 'get_current_installation_status';
1967
- };
1968
- 'GetCurrentInstallationStatus.Response': OneOf<[{
1969
- error: components['defs']['AdaptyError'];
1970
- }, {
1971
- success: components['defs']['AdaptyInstallationStatus'];
1972
- }]>;
1973
2138
  'SetFallback.Request': {
1974
2139
  method: 'set_fallback';
1975
2140
  } & OneOf<[{
@@ -1984,7 +2149,9 @@ interface components {
1984
2149
  }]>;
1985
2150
  'SetIntegrationIdentifier.Request': {
1986
2151
  method: 'set_integration_identifiers';
1987
- key_values: Record<string, string>;
2152
+ key_values: {
2153
+ [key: string]: string;
2154
+ };
1988
2155
  };
1989
2156
  'SetIntegrationIdentifier.Response': OneOf<[{
1990
2157
  error: components['defs']['AdaptyError'];
@@ -2216,19 +2383,6 @@ interface components {
2216
2383
  obfuscated_account_id?: string;
2217
2384
  obfuscated_profile_id?: string;
2218
2385
  };
2219
- 'AdaptyPaywallProduct.Request': {
2220
- vendor_product_id: string;
2221
- adapty_product_id: string;
2222
- access_level_id: string;
2223
- product_type: string;
2224
- paywall_product_index: number;
2225
- subscription_offer_identifier?: components['defs']['AdaptySubscriptionOffer.Identifier'];
2226
- paywall_variation_id: string;
2227
- paywall_ab_test_name: string;
2228
- paywall_name: string;
2229
- web_purchase_url?: string;
2230
- payload_data?: string;
2231
- };
2232
2386
  'AdaptyPaywallProduct.Response': {
2233
2387
  vendor_product_id: string;
2234
2388
  adapty_product_id: string;
@@ -2261,6 +2415,19 @@ interface components {
2261
2415
  renewal_type?: 'prepaid' | 'autorenewable';
2262
2416
  base_plan_id?: string;
2263
2417
  };
2418
+ 'AdaptyPaywallProduct.Request': {
2419
+ vendor_product_id: string;
2420
+ adapty_product_id: string;
2421
+ access_level_id: string;
2422
+ product_type: string;
2423
+ paywall_product_index: number;
2424
+ subscription_offer_identifier?: components['defs']['AdaptySubscriptionOffer.Identifier'];
2425
+ paywall_variation_id: string;
2426
+ paywall_ab_test_name: string;
2427
+ paywall_name: string;
2428
+ web_purchase_url?: string;
2429
+ payload_data?: string;
2430
+ };
2264
2431
  AdaptySubscriptionOffer: {
2265
2432
  offer_identifier: components['defs']['AdaptySubscriptionOffer.Identifier'];
2266
2433
  phases: components['defs']['AdaptySubscriptionOffer.Phase'][];
@@ -2268,46 +2435,46 @@ interface components {
2268
2435
  };
2269
2436
  'AdaptySubscriptionOffer.Phase': {
2270
2437
  price: components['defs']['AdaptyPrice'];
2271
- subscription_period: components['defs']['AdaptySubscriptionPeriod'];
2272
2438
  number_of_periods: number;
2273
2439
  payment_mode: components['defs']['AdaptySubscriptionOffer.PaymentMode'];
2440
+ subscription_period: components['defs']['AdaptySubscriptionPeriod'];
2274
2441
  localized_subscription_period?: string;
2275
2442
  localized_number_of_periods?: string;
2276
2443
  };
2277
- AdaptyPlacement: {
2278
- developer_id: string;
2279
- ab_test_name: string;
2280
- audience_name: string;
2281
- revision: number;
2282
- is_tracking_purchases?: boolean;
2283
- placement_audience_version_id: string;
2444
+ AdaptyOnboarding: {
2445
+ placement: components['defs']['AdaptyPlacement'];
2446
+ onboarding_id: string;
2447
+ onboarding_name: string;
2448
+ variation_id: string;
2449
+ remote_config?: components['defs']['AdaptyRemoteConfig'];
2450
+ onboarding_builder: {
2451
+ config_url: string;
2452
+ };
2453
+ payload_data?: string;
2454
+ response_created_at: number;
2455
+ request_locale: components['defs']['AdaptyLocale'];
2284
2456
  };
2285
2457
  AdaptyPaywall: {
2286
2458
  placement: components['defs']['AdaptyPlacement'];
2287
2459
  paywall_id: string;
2288
2460
  paywall_name: string;
2289
2461
  variation_id: string;
2290
- products: components['defs']['AdaptyPaywall.ProductReference'][];
2291
- response_created_at: number;
2292
2462
  remote_config?: components['defs']['AdaptyRemoteConfig'];
2293
2463
  paywall_builder?: components['defs']['AdaptyPaywall.ViewConfiguration'];
2464
+ products: components['defs']['AdaptyPaywall.ProductReference'][];
2294
2465
  web_purchase_url?: string;
2295
2466
  payload_data?: string;
2296
- request_locale: components['defs']['AdaptyLocale'];
2297
- };
2298
- AdaptyOnboarding: {
2299
- placement: components['defs']['AdaptyPlacement'];
2300
- onboarding_id: string;
2301
- onboarding_name: string;
2302
- variation_id: string;
2303
2467
  response_created_at: number;
2304
- remote_config?: components['defs']['AdaptyRemoteConfig'];
2305
- onboarding_builder?: {
2306
- config_url: string;
2307
- };
2308
- payload_data?: string;
2309
2468
  request_locale: components['defs']['AdaptyLocale'];
2310
2469
  };
2470
+ AdaptyPlacement: {
2471
+ developer_id: string;
2472
+ audience_name: string;
2473
+ revision: number;
2474
+ ab_test_name: string;
2475
+ is_tracking_purchases?: boolean;
2476
+ placement_audience_version_id: string;
2477
+ };
2311
2478
  AdaptyPlacementFetchPolicy: OneOf<[{
2312
2479
  type: 'reload_revalidating_cache_data' | 'return_cache_data_else_load';
2313
2480
  }, {
@@ -2331,6 +2498,7 @@ interface components {
2331
2498
  'AdaptyPaywall.ViewConfiguration': {
2332
2499
  paywall_builder_id: string;
2333
2500
  lang: components['defs']['AdaptyLocale'];
2501
+ json?: string;
2334
2502
  };
2335
2503
  AdaptySubscriptionPeriod: {
2336
2504
  unit: components['defs']['AdaptySubscriptionPeriod.Unit'];
@@ -2341,8 +2509,6 @@ interface components {
2341
2509
  profile_id: string;
2342
2510
  customer_user_id?: string;
2343
2511
  segment_hash: string;
2344
- is_test_user: boolean;
2345
- timestamp: number;
2346
2512
  custom_attributes?: components['defs']['AdaptyProfile.CustomAttributes'];
2347
2513
  paid_access_levels?: {
2348
2514
  [key: string]: components['defs']['AdaptyProfile.AccessLevel'];
@@ -2353,6 +2519,8 @@ interface components {
2353
2519
  non_subscriptions?: {
2354
2520
  [key: string]: components['defs']['AdaptyProfile.NonSubscription'][];
2355
2521
  };
2522
+ timestamp: number;
2523
+ is_test_user: boolean;
2356
2524
  };
2357
2525
  'AdaptyProfile.AccessLevel': {
2358
2526
  id: string;
@@ -2424,11 +2592,11 @@ interface components {
2424
2592
  analytics_disabled?: boolean;
2425
2593
  };
2426
2594
  'AdaptySubscriptionOffer.Identifier': OneOf<[{
2427
- type: 'introductory';
2428
2595
  id?: string;
2596
+ type: 'introductory';
2429
2597
  }, {
2430
- type: 'promotional' | 'win_back';
2431
2598
  id: string;
2599
+ type: 'promotional' | 'win_back';
2432
2600
  }]>;
2433
2601
  'AdaptySubscriptionOffer.PaymentMode': 'pay_as_you_go' | 'pay_up_front' | 'free_trial' | 'unknown';
2434
2602
  AdaptyPurchaseResult: OneOf<[{
@@ -2439,6 +2607,18 @@ interface components {
2439
2607
  apple_jws_transaction?: string;
2440
2608
  google_purchase_token?: string;
2441
2609
  }]>;
2610
+ AdaptyInstallationStatus: OneOf<[{
2611
+ status: 'not_available' | 'not_determined';
2612
+ }, {
2613
+ status: 'determined';
2614
+ details: components['defs']['AdaptyInstallationDetails'];
2615
+ }]>;
2616
+ AdaptyInstallationDetails: {
2617
+ install_id?: string;
2618
+ install_time: components['defs']['Date'];
2619
+ app_launch_count: number;
2620
+ payload?: string;
2621
+ };
2442
2622
  'AdaptyUI.CustomAssets': (components['assets']['Color'] | components['assets']['ColorGradient'] | components['assets']['Image'] | components['assets']['Video'])[];
2443
2623
  'AdaptyUI.PaywallView': {
2444
2624
  id: string;
@@ -2450,21 +2630,14 @@ interface components {
2450
2630
  placement_id: string;
2451
2631
  variation_id: string;
2452
2632
  };
2453
- 'AdaptyUI.OnboardingMeta': {
2454
- onboarding_id: string;
2455
- screen_cid: string;
2456
- screen_index: number;
2457
- total_screens: number;
2458
- };
2459
- 'AdaptyUI.OnboardingsStateParams': {
2460
- id: string;
2461
- value: string;
2462
- label: string;
2463
- };
2464
2633
  'AdaptyUI.UserAction': OneOf<[{
2465
2634
  type: 'close' | 'system_back';
2466
2635
  }, {
2467
- type: 'open_url' | 'custom';
2636
+ type: 'open_url';
2637
+ value: string;
2638
+ open_in: components['defs']['AdaptyWebPresentation'];
2639
+ }, {
2640
+ type: 'custom';
2468
2641
  value: string;
2469
2642
  }]>;
2470
2643
  'AdaptyUI.CustomTagsValues': {
@@ -2473,16 +2646,19 @@ interface components {
2473
2646
  'AdaptyUI.CustomTimersValues': {
2474
2647
  [key: string]: components['defs']['Date'];
2475
2648
  };
2649
+ 'AdaptyUI.AndroidPersonalizedOffers': {
2650
+ [key: string]: boolean;
2651
+ };
2476
2652
  'AdaptyUI.ProductPurchaseParameters': {
2477
2653
  [key: string]: components['defs']['AdaptyPurchaseParameters'];
2478
2654
  };
2479
2655
  'AdaptyUI.IOSPresentationStyle': 'full_screen' | 'page_sheet';
2480
2656
  AdaptyWebPresentation: 'browser_out_app' | 'browser_in_app';
2481
2657
  'AdaptyUI.DialogConfiguration': {
2482
- default_action_title: string;
2483
- secondary_action_title?: string;
2484
2658
  title?: string;
2485
2659
  content?: string;
2660
+ default_action_title: string;
2661
+ secondary_action_title?: string;
2486
2662
  };
2487
2663
  'AdaptyUI.DialogActionType': 'primary' | 'secondary';
2488
2664
  AdaptyPurchaseParameters: {
@@ -2494,30 +2670,30 @@ interface components {
2494
2670
  replacement_mode: 'charge_full_price' | 'deferred' | 'without_proration' | 'charge_prorated_price' | 'with_time_proration';
2495
2671
  };
2496
2672
  AdaptyRefundPreference: 'no_preference' | 'grant' | 'decline';
2497
- AdaptyInstallationStatus: OneOf<[{
2498
- status: 'not_available' | 'not_determined';
2499
- }, {
2500
- status: 'determined';
2501
- details: components['defs']['AdaptyInstallationDetails'];
2502
- }]>;
2503
- AdaptyInstallationDetails: {
2504
- install_id?: string;
2505
- install_time: components['defs']['Date'];
2506
- app_launch_count: number;
2507
- payload?: string;
2673
+ 'AdaptyUI.OnboardingMeta': {
2674
+ onboarding_id: string;
2675
+ screen_cid: string;
2676
+ screen_index: number;
2677
+ total_screens: number;
2678
+ };
2679
+ 'AdaptyUI.OnboardingsStateParams': {
2680
+ id: string;
2681
+ value: string;
2682
+ label: string;
2508
2683
  };
2509
2684
  };
2510
2685
  assets: {
2511
2686
  Color: {
2512
2687
  id: string;
2513
2688
  type: 'color';
2514
- value: string; // Hex string: ^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$
2689
+ value: components['assets']['Color.Hex'];
2515
2690
  };
2691
+ 'Color.Hex': string;
2516
2692
  ColorGradient: {
2517
2693
  id: string;
2518
2694
  type: 'linear-gradient';
2519
2695
  values: {
2520
- color: string;
2696
+ color: components['assets']['Color.Hex'];
2521
2697
  p: number;
2522
2698
  }[];
2523
2699
  points: {
@@ -2527,26 +2703,22 @@ interface components {
2527
2703
  y1: number;
2528
2704
  };
2529
2705
  };
2530
- Image: OneOf<[{
2706
+ Image: {
2531
2707
  id: string;
2532
2708
  type: 'image';
2533
- value: string; // base64
2709
+ } & OneOf<[{
2710
+ value: string;
2534
2711
  }, {
2535
- id: string;
2536
- type: 'image';
2537
2712
  asset_id: string;
2538
2713
  }, {
2539
- id: string;
2540
- type: 'image';
2541
2714
  path: string;
2542
2715
  }]>;
2543
- Video: OneOf<[{
2716
+ Video: {
2544
2717
  id: string;
2545
2718
  type: 'video';
2719
+ } & OneOf<[{
2546
2720
  asset_id: string;
2547
2721
  }, {
2548
- id: string;
2549
- type: 'video';
2550
2722
  path: string;
2551
2723
  }]>;
2552
2724
  };
@@ -3090,12 +3262,21 @@ interface PaywallDidAppearEvent extends BasePaywallEvent {
3090
3262
  interface PaywallDidDisappearEvent extends BasePaywallEvent {
3091
3263
  id: typeof PaywallEventId.DidDisappear;
3092
3264
  }
3265
+ type PaywallUserAction = {
3266
+ type: 'close';
3267
+ } | {
3268
+ type: 'system_back';
3269
+ } | {
3270
+ type: 'open_url';
3271
+ value: string;
3272
+ openIn: WebPresentation;
3273
+ } | {
3274
+ type: 'custom';
3275
+ value: string;
3276
+ };
3093
3277
  interface PaywallDidPerformActionEvent extends BasePaywallEvent {
3094
3278
  id: typeof PaywallEventId.DidPerformAction;
3095
- action: {
3096
- type: 'close' | 'system_back' | 'open_url' | 'custom';
3097
- value?: string;
3098
- };
3279
+ action: PaywallUserAction;
3099
3280
  }
3100
3281
  interface PaywallDidSelectProductEvent extends BasePaywallEvent {
3101
3282
  id: typeof PaywallEventId.DidSelectProduct;
@@ -3306,5 +3487,5 @@ declare function withErrorContext<T extends (...args: never[]) => unknown>(callb
3306
3487
  //#endregion
3307
3488
  //# sourceMappingURL=with-error-context.d.ts.map
3308
3489
 
3309
- export { ActivateParamsInput, AdaptyAccessLevel, AdaptyAndroidPurchaseParams, AdaptyAndroidSubscriptionUpdateParameters, AdaptyAndroidSubscriptionUpdateReplacementMode, AdaptyBridgeError, AdaptyCustomAsset, AdaptyCustomColorAsset, AdaptyCustomGradientAsset, AdaptyCustomImageAsset, AdaptyCustomVideoAsset, AdaptyDiscountPhase, AdaptyError, AdaptyErrorInput, AdaptyIOSPresentationStyle, AdaptyInstallationDetails, AdaptyInstallationStatus, AdaptyNativeError, AdaptyNonSubscription, AdaptyOnboarding, AdaptyOnboardingBuilder, AdaptyPaywall, AdaptyPaywallBuilder, AdaptyPaywallProduct, AdaptyPlacement, AdaptyPrice, AdaptyProductIdentifier, AdaptyProfile, AdaptyProfileParameters, AdaptyPurchaseResult, AdaptyRemoteConfig, AdaptySubscription, AdaptySubscriptionDetails, AdaptySubscriptionOffer, AdaptySubscriptionOfferId, AdaptySubscriptionPeriod, AdaptyType, AdaptyUiDialogActionType, AdaptyUiDialogConfig, AdaptyUiMediaCache, AdaptyUiOnboardingMeta, AdaptyUiOnboardingStateParams, AdaptyUiView, AppTrackingTransparencyStatus, ArgType, CancellationReason, CoderDependencies, CoderFactory, Converter, CreateOnboardingViewParamsInput, CreatePaywallViewParamsInput, DefaultLoggerAdapter, DefaultPlatformAdapter, DefaultSdkMetadataAdapter, ErrorCode, ErrorConverter, EventHandlerResult, EventHandlers, FetchPolicy, FileLocation, Gender, GetPaywallProductsParamsInput, GetPlacementForDefaultAudienceParamsInput, GetPlacementParamsInput, HANDLER_TO_EVENT_CONFIG, HANDLER_TO_NATIVE_EVENT, ILogContext, ILogScope, ILoggerAdapter, IPlatformAdapter, ISdkMetadataAdapter, IdentifyParamsInput, Log, LogArgs, LogContext, LogEvent, LogLevel, LogScope, LogSink, LogTrace, LoggerConfig, MakePurchaseParamsInput, MethodName, MethodNames, NATIVE_EVENT_RESOLVER, NATIVE_EVENT_TO_HANDLERS, ONBOARDING_EVENT_MAPPINGS, OfferType, OnboardingAnalyticsEvent, OnboardingAnalyticsEventName, OnboardingCloseEvent, OnboardingCustomEvent, OnboardingErrorEvent, OnboardingEventHandlers, OnboardingEventId, OnboardingEventIdType, OnboardingEventView, OnboardingFinishedLoadingEvent, OnboardingPaywallEvent, OnboardingStateUpdatedAction, OnboardingStateUpdatedEvent, ParsedOnboardingEvent, ParsedPaywallEvent, PaywallDidAppearEvent, PaywallDidDisappearEvent, PaywallDidFailLoadingProductsEvent, PaywallDidFailPurchaseEvent, PaywallDidFailRenderingEvent, PaywallDidFailRestoreEvent, PaywallDidFinishPurchaseEvent, PaywallDidFinishRestoreEvent, PaywallDidFinishWebPaymentNavigationEvent, PaywallDidPerformActionEvent, PaywallDidSelectProductEvent, PaywallDidStartPurchaseEvent, PaywallDidStartRestoreEvent, PaywallEventId, PaywallEventIdType, PaywallEventView, PlatformOS, ProductPeriod, ProductPurchaseParams, ProductReference, RefundPreference, ScopeArgs, Serializable$1 as Serializable, UserEventName, VendorStore, WebPresentation, components, consoleLogSink, extractOnboardingCallbackArgs, extractPaywallCallbackArgs, filterUndefined, generateId, getErrorCode, getErrorPrompt, mapValues, mergeOptions, parseCommonEvent, parseMethodResult, parseOnboardingEvent, parsePaywallEvent, withErrorContext };
3490
+ export { ActivateParamsInput, AdaptyAccessLevel, AdaptyAndroidPurchaseParams, AdaptyAndroidSubscriptionUpdateParameters, AdaptyAndroidSubscriptionUpdateReplacementMode, AdaptyBridgeError, AdaptyCustomAsset, AdaptyCustomColorAsset, AdaptyCustomGradientAsset, AdaptyCustomImageAsset, AdaptyCustomVideoAsset, AdaptyDiscountPhase, AdaptyError, AdaptyErrorInput, AdaptyIOSPresentationStyle, AdaptyInstallationDetails, AdaptyInstallationStatus, AdaptyNativeError, AdaptyNonSubscription, AdaptyOnboarding, AdaptyOnboardingBuilder, AdaptyPaywall, AdaptyPaywallBuilder, AdaptyPaywallProduct, AdaptyPlacement, AdaptyPrice, AdaptyProductIdentifier, AdaptyProfile, AdaptyProfileParameters, AdaptyPurchaseResult, AdaptyRemoteConfig, AdaptySubscription, AdaptySubscriptionDetails, AdaptySubscriptionOffer, AdaptySubscriptionOfferId, AdaptySubscriptionPeriod, AdaptyType, AdaptyUiDialogActionType, AdaptyUiDialogConfig, AdaptyUiMediaCache, AdaptyUiOnboardingMeta, AdaptyUiOnboardingStateParams, AdaptyUiView, AppTrackingTransparencyStatus, ArgType, CancellationReason, CoderDependencies, CoderFactory, Converter, CreateOnboardingViewParamsInput, CreatePaywallViewParamsInput, DefaultLoggerAdapter, DefaultPlatformAdapter, DefaultSdkMetadataAdapter, ErrorCode, ErrorCodeName, ErrorConverter, EventHandlerResult, EventHandlers, FetchPolicy, FileLocation, Gender, GetPaywallProductsParamsInput, GetPlacementForDefaultAudienceParamsInput, GetPlacementParamsInput, HANDLER_TO_EVENT_CONFIG, HANDLER_TO_NATIVE_EVENT, ILogContext, ILogScope, ILoggerAdapter, IPlatformAdapter, ISdkMetadataAdapter, IdentifyParamsInput, Log, LogArgs, LogContext, LogEvent, LogLevel, LogScope, LogSink, LogTrace, LoggerConfig, MakePurchaseParamsInput, MethodName, MethodNames, NATIVE_EVENT_RESOLVER, NATIVE_EVENT_TO_HANDLERS, ONBOARDING_EVENT_MAPPINGS, OfferType, OnboardingAnalyticsEvent, OnboardingAnalyticsEventName, OnboardingCloseEvent, OnboardingCustomEvent, OnboardingErrorEvent, OnboardingEventHandlers, OnboardingEventId, OnboardingEventIdType, OnboardingEventView, OnboardingFinishedLoadingEvent, OnboardingPaywallEvent, OnboardingStateUpdatedAction, OnboardingStateUpdatedEvent, ParsedOnboardingEvent, ParsedPaywallEvent, PaywallDidAppearEvent, PaywallDidDisappearEvent, PaywallDidFailLoadingProductsEvent, PaywallDidFailPurchaseEvent, PaywallDidFailRenderingEvent, PaywallDidFailRestoreEvent, PaywallDidFinishPurchaseEvent, PaywallDidFinishRestoreEvent, PaywallDidFinishWebPaymentNavigationEvent, PaywallDidPerformActionEvent, PaywallDidSelectProductEvent, PaywallDidStartPurchaseEvent, PaywallDidStartRestoreEvent, PaywallEventId, PaywallEventIdType, PaywallEventView, PaywallUserAction, PlatformOS, ProductPeriod, ProductPurchaseParams, ProductReference, RefundPreference, ScopeArgs, Serializable$1 as Serializable, UserEventName, VendorStore, WebPresentation, components, consoleLogSink, extractOnboardingCallbackArgs, extractPaywallCallbackArgs, filterUndefined, generateId, getErrorCode, getErrorPrompt, mapValues, mergeOptions, parseCommonEvent, parseMethodResult, parseOnboardingEvent, parsePaywallEvent, withErrorContext };
3310
3491
  //# sourceMappingURL=index.d.cts.map