@adshift/react-native-plugin 2.0.0 → 3.0.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/AdShiftReactNativePlugin.podspec +1 -1
- package/CHANGELOG.md +53 -1
- package/README.md +106 -50
- package/android/build.gradle +3 -1
- package/android/src/main/AndroidManifest.xml +14 -1
- package/android/src/main/java/com/adshift/reactnativeplugin/AdShiftReactNativePluginModule.kt +12 -1
- package/android/src/main/java/com/adshift/reactnativeplugin/RestoredIntents.kt +64 -0
- package/android/src/test/java/com/adshift/reactnativeplugin/DeepLinkDeliveryTest.kt +40 -3
- package/android/src/test/java/com/adshift/reactnativeplugin/InitializeOrderingTest.kt +14 -0
- package/android/src/test/java/com/adshift/reactnativeplugin/LaunchIntentForwardingTest.kt +30 -1
- package/android/src/test/java/com/adshift/reactnativeplugin/ModuleTestSupport.kt +13 -0
- package/ios/AdShiftReactNativePlugin.mm +5 -0
- package/ios/AdShiftReactNativePluginHelper.swift +25 -1
- package/ios/Core/BridgeRules.swift +18 -1
- package/lib/commonjs/Adshift.js +31 -5
- package/lib/commonjs/Adshift.js.map +1 -1
- package/lib/commonjs/NativeAdShiftReactNativePlugin.js.map +1 -1
- package/lib/commonjs/index.js +6 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/jest/index.js +2 -0
- package/lib/commonjs/jest/index.js.map +1 -1
- package/lib/commonjs/nativeSdkVersions.js +2 -2
- package/lib/commonjs/types/AdshiftConfig.js +10 -1
- package/lib/commonjs/types/AdshiftConfig.js.map +1 -1
- package/lib/commonjs/types/AdshiftDeepLink.js +50 -6
- package/lib/commonjs/types/AdshiftDeepLink.js.map +1 -1
- package/lib/commonjs/types/index.js +12 -0
- package/lib/commonjs/types/index.js.map +1 -1
- package/lib/commonjs/version.js +1 -1
- package/lib/module/Adshift.js +32 -6
- package/lib/module/Adshift.js.map +1 -1
- package/lib/module/NativeAdShiftReactNativePlugin.js.map +1 -1
- package/lib/module/index.js +1 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/jest/index.js +3 -1
- package/lib/module/jest/index.js.map +1 -1
- package/lib/module/nativeSdkVersions.js +2 -2
- package/lib/module/types/AdshiftConfig.js +9 -1
- package/lib/module/types/AdshiftConfig.js.map +1 -1
- package/lib/module/types/AdshiftDeepLink.js +50 -5
- package/lib/module/types/AdshiftDeepLink.js.map +1 -1
- package/lib/module/types/index.js +2 -2
- package/lib/module/types/index.js.map +1 -1
- package/lib/module/version.js +1 -1
- package/lib/typescript/commonjs/src/Adshift.d.ts +18 -7
- package/lib/typescript/commonjs/src/Adshift.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/NativeAdShiftReactNativePlugin.d.ts +13 -4
- package/lib/typescript/commonjs/src/NativeAdShiftReactNativePlugin.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/index.d.ts +2 -2
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/jest/index.d.ts +3 -1
- package/lib/typescript/commonjs/src/jest/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/nativeSdkVersions.d.ts +2 -2
- package/lib/typescript/commonjs/src/types/AdshiftConfig.d.ts +25 -2
- package/lib/typescript/commonjs/src/types/AdshiftConfig.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/types/AdshiftDeepLink.d.ts +55 -11
- package/lib/typescript/commonjs/src/types/AdshiftDeepLink.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/types/index.d.ts +3 -3
- package/lib/typescript/commonjs/src/types/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/version.d.ts +1 -1
- package/lib/typescript/module/src/Adshift.d.ts +18 -7
- package/lib/typescript/module/src/Adshift.d.ts.map +1 -1
- package/lib/typescript/module/src/NativeAdShiftReactNativePlugin.d.ts +13 -4
- package/lib/typescript/module/src/NativeAdShiftReactNativePlugin.d.ts.map +1 -1
- package/lib/typescript/module/src/index.d.ts +2 -2
- package/lib/typescript/module/src/index.d.ts.map +1 -1
- package/lib/typescript/module/src/jest/index.d.ts +3 -1
- package/lib/typescript/module/src/jest/index.d.ts.map +1 -1
- package/lib/typescript/module/src/nativeSdkVersions.d.ts +2 -2
- package/lib/typescript/module/src/types/AdshiftConfig.d.ts +25 -2
- package/lib/typescript/module/src/types/AdshiftConfig.d.ts.map +1 -1
- package/lib/typescript/module/src/types/AdshiftDeepLink.d.ts +55 -11
- package/lib/typescript/module/src/types/AdshiftDeepLink.d.ts.map +1 -1
- package/lib/typescript/module/src/types/index.d.ts +3 -3
- package/lib/typescript/module/src/types/index.d.ts.map +1 -1
- package/lib/typescript/module/src/version.d.ts +1 -1
- package/package.json +2 -2
- package/src/Adshift.ts +48 -8
- package/src/NativeAdShiftReactNativePlugin.ts +14 -4
- package/src/index.tsx +6 -2
- package/src/jest/index.ts +5 -0
- package/src/nativeSdkVersions.ts +2 -2
- package/src/types/AdshiftConfig.ts +38 -2
- package/src/types/AdshiftDeepLink.ts +87 -11
- package/src/types/index.ts +9 -2
- package/src/version.ts +1 -1
|
@@ -4,20 +4,46 @@
|
|
|
4
4
|
* Status of a deep link result.
|
|
5
5
|
*/
|
|
6
6
|
export let AdshiftDeepLinkStatus = /*#__PURE__*/function (AdshiftDeepLinkStatus) {
|
|
7
|
-
/**
|
|
7
|
+
/** A RightLink link, or a deferred deep link with a value. Navigate on this. */
|
|
8
8
|
AdshiftDeepLinkStatus["Found"] = "found";
|
|
9
|
-
/**
|
|
9
|
+
/** Not a RightLink link, a deleted one, or no deferred deep link. */
|
|
10
10
|
AdshiftDeepLinkStatus["NotFound"] = "notFound";
|
|
11
|
-
/**
|
|
11
|
+
/** Not resolved yet; the same link can still arrive as `found`. */
|
|
12
12
|
AdshiftDeepLinkStatus["Error"] = "error";
|
|
13
13
|
return AdshiftDeepLinkStatus;
|
|
14
14
|
}({});
|
|
15
15
|
|
|
16
|
+
/**
|
|
17
|
+
* How the link of a result reached the app.
|
|
18
|
+
*/
|
|
19
|
+
export let AdshiftDeepLinkSource = /*#__PURE__*/function (AdshiftDeepLinkSource) {
|
|
20
|
+
/** A Universal Link, or a link the app passed in itself. iOS. */
|
|
21
|
+
AdshiftDeepLinkSource["UniversalLink"] = "ul";
|
|
22
|
+
/** An App Link, or a link the app passed in itself. Android. */
|
|
23
|
+
AdshiftDeepLinkSource["AppLink"] = "app_link";
|
|
24
|
+
/** The app's own scheme; `found` only when it wraps a RightLink link in `as_rl`. */
|
|
25
|
+
AdshiftDeepLinkSource["Scheme"] = "scheme";
|
|
26
|
+
/** The open-in-app button of a RightLink page. */
|
|
27
|
+
AdshiftDeepLinkSource["Cta"] = "cta";
|
|
28
|
+
/** A push notification. */
|
|
29
|
+
AdshiftDeepLinkSource["Push"] = "push";
|
|
30
|
+
/** An AdAttributionKit re-engagement open. iOS. */
|
|
31
|
+
AdshiftDeepLinkSource["AdAttributionKit"] = "aak";
|
|
32
|
+
/** A link opened by a Meta app that is not a RightLink link. Android. */
|
|
33
|
+
AdshiftDeepLinkSource["MetaAppLink"] = "meta_applink";
|
|
34
|
+
/** The lookup on the first launch after install. */
|
|
35
|
+
AdshiftDeepLinkSource["Deferred"] = "deferred";
|
|
36
|
+
/** A web link that is not a RightLink link. */
|
|
37
|
+
AdshiftDeepLinkSource["Foreign"] = "foreign";
|
|
38
|
+
return AdshiftDeepLinkSource;
|
|
39
|
+
}({});
|
|
40
|
+
|
|
16
41
|
/**
|
|
17
42
|
* Deep link delivered through `Adshift.onDeepLink()`.
|
|
18
43
|
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
44
|
+
* Navigate only on `status: 'found'`, and validate `deepLinkValue` first:
|
|
45
|
+
* anyone can write a link. Any other URL comes back `notFound` with the URL
|
|
46
|
+
* in `deepLink`. Treat `error` as "not yet".
|
|
21
47
|
*
|
|
22
48
|
* @example
|
|
23
49
|
* ```typescript
|
|
@@ -29,6 +55,7 @@ export let AdshiftDeepLinkStatus = /*#__PURE__*/function (AdshiftDeepLinkStatus)
|
|
|
29
55
|
* ```
|
|
30
56
|
*/
|
|
31
57
|
|
|
58
|
+
const SOURCES = new Set(Object.values(AdshiftDeepLinkSource));
|
|
32
59
|
const SUB_KEYS = ['deepLinkSub1', 'deepLinkSub2', 'deepLinkSub3', 'deepLinkSub4', 'deepLinkSub5'];
|
|
33
60
|
|
|
34
61
|
/**
|
|
@@ -50,6 +77,15 @@ export const AdshiftDeepLink = {
|
|
|
50
77
|
if (options.isFirstSession !== undefined) {
|
|
51
78
|
result.isFirstSession = options.isFirstSession;
|
|
52
79
|
}
|
|
80
|
+
if (options.source !== undefined) {
|
|
81
|
+
result.source = options.source;
|
|
82
|
+
}
|
|
83
|
+
if (options.clickId !== undefined) {
|
|
84
|
+
result.clickId = options.clickId;
|
|
85
|
+
}
|
|
86
|
+
if (options.matchGuaranteed !== undefined) {
|
|
87
|
+
result.matchGuaranteed = options.matchGuaranteed;
|
|
88
|
+
}
|
|
53
89
|
for (const key of SUB_KEYS) {
|
|
54
90
|
const value = options[key];
|
|
55
91
|
if (value !== undefined) {
|
|
@@ -98,6 +134,15 @@ export const AdshiftDeepLink = {
|
|
|
98
134
|
if (typeof map.isFirstSession === 'boolean') {
|
|
99
135
|
result.isFirstSession = map.isFirstSession;
|
|
100
136
|
}
|
|
137
|
+
if (typeof map.source === 'string' && SOURCES.has(map.source)) {
|
|
138
|
+
result.source = map.source;
|
|
139
|
+
}
|
|
140
|
+
if (typeof map.clickId === 'string' && map.clickId.length > 0) {
|
|
141
|
+
result.clickId = map.clickId;
|
|
142
|
+
}
|
|
143
|
+
if (typeof map.matchGuaranteed === 'boolean') {
|
|
144
|
+
result.matchGuaranteed = map.matchGuaranteed;
|
|
145
|
+
}
|
|
101
146
|
SUB_KEYS.forEach((key, index) => {
|
|
102
147
|
const sub = map[key] ?? params?.[`deep_link_sub${index + 1}`];
|
|
103
148
|
if (typeof sub === 'string') {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["AdshiftDeepLinkStatus","SUB_KEYS","AdshiftDeepLink","found","options","result","deepLink","isDeferred","status","Found","deepLinkValue","undefined","params","isFirstSession","key","value","notFound","NotFound","error","message","Error","errorMessage","fromMap","map","readParams","readStatus","deep_link_value","forEach","index","sub","out","count","raw","
|
|
1
|
+
{"version":3,"names":["AdshiftDeepLinkStatus","AdshiftDeepLinkSource","SOURCES","Set","Object","values","SUB_KEYS","AdshiftDeepLink","found","options","result","deepLink","isDeferred","status","Found","deepLinkValue","undefined","params","isFirstSession","source","clickId","matchGuaranteed","key","value","notFound","NotFound","error","message","Error","errorMessage","fromMap","map","readParams","readStatus","deep_link_value","has","length","forEach","index","sub","out","count","raw","entries","String","deepLinkToMap"],"sourceRoot":"../../../src","sources":["types/AdshiftDeepLink.ts"],"mappings":";;AAAA;AACA;AACA;AACA,WAAYA,qBAAqB,0BAArBA,qBAAqB;EAC/B;EADUA,qBAAqB;EAI/B;EAJUA,qBAAqB;EAO/B;EAPUA,qBAAqB;EAAA,OAArBA,qBAAqB;AAAA;;AAWjC;AACA;AACA;AACA,WAAYC,qBAAqB,0BAArBA,qBAAqB;EAC/B;EADUA,qBAAqB;EAI/B;EAJUA,qBAAqB;EAO/B;EAPUA,qBAAqB;EAU/B;EAVUA,qBAAqB;EAa/B;EAbUA,qBAAqB;EAgB/B;EAhBUA,qBAAqB;EAmB/B;EAnBUA,qBAAqB;EAsB/B;EAtBUA,qBAAqB;EAyB/B;EAzBUA,qBAAqB;EAAA,OAArBA,qBAAqB;AAAA;;AA6BjC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAgEA,MAAMC,OAAO,GAAG,IAAIC,GAAG,CAASC,MAAM,CAACC,MAAM,CAACJ,qBAAqB,CAAC,CAAC;AAErE,MAAMK,QAAQ,GAAG,CACf,cAAc,EACd,cAAc,EACd,cAAc,EACd,cAAc,EACd,cAAc,CACN;;AAEV;AACA;AACA;AACA,OAAO,MAAMC,eAAe,GAAG;EAC7BC,KAAKA,CAACC,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;EACT;EACA,OAAOA,KAAK,GAAG,CAAC,GAAGD,GAAG,GAAGxB,SAAS;AACpC;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAO,SAAS6B,aAAaA,CAC3BlC,QAAyB,EACA;EACzB,MAAMoB,GAA4B,GAAG;IACnCnB,UAAU,EAAED,QAAQ,CAACC,UAAU;IAC/BC,MAAM,EAAEF,QAAQ,CAACE;EACnB,CAAC;EACD,KAAK,MAAM,CAACS,GAAG,EAAEC,KAAK,CAAC,IAAInB,MAAM,CAACuC,OAAO,CAAChC,QAAQ,CAAC,EAAE;IACnD,IAAIY,KAAK,KAAKP,SAAS,IAAI,EAAEM,GAAG,IAAIS,GAAG,CAAC,EAAE;MACxCA,GAAG,CAACT,GAAG,CAAC,GAAGC,KAAK;IAClB;EACF;EACA,OAAOQ,GAAG;AACZ","ignoreList":[]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
export { configToMap } from "./AdshiftConfig.js";
|
|
3
|
+
export { configToMap, DEFERRED_DEEP_LINK_CLIPBOARD_MODES } from "./AdshiftConfig.js";
|
|
4
4
|
export { AdshiftConsent, consentToMap } from "./AdshiftConsent.js";
|
|
5
5
|
export { consentSnapshotFromMap } from "./AdshiftConsentSnapshot.js";
|
|
6
6
|
export { AdshiftThirdPartySharing, thirdPartySharingToMap } from "./AdshiftThirdPartySharing.js";
|
|
7
|
-
export { AdshiftDeepLinkStatus, AdshiftDeepLink, deepLinkToMap } from "./AdshiftDeepLink.js";
|
|
7
|
+
export { AdshiftDeepLinkStatus, AdshiftDeepLinkSource, AdshiftDeepLink, deepLinkToMap } from "./AdshiftDeepLink.js";
|
|
8
8
|
export { AdshiftEventType, getAllEventTypes } from "./AdshiftEventType.js";
|
|
9
9
|
export { AdshiftEventParam, getAllEventParams } from "./AdshiftEventParam.js";
|
|
10
10
|
export { AdshiftMediationNetwork } from "./AdshiftAdRevenue.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["configToMap","AdshiftConsent","consentToMap","consentSnapshotFromMap","AdshiftThirdPartySharing","thirdPartySharingToMap","AdshiftDeepLinkStatus","AdshiftDeepLink","deepLinkToMap","AdshiftEventType","getAllEventTypes","AdshiftEventParam","getAllEventParams","AdshiftMediationNetwork","AdshiftErrorCode","isAdshiftError","createAdshiftError","toAdshiftError"],"sourceRoot":"../../../src","sources":["types/index.ts"],"mappings":";;
|
|
1
|
+
{"version":3,"names":["configToMap","DEFERRED_DEEP_LINK_CLIPBOARD_MODES","AdshiftConsent","consentToMap","consentSnapshotFromMap","AdshiftThirdPartySharing","thirdPartySharingToMap","AdshiftDeepLinkStatus","AdshiftDeepLinkSource","AdshiftDeepLink","deepLinkToMap","AdshiftEventType","getAllEventTypes","AdshiftEventParam","getAllEventParams","AdshiftMediationNetwork","AdshiftErrorCode","isAdshiftError","createAdshiftError","toAdshiftError"],"sourceRoot":"../../../src","sources":["types/index.ts"],"mappings":";;AAIA,SACEA,WAAW,EACXC,kCAAkC,QAC7B,oBAAiB;AAGxB,SAASC,cAAc,EAAEC,YAAY,QAAQ,qBAAkB;AAG/D,SAASC,sBAAsB,QAAQ,6BAA0B;AAEjE,SACEC,wBAAwB,EACxBC,sBAAsB,QACjB,+BAA4B;AAEnC,SACEC,qBAAqB,EACrBC,qBAAqB,EACrBC,eAAe,EACfC,aAAa,QACR,sBAAmB;AAE1B,SAASC,gBAAgB,EAAEC,gBAAgB,QAAQ,uBAAoB;AAGvE,SAASC,iBAAiB,EAAEC,iBAAiB,QAAQ,wBAAqB;AAG1E,SAASC,uBAAuB,QAAQ,uBAAoB;AAM5D,SACEC,gBAAgB,EAChBC,cAAc,EACdC,kBAAkB,EAClBC,cAAc,QACT,mBAAgB","ignoreList":[]}
|
package/lib/module/version.js
CHANGED
|
@@ -34,16 +34,19 @@ import { AdshiftErrorCode } from './types';
|
|
|
34
34
|
/**
|
|
35
35
|
* Result of `Adshift.start()`.
|
|
36
36
|
*
|
|
37
|
-
* `success` reports whether the SDK started locally.
|
|
38
|
-
* the
|
|
39
|
-
* `config.onError`
|
|
37
|
+
* `success` reports whether the SDK started locally. The API key is checked
|
|
38
|
+
* with the backend in the background: `apiKeyValidationStatus` is the verdict
|
|
39
|
+
* at the time `start()` resolved, and `config.onError` reports
|
|
40
|
+
* `INVALID_API_KEY` when that verdict is `invalid`. On iOS the verdict usually
|
|
41
|
+
* arrives after `start()` resolved and is reported by the next `start()`; on
|
|
42
|
+
* Android `start()` waits up to 5 s for it.
|
|
40
43
|
*/
|
|
41
44
|
export interface StartResult {
|
|
42
45
|
success: boolean;
|
|
43
46
|
/**
|
|
44
|
-
* Outcome of the API key check at the time `start()` resolved
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
+
* Outcome of the API key check at the time `start()` resolved; `pending`
|
|
48
|
+
* means the answer had not arrived yet. It changes nothing you have to do:
|
|
49
|
+
* events tracked meanwhile stay queued on the device by the native SDK.
|
|
47
50
|
*/
|
|
48
51
|
apiKeyValidationStatus?: ApiKeyValidationStatus;
|
|
49
52
|
/** Platform error number behind `errorCode`, for support requests. */
|
|
@@ -280,6 +283,13 @@ export declare const Adshift: {
|
|
|
280
283
|
* `INVALID_ARGUMENT`).
|
|
281
284
|
*/
|
|
282
285
|
readonly handleDeepLink: (url: string) => Promise<void>;
|
|
286
|
+
/**
|
|
287
|
+
* With `deferredDeepLinkClipboard: 'pasteControl'`, passes what the user
|
|
288
|
+
* pasted with `UIPasteControl`, or `null` when they skipped it. Call it on
|
|
289
|
+
* every way out of onboarding: the first launch's deferred deep link waits
|
|
290
|
+
* for it. No-op on Android.
|
|
291
|
+
*/
|
|
292
|
+
readonly handlePastedDeepLink: (url: string | null) => void;
|
|
283
293
|
/**
|
|
284
294
|
* Adds a key path inside push payloads that carries an AdShift deep link.
|
|
285
295
|
*
|
|
@@ -302,7 +312,8 @@ export declare const Adshift: {
|
|
|
302
312
|
*
|
|
303
313
|
* Safe to call before `initialize()`. Results that arrive while no
|
|
304
314
|
* listener is registered are buffered and delivered to the first listener.
|
|
305
|
-
* Every link that reaches the SDK (direct, deferred, push) is delivered
|
|
315
|
+
* Every link that reaches the SDK (direct, deferred, push) is delivered,
|
|
316
|
+
* each result once.
|
|
306
317
|
*/
|
|
307
318
|
readonly onDeepLink: (callback: DeepLinkCallback) => DeepLinkSubscription;
|
|
308
319
|
readonly getInfo: () => AdshiftInfo;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Adshift.d.ts","sourceRoot":"","sources":["../../../../src/Adshift.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAOH,OAAO,KAAK,EACV,eAAe,EACf,aAAa,EACb,cAAc,EACd,eAAe,EAEf,qBAAqB,EACrB,wBAAwB,EACxB,eAAe,EAChB,MAAM,SAAS,CAAC;AACjB,OAAO,EAEL,gBAAgB,
|
|
1
|
+
{"version":3,"file":"Adshift.d.ts","sourceRoot":"","sources":["../../../../src/Adshift.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAOH,OAAO,KAAK,EACV,eAAe,EACf,aAAa,EACb,cAAc,EACd,eAAe,EAEf,qBAAqB,EACrB,wBAAwB,EACxB,eAAe,EAChB,MAAM,SAAS,CAAC;AACjB,OAAO,EAEL,gBAAgB,EAWjB,MAAM,SAAS,CAAC;AAKjB;;;;;;;;;GASG;AACH,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,OAAO,CAAC;IACjB;;;;OAIG;IACH,sBAAsB,CAAC,EAAE,sBAAsB,CAAC;IAChD,sEAAsE;IACtE,UAAU,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC7B,8DAA8D;IAC9D,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,mCAAmC;IACnC,SAAS,CAAC,EAAE,gBAAgB,CAAC;IAC7B,mCAAmC;IACnC,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,iEAA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|
24
|
+
clickId?: string;
|
|
25
|
+
matchGuaranteed?: boolean;
|
|
23
26
|
};
|
|
24
27
|
/**
|
|
25
28
|
* TurboModule contract between JavaScript and native code.
|
|
@@ -33,10 +36,11 @@ export interface Spec extends TurboModule {
|
|
|
33
36
|
* Initializes the SDK.
|
|
34
37
|
*
|
|
35
38
|
* Config keys (all optional except `apiKey`): `apiKey`, `isDebug`,
|
|
36
|
-
* `appOpenDebounceMs`, `brandedDomains: string[]`, `
|
|
37
|
-
* `pushDeepLinkPaths: string[][]`,
|
|
38
|
-
* `disableSKAN` / `waitForATTBeforeStart` /
|
|
39
|
-
* `
|
|
39
|
+
* `appOpenDebounceMs`, `brandedDomains: string[]`, `testMode`,
|
|
40
|
+
* `metaAppId` (Android), `pushDeepLinkPaths: string[][]`,
|
|
41
|
+
* `autoHandleDeepLinks`, `disableSKAN` / `waitForATTBeforeStart` /
|
|
42
|
+
* `attTimeoutMs` / `deferredDeepLinkClipboard` (iOS), `collectOaid`
|
|
43
|
+
* (Android). Keys that are absent leave SDK defaults untouched.
|
|
40
44
|
*/
|
|
41
45
|
initialize(config: Object): void;
|
|
42
46
|
/**
|
|
@@ -91,6 +95,11 @@ export interface Spec extends TurboModule {
|
|
|
91
95
|
* while a genuine second tap on the same link is still forwarded.
|
|
92
96
|
*/
|
|
93
97
|
handleDeepLink(url: string, fromLaunch: boolean): Promise<void>;
|
|
98
|
+
/**
|
|
99
|
+
* Passes what the user pasted with `UIPasteControl`, or null when they
|
|
100
|
+
* skipped it. iOS only; no-op on Android.
|
|
101
|
+
*/
|
|
102
|
+
handlePastedDeepLink(url: string | null): void;
|
|
94
103
|
/** Registers a push payload key path that carries a deep link. */
|
|
95
104
|
addPushNotificationDeepLinkPath(path: string[]): void;
|
|
96
105
|
/** Resolves to true when the payload was recognised as an AdShift push. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NativeAdShiftReactNativePlugin.d.ts","sourceRoot":"","sources":["../../../../src/NativeAdShiftReactNativePlugin.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAG9D;;;;;GAKG;AACH,MAAM,MAAM,qBAAqB,GAAG;IAClC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAClC,UAAU,EAAE,OAAO,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"NativeAdShiftReactNativePlugin.d.ts","sourceRoot":"","sources":["../../../../src/NativeAdShiftReactNativePlugin.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAG9D;;;;;GAKG;AACH,MAAM,MAAM,qBAAqB,GAAG;IAClC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,MAAM,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IAClC,UAAU,EAAE,OAAO,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,YAAY,CAAC,EAAE,MAAM,CAAC;IACt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MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEpE,aAAa,CACX,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,MAAM,EACb,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,MAAM,GACZ,OAAO,CAAC,IAAI,CAAC,CAAC;IAEjB;;;OAGG;IACH,YAAY,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAI1C,wEAAwE;IACxE,kBAAkB,IAAI,OAAO,CAAC,MAAM,GAAG,IAAI,CAAC,CAAC;IAI7C;;;;;;;;OAQG;IACH,cAAc,CAAC,GAAG,EAAE,MAAM,EAAE,UAAU,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEhE;;;OAGG;IACH,oBAAoB,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;IAE/C,kEAAkE;IAClE,+BAA+B,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC;IAEtD,2EAA2E;IAC3E,sBAAsB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAAC;IAE1D,QAAQ,CAAC,UAAU,EAAE,YAAY,CAAC,YAAY,CAAC,qBAAqB,CAAC,CAAC;CACvE;;AAED,wBAEE"}
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
*/
|
|
33
33
|
export { Adshift, default } from './Adshift';
|
|
34
34
|
export type { StartResult, EventValues, PurchaseParams, DeepLinkSubscription, DeepLinkCallback, NativeSdkVersions, AdshiftInfo, } from './Adshift';
|
|
35
|
-
export type { AdshiftConfig } from './types';
|
|
35
|
+
export type { AdshiftConfig, AdshiftDeferredDeepLinkClipboard } from './types';
|
|
36
36
|
export { AdshiftConsent } from './types';
|
|
37
37
|
export type { AdshiftConsent as AdshiftConsentType, ConsentFlag, ConsentSnapshot, ConsentSource, } from './types';
|
|
38
38
|
export { AdshiftThirdPartySharing } from './types';
|
|
39
39
|
export type { AdshiftThirdPartySharing as AdshiftThirdPartySharingType } from './types';
|
|
40
|
-
export { AdshiftDeepLinkStatus, AdshiftDeepLink } from './types';
|
|
40
|
+
export { AdshiftDeepLinkStatus, AdshiftDeepLinkSource, AdshiftDeepLink, } from './types';
|
|
41
41
|
export type { AdshiftDeepLink as AdshiftDeepLinkType } from './types';
|
|
42
42
|
export { AdshiftEventType, getAllEventTypes } from './types';
|
|
43
43
|
export type { AdshiftEventTypeValue } from './types';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAGH,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAE7C,YAAY,EACV,WAAW,EACX,WAAW,EACX,cAAc,EACd,oBAAoB,EACpB,gBAAgB,EAChB,iBAAiB,EACjB,WAAW,GACZ,MAAM,WAAW,CAAC;AAGnB,YAAY,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAGH,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAE7C,YAAY,EACV,WAAW,EACX,WAAW,EACX,cAAc,EACd,oBAAoB,EACpB,gBAAgB,EAChB,iBAAiB,EACjB,WAAW,GACZ,MAAM,WAAW,CAAC;AAGnB,YAAY,EAAE,aAAa,EAAE,gCAAgC,EAAE,MAAM,SAAS,CAAC;AAI/E,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AACzC,YAAY,EACV,cAAc,IAAI,kBAAkB,EACpC,WAAW,EACX,eAAe,EACf,aAAa,GACd,MAAM,SAAS,CAAC;AAEjB,OAAO,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC;AACnD,YAAY,EAAE,wBAAwB,IAAI,4BAA4B,EAAE,MAAM,SAAS,CAAC;AAIxF,OAAO,EACL,qBAAqB,EACrB,qBAAqB,EACrB,eAAe,GAChB,MAAM,SAAS,CAAC;AACjB,YAAY,EAAE,eAAe,IAAI,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAGtE,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAC7D,YAAY,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AACrD,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAC/D,YAAY,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAC;AAGtD,OAAO,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAClD,YAAY,EAAE,4BAA4B,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAG7E,OAAO,EAAE,gBAAgB,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAC3D,YAAY,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAG9D,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -20,7 +20,7 @@ import { AdshiftConsent } from '../types/AdshiftConsent';
|
|
|
20
20
|
import type { AdshiftThirdPartySharing as AdshiftThirdPartySharingType } from '../types/AdshiftThirdPartySharing';
|
|
21
21
|
import { AdshiftThirdPartySharing } from '../types/AdshiftThirdPartySharing';
|
|
22
22
|
import type { AdshiftDeepLink as AdshiftDeepLinkType } from '../types/AdshiftDeepLink';
|
|
23
|
-
import { AdshiftDeepLink, AdshiftDeepLinkStatus } from '../types/AdshiftDeepLink';
|
|
23
|
+
import { AdshiftDeepLink, AdshiftDeepLinkSource, AdshiftDeepLinkStatus } from '../types/AdshiftDeepLink';
|
|
24
24
|
import { AdshiftEventType, getAllEventTypes } from '../types/AdshiftEventType';
|
|
25
25
|
import { AdshiftEventParam, getAllEventParams } from '../types/AdshiftEventParam';
|
|
26
26
|
import { AdshiftMediationNetwork } from '../types/AdshiftAdRevenue';
|
|
@@ -54,6 +54,7 @@ export interface AdshiftMock {
|
|
|
54
54
|
logAdRevenue: MockFn<(params: Record<string, unknown>) => Promise<void>>;
|
|
55
55
|
getAdShiftDeviceId: MockFn<() => Promise<string | null>>;
|
|
56
56
|
handleDeepLink: MockFn<(url: string) => Promise<void>>;
|
|
57
|
+
handlePastedDeepLink: MockFn<(url: string | null) => void>;
|
|
57
58
|
addPushNotificationDeepLinkPath: MockFn<(path: string[]) => void>;
|
|
58
59
|
handlePushNotification: MockFn<(payload: Record<string, unknown>) => Promise<boolean>>;
|
|
59
60
|
onDeepLink: MockFn<(callback: Listener) => {
|
|
@@ -86,6 +87,7 @@ export interface AdshiftModuleMock {
|
|
|
86
87
|
AdshiftThirdPartySharing: typeof AdshiftThirdPartySharing;
|
|
87
88
|
AdshiftDeepLink: typeof AdshiftDeepLink;
|
|
88
89
|
AdshiftDeepLinkStatus: typeof AdshiftDeepLinkStatus;
|
|
90
|
+
AdshiftDeepLinkSource: typeof AdshiftDeepLinkSource;
|
|
89
91
|
AdshiftEventType: typeof AdshiftEventType;
|
|
90
92
|
getAllEventTypes: typeof getAllEventTypes;
|
|
91
93
|
AdshiftEventParam: typeof AdshiftEventParam;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/jest/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAIH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,KAAK,EAAE,cAAc,IAAI,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AACpF,OAAO,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzD,OAAO,KAAK,EAAE,wBAAwB,IAAI,4BAA4B,EAAE,MAAM,mCAAmC,C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,iBAAiB,EAAE;YAAE,OAAO,EAAE,MAAM,CAAC;YAAC,GAAG,EAAE,MAAM,CAAA;SAAE,CAAC;KACrD,CACF,CAAC;IAEF,sEAAsE;IACtE,cAAc,CAAC,QAAQ,EAAE,mBAAmB,GAAG,IAAI,CAAC;IACpD;;;;OAIG;IACH,OAAO,IAAI,IAAI,CAAC;CACjB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,WAAW,CAAC;IACrB,OAAO,EAAE,WAAW,CAAC;IACrB,cAAc,EAAE,OAAO,cAAc,CAAC;IACtC,wBAAwB,EAAE,OAAO,wBAAwB,CAAC;IAC1D,eAAe,EAAE,OAAO,eAAe,CAAC;IACxC,qBAAqB,EAAE,OAAO,qBAAqB,CAAC;IACpD,qBAAqB,EAAE,OAAO,qBAAqB,CAAC;IACpD,gBAAgB,EAAE,OAAO,gBAAgB,CAAC;IAC1C,gBAAgB,EAAE,OAAO,gBAAgB,CAAC;IAC1C,iBAAiB,EAAE,OAAO,iBAAiB,CAAC;IAC5C,iBAAiB,EAAE,OAAO,iBAAiB,CAAC;IAC5C,uBAAuB,EAAE,OAAO,uBAAuB,CAAC;IACxD,gBAAgB,EAAE,OAAO,gBAAgB,CAAC;IAC1C,cAAc,EAAE,OAAO,cAAc,CAAC;IACtC,cAAc,EAAE,MAAM,CAAC;CACxB;AAED;;GAEG;AACH,wBAAgB,iBAAiB,IAAI,iBAAiB,CAoGrD;AAED,OAAO,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,cAAc,EAAE,CAAC"}
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
import type { AdshiftError } from './AdshiftError';
|
|
2
|
+
/**
|
|
3
|
+
* Whether the first launch on iOS reads the deferred deep link a RightLink
|
|
4
|
+
* page copied to the clipboard.
|
|
5
|
+
*/
|
|
6
|
+
export type AdshiftDeferredDeepLinkClipboard = 'disabled' | 'prompt' | 'pasteControl';
|
|
7
|
+
/** @internal */
|
|
8
|
+
export declare const DEFERRED_DEEP_LINK_CLIPBOARD_MODES: ReadonlySet<string>;
|
|
2
9
|
/**
|
|
3
10
|
* Configuration for initializing the AdShift SDK.
|
|
4
11
|
*
|
|
@@ -30,10 +37,16 @@ export interface AdshiftConfig {
|
|
|
30
37
|
*/
|
|
31
38
|
appOpenDebounceMs?: number;
|
|
32
39
|
/**
|
|
33
|
-
*
|
|
34
|
-
*
|
|
40
|
+
* Your own link domains, e.g. `links.example.com`. Without this a link on
|
|
41
|
+
* such a domain comes back `notFound` and is not counted as a click.
|
|
35
42
|
*/
|
|
36
43
|
brandedDomains?: string[];
|
|
44
|
+
/**
|
|
45
|
+
* Mark every click and event as test traffic, which is kept out of
|
|
46
|
+
* reports, postbacks and billing. A debug build does not turn it on.
|
|
47
|
+
* @default false
|
|
48
|
+
*/
|
|
49
|
+
testMode?: boolean;
|
|
37
50
|
/**
|
|
38
51
|
* Meta app id used to parse Meta App Links.
|
|
39
52
|
* @platform android
|
|
@@ -75,6 +88,16 @@ export interface AdshiftConfig {
|
|
|
75
88
|
* @platform ios
|
|
76
89
|
*/
|
|
77
90
|
attTimeoutMs?: number;
|
|
91
|
+
/**
|
|
92
|
+
* Read the deferred deep link from the clipboard on the first launch, for
|
|
93
|
+
* RightLink templates with the clipboard option. `prompt`: iOS asks the
|
|
94
|
+
* user to allow the paste, once per install. `pasteControl`: your
|
|
95
|
+
* onboarding shows `UIPasteControl` and passes the result to
|
|
96
|
+
* `Adshift.handlePastedDeepLink()`.
|
|
97
|
+
* @default 'disabled'
|
|
98
|
+
* @platform ios
|
|
99
|
+
*/
|
|
100
|
+
deferredDeepLinkClipboard?: AdshiftDeferredDeepLinkClipboard;
|
|
78
101
|
/**
|
|
79
102
|
* Enable OAID collection on devices without Google Play services.
|
|
80
103
|
* @default true
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AdshiftConfig.d.ts","sourceRoot":"","sources":["../../../../../src/types/AdshiftConfig.ts"],"names":[],"mappings":"AAAA,O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,CAAC,EAAE,OAAO,CAAC;IAEnB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;;OAKG;IACH,iBAAiB,CAAC,EAAE,MAAM,EAAE,EAAE,CAAC;IAE/B;;;;;;;OAOG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAI9B;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IAEtB;;;;;OAKG;IACH,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAEhC;;;;;OAKG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;;;;;;OAQG;IACH,yBAAyB,CAAC,EAAE,gCAAgC,CAAC;IAI7D;;;;OAIG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IAItB;;;;;;;;;;;;;;;;OAgBG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;CACzC;AA6BD,wBAAgB,WAAW,CAAC,MAAM,EAAE,aAAa,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAS1E"}
|
|
@@ -2,18 +2,42 @@
|
|
|
2
2
|
* Status of a deep link result.
|
|
3
3
|
*/
|
|
4
4
|
export declare enum AdshiftDeepLinkStatus {
|
|
5
|
-
/**
|
|
5
|
+
/** A RightLink link, or a deferred deep link with a value. Navigate on this. */
|
|
6
6
|
Found = "found",
|
|
7
|
-
/**
|
|
7
|
+
/** Not a RightLink link, a deleted one, or no deferred deep link. */
|
|
8
8
|
NotFound = "notFound",
|
|
9
|
-
/**
|
|
9
|
+
/** Not resolved yet; the same link can still arrive as `found`. */
|
|
10
10
|
Error = "error"
|
|
11
11
|
}
|
|
12
|
+
/**
|
|
13
|
+
* How the link of a result reached the app.
|
|
14
|
+
*/
|
|
15
|
+
export declare enum AdshiftDeepLinkSource {
|
|
16
|
+
/** A Universal Link, or a link the app passed in itself. iOS. */
|
|
17
|
+
UniversalLink = "ul",
|
|
18
|
+
/** An App Link, or a link the app passed in itself. Android. */
|
|
19
|
+
AppLink = "app_link",
|
|
20
|
+
/** The app's own scheme; `found` only when it wraps a RightLink link in `as_rl`. */
|
|
21
|
+
Scheme = "scheme",
|
|
22
|
+
/** The open-in-app button of a RightLink page. */
|
|
23
|
+
Cta = "cta",
|
|
24
|
+
/** A push notification. */
|
|
25
|
+
Push = "push",
|
|
26
|
+
/** An AdAttributionKit re-engagement open. iOS. */
|
|
27
|
+
AdAttributionKit = "aak",
|
|
28
|
+
/** A link opened by a Meta app that is not a RightLink link. Android. */
|
|
29
|
+
MetaAppLink = "meta_applink",
|
|
30
|
+
/** The lookup on the first launch after install. */
|
|
31
|
+
Deferred = "deferred",
|
|
32
|
+
/** A web link that is not a RightLink link. */
|
|
33
|
+
Foreign = "foreign"
|
|
34
|
+
}
|
|
12
35
|
/**
|
|
13
36
|
* Deep link delivered through `Adshift.onDeepLink()`.
|
|
14
37
|
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
38
|
+
* Navigate only on `status: 'found'`, and validate `deepLinkValue` first:
|
|
39
|
+
* anyone can write a link. Any other URL comes back `notFound` with the URL
|
|
40
|
+
* in `deepLink`. Treat `error` as "not yet".
|
|
17
41
|
*
|
|
18
42
|
* @example
|
|
19
43
|
* ```typescript
|
|
@@ -25,23 +49,40 @@ export declare enum AdshiftDeepLinkStatus {
|
|
|
25
49
|
* ```
|
|
26
50
|
*/
|
|
27
51
|
export interface AdshiftDeepLink {
|
|
52
|
+
/**
|
|
53
|
+
* The link as opened, a short link expanded. On iOS a deferred result has
|
|
54
|
+
* none: route on `deepLinkValue`.
|
|
55
|
+
*/
|
|
28
56
|
deepLink?: string;
|
|
29
57
|
/** Standardized routing value (`deep_link_value`). */
|
|
30
58
|
deepLinkValue?: string;
|
|
31
59
|
/**
|
|
32
|
-
* Query parameters of
|
|
33
|
-
*
|
|
34
|
-
* below, which both platforms fill.
|
|
60
|
+
* Query parameters of a RightLink link, your own keys included. Absent for
|
|
61
|
+
* any other URL.
|
|
35
62
|
*/
|
|
36
63
|
params?: Record<string, string>;
|
|
37
64
|
/** Whether this result comes from deferred deep linking (first launch). */
|
|
38
65
|
isDeferred: boolean;
|
|
39
66
|
status: AdshiftDeepLinkStatus;
|
|
40
|
-
/** Error message when `status` is `error
|
|
67
|
+
/** Error message when `status` is `error`; wording differs per platform. */
|
|
41
68
|
errorMessage?: string;
|
|
69
|
+
/** How the link reached the app. */
|
|
70
|
+
source?: AdshiftDeepLinkSource;
|
|
71
|
+
/**
|
|
72
|
+
* Id of the click this open was attributed to. Absent for a deferred result
|
|
73
|
+
* and when no click was recorded.
|
|
74
|
+
*/
|
|
75
|
+
clickId?: string;
|
|
76
|
+
/**
|
|
77
|
+
* `false` for a deferred result matched without a clipboard token or an
|
|
78
|
+
* advertising identifier: route the user, but do not sign them in or grant
|
|
79
|
+
* a reward because of it.
|
|
80
|
+
* @platform ios
|
|
81
|
+
*/
|
|
82
|
+
matchGuaranteed?: boolean;
|
|
42
83
|
/**
|
|
43
|
-
* Whether the result
|
|
44
|
-
*
|
|
84
|
+
* Whether the result came in the first session after install. `isDeferred`
|
|
85
|
+
* alone does not mean a new user.
|
|
45
86
|
*/
|
|
46
87
|
isFirstSession?: boolean;
|
|
47
88
|
/** Custom sub-parameter 1 (`deep_link_sub1`). */
|
|
@@ -65,6 +106,9 @@ export declare const AdshiftDeepLink: {
|
|
|
65
106
|
params?: Record<string, string>;
|
|
66
107
|
isDeferred?: boolean;
|
|
67
108
|
isFirstSession?: boolean;
|
|
109
|
+
source?: AdshiftDeepLinkSource;
|
|
110
|
+
clickId?: string;
|
|
111
|
+
matchGuaranteed?: boolean;
|
|
68
112
|
deepLinkSub1?: string;
|
|
69
113
|
deepLinkSub2?: string;
|
|
70
114
|
deepLinkSub3?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AdshiftDeepLink.d.ts","sourceRoot":"","sources":["../../../../../src/types/AdshiftDeepLink.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,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,CAAC;IAEtB,iDAAiD;IACjD,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,iDAAiD;IACjD,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,iDAAiD;IACjD,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB,iDAAiD;IACjD,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAYD;;GAEG;AACH,eAAO,MAAM,eAAe;mBACX;QACb,QAAQ,EAAE,MAAM,CAAC;QACjB,aAAa,CAAC,EAAE,MAAM,CAAC;QACvB,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAChC,UAAU,CAAC,EAAE,OAAO,CAAC;QACrB,cAAc,CAAC,EAAE,OAAO,CAAC;QACzB,MAAM,CAAC,EAAE,qBAAqB,CAAC;QAC/B,OAAO,CAAC,EAAE,MAAM,CAAC;QACjB,eAAe,CAAC,EAAE,OAAO,CAAC;QAC1B,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,YAAY,CAAC,EAAE,MAAM,CAAC;QACtB,YAAY,CAAC,EAAE,MAAM,CAAC;KACvB,GAAG,eAAe;gBAiCP,eAAe;mBAOZ,MAAM,GAAG,eAAe;IAQvC;;;;OAIG;iBACU,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,eAAe;CAuCvD,CAAC;AA2BF;;;;GAIG;AACH,wBAAgB,aAAa,CAC3B,QAAQ,EAAE,eAAe,GACxB,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAWzB"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export type { AdshiftConfig } from './AdshiftConfig';
|
|
2
|
-
export { configToMap } from './AdshiftConfig';
|
|
1
|
+
export type { AdshiftConfig, AdshiftDeferredDeepLinkClipboard, } from './AdshiftConfig';
|
|
2
|
+
export { configToMap, DEFERRED_DEEP_LINK_CLIPBOARD_MODES, } from './AdshiftConfig';
|
|
3
3
|
export type { ConsentFlag } from './AdshiftConsent';
|
|
4
4
|
export { AdshiftConsent, consentToMap } from './AdshiftConsent';
|
|
5
5
|
export type { ConsentSnapshot, ConsentSource } from './AdshiftConsentSnapshot';
|
|
6
6
|
export { consentSnapshotFromMap } from './AdshiftConsentSnapshot';
|
|
7
7
|
export { AdshiftThirdPartySharing, thirdPartySharingToMap, } from './AdshiftThirdPartySharing';
|
|
8
|
-
export { AdshiftDeepLinkStatus, AdshiftDeepLink, deepLinkToMap, } from './AdshiftDeepLink';
|
|
8
|
+
export { AdshiftDeepLinkStatus, AdshiftDeepLinkSource, AdshiftDeepLink, deepLinkToMap, } from './AdshiftDeepLink';
|
|
9
9
|
export { AdshiftEventType, getAllEventTypes } from './AdshiftEventType';
|
|
10
10
|
export type { AdshiftEventTypeValue } from './AdshiftEventType';
|
|
11
11
|
export { AdshiftEventParam, getAllEventParams } from './AdshiftEventParam';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/types/index.ts"],"names":[],"mappings":"AAAA,YAAY,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/types/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,aAAa,EACb,gCAAgC,GACjC,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,WAAW,EACX,kCAAkC,GACnC,MAAM,iBAAiB,CAAC;AAEzB,YAAY,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAEhE,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AAC/E,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAElE,OAAO,EACL,wBAAwB,EACxB,sBAAsB,GACvB,MAAM,4BAA4B,CAAC;AAEpC,OAAO,EACL,qBAAqB,EACrB,qBAAqB,EACrB,eAAe,EACf,aAAa,GACd,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACxE,YAAY,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAEhE,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC3E,YAAY,EAAE,sBAAsB,EAAE,MAAM,qBAAqB,CAAC;AAElE,OAAO,EAAE,uBAAuB,EAAE,MAAM,oBAAoB,CAAC;AAC7D,YAAY,EACV,4BAA4B,EAC5B,eAAe,GAChB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EACL,gBAAgB,EAChB,cAAc,EACd,kBAAkB,EAClB,cAAc,GACf,MAAM,gBAAgB,CAAC;AACxB,YAAY,EAAE,YAAY,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const PLUGIN_VERSION = "
|
|
1
|
+
export declare const PLUGIN_VERSION = "3.0.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
|
@@ -34,16 +34,19 @@ import { AdshiftErrorCode } from './types';
|
|
|
34
34
|
/**
|
|
35
35
|
* Result of `Adshift.start()`.
|
|
36
36
|
*
|
|
37
|
-
* `success` reports whether the SDK started locally.
|
|
38
|
-
* the
|
|
39
|
-
* `config.onError`
|
|
37
|
+
* `success` reports whether the SDK started locally. The API key is checked
|
|
38
|
+
* with the backend in the background: `apiKeyValidationStatus` is the verdict
|
|
39
|
+
* at the time `start()` resolved, and `config.onError` reports
|
|
40
|
+
* `INVALID_API_KEY` when that verdict is `invalid`. On iOS the verdict usually
|
|
41
|
+
* arrives after `start()` resolved and is reported by the next `start()`; on
|
|
42
|
+
* Android `start()` waits up to 5 s for it.
|
|
40
43
|
*/
|
|
41
44
|
export interface StartResult {
|
|
42
45
|
success: boolean;
|
|
43
46
|
/**
|
|
44
|
-
* Outcome of the API key check at the time `start()` resolved
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
+
* Outcome of the API key check at the time `start()` resolved; `pending`
|
|
48
|
+
* means the answer had not arrived yet. It changes nothing you have to do:
|
|
49
|
+
* events tracked meanwhile stay queued on the device by the native SDK.
|
|
47
50
|
*/
|
|
48
51
|
apiKeyValidationStatus?: ApiKeyValidationStatus;
|
|
49
52
|
/** Platform error number behind `errorCode`, for support requests. */
|
|
@@ -280,6 +283,13 @@ export declare const Adshift: {
|
|
|
280
283
|
* `INVALID_ARGUMENT`).
|
|
281
284
|
*/
|
|
282
285
|
readonly handleDeepLink: (url: string) => Promise<void>;
|
|
286
|
+
/**
|
|
287
|
+
* With `deferredDeepLinkClipboard: 'pasteControl'`, passes what the user
|
|
288
|
+
* pasted with `UIPasteControl`, or `null` when they skipped it. Call it on
|
|
289
|
+
* every way out of onboarding: the first launch's deferred deep link waits
|
|
290
|
+
* for it. No-op on Android.
|
|
291
|
+
*/
|
|
292
|
+
readonly handlePastedDeepLink: (url: string | null) => void;
|
|
283
293
|
/**
|
|
284
294
|
* Adds a key path inside push payloads that carries an AdShift deep link.
|
|
285
295
|
*
|
|
@@ -302,7 +312,8 @@ export declare const Adshift: {
|
|
|
302
312
|
*
|
|
303
313
|
* Safe to call before `initialize()`. Results that arrive while no
|
|
304
314
|
* listener is registered are buffered and delivered to the first listener.
|
|
305
|
-
* Every link that reaches the SDK (direct, deferred, push) is delivered
|
|
315
|
+
* Every link that reaches the SDK (direct, deferred, push) is delivered,
|
|
316
|
+
* each result once.
|
|
306
317
|
*/
|
|
307
318
|
readonly onDeepLink: (callback: DeepLinkCallback) => DeepLinkSubscription;
|
|
308
319
|
readonly getInfo: () => AdshiftInfo;
|