@tinkerlandai/longplay-sdk 0.0.0-stage → 0.10.4
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/CHANGELOG.md +209 -0
- package/README.md +485 -2
- package/README.zh-CN.md +375 -0
- package/THIRD_PARTY_NOTICES.md +101 -0
- package/dist/ai-usage-Btwg1nD7.d.ts +247 -0
- package/dist/api-5gAz4-Sb.d.ts +16897 -0
- package/dist/chunk-2HFA34QO.js +6 -0
- package/dist/chunk-7DXL3LHT.js +1 -0
- package/dist/chunk-ACF2FBUB.js +1 -0
- package/dist/chunk-CLXORAOK.js +1 -0
- package/dist/chunk-DSPLGTQI.js +1 -0
- package/dist/chunk-EARSGITJ.js +1 -0
- package/dist/chunk-G56XGVMS.js +1 -0
- package/dist/chunk-HOW7NIIR.js +1 -0
- package/dist/chunk-JB46ZKGZ.js +1 -0
- package/dist/chunk-KBM7BYQY.js +1 -0
- package/dist/chunk-MRN4HP4W.js +1 -0
- package/dist/chunk-RE6BIFLN.js +2 -0
- package/dist/chunk-SBPTOOYB.js +1 -0
- package/dist/chunk-SSLZKIIU.js +1 -0
- package/dist/chunk-VMM3GA3L.js +4 -0
- package/dist/chunk-VOEFXEPP.js +1 -0
- package/dist/chunk-X6BCUINI.js +173 -0
- package/dist/chunk-XSVQHPQT.js +17 -0
- package/dist/chunk-YQHPEP4X.js +1 -0
- package/dist/chunk-ZPZVSC4J.js +1 -0
- package/dist/configuration-sync-CywDxRkX.d.ts +1698 -0
- package/dist/content-NYMIZRNR.js +1 -0
- package/dist/coupon-fA1QujHt.d.ts +184 -0
- package/dist/customer-page-km5f1PJZ.d.ts +480 -0
- package/dist/funnel-local-client-CVokI0rx.d.ts +46997 -0
- package/dist/funnel-node-evaluation-P5B4fPfJ.d.ts +2054 -0
- package/dist/funnel-resource-client-Cv5OjfAn.d.ts +14525 -0
- package/dist/funnel-runtime-host-UL4DEJDU.js +1 -0
- package/dist/growth-rules-B4YYy64R.d.ts +173 -0
- package/dist/index.d.ts +23545 -0
- package/dist/index.js +1 -0
- package/dist/native-shell.d.ts +4 -0
- package/dist/native-shell.js +1 -0
- package/dist/openrouter.d.ts +43 -0
- package/dist/openrouter.js +1 -0
- package/dist/page.d.ts +134 -0
- package/dist/page.js +1 -0
- package/dist/paywall-EJCNWDHK.js +1 -0
- package/dist/popup.d.ts +191 -0
- package/dist/popup.js +1 -0
- package/dist/react-native.d.ts +36701 -0
- package/dist/react-native.js +1 -0
- package/dist/screen-D81zCpfi.d.ts +3000 -0
- package/dist/screen-renderer-JMHV4GPP.js +1 -0
- package/dist/server.d.ts +7073 -0
- package/dist/server.js +1 -0
- package/dist/visual-dom-DQLPBZ2Z.js +1 -0
- package/dist/visual.d.ts +87 -0
- package/dist/visual.js +1 -0
- package/package.json +90 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{f as _,j as F}from"./chunk-X6BCUINI.js";import{b as q}from"./chunk-SSLZKIIU.js";import{L as U}from"./chunk-2HFA34QO.js";import{Y as P,ca as M,ja as z,ka as N,qa as d}from"./chunk-ACF2FBUB.js";import{a as v}from"./chunk-DSPLGTQI.js";import"./chunk-G56XGVMS.js";import"./chunk-MRN4HP4W.js";import{a as O}from"./chunk-7DXL3LHT.js";import"./chunk-XSVQHPQT.js";import{z as p}from"zod";var V=new WeakMap;function Q(r){let t={string:p.string(),number:p.number().finite(),boolean:p.boolean(),strings:p.array(p.string()),json:O}[r.type];return r.nullable?t.nullable():t}async function ne(r,t){return W(r,t,!1)}async function re(r,t){return W(r,t,!0)}async function W(r,t,w){t.signal?.throwIfAborted();let T=U.parse(t.content),o=T.document;if(V.has(r))throw new d("CONFLICT","Content is already mounted in this container");let f=p.record(p.string(),O).parse(t.inputs??{});if(Object.keys(f).length>40)throw new d("INVALID_REQUEST","Too many content inputs");for(let[e,s]of Object.entries(f))z.parse({[e]:s});if(Object.keys(f).some(e=>!Object.hasOwn(o.contract.inputs,e)))throw new d("INVALID_REQUEST","Undeclared content input");for(let[e,s]of Object.entries(o.contract.inputs))if(Object.hasOwn(f,e))Q(s).parse(f[e]);else if(s.required)throw new d("INVALID_REQUEST",`Missing content input ${e}`);for(let e of Object.keys(o.contract.outputs))if(typeof t.actions[e]!="function")throw new d("INVALID_REQUEST",`Missing host handler for ${e}`);let $=N.parse(t.bindings??[]),a=r.ownerDocument,L,k=o.kind==="popup",n=k?a.createElement("dialog"):null,i=a.createElement("div");if(i.dataset.indianaContent=o.kind,i.setAttribute("aria-label",o.name),i.style.cssText="width:100%;min-width:0",n){n.setAttribute("aria-label",o.name);let e=o.screen.presentation;n.style.cssText="box-sizing:border-box;padding:0;border:0;max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);overflow:auto",e.type==="modal"||e.type==="sheet"?(n.style.width=`${P[e.size]}px`,e.type==="sheet"&&(n.style.margin="auto auto 0")):n.style.width="100vw",n.append(i),r.append(n)}else r.append(i);let c=!1,C=!1,g=!1;w&&!n&&(i.style.width=`${r.getBoundingClientRect().width||a.defaultView?.innerWidth||800}px`);let B=w?_(n??i):()=>{},H,x,A=new Promise((e,s)=>{H=e,x=s});A.catch(()=>{});let l=null,E=structuredClone(o.screen);E.actions=E.actions.map(e=>e.type==="event"?{...e,close:!1}:e);let b;function m(){c||(c=!0,t.signal?.removeEventListener("abort",m),x(new Error("Content preparation cancelled")),b?.destroy(),n?.close(),n?.remove(),i.remove(),V.delete(r),n&&L?.())}let S=()=>{g&&(m(),v(t.onDismiss))};if(n){let e=a.createElement("button");e.type="button",e.textContent="\xD7",e.setAttribute("aria-label",t.locale?.startsWith("zh")?"\u5173\u95ED":"Close"),e.style.cssText="position:absolute;right:8px;top:8px;width:30px;height:30px;z-index:1",e.addEventListener("click",S),n.prepend(e)}n?.addEventListener("cancel",e=>{e.preventDefault(),S()});async function D(){if(c||!g||C||!l)return;let e=l;C=!0,i.setAttribute("aria-busy","true");try{await t.actions[e.actionId](structuredClone(e)),l=null}catch(s){v(t.onError,s)}finally{C=!1,c||i.removeAttribute("aria-busy")}}function R(){if(c)throw new d("CONFLICT","Content host has been destroyed");g||(L=q(a),B(),w&&!n&&(i.style.width="100%"),n?.showModal(),g=!0)}try{w||R(),b=F(i,{mode:"live",title:o.name,viewportHeight:o.kind==="page"?r.clientHeight||a.defaultView?.innerHeight||800:void 0,onRendered:H,onError:u=>{let I=new Error(u);x(I),v(t.onError,I)},onEscape:k?S:void 0,onAction:(u,I,J)=>{if(c||!g||C||l)return;let h=o.screen.actions.find(y=>y.id===u),j=o.contract.outputs[u];if(!(h?.type!=="event"||!j))try{let y=Q(j).parse(Object.hasOwn(h.properties,"value")?h.properties.value:h.properties);l={requestId:crypto.randomUUID(),contentVersionId:T.id,actionId:u,event:h.event,value:y,selection:I??{},answers:J??{},requestedClose:h.close},D()}catch(y){v(t.onError,y)}}});let e={destroy:m,show:R,get pendingAction(){return l?structuredClone(l):null},retryAction:D,updateCapabilities:u=>b?.updateCapabilities(u)};V.set(r,e),t.signal?.addEventListener("abort",m,{once:!0}),t.signal?.aborted&&(m(),t.signal.throwIfAborted());let s=M(E,[t.locale,...a.defaultView?.navigator.languages??[]]);if(b.update(E,s,{capabilities:t.capabilities,serverInput:{bindings:$,answers:{},values:f}}),await Promise.race([b.ready,A]),w&&await A,c)throw new Error("Content preparation cancelled");return e}catch(e){throw m(),e}}export{ne as mountContent,re as prepareContent};
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
declare const couponInputSchema: z.ZodObject<{
|
|
4
|
+
name: z.ZodString;
|
|
5
|
+
description: z.ZodString;
|
|
6
|
+
discount: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
7
|
+
type: z.ZodLiteral<"percent">;
|
|
8
|
+
percentOff: z.ZodNumber;
|
|
9
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
10
|
+
type: z.ZodLiteral<"amount">;
|
|
11
|
+
amountOffCents: z.ZodNumber;
|
|
12
|
+
currency: z.ZodEnum<{
|
|
13
|
+
USD: "USD";
|
|
14
|
+
EUR: "EUR";
|
|
15
|
+
CNY: "CNY";
|
|
16
|
+
GBP: "GBP";
|
|
17
|
+
JPY: "JPY";
|
|
18
|
+
CAD: "CAD";
|
|
19
|
+
AUD: "AUD";
|
|
20
|
+
NZD: "NZD";
|
|
21
|
+
CHF: "CHF";
|
|
22
|
+
HKD: "HKD";
|
|
23
|
+
SGD: "SGD";
|
|
24
|
+
KRW: "KRW";
|
|
25
|
+
INR: "INR";
|
|
26
|
+
BRL: "BRL";
|
|
27
|
+
MXN: "MXN";
|
|
28
|
+
TWD: "TWD";
|
|
29
|
+
THB: "THB";
|
|
30
|
+
IDR: "IDR";
|
|
31
|
+
MYR: "MYR";
|
|
32
|
+
PHP: "PHP";
|
|
33
|
+
VND: "VND";
|
|
34
|
+
ZAR: "ZAR";
|
|
35
|
+
AED: "AED";
|
|
36
|
+
SAR: "SAR";
|
|
37
|
+
SEK: "SEK";
|
|
38
|
+
NOK: "NOK";
|
|
39
|
+
DKK: "DKK";
|
|
40
|
+
PLN: "PLN";
|
|
41
|
+
CZK: "CZK";
|
|
42
|
+
HUF: "HUF";
|
|
43
|
+
ILS: "ILS";
|
|
44
|
+
TRY: "TRY";
|
|
45
|
+
RON: "RON";
|
|
46
|
+
}>;
|
|
47
|
+
}, z.core.$strict>], "type">;
|
|
48
|
+
duration: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
49
|
+
type: z.ZodLiteral<"once">;
|
|
50
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
51
|
+
type: z.ZodLiteral<"repeating">;
|
|
52
|
+
months: z.ZodNumber;
|
|
53
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
54
|
+
type: z.ZodLiteral<"forever">;
|
|
55
|
+
}, z.core.$strict>], "type">;
|
|
56
|
+
appliesTo: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
57
|
+
type: z.ZodLiteral<"all">;
|
|
58
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
59
|
+
type: z.ZodLiteral<"plans">;
|
|
60
|
+
planIds: z.ZodArray<z.ZodUUID>;
|
|
61
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
62
|
+
type: z.ZodLiteral<"merchandise">;
|
|
63
|
+
scope: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
64
|
+
type: z.ZodLiteral<"all">;
|
|
65
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
66
|
+
type: z.ZodLiteral<"selected">;
|
|
67
|
+
merchandiseIds: z.ZodArray<z.ZodUUID>;
|
|
68
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
69
|
+
type: z.ZodLiteral<"condition">;
|
|
70
|
+
condition: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
|
|
71
|
+
}, z.core.$strict>], "type">;
|
|
72
|
+
}, z.core.$strict>], "type">;
|
|
73
|
+
eligibility: z.ZodObject<{
|
|
74
|
+
firstPurchaseOnly: z.ZodBoolean;
|
|
75
|
+
condition: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
|
|
76
|
+
}, z.core.$strict>;
|
|
77
|
+
selfClaimEnabled: z.ZodDefault<z.ZodBoolean>;
|
|
78
|
+
startsAt: z.ZodNullable<z.ZodISODateTime>;
|
|
79
|
+
endsAt: z.ZodNullable<z.ZodISODateTime>;
|
|
80
|
+
totalLimit: z.ZodNullable<z.ZodNumber>;
|
|
81
|
+
perCustomerLimit: z.ZodNumber;
|
|
82
|
+
grantWindowHours: z.ZodNumber;
|
|
83
|
+
}, z.core.$strict>;
|
|
84
|
+
type CouponInput = z.infer<typeof couponInputSchema>;
|
|
85
|
+
/**
|
|
86
|
+
* 客户领到的优惠(SDK 返回)。id 用作 previewAttach 的 offerId;报价冻结优惠与逐套餐分配,attach 仅接受 operationId。
|
|
87
|
+
* 支付金额由原生渠道验证后入账。appliesTo.planIds 对应商品根 ID。
|
|
88
|
+
*/
|
|
89
|
+
declare const offerSchema: z.ZodObject<{
|
|
90
|
+
id: z.ZodUUID;
|
|
91
|
+
couponId: z.ZodUUID;
|
|
92
|
+
status: z.ZodEnum<{
|
|
93
|
+
expired: "expired";
|
|
94
|
+
issued: "issued";
|
|
95
|
+
reserved: "reserved";
|
|
96
|
+
redeemed: "redeemed";
|
|
97
|
+
revoked: "revoked";
|
|
98
|
+
}>;
|
|
99
|
+
issuedAt: z.ZodISODateTime;
|
|
100
|
+
expiresAt: z.ZodISODateTime;
|
|
101
|
+
coupon: z.ZodObject<{
|
|
102
|
+
name: z.ZodString;
|
|
103
|
+
discount: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
104
|
+
type: z.ZodLiteral<"percent">;
|
|
105
|
+
percentOff: z.ZodNumber;
|
|
106
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
107
|
+
type: z.ZodLiteral<"amount">;
|
|
108
|
+
amountOffCents: z.ZodNumber;
|
|
109
|
+
currency: z.ZodEnum<{
|
|
110
|
+
USD: "USD";
|
|
111
|
+
EUR: "EUR";
|
|
112
|
+
CNY: "CNY";
|
|
113
|
+
GBP: "GBP";
|
|
114
|
+
JPY: "JPY";
|
|
115
|
+
CAD: "CAD";
|
|
116
|
+
AUD: "AUD";
|
|
117
|
+
NZD: "NZD";
|
|
118
|
+
CHF: "CHF";
|
|
119
|
+
HKD: "HKD";
|
|
120
|
+
SGD: "SGD";
|
|
121
|
+
KRW: "KRW";
|
|
122
|
+
INR: "INR";
|
|
123
|
+
BRL: "BRL";
|
|
124
|
+
MXN: "MXN";
|
|
125
|
+
TWD: "TWD";
|
|
126
|
+
THB: "THB";
|
|
127
|
+
IDR: "IDR";
|
|
128
|
+
MYR: "MYR";
|
|
129
|
+
PHP: "PHP";
|
|
130
|
+
VND: "VND";
|
|
131
|
+
ZAR: "ZAR";
|
|
132
|
+
AED: "AED";
|
|
133
|
+
SAR: "SAR";
|
|
134
|
+
SEK: "SEK";
|
|
135
|
+
NOK: "NOK";
|
|
136
|
+
DKK: "DKK";
|
|
137
|
+
PLN: "PLN";
|
|
138
|
+
CZK: "CZK";
|
|
139
|
+
HUF: "HUF";
|
|
140
|
+
ILS: "ILS";
|
|
141
|
+
TRY: "TRY";
|
|
142
|
+
RON: "RON";
|
|
143
|
+
}>;
|
|
144
|
+
}, z.core.$strict>], "type">;
|
|
145
|
+
duration: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
146
|
+
type: z.ZodLiteral<"once">;
|
|
147
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
148
|
+
type: z.ZodLiteral<"repeating">;
|
|
149
|
+
months: z.ZodNumber;
|
|
150
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
151
|
+
type: z.ZodLiteral<"forever">;
|
|
152
|
+
}, z.core.$strict>], "type">;
|
|
153
|
+
appliesTo: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
154
|
+
type: z.ZodLiteral<"all">;
|
|
155
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
156
|
+
type: z.ZodLiteral<"plans">;
|
|
157
|
+
planIds: z.ZodArray<z.ZodUUID>;
|
|
158
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
159
|
+
type: z.ZodLiteral<"merchandise">;
|
|
160
|
+
scope: z.ZodObject<{
|
|
161
|
+
type: z.ZodEnum<{
|
|
162
|
+
selected: "selected";
|
|
163
|
+
all: "all";
|
|
164
|
+
condition: "condition";
|
|
165
|
+
}>;
|
|
166
|
+
}, z.core.$strict>;
|
|
167
|
+
}, z.core.$strict>], "type">;
|
|
168
|
+
}, z.core.$strict>;
|
|
169
|
+
}, z.core.$strict>;
|
|
170
|
+
type Offer = z.infer<typeof offerSchema>;
|
|
171
|
+
/** 领取失败的原因:未生效 / 不在有效期 / 不符合标签 / 不是首购 / 已达每人上限 / 已领完。 */
|
|
172
|
+
declare const offerUnavailableReasonSchema: z.ZodEnum<{
|
|
173
|
+
unavailable: "unavailable";
|
|
174
|
+
inactive: "inactive";
|
|
175
|
+
claim_disabled: "claim_disabled";
|
|
176
|
+
outside_window: "outside_window";
|
|
177
|
+
not_targeted: "not_targeted";
|
|
178
|
+
not_first_purchase: "not_first_purchase";
|
|
179
|
+
limit_reached: "limit_reached";
|
|
180
|
+
sold_out: "sold_out";
|
|
181
|
+
}>;
|
|
182
|
+
type OfferUnavailableReason = z.infer<typeof offerUnavailableReasonSchema>;
|
|
183
|
+
|
|
184
|
+
export type { CouponInput as C, Offer as O, OfferUnavailableReason as a };
|
|
@@ -0,0 +1,480 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
declare const surfaceDataSchema: z.ZodObject<{
|
|
4
|
+
paywall: z.ZodOptional<z.ZodObject<{
|
|
5
|
+
internal_feature_id: z.ZodString;
|
|
6
|
+
name: z.ZodString;
|
|
7
|
+
kind: z.ZodEnum<{
|
|
8
|
+
access: "access";
|
|
9
|
+
metered: "metered";
|
|
10
|
+
credit: "credit";
|
|
11
|
+
}>;
|
|
12
|
+
quantity: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
13
|
+
allowed: z.ZodBoolean;
|
|
14
|
+
reason: z.ZodNullable<z.ZodEnum<{
|
|
15
|
+
not_entitled: "not_entitled";
|
|
16
|
+
insufficient_balance: "insufficient_balance";
|
|
17
|
+
capacity_exceeded: "capacity_exceeded";
|
|
18
|
+
limit_exceeded: "limit_exceeded";
|
|
19
|
+
awaiting_topup: "awaiting_topup";
|
|
20
|
+
authorization_required: "authorization_required";
|
|
21
|
+
payment_blocked: "payment_blocked";
|
|
22
|
+
cash_budget_exceeded: "cash_budget_exceeded";
|
|
23
|
+
unavailable: "unavailable";
|
|
24
|
+
authentication_required: "authentication_required";
|
|
25
|
+
}>>;
|
|
26
|
+
preview: z.ZodNullable<z.ZodObject<{
|
|
27
|
+
scenario: z.ZodEnum<{
|
|
28
|
+
feature_flag: "feature_flag";
|
|
29
|
+
usage_limit: "usage_limit";
|
|
30
|
+
}>;
|
|
31
|
+
candidates: z.ZodArray<z.ZodObject<{
|
|
32
|
+
productId: z.ZodString;
|
|
33
|
+
productVersionId: z.ZodString;
|
|
34
|
+
name: z.ZodString;
|
|
35
|
+
action: z.ZodEnum<{
|
|
36
|
+
purchase: "purchase";
|
|
37
|
+
upgrade: "upgrade";
|
|
38
|
+
addon: "addon";
|
|
39
|
+
topup: "topup";
|
|
40
|
+
}>;
|
|
41
|
+
membershipId: z.ZodNullable<z.ZodString>;
|
|
42
|
+
currency: z.ZodEnum<{
|
|
43
|
+
USD: "USD";
|
|
44
|
+
EUR: "EUR";
|
|
45
|
+
CNY: "CNY";
|
|
46
|
+
GBP: "GBP";
|
|
47
|
+
JPY: "JPY";
|
|
48
|
+
CAD: "CAD";
|
|
49
|
+
AUD: "AUD";
|
|
50
|
+
NZD: "NZD";
|
|
51
|
+
CHF: "CHF";
|
|
52
|
+
HKD: "HKD";
|
|
53
|
+
SGD: "SGD";
|
|
54
|
+
KRW: "KRW";
|
|
55
|
+
INR: "INR";
|
|
56
|
+
BRL: "BRL";
|
|
57
|
+
MXN: "MXN";
|
|
58
|
+
TWD: "TWD";
|
|
59
|
+
THB: "THB";
|
|
60
|
+
IDR: "IDR";
|
|
61
|
+
MYR: "MYR";
|
|
62
|
+
PHP: "PHP";
|
|
63
|
+
VND: "VND";
|
|
64
|
+
ZAR: "ZAR";
|
|
65
|
+
AED: "AED";
|
|
66
|
+
SAR: "SAR";
|
|
67
|
+
SEK: "SEK";
|
|
68
|
+
NOK: "NOK";
|
|
69
|
+
DKK: "DKK";
|
|
70
|
+
PLN: "PLN";
|
|
71
|
+
CZK: "CZK";
|
|
72
|
+
HUF: "HUF";
|
|
73
|
+
ILS: "ILS";
|
|
74
|
+
TRY: "TRY";
|
|
75
|
+
RON: "RON";
|
|
76
|
+
}>;
|
|
77
|
+
amountMinor: z.ZodString;
|
|
78
|
+
interval: z.ZodEnum<{
|
|
79
|
+
free: "free";
|
|
80
|
+
week: "week";
|
|
81
|
+
month: "month";
|
|
82
|
+
year: "year";
|
|
83
|
+
one_time: "one_time";
|
|
84
|
+
}>;
|
|
85
|
+
intervalCount: z.ZodNumber;
|
|
86
|
+
}, z.core.$strict>>;
|
|
87
|
+
}, z.core.$strict>>;
|
|
88
|
+
}, z.core.$strict>>;
|
|
89
|
+
nodes: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
90
|
+
base: z.ZodObject<{
|
|
91
|
+
text: z.ZodOptional<z.ZodString>;
|
|
92
|
+
label: z.ZodOptional<z.ZodString>;
|
|
93
|
+
alt: z.ZodOptional<z.ZodString>;
|
|
94
|
+
html: z.ZodOptional<z.ZodString>;
|
|
95
|
+
price: z.ZodOptional<z.ZodObject<{
|
|
96
|
+
current: z.ZodString;
|
|
97
|
+
original: z.ZodNullable<z.ZodString>;
|
|
98
|
+
period: z.ZodString;
|
|
99
|
+
}, z.core.$strip>>;
|
|
100
|
+
code: z.ZodOptional<z.ZodString>;
|
|
101
|
+
countdownAt: z.ZodOptional<z.ZodISODateTime>;
|
|
102
|
+
planId: z.ZodOptional<z.ZodString>;
|
|
103
|
+
planVersionId: z.ZodOptional<z.ZodString>;
|
|
104
|
+
currency: z.ZodOptional<z.ZodEnum<{
|
|
105
|
+
USD: "USD";
|
|
106
|
+
EUR: "EUR";
|
|
107
|
+
CNY: "CNY";
|
|
108
|
+
GBP: "GBP";
|
|
109
|
+
JPY: "JPY";
|
|
110
|
+
CAD: "CAD";
|
|
111
|
+
AUD: "AUD";
|
|
112
|
+
NZD: "NZD";
|
|
113
|
+
CHF: "CHF";
|
|
114
|
+
HKD: "HKD";
|
|
115
|
+
SGD: "SGD";
|
|
116
|
+
KRW: "KRW";
|
|
117
|
+
INR: "INR";
|
|
118
|
+
BRL: "BRL";
|
|
119
|
+
MXN: "MXN";
|
|
120
|
+
TWD: "TWD";
|
|
121
|
+
THB: "THB";
|
|
122
|
+
IDR: "IDR";
|
|
123
|
+
MYR: "MYR";
|
|
124
|
+
PHP: "PHP";
|
|
125
|
+
VND: "VND";
|
|
126
|
+
ZAR: "ZAR";
|
|
127
|
+
AED: "AED";
|
|
128
|
+
SAR: "SAR";
|
|
129
|
+
SEK: "SEK";
|
|
130
|
+
NOK: "NOK";
|
|
131
|
+
DKK: "DKK";
|
|
132
|
+
PLN: "PLN";
|
|
133
|
+
CZK: "CZK";
|
|
134
|
+
HUF: "HUF";
|
|
135
|
+
ILS: "ILS";
|
|
136
|
+
TRY: "TRY";
|
|
137
|
+
RON: "RON";
|
|
138
|
+
}>>;
|
|
139
|
+
couponId: z.ZodOptional<z.ZodUUID>;
|
|
140
|
+
offerId: z.ZodOptional<z.ZodUUID>;
|
|
141
|
+
unavailable: z.ZodOptional<z.ZodBoolean>;
|
|
142
|
+
unavailableReason: z.ZodOptional<z.ZodString>;
|
|
143
|
+
missing: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
144
|
+
}, z.core.$strict>;
|
|
145
|
+
picker: z.ZodOptional<z.ZodString>;
|
|
146
|
+
byPlan: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
147
|
+
text: z.ZodOptional<z.ZodString>;
|
|
148
|
+
label: z.ZodOptional<z.ZodString>;
|
|
149
|
+
alt: z.ZodOptional<z.ZodString>;
|
|
150
|
+
html: z.ZodOptional<z.ZodString>;
|
|
151
|
+
price: z.ZodOptional<z.ZodObject<{
|
|
152
|
+
current: z.ZodString;
|
|
153
|
+
original: z.ZodNullable<z.ZodString>;
|
|
154
|
+
period: z.ZodString;
|
|
155
|
+
}, z.core.$strip>>;
|
|
156
|
+
code: z.ZodOptional<z.ZodString>;
|
|
157
|
+
countdownAt: z.ZodOptional<z.ZodISODateTime>;
|
|
158
|
+
planId: z.ZodOptional<z.ZodString>;
|
|
159
|
+
planVersionId: z.ZodOptional<z.ZodString>;
|
|
160
|
+
currency: z.ZodOptional<z.ZodEnum<{
|
|
161
|
+
USD: "USD";
|
|
162
|
+
EUR: "EUR";
|
|
163
|
+
CNY: "CNY";
|
|
164
|
+
GBP: "GBP";
|
|
165
|
+
JPY: "JPY";
|
|
166
|
+
CAD: "CAD";
|
|
167
|
+
AUD: "AUD";
|
|
168
|
+
NZD: "NZD";
|
|
169
|
+
CHF: "CHF";
|
|
170
|
+
HKD: "HKD";
|
|
171
|
+
SGD: "SGD";
|
|
172
|
+
KRW: "KRW";
|
|
173
|
+
INR: "INR";
|
|
174
|
+
BRL: "BRL";
|
|
175
|
+
MXN: "MXN";
|
|
176
|
+
TWD: "TWD";
|
|
177
|
+
THB: "THB";
|
|
178
|
+
IDR: "IDR";
|
|
179
|
+
MYR: "MYR";
|
|
180
|
+
PHP: "PHP";
|
|
181
|
+
VND: "VND";
|
|
182
|
+
ZAR: "ZAR";
|
|
183
|
+
AED: "AED";
|
|
184
|
+
SAR: "SAR";
|
|
185
|
+
SEK: "SEK";
|
|
186
|
+
NOK: "NOK";
|
|
187
|
+
DKK: "DKK";
|
|
188
|
+
PLN: "PLN";
|
|
189
|
+
CZK: "CZK";
|
|
190
|
+
HUF: "HUF";
|
|
191
|
+
ILS: "ILS";
|
|
192
|
+
TRY: "TRY";
|
|
193
|
+
RON: "RON";
|
|
194
|
+
}>>;
|
|
195
|
+
couponId: z.ZodOptional<z.ZodUUID>;
|
|
196
|
+
offerId: z.ZodOptional<z.ZodUUID>;
|
|
197
|
+
unavailable: z.ZodOptional<z.ZodBoolean>;
|
|
198
|
+
unavailableReason: z.ZodOptional<z.ZodString>;
|
|
199
|
+
missing: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
200
|
+
}, z.core.$strict>>>;
|
|
201
|
+
}, z.core.$strict>>;
|
|
202
|
+
plans: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
203
|
+
id: z.ZodString;
|
|
204
|
+
versionId: z.ZodString;
|
|
205
|
+
available: z.ZodBoolean;
|
|
206
|
+
name: z.ZodString;
|
|
207
|
+
price: z.ZodString;
|
|
208
|
+
period: z.ZodString;
|
|
209
|
+
currency: z.ZodOptional<z.ZodEnum<{
|
|
210
|
+
USD: "USD";
|
|
211
|
+
EUR: "EUR";
|
|
212
|
+
CNY: "CNY";
|
|
213
|
+
GBP: "GBP";
|
|
214
|
+
JPY: "JPY";
|
|
215
|
+
CAD: "CAD";
|
|
216
|
+
AUD: "AUD";
|
|
217
|
+
NZD: "NZD";
|
|
218
|
+
CHF: "CHF";
|
|
219
|
+
HKD: "HKD";
|
|
220
|
+
SGD: "SGD";
|
|
221
|
+
KRW: "KRW";
|
|
222
|
+
INR: "INR";
|
|
223
|
+
BRL: "BRL";
|
|
224
|
+
MXN: "MXN";
|
|
225
|
+
TWD: "TWD";
|
|
226
|
+
THB: "THB";
|
|
227
|
+
IDR: "IDR";
|
|
228
|
+
MYR: "MYR";
|
|
229
|
+
PHP: "PHP";
|
|
230
|
+
VND: "VND";
|
|
231
|
+
ZAR: "ZAR";
|
|
232
|
+
AED: "AED";
|
|
233
|
+
SAR: "SAR";
|
|
234
|
+
SEK: "SEK";
|
|
235
|
+
NOK: "NOK";
|
|
236
|
+
DKK: "DKK";
|
|
237
|
+
PLN: "PLN";
|
|
238
|
+
CZK: "CZK";
|
|
239
|
+
HUF: "HUF";
|
|
240
|
+
ILS: "ILS";
|
|
241
|
+
TRY: "TRY";
|
|
242
|
+
RON: "RON";
|
|
243
|
+
}>>;
|
|
244
|
+
amountMinor: z.ZodOptional<z.ZodNumber>;
|
|
245
|
+
interval: z.ZodOptional<z.ZodEnum<{
|
|
246
|
+
free: "free";
|
|
247
|
+
week: "week";
|
|
248
|
+
month: "month";
|
|
249
|
+
year: "year";
|
|
250
|
+
one_time: "one_time";
|
|
251
|
+
}>>;
|
|
252
|
+
intervalCount: z.ZodOptional<z.ZodNumber>;
|
|
253
|
+
prepaid: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
254
|
+
internalFeatureId: z.ZodUUID;
|
|
255
|
+
name: z.ZodString;
|
|
256
|
+
includedAmount: z.ZodString;
|
|
257
|
+
reset: z.ZodEnum<{
|
|
258
|
+
week: "week";
|
|
259
|
+
month: "month";
|
|
260
|
+
year: "year";
|
|
261
|
+
hour: "hour";
|
|
262
|
+
day: "day";
|
|
263
|
+
lifetime: "lifetime";
|
|
264
|
+
}>;
|
|
265
|
+
resetCount: z.ZodNumber;
|
|
266
|
+
terms: z.ZodObject<{
|
|
267
|
+
units: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
268
|
+
prices: z.ZodArray<z.ZodObject<{
|
|
269
|
+
currency: z.ZodEnum<{
|
|
270
|
+
USD: "USD";
|
|
271
|
+
EUR: "EUR";
|
|
272
|
+
CNY: "CNY";
|
|
273
|
+
GBP: "GBP";
|
|
274
|
+
JPY: "JPY";
|
|
275
|
+
CAD: "CAD";
|
|
276
|
+
AUD: "AUD";
|
|
277
|
+
NZD: "NZD";
|
|
278
|
+
CHF: "CHF";
|
|
279
|
+
HKD: "HKD";
|
|
280
|
+
SGD: "SGD";
|
|
281
|
+
KRW: "KRW";
|
|
282
|
+
INR: "INR";
|
|
283
|
+
BRL: "BRL";
|
|
284
|
+
MXN: "MXN";
|
|
285
|
+
TWD: "TWD";
|
|
286
|
+
THB: "THB";
|
|
287
|
+
IDR: "IDR";
|
|
288
|
+
MYR: "MYR";
|
|
289
|
+
PHP: "PHP";
|
|
290
|
+
VND: "VND";
|
|
291
|
+
ZAR: "ZAR";
|
|
292
|
+
AED: "AED";
|
|
293
|
+
SAR: "SAR";
|
|
294
|
+
SEK: "SEK";
|
|
295
|
+
NOK: "NOK";
|
|
296
|
+
DKK: "DKK";
|
|
297
|
+
PLN: "PLN";
|
|
298
|
+
CZK: "CZK";
|
|
299
|
+
HUF: "HUF";
|
|
300
|
+
ILS: "ILS";
|
|
301
|
+
TRY: "TRY";
|
|
302
|
+
RON: "RON";
|
|
303
|
+
}>;
|
|
304
|
+
amountMinor: z.ZodNumber;
|
|
305
|
+
pricing: z.ZodOptional<z.ZodObject<{
|
|
306
|
+
kind: z.ZodEnum<{
|
|
307
|
+
graduated: "graduated";
|
|
308
|
+
volume: "volume";
|
|
309
|
+
}>;
|
|
310
|
+
tiers: z.ZodArray<z.ZodObject<{
|
|
311
|
+
upTo: z.ZodNullable<z.ZodNumber>;
|
|
312
|
+
unitAmountMinor: z.ZodNumber;
|
|
313
|
+
flatAmountMinor: z.ZodOptional<z.ZodNumber>;
|
|
314
|
+
}, z.core.$strict>>;
|
|
315
|
+
}, z.core.$strict>>;
|
|
316
|
+
}, z.core.$strict>>;
|
|
317
|
+
minimumQuantity: z.ZodNumber;
|
|
318
|
+
maximumQuantity: z.ZodNumber;
|
|
319
|
+
}, z.core.$strict>;
|
|
320
|
+
}, z.core.$strict>>>;
|
|
321
|
+
}, z.core.$strict>>;
|
|
322
|
+
pickers: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
323
|
+
options: z.ZodArray<z.ZodString>;
|
|
324
|
+
selected: z.ZodNullable<z.ZodString>;
|
|
325
|
+
}, z.core.$strict>>;
|
|
326
|
+
quantities: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
327
|
+
minimum: z.ZodNumber;
|
|
328
|
+
maximum: z.ZodNumber;
|
|
329
|
+
step: z.ZodNumber;
|
|
330
|
+
value: z.ZodNumber;
|
|
331
|
+
label: z.ZodString;
|
|
332
|
+
available: z.ZodBoolean;
|
|
333
|
+
}, z.core.$strict>>>;
|
|
334
|
+
diagnostics: z.ZodArray<z.ZodObject<{
|
|
335
|
+
nodeId: z.ZodString;
|
|
336
|
+
message: z.ZodString;
|
|
337
|
+
}, z.core.$strict>>;
|
|
338
|
+
}, z.core.$strict>;
|
|
339
|
+
type SurfaceData = z.infer<typeof surfaceDataSchema>;
|
|
340
|
+
|
|
341
|
+
declare const screenAnswersSchema: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodBoolean, z.ZodArray<z.ZodString>]>>;
|
|
342
|
+
declare const screenParametersSchema: z.ZodRecord<z.ZodString, z.ZodJSONSchema>;
|
|
343
|
+
type ScreenParameters = z.infer<typeof screenParametersSchema>;
|
|
344
|
+
type ScreenAnswers = z.infer<typeof screenAnswersSchema>;
|
|
345
|
+
declare const screenInputBindingsSchema: z.ZodArray<z.ZodObject<{
|
|
346
|
+
variable: z.ZodString;
|
|
347
|
+
componentId: z.ZodString;
|
|
348
|
+
required: z.ZodBoolean;
|
|
349
|
+
}, z.core.$strict>>;
|
|
350
|
+
declare const screenRendererInputSchema: z.ZodObject<{
|
|
351
|
+
bindings: z.ZodArray<z.ZodObject<{
|
|
352
|
+
variable: z.ZodString;
|
|
353
|
+
componentId: z.ZodString;
|
|
354
|
+
required: z.ZodBoolean;
|
|
355
|
+
}, z.core.$strict>>;
|
|
356
|
+
answers: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodBoolean, z.ZodArray<z.ZodString>]>>;
|
|
357
|
+
values: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodJSONSchema>>;
|
|
358
|
+
}, z.core.$strict>;
|
|
359
|
+
type ScreenRendererInput = z.infer<typeof screenRendererInputSchema>;
|
|
360
|
+
|
|
361
|
+
declare const customerPageDataSchema: z.ZodObject<{
|
|
362
|
+
nodes: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
363
|
+
source: z.ZodEnum<{
|
|
364
|
+
membership: "membership";
|
|
365
|
+
credit_balance: "credit_balance";
|
|
366
|
+
credit_transactions: "credit_transactions";
|
|
367
|
+
billing: "billing";
|
|
368
|
+
billing_controls: "billing_controls";
|
|
369
|
+
customer_plans: "customer_plans";
|
|
370
|
+
credit_packs: "credit_packs";
|
|
371
|
+
credit_pack_orders: "credit_pack_orders";
|
|
372
|
+
offer_history: "offer_history";
|
|
373
|
+
}>;
|
|
374
|
+
status: z.ZodEnum<{
|
|
375
|
+
error: "error";
|
|
376
|
+
idle: "idle";
|
|
377
|
+
loading: "loading";
|
|
378
|
+
ready: "ready";
|
|
379
|
+
}>;
|
|
380
|
+
stale: z.ZodBoolean;
|
|
381
|
+
preview: z.ZodBoolean;
|
|
382
|
+
errorCode: z.ZodOptional<z.ZodString>;
|
|
383
|
+
errorMessage: z.ZodOptional<z.ZodString>;
|
|
384
|
+
resources: z.ZodArray<z.ZodObject<{
|
|
385
|
+
key: z.ZodString;
|
|
386
|
+
name: z.ZodString;
|
|
387
|
+
spendable: z.ZodString;
|
|
388
|
+
reserved: z.ZodString;
|
|
389
|
+
available: z.ZodString;
|
|
390
|
+
expiry: z.ZodNullable<z.ZodString>;
|
|
391
|
+
sources: z.ZodArray<z.ZodObject<{
|
|
392
|
+
id: z.ZodString;
|
|
393
|
+
label: z.ZodString;
|
|
394
|
+
detail: z.ZodArray<z.ZodString>;
|
|
395
|
+
value: z.ZodOptional<z.ZodString>;
|
|
396
|
+
status: z.ZodOptional<z.ZodString>;
|
|
397
|
+
facts: z.ZodArray<z.ZodObject<{
|
|
398
|
+
label: z.ZodString;
|
|
399
|
+
value: z.ZodString;
|
|
400
|
+
}, z.core.$strict>>;
|
|
401
|
+
purchaseId: z.ZodOptional<z.ZodUUID>;
|
|
402
|
+
invoiceUrl: z.ZodOptional<z.ZodURL>;
|
|
403
|
+
billingActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
404
|
+
action: z.ZodLiteral<"invoice_open">;
|
|
405
|
+
label: z.ZodString;
|
|
406
|
+
}, z.core.$strict>>>;
|
|
407
|
+
membershipActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
408
|
+
value: z.ZodString;
|
|
409
|
+
label: z.ZodString;
|
|
410
|
+
}, z.core.$strict>>>;
|
|
411
|
+
}, z.core.$strict>>;
|
|
412
|
+
sourceCount: z.ZodNumber;
|
|
413
|
+
sourcePage: z.ZodNumber;
|
|
414
|
+
hasNextSources: z.ZodBoolean;
|
|
415
|
+
hasPreviousSources: z.ZodBoolean;
|
|
416
|
+
}, z.core.$strict>>;
|
|
417
|
+
rows: z.ZodArray<z.ZodObject<{
|
|
418
|
+
id: z.ZodString;
|
|
419
|
+
label: z.ZodString;
|
|
420
|
+
detail: z.ZodArray<z.ZodString>;
|
|
421
|
+
value: z.ZodOptional<z.ZodString>;
|
|
422
|
+
status: z.ZodOptional<z.ZodString>;
|
|
423
|
+
facts: z.ZodArray<z.ZodObject<{
|
|
424
|
+
label: z.ZodString;
|
|
425
|
+
value: z.ZodString;
|
|
426
|
+
}, z.core.$strict>>;
|
|
427
|
+
purchaseId: z.ZodOptional<z.ZodUUID>;
|
|
428
|
+
invoiceUrl: z.ZodOptional<z.ZodURL>;
|
|
429
|
+
billingActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
430
|
+
action: z.ZodLiteral<"invoice_open">;
|
|
431
|
+
label: z.ZodString;
|
|
432
|
+
}, z.core.$strict>>>;
|
|
433
|
+
membershipActions: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
434
|
+
value: z.ZodString;
|
|
435
|
+
label: z.ZodString;
|
|
436
|
+
}, z.core.$strict>>>;
|
|
437
|
+
}, z.core.$strict>>;
|
|
438
|
+
hasNext: z.ZodBoolean;
|
|
439
|
+
hasPrevious: z.ZodBoolean;
|
|
440
|
+
page: z.ZodNumber;
|
|
441
|
+
filter: z.ZodString;
|
|
442
|
+
updatedAt: z.ZodOptional<z.ZodISODateTime>;
|
|
443
|
+
buyingId: z.ZodOptional<z.ZodUUID>;
|
|
444
|
+
membershipBusy: z.ZodOptional<z.ZodBoolean>;
|
|
445
|
+
billingBusy: z.ZodOptional<z.ZodBoolean>;
|
|
446
|
+
membershipReview: z.ZodOptional<z.ZodObject<{
|
|
447
|
+
title: z.ZodString;
|
|
448
|
+
note: z.ZodString;
|
|
449
|
+
facts: z.ZodArray<z.ZodObject<{
|
|
450
|
+
label: z.ZodString;
|
|
451
|
+
value: z.ZodString;
|
|
452
|
+
}, z.core.$strict>>;
|
|
453
|
+
}, z.core.$strict>>;
|
|
454
|
+
membershipResult: z.ZodOptional<z.ZodString>;
|
|
455
|
+
}, z.core.$strict>>;
|
|
456
|
+
}, z.core.$strict>;
|
|
457
|
+
type CustomerPageData = z.infer<typeof customerPageDataSchema>;
|
|
458
|
+
declare const customerDataIntentSchema: z.ZodObject<{
|
|
459
|
+
nodeId: z.ZodString;
|
|
460
|
+
action: z.ZodEnum<{
|
|
461
|
+
filter: "filter";
|
|
462
|
+
billing_adjustment: "billing_adjustment";
|
|
463
|
+
billing_authorization: "billing_authorization";
|
|
464
|
+
buy_pack: "buy_pack";
|
|
465
|
+
billing_portal: "billing_portal";
|
|
466
|
+
invoice_open: "invoice_open";
|
|
467
|
+
refresh: "refresh";
|
|
468
|
+
next: "next";
|
|
469
|
+
previous: "previous";
|
|
470
|
+
membership_preview: "membership_preview";
|
|
471
|
+
membership_confirm: "membership_confirm";
|
|
472
|
+
membership_dismiss: "membership_dismiss";
|
|
473
|
+
sources_next: "sources_next";
|
|
474
|
+
sources_previous: "sources_previous";
|
|
475
|
+
}>;
|
|
476
|
+
value: z.ZodOptional<z.ZodString>;
|
|
477
|
+
}, z.core.$strict>;
|
|
478
|
+
type CustomerDataIntent = z.infer<typeof customerDataIntentSchema>;
|
|
479
|
+
|
|
480
|
+
export { type CustomerDataIntent as C, type ScreenAnswers as S, type SurfaceData as a, type CustomerPageData as b, type ScreenParameters as c, type ScreenRendererInput as d, screenInputBindingsSchema as s };
|