@encorekit/web-sdk 2.1.4 → 2.2.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/README.md +20 -0
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/umd/encore.min.js +1 -1
- package/dist/umd/encore.min.js.map +1 -1
- package/package.json +1 -1
- package/types/analytics/events.d.ts +54 -2
- package/types/analytics/events.d.ts.map +1 -1
- package/types/api/APIClient.d.ts +15 -1
- package/types/api/APIClient.d.ts.map +1 -1
- package/types/api/generated/types.d.ts +94 -7
- package/types/api/generated/types.d.ts.map +1 -1
- package/types/api/models.d.ts +7 -0
- package/types/api/models.d.ts.map +1 -1
- package/types/core/Configuration.d.ts +2 -0
- package/types/core/Configuration.d.ts.map +1 -1
- package/types/core/Encore.d.ts.map +1 -1
- package/types/core/giftVariant.d.ts +11 -6
- package/types/core/giftVariant.d.ts.map +1 -1
- package/types/core/share.d.ts +58 -0
- package/types/core/share.d.ts.map +1 -0
- package/types/core/unlockCode.d.ts +25 -0
- package/types/core/unlockCode.d.ts.map +1 -0
- package/types/core/version.d.ts +1 -1
- package/types/types.d.ts +61 -8
- package/types/types.d.ts.map +1 -1
- package/types/ui/CodeUnlock.d.ts +151 -0
- package/types/ui/CodeUnlock.d.ts.map +1 -0
- package/types/ui/GiftSheet.d.ts +47 -3
- package/types/ui/GiftSheet.d.ts.map +1 -1
- package/types/ui/GiftUnwrap.d.ts +70 -0
- package/types/ui/GiftUnwrap.d.ts.map +1 -1
- package/types/ui/OfferModal.d.ts +30 -0
- package/types/ui/OfferModal.d.ts.map +1 -1
- package/types/ui/giftUnwrapArt.d.ts +6 -0
- package/types/ui/giftUnwrapArt.d.ts.map +1 -1
- package/types/ui/giftUnwrapCopy.d.ts +20 -0
- package/types/ui/giftUnwrapCopy.d.ts.map +1 -1
- package/types/ui/styles.d.ts.map +1 -1
package/package.json
CHANGED
|
@@ -43,6 +43,33 @@ export declare const ClaimFailureReason: {
|
|
|
43
43
|
readonly INVALID_DESTINATION_URL: "invalid_destination_url";
|
|
44
44
|
readonly POPUP_BLOCKED: "popup_blocked";
|
|
45
45
|
};
|
|
46
|
+
/**
|
|
47
|
+
* `properties.reason` on `sdk_offer_share_failed`, the terminal twin of a share tap
|
|
48
|
+
* that never reached anything that could take the link. `missing_share_link` is iOS's
|
|
49
|
+
* and Android's spelling (swift#156, android#93): the offer carries no `shareUrl`, and
|
|
50
|
+
* there is deliberately no fallback to another URL.
|
|
51
|
+
*
|
|
52
|
+
* `share_unavailable` is web's own, in the slot iOS fills with `no_presenter` and
|
|
53
|
+
* Android with `no_chooser`: neither the system share sheet nor the clipboard would
|
|
54
|
+
* take the link (an insecure page with the copy command refused, a frame denied both
|
|
55
|
+
* permissions). A cancel is never a failure; see `sdk_offer_share_completed`.
|
|
56
|
+
*/
|
|
57
|
+
export declare const ShareFailureReason: {
|
|
58
|
+
readonly MISSING_SHARE_LINK: "missing_share_link";
|
|
59
|
+
readonly SHARE_UNAVAILABLE: "share_unavailable";
|
|
60
|
+
};
|
|
61
|
+
export type ShareFailureReasonValue = (typeof ShareFailureReason)[keyof typeof ShareFailureReason];
|
|
62
|
+
/**
|
|
63
|
+
* `properties.share_destination` on a completed web share. iOS reports the
|
|
64
|
+
* `UIActivity.ActivityType` the user picked; a browser never learns which app the
|
|
65
|
+
* system sheet handed the link to, so web reports which of its two routes took it:
|
|
66
|
+
* `web_share` (`navigator.share` resolved) or `clipboard` (the fallback copied it).
|
|
67
|
+
*/
|
|
68
|
+
export declare const ShareDestination: {
|
|
69
|
+
readonly SHARE_SHEET: "web_share";
|
|
70
|
+
readonly CLIPBOARD: "clipboard";
|
|
71
|
+
};
|
|
72
|
+
export type ShareDestinationValue = (typeof ShareDestination)[keyof typeof ShareDestination];
|
|
46
73
|
/**
|
|
47
74
|
* Translate an SDK-internal decline reason to its wire value.
|
|
48
75
|
*
|
|
@@ -181,6 +208,29 @@ export declare function offerClaimFailed(distinctId: string, ctx: OfferEventCont
|
|
|
181
208
|
export declare function offerClaimReturned(distinctId: string, ctx: OfferEventContext, params: {
|
|
182
209
|
transactionId?: string;
|
|
183
210
|
}): AnalyticsEvent;
|
|
211
|
+
/**
|
|
212
|
+
* The user tapped a share control, before anything is shared. Mirrors iOS
|
|
213
|
+
* `OfferShareTappedEvent` and Android's: the claim context and nothing else. A tap
|
|
214
|
+
* made while an earlier share is still open is not a new tap and is not reported.
|
|
215
|
+
*/
|
|
216
|
+
export declare function offerShareTapped(distinctId: string, ctx: OfferEventContext): AnalyticsEvent;
|
|
217
|
+
/**
|
|
218
|
+
* A share tap that never reached anything that could take the link. The twin of
|
|
219
|
+
* `sdk_offer_share_tapped`, so every tap has a terminal event. See `ShareFailureReason`.
|
|
220
|
+
*/
|
|
221
|
+
export declare function offerShareFailed(distinctId: string, ctx: OfferEventContext, params: {
|
|
222
|
+
reason: ShareFailureReasonValue;
|
|
223
|
+
}): AnalyticsEvent;
|
|
224
|
+
/**
|
|
225
|
+
* The share settled. `completed` is false when the user dismissed the share sheet
|
|
226
|
+
* without sending, and then there is no destination, which iOS also encodes by
|
|
227
|
+
* omission. Mirrors iOS `OfferShareCompletedEvent`; Android emits none because it
|
|
228
|
+
* cannot observe the chooser. See `ShareDestination` for web's destinations.
|
|
229
|
+
*/
|
|
230
|
+
export declare function offerShareCompleted(distinctId: string, ctx: OfferEventContext, params: {
|
|
231
|
+
shareDestination?: ShareDestinationValue;
|
|
232
|
+
completed: boolean;
|
|
233
|
+
}): AnalyticsEvent;
|
|
184
234
|
/**
|
|
185
235
|
* Web's advertiser handoff is a browser tab, not an embedded webview, so these
|
|
186
236
|
* keep iOS's event NAMES (the warehouse funnel is keyed on them) while reporting
|
|
@@ -343,11 +393,13 @@ export declare function sduiConfigLoaded(distinctId: string, params: {
|
|
|
343
393
|
}): AnalyticsEvent;
|
|
344
394
|
/**
|
|
345
395
|
* A control in the offer sheet was activated. `actionType` uses iOS's action
|
|
346
|
-
* vocabulary so the same query reads both platforms
|
|
396
|
+
* vocabulary so the same query reads both platforms: `share` is the share control,
|
|
397
|
+
* and `setState` is the one state change web reports, the × that opens the
|
|
398
|
+
* "keep your gift for later" panel instead of closing.
|
|
347
399
|
*/
|
|
348
400
|
export declare function sduiButtonTapped(distinctId: string, params: {
|
|
349
401
|
variantId?: string;
|
|
350
|
-
actionType: 'close' | 'claimOffer' | 'openUrl' | 'next' | 'previous';
|
|
402
|
+
actionType: 'close' | 'claimOffer' | 'openUrl' | 'next' | 'previous' | 'share' | 'setState';
|
|
351
403
|
presentationId: string;
|
|
352
404
|
currentState: string;
|
|
353
405
|
useCase?: UseCase;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/analytics/events.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAQxC;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,wBAAwB;;;;CAI3B,CAAC;AAEX;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB;;;;;;CAMrB,CAAC;AA+
|
|
1
|
+
{"version":3,"file":"events.d.ts","sourceRoot":"","sources":["../../src/analytics/events.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAC/C,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAQxC;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,wBAAwB;;;;CAI3B,CAAC;AAEX;;;;;;;GAOG;AACH,eAAO,MAAM,kBAAkB;;;;;;CAMrB,CAAC;AAEX;;;;;;;;;;GAUG;AACH,eAAO,MAAM,kBAAkB;;;CAGrB,CAAC;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CAahB;AAMD;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,YAAY,EAAE,MAAM,EACpB,MAAM,EAAE;IAAE,UAAU,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,MAAM,CAAC;IAAC,iBAAiB,EAAE,MAAM,CAAA;CAAE,GACxE,cAAc,CAWhB;AAMD,wBAAgB,QAAQ,CACtB,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,EACjB,gBAAgB,EAAE,MAAM,EACxB,OAAO,CAAC,EAAE,MAAM,GACf,cAAc,CAMhB"}
|
package/types/api/APIClient.d.ts
CHANGED
|
@@ -24,6 +24,17 @@ export declare function readProposedCategory(campaign: unknown): string | undefi
|
|
|
24
24
|
* `http:` row included, is dropped, so a bad row can never inject a scheme.
|
|
25
25
|
*/
|
|
26
26
|
export declare function readCampaignUrl(campaign: unknown, key: 'heroImageUrl' | 'termsUrl'): string | undefined;
|
|
27
|
+
/**
|
|
28
|
+
* The link a user can send someone for this offer (`campaign.shareUrl`, declared by
|
|
29
|
+
* backend#659 and not yet in the synced contract), read tolerantly: a non-blank string,
|
|
30
|
+
* trimmed, that parses as an ABSOLUTE `http:` or `https:` URL. Anything else is absent,
|
|
31
|
+
* which the share action reports as `missing_share_link`.
|
|
32
|
+
*
|
|
33
|
+
* Only the field is dropped, never the offer: a bad link costs one button, not the
|
|
34
|
+
* offer list. A relative value is absent too, because `navigator.share` would resolve
|
|
35
|
+
* it against the HOST page and send the publisher's own URL.
|
|
36
|
+
*/
|
|
37
|
+
export declare function readShareUrl(campaign: unknown): string | undefined;
|
|
27
38
|
interface RequestOptions {
|
|
28
39
|
method: 'GET' | 'POST' | 'PATCH';
|
|
29
40
|
headers?: Record<string, string>;
|
|
@@ -133,8 +144,11 @@ export declare class APIClient {
|
|
|
133
144
|
*
|
|
134
145
|
* `demoVariant` is Encore's internal demo-page override and rides both. See
|
|
135
146
|
* `EncoreConfig.demoVariant`; the backend ignores it for every non-demo app.
|
|
147
|
+
*
|
|
148
|
+
* `placementId` is sent only by the placement-scoped fetch behind
|
|
149
|
+
* `EncoreConfig.resolveVariantsByPlacement`, already normalised by the caller.
|
|
136
150
|
*/
|
|
137
|
-
fetchConfig(userId: string, sdkVersion: string, useCase?: UseCase, demoVariant?: string): Promise<RemoteConfigResponse>;
|
|
151
|
+
fetchConfig(userId: string, sdkVersion: string, useCase?: UseCase, demoVariant?: string, placementId?: string): Promise<RemoteConfigResponse>;
|
|
138
152
|
/**
|
|
139
153
|
* Report a client error (fire-and-forget)
|
|
140
154
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"APIClient.d.ts","sourceRoot":"","sources":["../../src/api/APIClient.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,KAAK,EAAe,cAAc,EAAE,WAAW,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAGtG,OAAO,KAAK,EAEV,wBAAwB,EAIxB,gBAAgB,EAChB,oBAAoB,EACpB,oBAAoB,EACpB,UAAU,EACV,yBAAyB,EAC1B,MAAM,UAAU,CAAC;AAalB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAOzD;;;;;;;;;;GAUG;AACH,wBAAgB,oBAAoB,CAAC,QAAQ,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAM1E;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAC7B,QAAQ,EAAE,OAAO,EACjB,GAAG,EAAE,cAAc,GAAG,UAAU,GAC/B,MAAM,GAAG,SAAS,CAKpB;AAMD,UAAU,cAAc;IACtB,MAAM,EAAE,KAAK,GAAG,MAAM,GAAG,OAAO,CAAC;IACjC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAQD,qBAA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AAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,EAClB,OAAO,CAAC,EAAE,OAAO,EACjB,WAAW,CAAC,EAAE,MAAM,EACpB,WAAW,CAAC,EAAE,MAAM,GACnB,OAAO,CAAC,oBAAoB,CAAC;IAuBhC;;OAEG;IACG,WAAW,CAAC,MAAM,EAAE;QACxB,SAAS,EAAE,MAAM,CAAC;QAClB,OAAO,EAAE,MAAM,CAAC;QAChB,6FAA6F;QAC7F,OAAO,EAAE,YAAY,CAAC;QACtB,QAAQ,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,SAAS,GAAG,MAAM,CAAC;QAClD,UAAU,CAAC,EAAE,MAAM,CAAC;QACpB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;KACnC,GAAG,OAAO,CAAC,IAAI,CAAC;IA0CjB;;OAEG;IACG,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;CAW3D"}
|
|
@@ -46,7 +46,7 @@ export interface paths {
|
|
|
46
46
|
organizationId: string;
|
|
47
47
|
name: string;
|
|
48
48
|
/** @enum {string} */
|
|
49
|
-
payoutModel: "CPA" | "CPC" | "CPI" | "CPM";
|
|
49
|
+
payoutModel: "CPA" | "CPC" | "CPI" | "CPL" | "CPM";
|
|
50
50
|
payoutAmount: number;
|
|
51
51
|
/** @description Attribution platform (e.g., rakuten, impact, tune) */
|
|
52
52
|
attributionPlatform: string | null;
|
|
@@ -351,7 +351,7 @@ export interface paths {
|
|
|
351
351
|
organizationId: string;
|
|
352
352
|
name: string;
|
|
353
353
|
/** @enum {string} */
|
|
354
|
-
payoutModel: "CPA" | "CPC" | "CPI" | "CPM";
|
|
354
|
+
payoutModel: "CPA" | "CPC" | "CPI" | "CPL" | "CPM";
|
|
355
355
|
payoutAmount: number;
|
|
356
356
|
/** @description Attribution platform (e.g., rakuten, impact, tune) */
|
|
357
357
|
attributionPlatform: string | null;
|
|
@@ -517,10 +517,17 @@ export interface paths {
|
|
|
517
517
|
/** Format: date-time */
|
|
518
518
|
updatedAt: string;
|
|
519
519
|
}[];
|
|
520
|
+
/** @description Opaque link a user can send to someone else for this campaign. A claim made through it attributes back to the user who shared it. MUST be absolute and http or https: both SDKs drop anything else while parsing, so a scheme-less or relative value reads as absent and no share control is drawn. ABSENT until share links ship, and a client that finds it absent must share nothing rather than falling back to another URL: an unattributed link loses the claim the share exists to carry. /offers/search only. Deliberately a plain string, not `format: uri`: that format makes the Kotlin generator emit java.net.URI, and a link its parser rejects would fail the WHOLE offers decode on Android rather than just the share button. */
|
|
521
|
+
shareUrl?: string | null;
|
|
520
522
|
/** @description Display name of the campaign category, e.g. "Music and Audio". Free string: the taxonomy is admin-editable, so accept any value. */
|
|
521
523
|
category?: string | null;
|
|
522
524
|
/** @description The gift-sheet group this campaign files under: "Watch & listen", "Money" or "Everyday". Derived from `category` by the server so a native chip strip shows what web tabs show without holding the taxonomy map. Always set: an absent, blank or unmapped category files under "Everyday", so every offer sits in some group. Whether a strip is worth drawing is the client's call, because only it knows which offers its sheet lists. /offers/search only: web-sdk holds its own copy of the map and groups `category` itself. */
|
|
523
525
|
categoryGroup?: string | null;
|
|
526
|
+
/** @description Estimated time from the user tapping this offer to the reward being confirmed, from recent real conversions (on demo offers, from the demo advertiser's configured behavior instead). Half confirm within medianSeconds, 9 in 10 within p90Seconds. Not a guarantee: to show a wait, use p90Seconds. Null when there is no current estimate (too few recent conversions, data more than 7 days old, or an offer that does not confirm through the advertiser); say nothing about timing then. */
|
|
527
|
+
rewardConfirmationTime?: {
|
|
528
|
+
medianSeconds: number;
|
|
529
|
+
p90Seconds: number;
|
|
530
|
+
} | null;
|
|
524
531
|
}[];
|
|
525
532
|
metadata: {
|
|
526
533
|
/** @description Total offers available */
|
|
@@ -671,6 +678,13 @@ export interface paths {
|
|
|
671
678
|
targetCountries: string[];
|
|
672
679
|
/** @description When true, this is a demo offer: a fictional brand served only to pk_test_* keys so an integration can be exercised end to end without contacting a real advertiser. Surface it as such rather than presenting it as real inventory. Absent or false means ordinary inventory. */
|
|
673
680
|
isDemo?: boolean;
|
|
681
|
+
/** @description https link to the advertiser offer terms. Null or absent: render terms copy as plain text. */
|
|
682
|
+
termsUrl?: string | null;
|
|
683
|
+
/** @description Estimated time from the user tapping this offer to the reward being confirmed, from recent real conversions (on demo offers, from the demo advertiser's configured behavior instead). Half confirm within medianSeconds, 9 in 10 within p90Seconds. Not a guarantee: to show a wait, use p90Seconds. Null when there is no current estimate (too few recent conversions, data more than 7 days old, or an offer that does not confirm through the advertiser); say nothing about timing then. */
|
|
684
|
+
rewardConfirmationTime?: {
|
|
685
|
+
medianSeconds: number;
|
|
686
|
+
p90Seconds: number;
|
|
687
|
+
} | null;
|
|
674
688
|
organization?: {
|
|
675
689
|
/** Format: uuid */
|
|
676
690
|
id: string;
|
|
@@ -693,6 +707,14 @@ export interface paths {
|
|
|
693
707
|
ctaText: string;
|
|
694
708
|
/** @description Platforms this creative supports (empty = all platforms) */
|
|
695
709
|
supportedPlatforms: ("android" | "ios" | "web")[] | null;
|
|
710
|
+
/** @description Step by step instructions from the creative, translated like the title. Null or absent: the creative has none. */
|
|
711
|
+
instructions?: {
|
|
712
|
+
title: string;
|
|
713
|
+
subtitle: string;
|
|
714
|
+
ctaButtonText?: string;
|
|
715
|
+
}[] | null;
|
|
716
|
+
/** @description A short one line version of the instructions, e.g. "sign up, complete one survey". Null or absent: the creative has none. */
|
|
717
|
+
quickInstructions?: string | null;
|
|
696
718
|
/**
|
|
697
719
|
* Format: uri
|
|
698
720
|
* @description Tokenized click URL for THIS creative. Send the end user here when they tap the offer: it records a transaction attributed to (your app, this offer, this creative, the userId you supplied) and 302-redirects to the advertiser with the transaction id substituted. Treat it as opaque, do not modify it. Present on serve responses; absent when includeAllRegions is set.
|
|
@@ -994,6 +1016,19 @@ export interface paths {
|
|
|
994
1016
|
termsUrl?: string | null;
|
|
995
1017
|
/** @description Display name of the campaign category, e.g. "Music and Audio". Free string: the taxonomy is admin-editable, so accept any value. */
|
|
996
1018
|
category?: string | null;
|
|
1019
|
+
/** @description Step by step instructions from the creative, translated like the title. Null or absent: the creative has none. */
|
|
1020
|
+
instructions?: {
|
|
1021
|
+
title: string;
|
|
1022
|
+
subtitle: string;
|
|
1023
|
+
ctaButtonText?: string;
|
|
1024
|
+
}[] | null;
|
|
1025
|
+
/** @description A short one line version of the instructions, e.g. "sign up, complete one survey". Null or absent: the creative has none. */
|
|
1026
|
+
quickInstructions?: string | null;
|
|
1027
|
+
/** @description Estimated time from the user tapping this offer to the reward being confirmed, from recent real conversions (on demo offers, from the demo advertiser's configured behavior instead). Half confirm within medianSeconds, 9 in 10 within p90Seconds. Not a guarantee: to show a wait, use p90Seconds. Null when there is no current estimate (too few recent conversions, data more than 7 days old, or an offer that does not confirm through the advertiser); say nothing about timing then. */
|
|
1028
|
+
rewardConfirmationTime?: {
|
|
1029
|
+
medianSeconds: number;
|
|
1030
|
+
p90Seconds: number;
|
|
1031
|
+
} | null;
|
|
997
1032
|
}[];
|
|
998
1033
|
};
|
|
999
1034
|
};
|
|
@@ -2301,7 +2336,7 @@ export interface paths {
|
|
|
2301
2336
|
path?: never;
|
|
2302
2337
|
cookie?: never;
|
|
2303
2338
|
};
|
|
2304
|
-
/** @description Get unified SDK configuration including SDUI, entitlements, experiments, and remote config. This endpoint replaces /ui-config with a cleaner structure. Entitlement mode is implicit: if entitlements.iap.productId exists, use IAP mode; otherwise use Native mode. Pass `useCase` to configure a surface other than churn-intervention; the response echoes it as ui.useCase. `demoVariant` names an SDUI variant to serve for this request. It is honoured on a TEST key (pk_test_*) for any app, and
|
|
2339
|
+
/** @description Get unified SDK configuration including SDUI, entitlements, experiments, and remote config. This endpoint replaces /ui-config with a cleaner structure. Entitlement mode is implicit: if entitlements.iap.productId exists, use IAP mode; otherwise use Native mode. Pass `useCase` to configure a surface other than churn-intervention; the response echoes it as ui.useCase. `demoVariant` names an SDUI variant to serve for this request. It is honoured on a TEST key (pk_test_*) for any app, and on a live key only for Encore's own demo apps; for every other app it is ignored silently (never an error). It exists for demos and previews: Encore's own demo pages, and a publisher who wants to see the other variants against their own test key. `placementId` selects a variant an admin pinned to that placement, in `ui` only; any label without a pin resolves as before. Requesting a surface is all it takes to be served it — no setup call is required. A surface Encore has explicitly switched off for this app, or one with no variant available, returns ui.template: null — clients must no-op, never reuse another use case's template. */
|
|
2305
2340
|
get: {
|
|
2306
2341
|
parameters: {
|
|
2307
2342
|
query: {
|
|
@@ -2313,8 +2348,10 @@ export interface paths {
|
|
|
2313
2348
|
language?: string;
|
|
2314
2349
|
/** @description Which Encore surface is being configured. Omit for today's behaviour. Requesting a surface is all it takes to be served it — no setup call is required. A surface Encore has explicitly switched off for this app, or one with no variant available, resolves to template: null — it NEVER falls back to another use case's template. */
|
|
2315
2350
|
useCase?: "churn-intervention" | "post-action-reward";
|
|
2316
|
-
/** @description Demos and previews only. The SDUI variant file stem to serve for this request, e.g. 'giftUnwrap'. Honoured on a TEST key (pk_test_*) for any app
|
|
2351
|
+
/** @description Demos and previews only. The SDUI variant file stem to serve for this request, e.g. 'giftUnwrap'. Honoured on a TEST key (pk_test_*) for any app. On a live key it is honoured only for Encore's own demo apps; for every other app it is ignored silently and resolution is unchanged, never an error. Intended for Encore's internal demos and for a publisher previewing the other variants against their own test key. An honoured value bypasses app targeting, experiments and arm weights, and WIDENS the status filter from 'active' to 'active' or 'valid' — the filter is widened, not removed, so a draft, testing, invalid or archived variant is still refused. The use-case partition, the per-app kill switch and the SDK version gate all still apply. Note that a test key also serves the demo campaign catalog rather than live advertiser inventory, and tags the request as test traffic in analytics. */
|
|
2317
2352
|
demoVariant?: string;
|
|
2353
|
+
/** @description The publisher's placement label for the surface being configured, e.g. 'email_code'. Optional. When an admin has pinned an SDUI variant to this (app, placement), `ui` serves that variant instead of the experiment assignment, provided it is active or valid, matches the requested use case and passes its SDK version gate and app targeting. Otherwise, and for any label with no pin, resolution is unchanged. Never a 4xx on any input. Applies to `ui` only; the `useCases` prefetch block is never pinned. */
|
|
2354
|
+
placementId?: string;
|
|
2318
2355
|
};
|
|
2319
2356
|
header?: never;
|
|
2320
2357
|
path?: never;
|
|
@@ -2384,6 +2421,12 @@ export interface paths {
|
|
|
2384
2421
|
rewardHeadline?: string | null;
|
|
2385
2422
|
/** @description Subheadline for the reward template. NON-NULL whenever ui.useCase is 'post-action-reward', for the same reason as rewardHeadline — the template references ${rewardSubheadline} unconditionally. Resolution: app_use_cases.subheadline, else the shipped default. */
|
|
2386
2423
|
rewardSubheadline?: string | null;
|
|
2424
|
+
/** @description Primary button label for the reward template. Resolution: the variant's own defaultCopy.cta. Null when the variant declares none, in which case its template carries a literal instead. An SDK that predates this field receives the wording inlined in the template, not a token. */
|
|
2425
|
+
rewardCta?: string | null;
|
|
2426
|
+
/** @description Decline button label for the reward template. Same resolution and same null meaning as rewardCta. */
|
|
2427
|
+
rewardDecline?: string | null;
|
|
2428
|
+
/** @description Badge on the highlighted offer card, e.g. 'Most claimed'. Same resolution and same null meaning as rewardCta. */
|
|
2429
|
+
rewardBadge?: string | null;
|
|
2387
2430
|
};
|
|
2388
2431
|
/** @description Appearance values */
|
|
2389
2432
|
appearance: {
|
|
@@ -2452,6 +2495,12 @@ export interface paths {
|
|
|
2452
2495
|
rewardHeadline?: string | null;
|
|
2453
2496
|
/** @description Subheadline for the reward template. NON-NULL whenever ui.useCase is 'post-action-reward', for the same reason as rewardHeadline — the template references ${rewardSubheadline} unconditionally. Resolution: app_use_cases.subheadline, else the shipped default. */
|
|
2454
2497
|
rewardSubheadline?: string | null;
|
|
2498
|
+
/** @description Primary button label for the reward template. Resolution: the variant's own defaultCopy.cta. Null when the variant declares none, in which case its template carries a literal instead. An SDK that predates this field receives the wording inlined in the template, not a token. */
|
|
2499
|
+
rewardCta?: string | null;
|
|
2500
|
+
/** @description Decline button label for the reward template. Same resolution and same null meaning as rewardCta. */
|
|
2501
|
+
rewardDecline?: string | null;
|
|
2502
|
+
/** @description Badge on the highlighted offer card, e.g. 'Most claimed'. Same resolution and same null meaning as rewardCta. */
|
|
2503
|
+
rewardBadge?: string | null;
|
|
2455
2504
|
};
|
|
2456
2505
|
/** @description Appearance values */
|
|
2457
2506
|
appearance: {
|
|
@@ -2518,6 +2567,12 @@ export interface paths {
|
|
|
2518
2567
|
rewardHeadline?: string | null;
|
|
2519
2568
|
/** @description Subheadline for the reward template. NON-NULL whenever ui.useCase is 'post-action-reward', for the same reason as rewardHeadline — the template references ${rewardSubheadline} unconditionally. Resolution: app_use_cases.subheadline, else the shipped default. */
|
|
2520
2569
|
rewardSubheadline?: string | null;
|
|
2570
|
+
/** @description Primary button label for the reward template. Resolution: the variant's own defaultCopy.cta. Null when the variant declares none, in which case its template carries a literal instead. An SDK that predates this field receives the wording inlined in the template, not a token. */
|
|
2571
|
+
rewardCta?: string | null;
|
|
2572
|
+
/** @description Decline button label for the reward template. Same resolution and same null meaning as rewardCta. */
|
|
2573
|
+
rewardDecline?: string | null;
|
|
2574
|
+
/** @description Badge on the highlighted offer card, e.g. 'Most claimed'. Same resolution and same null meaning as rewardCta. */
|
|
2575
|
+
rewardBadge?: string | null;
|
|
2521
2576
|
};
|
|
2522
2577
|
/** @description Appearance values */
|
|
2523
2578
|
appearance: {
|
|
@@ -4082,7 +4137,7 @@ export interface paths {
|
|
|
4082
4137
|
* @description Campaign payout model (CPA / CPC / CPI / CPM).
|
|
4083
4138
|
* @enum {string}
|
|
4084
4139
|
*/
|
|
4085
|
-
model: "CPA" | "CPC" | "CPI" | "CPM";
|
|
4140
|
+
model: "CPA" | "CPC" | "CPI" | "CPL" | "CPM";
|
|
4086
4141
|
};
|
|
4087
4142
|
/** @description The campaign's categories (for offer-wall filter tabs). Empty when the campaign has none. */
|
|
4088
4143
|
categories: {
|
|
@@ -4438,6 +4493,12 @@ export interface components {
|
|
|
4438
4493
|
rewardHeadline?: string | null;
|
|
4439
4494
|
/** @description Subheadline for the reward template. NON-NULL whenever ui.useCase is 'post-action-reward', for the same reason as rewardHeadline — the template references ${rewardSubheadline} unconditionally. Resolution: app_use_cases.subheadline, else the shipped default. */
|
|
4440
4495
|
rewardSubheadline?: string | null;
|
|
4496
|
+
/** @description Primary button label for the reward template. Resolution: the variant's own defaultCopy.cta. Null when the variant declares none, in which case its template carries a literal instead. An SDK that predates this field receives the wording inlined in the template, not a token. */
|
|
4497
|
+
rewardCta?: string | null;
|
|
4498
|
+
/** @description Decline button label for the reward template. Same resolution and same null meaning as rewardCta. */
|
|
4499
|
+
rewardDecline?: string | null;
|
|
4500
|
+
/** @description Badge on the highlighted offer card, e.g. 'Most claimed'. Same resolution and same null meaning as rewardCta. */
|
|
4501
|
+
rewardBadge?: string | null;
|
|
4441
4502
|
};
|
|
4442
4503
|
/** @description Appearance values */
|
|
4443
4504
|
appearance: {
|
|
@@ -4506,6 +4567,12 @@ export interface components {
|
|
|
4506
4567
|
rewardHeadline?: string | null;
|
|
4507
4568
|
/** @description Subheadline for the reward template. NON-NULL whenever ui.useCase is 'post-action-reward', for the same reason as rewardHeadline — the template references ${rewardSubheadline} unconditionally. Resolution: app_use_cases.subheadline, else the shipped default. */
|
|
4508
4569
|
rewardSubheadline?: string | null;
|
|
4570
|
+
/** @description Primary button label for the reward template. Resolution: the variant's own defaultCopy.cta. Null when the variant declares none, in which case its template carries a literal instead. An SDK that predates this field receives the wording inlined in the template, not a token. */
|
|
4571
|
+
rewardCta?: string | null;
|
|
4572
|
+
/** @description Decline button label for the reward template. Same resolution and same null meaning as rewardCta. */
|
|
4573
|
+
rewardDecline?: string | null;
|
|
4574
|
+
/** @description Badge on the highlighted offer card, e.g. 'Most claimed'. Same resolution and same null meaning as rewardCta. */
|
|
4575
|
+
rewardBadge?: string | null;
|
|
4509
4576
|
};
|
|
4510
4577
|
/** @description Appearance values */
|
|
4511
4578
|
appearance: {
|
|
@@ -4572,6 +4639,12 @@ export interface components {
|
|
|
4572
4639
|
rewardHeadline?: string | null;
|
|
4573
4640
|
/** @description Subheadline for the reward template. NON-NULL whenever ui.useCase is 'post-action-reward', for the same reason as rewardHeadline — the template references ${rewardSubheadline} unconditionally. Resolution: app_use_cases.subheadline, else the shipped default. */
|
|
4574
4641
|
rewardSubheadline?: string | null;
|
|
4642
|
+
/** @description Primary button label for the reward template. Resolution: the variant's own defaultCopy.cta. Null when the variant declares none, in which case its template carries a literal instead. An SDK that predates this field receives the wording inlined in the template, not a token. */
|
|
4643
|
+
rewardCta?: string | null;
|
|
4644
|
+
/** @description Decline button label for the reward template. Same resolution and same null meaning as rewardCta. */
|
|
4645
|
+
rewardDecline?: string | null;
|
|
4646
|
+
/** @description Badge on the highlighted offer card, e.g. 'Most claimed'. Same resolution and same null meaning as rewardCta. */
|
|
4647
|
+
rewardBadge?: string | null;
|
|
4575
4648
|
};
|
|
4576
4649
|
/** @description Appearance values */
|
|
4577
4650
|
appearance: {
|
|
@@ -4642,7 +4715,7 @@ export interface components {
|
|
|
4642
4715
|
organizationId: string;
|
|
4643
4716
|
name: string;
|
|
4644
4717
|
/** @enum {string} */
|
|
4645
|
-
payoutModel: "CPA" | "CPC" | "CPI" | "CPM";
|
|
4718
|
+
payoutModel: "CPA" | "CPC" | "CPI" | "CPL" | "CPM";
|
|
4646
4719
|
payoutAmount: number;
|
|
4647
4720
|
/** @description Attribution platform (e.g., rakuten, impact, tune) */
|
|
4648
4721
|
attributionPlatform: string | null;
|
|
@@ -4808,10 +4881,17 @@ export interface components {
|
|
|
4808
4881
|
/** Format: date-time */
|
|
4809
4882
|
updatedAt: string;
|
|
4810
4883
|
}[];
|
|
4884
|
+
/** @description Opaque link a user can send to someone else for this campaign. A claim made through it attributes back to the user who shared it. MUST be absolute and http or https: both SDKs drop anything else while parsing, so a scheme-less or relative value reads as absent and no share control is drawn. ABSENT until share links ship, and a client that finds it absent must share nothing rather than falling back to another URL: an unattributed link loses the claim the share exists to carry. /offers/search only. Deliberately a plain string, not `format: uri`: that format makes the Kotlin generator emit java.net.URI, and a link its parser rejects would fail the WHOLE offers decode on Android rather than just the share button. */
|
|
4885
|
+
shareUrl?: string | null;
|
|
4811
4886
|
/** @description Display name of the campaign category, e.g. "Music and Audio". Free string: the taxonomy is admin-editable, so accept any value. */
|
|
4812
4887
|
category?: string | null;
|
|
4813
4888
|
/** @description The gift-sheet group this campaign files under: "Watch & listen", "Money" or "Everyday". Derived from `category` by the server so a native chip strip shows what web tabs show without holding the taxonomy map. Always set: an absent, blank or unmapped category files under "Everyday", so every offer sits in some group. Whether a strip is worth drawing is the client's call, because only it knows which offers its sheet lists. /offers/search only: web-sdk holds its own copy of the map and groups `category` itself. */
|
|
4814
4889
|
categoryGroup?: string | null;
|
|
4890
|
+
/** @description Estimated time from the user tapping this offer to the reward being confirmed, from recent real conversions (on demo offers, from the demo advertiser's configured behavior instead). Half confirm within medianSeconds, 9 in 10 within p90Seconds. Not a guarantee: to show a wait, use p90Seconds. Null when there is no current estimate (too few recent conversions, data more than 7 days old, or an offer that does not confirm through the advertiser); say nothing about timing then. */
|
|
4891
|
+
rewardConfirmationTime?: {
|
|
4892
|
+
medianSeconds: number;
|
|
4893
|
+
p90Seconds: number;
|
|
4894
|
+
} | null;
|
|
4815
4895
|
}[];
|
|
4816
4896
|
metadata: {
|
|
4817
4897
|
/** @description Total offers available */
|
|
@@ -4838,7 +4918,7 @@ export interface components {
|
|
|
4838
4918
|
organizationId: string;
|
|
4839
4919
|
name: string;
|
|
4840
4920
|
/** @enum {string} */
|
|
4841
|
-
payoutModel: "CPA" | "CPC" | "CPI" | "CPM";
|
|
4921
|
+
payoutModel: "CPA" | "CPC" | "CPI" | "CPL" | "CPM";
|
|
4842
4922
|
payoutAmount: number;
|
|
4843
4923
|
/** @description Attribution platform (e.g., rakuten, impact, tune) */
|
|
4844
4924
|
attributionPlatform: string | null;
|
|
@@ -5004,10 +5084,17 @@ export interface components {
|
|
|
5004
5084
|
/** Format: date-time */
|
|
5005
5085
|
updatedAt: string;
|
|
5006
5086
|
}[];
|
|
5087
|
+
/** @description Opaque link a user can send to someone else for this campaign. A claim made through it attributes back to the user who shared it. MUST be absolute and http or https: both SDKs drop anything else while parsing, so a scheme-less or relative value reads as absent and no share control is drawn. ABSENT until share links ship, and a client that finds it absent must share nothing rather than falling back to another URL: an unattributed link loses the claim the share exists to carry. /offers/search only. Deliberately a plain string, not `format: uri`: that format makes the Kotlin generator emit java.net.URI, and a link its parser rejects would fail the WHOLE offers decode on Android rather than just the share button. */
|
|
5088
|
+
shareUrl?: string | null;
|
|
5007
5089
|
/** @description Display name of the campaign category, e.g. "Music and Audio". Free string: the taxonomy is admin-editable, so accept any value. */
|
|
5008
5090
|
category?: string | null;
|
|
5009
5091
|
/** @description The gift-sheet group this campaign files under: "Watch & listen", "Money" or "Everyday". Derived from `category` by the server so a native chip strip shows what web tabs show without holding the taxonomy map. Always set: an absent, blank or unmapped category files under "Everyday", so every offer sits in some group. Whether a strip is worth drawing is the client's call, because only it knows which offers its sheet lists. /offers/search only: web-sdk holds its own copy of the map and groups `category` itself. */
|
|
5010
5092
|
categoryGroup?: string | null;
|
|
5093
|
+
/** @description Estimated time from the user tapping this offer to the reward being confirmed, from recent real conversions (on demo offers, from the demo advertiser's configured behavior instead). Half confirm within medianSeconds, 9 in 10 within p90Seconds. Not a guarantee: to show a wait, use p90Seconds. Null when there is no current estimate (too few recent conversions, data more than 7 days old, or an offer that does not confirm through the advertiser); say nothing about timing then. */
|
|
5094
|
+
rewardConfirmationTime?: {
|
|
5095
|
+
medianSeconds: number;
|
|
5096
|
+
p90Seconds: number;
|
|
5097
|
+
} | null;
|
|
5011
5098
|
};
|
|
5012
5099
|
Creative: {
|
|
5013
5100
|
/** Format: uuid */
|