@tbox.cn/app-module-member 0.1.0 → 0.8.6

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.
Files changed (65) hide show
  1. package/AGENTS.md +16 -0
  2. package/README.md +99 -11
  3. package/dist/chunk-KEBILLQ5.js +771 -0
  4. package/dist/chunk-T4SYPQA5.js +1565 -0
  5. package/dist/client/index.d.ts +11 -2
  6. package/dist/client/index.js +1 -1
  7. package/dist/index.d.ts +2 -2
  8. package/dist/index.js +14 -4
  9. package/dist/login-mascot-5D4X6YZ7.jpg +0 -0
  10. package/dist/member-QFCIYILN.css +1734 -0
  11. package/dist/server/index.d.ts +928 -41
  12. package/dist/server/index.js +13 -3
  13. package/package.json +25 -16
  14. package/skills/member/SKILL.md +141 -0
  15. package/skills/member/references/enrollment.md +34 -0
  16. package/skills/member/references/points-and-card.md +24 -0
  17. package/src/client/assets/login-mascot.jpg +0 -0
  18. package/src/client/assets.d.ts +5 -0
  19. package/src/client/cards/index.ts +10 -0
  20. package/src/client/cards/member-card-summary/index.tsx +375 -0
  21. package/src/client/cards/member-enrollment-cta/index.tsx +61 -0
  22. package/src/client/cards/member-enrollment-form/index.tsx +181 -0
  23. package/src/client/cards/member-enrollment-status/index.tsx +65 -0
  24. package/src/client/cards/member-info/index.tsx +60 -0
  25. package/src/client/cards/member-login-cta/index.tsx +81 -0
  26. package/src/client/cards/member-point-usage-list/index.tsx +53 -0
  27. package/src/client/cards/view.ts +39 -0
  28. package/src/client/components/ImageWithFallback.tsx +38 -0
  29. package/src/client/index.ts +21 -4
  30. package/src/client/styles/member.css +1734 -0
  31. package/src/client/types/css.d.ts +2 -0
  32. package/src/server/action.ts +348 -0
  33. package/src/server/cards/index.ts +31 -0
  34. package/src/server/cards/member-card-summary/meta.ts +42 -0
  35. package/src/server/cards/member-card-summary/samples.ts +272 -0
  36. package/src/server/cards/member-enrollment-cta/meta.ts +19 -0
  37. package/src/server/cards/member-enrollment-form/meta.ts +26 -0
  38. package/src/server/cards/member-enrollment-status/meta.ts +18 -0
  39. package/src/server/cards/member-info/meta.ts +19 -0
  40. package/src/server/cards/member-login-cta/meta.ts +16 -0
  41. package/src/server/cards/member-point-usage-list/meta.ts +19 -0
  42. package/src/server/handler.ts +170 -16
  43. package/src/server/index.ts +136 -24
  44. package/src/server/ports.ts +66 -0
  45. package/src/server/service.ts +188 -36
  46. package/src/server/status.ts +87 -0
  47. package/src/server/subject-binding.ts +19 -0
  48. package/src/server/tool.ts +514 -19
  49. package/src/server/util.ts +4 -0
  50. package/tbox.module.json +124 -0
  51. package/tests/cards-render.test.tsx +526 -0
  52. package/tests/enrollment.test.ts +121 -0
  53. package/tests/ports-resolve.test.ts +95 -0
  54. package/tests/preference-memory.test.ts +86 -0
  55. package/tests/samples.test.ts +61 -0
  56. package/tests/service.test.ts +597 -36
  57. package/tests/skills.test.ts +65 -0
  58. package/tests/status.test.ts +127 -0
  59. package/tests/view.test.ts +33 -0
  60. package/tsup.config.ts +9 -1
  61. package/dist/chunk-F6FHBH3N.js +0 -160
  62. package/dist/chunk-OXXT6F5B.js +0 -33
  63. package/src/client/cards/points/index.tsx +0 -19
  64. package/src/server/cards/points/meta.ts +0 -22
  65. package/tbox.component.json +0 -20
@@ -1,28 +1,40 @@
1
+ import * as _tbox_cn_app_sdk_server from '@tbox.cn/app-sdk/server';
2
+ import { ServerContext } from '@tbox.cn/app-sdk/server';
1
3
  import * as _tbox_cn_app_contracts from '@tbox.cn/app-contracts';
2
- import { CardMeta } from '@tbox.cn/app-contracts';
4
+ import { RequestContext } from '@tbox.cn/app-contracts';
3
5
  import * as zod from 'zod';
4
- import { z } from 'zod';
5
- import { ServerContext } from '@tbox.cn/app-sdk/server';
6
- import { MemberQueryPort, MemberSettlementPort, Points, DiscountRule } from '@tbox.cn/app-contracts-mall';
6
+ import { MemberAccountPort, MemberProfilePort, MemberCardPort, MemberBenefitsPort, MemberEnrollmentPort, MemberAccountSnapshot, MemberProfileSnapshot, MemberCardSnapshot, Points, MemberBenefitsSnapshot, MemberEnrollmentFormDefinition, PointUsageRecord, DiscountRule, MemberEnrollmentInput, MemberEnrollmentResult, MemberEnrollmentStatus } from '@tbox.cn/app-contracts-mall';
7
7
 
8
8
  /**
9
- * MemberService:商圈会员完整实现。
9
+ * MemberService:商圈会员完整实现(011 K2 六 Port + 015 入会升级)。
10
10
  * extends 契约 Port(保证满足消费方子集约束);完整接口只在本模块包内。
11
11
  */
12
- interface MemberService extends MemberQueryPort, MemberSettlementPort {
13
- /** 积分变动记录(单测/观测用) */
14
- audit: {
15
- action: string;
16
- userId: string;
17
- amount: number;
18
- key?: string;
19
- }[];
12
+ /**
13
+ * InMemory 演示实现(仅供隔离单测;运行时注册与 Provider 解析不得使用)。
14
+ * 017 槽位原子化后非 Port 成员归位:getEnrollmentFormDefinition 已收编
15
+ * MemberEnrollmentPort optional 方法(R13);enrollUrl/loginUrl 为槽产物自由属性
16
+ * (enrollment/account 槽的类型视图见 ports.ts);audit 转 InMemory 私有观测成员。
17
+ */
18
+ interface MemberService extends MemberAccountPort, MemberProfilePort, MemberCardPort, MemberBenefitsPort, MemberEnrollmentPort {
19
+ /** 入会落地页深链(alipays:// 或 H5 链接),从 deployment provider config 注入;空串表示未配置。 */
20
+ readonly enrollUrl: string;
21
+ /**
22
+ * 登录页深链,同样从 deployment provider config 注入。
23
+ * 可选而非必填——真实 provider 接入前不该被迫实现;缺省时登录引导退回文本。
24
+ */
25
+ readonly loginUrl?: string;
20
26
  }
21
- /** 内存实现(PoC) */
27
+
28
+ /** 仅供隔离单测使用的 fixture;运行时注册与 Provider 解析不得使用。 */
22
29
  declare class InMemoryMemberService implements MemberService {
30
+ readonly enrollUrl: string;
23
31
  private balances;
24
- private levels;
25
32
  private idempotentKeys;
33
+ private usages;
34
+ private profiles;
35
+ private enrollmentAttempts;
36
+ private pendingConfirmations;
37
+ private statusQueries;
26
38
  audit: {
27
39
  action: string;
28
40
  userId: string;
@@ -30,53 +42,928 @@ declare class InMemoryMemberService implements MemberService {
30
42
  key?: string;
31
43
  }[];
32
44
  constructor(initial?: Record<string, number>);
45
+ getAccount(userId: string): Promise<MemberAccountSnapshot>;
46
+ getProfile(userId: string): Promise<MemberProfileSnapshot>;
47
+ getCard(userId: string): Promise<MemberCardSnapshot | null>;
33
48
  queryPoints(userId: string): Promise<Points>;
49
+ getBenefits(userId: string): Promise<MemberBenefitsSnapshot>;
50
+ getEnrollmentFormDefinition(): Promise<MemberEnrollmentFormDefinition>;
51
+ listPointUsage(userId: string, page: number, pageSize: number): Promise<{
52
+ items: ReadonlyArray<PointUsageRecord>;
53
+ total: number;
54
+ }>;
34
55
  queryDiscount(userId: string): Promise<DiscountRule | undefined>;
35
56
  deductPoints(userId: string, amount: number, idempotencyKey: string): Promise<boolean>;
36
57
  refundPoints(userId: string, amount: number, idempotencyKey: string): Promise<boolean>;
37
58
  awardPoints(userId: string, amount: number): Promise<boolean>;
38
- private levelOf;
39
- private maybeUpgrade;
40
- private levelChangeListeners;
41
- onLevelChange(fn: (e: {
42
- userId: string;
43
- newLevel: 'silver' | 'gold' | 'platinum';
44
- }) => void): void;
59
+ enroll(input: MemberEnrollmentInput): Promise<MemberEnrollmentResult>;
60
+ getEnrollmentStatus(userId: string, attemptRef: string): Promise<{
61
+ status: MemberEnrollmentStatus;
62
+ memberRef?: string;
63
+ reason?: string;
64
+ }>;
45
65
  }
46
66
 
47
- declare const dataSchema: z.ZodObject<{
48
- userId: z.ZodString;
49
- balance: z.ZodNumber;
50
- level: z.ZodEnum<["silver", "gold", "platinum"]>;
51
- }, "strip", z.ZodTypeAny, {
52
- userId: string;
53
- balance: number;
54
- level: "silver" | "gold" | "platinum";
55
- }, {
56
- userId: string;
57
- balance: number;
58
- level: "silver" | "gold" | "platinum";
59
- }>;
60
- declare const meta: CardMeta<typeof dataSchema>;
67
+ /**
68
+ * member Port 分槽解析(017 槽位原子化):五槽独立解析(account/profile/card/
69
+ * benefits/enrollment),无运行时 InMemory 兜底(InMemoryMemberService 仅限隔离单测)。
70
+ * 解析失败一律上抛:未配置/禁用等预期缺席错误码由 registry 抛出,调用方按业务文案转译
71
+ * (status fail-soft / 工具层文案兜底)。
72
+ *
73
+ * 非 Port 成员归位:loginUrl 挂 account 槽产物、enrollUrl 挂 enrollment 槽产物
74
+ * (厂商 fat 实现运行期携带;契约 Port 不含——返回类型上的可选属性扩展即类型视图)。
75
+ */
76
+
77
+ /** account 槽产物类型视图:Port + 厂商实例携带的登录深链(可选) */
78
+ type MemberAccountService = MemberAccountPort & {
79
+ readonly loginUrl?: string;
80
+ };
81
+ /** enrollment 槽产物类型视图:Port + 厂商实例携带的入会深链(可选) */
82
+ type MemberEnrollmentService = MemberEnrollmentPort & {
83
+ readonly enrollUrl?: string;
84
+ };
85
+ declare function resolveMemberAccountPort(reqCtx: RequestContext, ctx: ServerContext): Promise<MemberAccountService>;
86
+ declare function resolveMemberProfilePort(reqCtx: RequestContext, ctx: ServerContext): Promise<MemberProfilePort>;
87
+ declare function resolveMemberCardPort(reqCtx: RequestContext, ctx: ServerContext): Promise<MemberCardPort>;
88
+ declare function resolveMemberBenefitsPort(reqCtx: RequestContext, ctx: ServerContext): Promise<MemberBenefitsPort>;
89
+ declare function resolveMemberEnrollmentPort(reqCtx: RequestContext, ctx: ServerContext): Promise<MemberEnrollmentService>;
90
+
91
+ /** 7 卡 meta map(key 约定 = cardType) */
92
+ declare const memberCards: {
93
+ readonly 'member-info': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
94
+ userId: zod.ZodString;
95
+ authState: zod.ZodEnum<["authenticated", "unauthenticated"]>;
96
+ state: zod.ZodEnum<["unknown", "active", "not_enrolled", "closed"]>;
97
+ displayName: zod.ZodOptional<zod.ZodString>;
98
+ avatarUrl: zod.ZodOptional<zod.ZodString>;
99
+ contactDisplay: zod.ZodOptional<zod.ZodString>;
100
+ memberRef: zod.ZodOptional<zod.ZodString>;
101
+ registeredAt: zod.ZodOptional<zod.ZodString>;
102
+ labels: zod.ZodArray<zod.ZodObject<{
103
+ labelRef: zod.ZodString;
104
+ name: zod.ZodString;
105
+ }, "strip", zod.ZodTypeAny, {
106
+ name: string;
107
+ labelRef: string;
108
+ }, {
109
+ name: string;
110
+ labelRef: string;
111
+ }>, "many">;
112
+ }, "strip", zod.ZodTypeAny, {
113
+ userId: string;
114
+ state: "unknown" | "active" | "not_enrolled" | "closed";
115
+ authState: "authenticated" | "unauthenticated";
116
+ labels: {
117
+ name: string;
118
+ labelRef: string;
119
+ }[];
120
+ displayName?: string | undefined;
121
+ avatarUrl?: string | undefined;
122
+ contactDisplay?: string | undefined;
123
+ memberRef?: string | undefined;
124
+ registeredAt?: string | undefined;
125
+ }, {
126
+ userId: string;
127
+ state: "unknown" | "active" | "not_enrolled" | "closed";
128
+ authState: "authenticated" | "unauthenticated";
129
+ labels: {
130
+ name: string;
131
+ labelRef: string;
132
+ }[];
133
+ displayName?: string | undefined;
134
+ avatarUrl?: string | undefined;
135
+ contactDisplay?: string | undefined;
136
+ memberRef?: string | undefined;
137
+ registeredAt?: string | undefined;
138
+ }>>;
139
+ readonly 'member-card-summary': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
140
+ userId: zod.ZodString;
141
+ cardRef: zod.ZodString;
142
+ cardDisplay: zod.ZodString;
143
+ status: zod.ZodEnum<["active", "inactive", "frozen", "expired", "unknown"]>;
144
+ levelName: zod.ZodOptional<zod.ZodString>;
145
+ availablePoints: zod.ZodNumber;
146
+ cardImageUrl: zod.ZodOptional<zod.ZodString>;
147
+ pointsRuleImageUrl: zod.ZodOptional<zod.ZodString>;
148
+ pointsRuleContent: zod.ZodOptional<zod.ZodString>;
149
+ pointsUrl: zod.ZodOptional<zod.ZodString>;
150
+ presentation: zod.ZodOptional<zod.ZodObject<{
151
+ variant: zod.ZodEnum<["blue", "silver", "gold", "black"]>;
152
+ labelsEmbedded: zod.ZodOptional<zod.ZodBoolean>;
153
+ }, "strip", zod.ZodTypeAny, {
154
+ variant: "silver" | "gold" | "blue" | "black";
155
+ labelsEmbedded?: boolean | undefined;
156
+ }, {
157
+ variant: "silver" | "gold" | "blue" | "black";
158
+ labelsEmbedded?: boolean | undefined;
159
+ }>>;
160
+ progress: zod.ZodOptional<zod.ZodObject<{
161
+ daySpentCents: zod.ZodNumber;
162
+ yearSpentCents: zod.ZodNumber;
163
+ percent: zod.ZodNumber;
164
+ message: zod.ZodString;
165
+ }, "strip", zod.ZodTypeAny, {
166
+ message: string;
167
+ daySpentCents: number;
168
+ yearSpentCents: number;
169
+ percent: number;
170
+ }, {
171
+ message: string;
172
+ daySpentCents: number;
173
+ yearSpentCents: number;
174
+ percent: number;
175
+ }>>;
176
+ benefits: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
177
+ benefitRef: zod.ZodString;
178
+ name: zod.ZodString;
179
+ iconUrl: zod.ZodOptional<zod.ZodString>;
180
+ description: zod.ZodOptional<zod.ZodString>;
181
+ action: zod.ZodOptional<zod.ZodObject<{
182
+ kind: zod.ZodEnum<["miniapp", "dialog", "toast"]>;
183
+ url: zod.ZodOptional<zod.ZodString>;
184
+ title: zod.ZodOptional<zod.ZodString>;
185
+ text: zod.ZodOptional<zod.ZodString>;
186
+ }, "strip", zod.ZodTypeAny, {
187
+ kind: "toast" | "miniapp" | "dialog";
188
+ url?: string | undefined;
189
+ text?: string | undefined;
190
+ title?: string | undefined;
191
+ }, {
192
+ kind: "toast" | "miniapp" | "dialog";
193
+ url?: string | undefined;
194
+ text?: string | undefined;
195
+ title?: string | undefined;
196
+ }>>;
197
+ }, "strip", zod.ZodTypeAny, {
198
+ name: string;
199
+ benefitRef: string;
200
+ description?: string | undefined;
201
+ action?: {
202
+ kind: "toast" | "miniapp" | "dialog";
203
+ url?: string | undefined;
204
+ text?: string | undefined;
205
+ title?: string | undefined;
206
+ } | undefined;
207
+ iconUrl?: string | undefined;
208
+ }, {
209
+ name: string;
210
+ benefitRef: string;
211
+ description?: string | undefined;
212
+ action?: {
213
+ kind: "toast" | "miniapp" | "dialog";
214
+ url?: string | undefined;
215
+ text?: string | undefined;
216
+ title?: string | undefined;
217
+ } | undefined;
218
+ iconUrl?: string | undefined;
219
+ }>, "many">>;
220
+ preferencePrompts: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
221
+ value: zod.ZodEnum<["我常来买衣服", "我常带娃来玩", "我常来吃美食"]>;
222
+ query: zod.ZodString;
223
+ }, "strip", zod.ZodTypeAny, {
224
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
225
+ query: string;
226
+ }, {
227
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
228
+ query: string;
229
+ }>, "many">>;
230
+ }, "strip", zod.ZodTypeAny, {
231
+ status: "unknown" | "active" | "inactive" | "frozen" | "expired";
232
+ userId: string;
233
+ cardRef: string;
234
+ cardDisplay: string;
235
+ availablePoints: number;
236
+ presentation?: {
237
+ variant: "silver" | "gold" | "blue" | "black";
238
+ labelsEmbedded?: boolean | undefined;
239
+ } | undefined;
240
+ levelName?: string | undefined;
241
+ cardImageUrl?: string | undefined;
242
+ pointsRuleImageUrl?: string | undefined;
243
+ pointsRuleContent?: string | undefined;
244
+ pointsUrl?: string | undefined;
245
+ progress?: {
246
+ message: string;
247
+ daySpentCents: number;
248
+ yearSpentCents: number;
249
+ percent: number;
250
+ } | undefined;
251
+ benefits?: {
252
+ name: string;
253
+ benefitRef: string;
254
+ description?: string | undefined;
255
+ action?: {
256
+ kind: "toast" | "miniapp" | "dialog";
257
+ url?: string | undefined;
258
+ text?: string | undefined;
259
+ title?: string | undefined;
260
+ } | undefined;
261
+ iconUrl?: string | undefined;
262
+ }[] | undefined;
263
+ preferencePrompts?: {
264
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
265
+ query: string;
266
+ }[] | undefined;
267
+ }, {
268
+ status: "unknown" | "active" | "inactive" | "frozen" | "expired";
269
+ userId: string;
270
+ cardRef: string;
271
+ cardDisplay: string;
272
+ availablePoints: number;
273
+ presentation?: {
274
+ variant: "silver" | "gold" | "blue" | "black";
275
+ labelsEmbedded?: boolean | undefined;
276
+ } | undefined;
277
+ levelName?: string | undefined;
278
+ cardImageUrl?: string | undefined;
279
+ pointsRuleImageUrl?: string | undefined;
280
+ pointsRuleContent?: string | undefined;
281
+ pointsUrl?: string | undefined;
282
+ progress?: {
283
+ message: string;
284
+ daySpentCents: number;
285
+ yearSpentCents: number;
286
+ percent: number;
287
+ } | undefined;
288
+ benefits?: {
289
+ name: string;
290
+ benefitRef: string;
291
+ description?: string | undefined;
292
+ action?: {
293
+ kind: "toast" | "miniapp" | "dialog";
294
+ url?: string | undefined;
295
+ text?: string | undefined;
296
+ title?: string | undefined;
297
+ } | undefined;
298
+ iconUrl?: string | undefined;
299
+ }[] | undefined;
300
+ preferencePrompts?: {
301
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
302
+ query: string;
303
+ }[] | undefined;
304
+ }>>;
305
+ readonly 'member-point-usage-list': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
306
+ userId: zod.ZodString;
307
+ balance: zod.ZodNumber;
308
+ membershipLabel: zod.ZodOptional<zod.ZodString>;
309
+ items: zod.ZodArray<zod.ZodObject<{
310
+ usageRecordRef: zod.ZodString;
311
+ title: zod.ZodString;
312
+ amount: zod.ZodString;
313
+ usedAt: zod.ZodOptional<zod.ZodString>;
314
+ description: zod.ZodOptional<zod.ZodString>;
315
+ }, "strip", zod.ZodTypeAny, {
316
+ title: string;
317
+ usageRecordRef: string;
318
+ amount: string;
319
+ description?: string | undefined;
320
+ usedAt?: string | undefined;
321
+ }, {
322
+ title: string;
323
+ usageRecordRef: string;
324
+ amount: string;
325
+ description?: string | undefined;
326
+ usedAt?: string | undefined;
327
+ }>, "many">;
328
+ total: zod.ZodNumber;
329
+ }, "strip", zod.ZodTypeAny, {
330
+ userId: string;
331
+ total: number;
332
+ items: {
333
+ title: string;
334
+ usageRecordRef: string;
335
+ amount: string;
336
+ description?: string | undefined;
337
+ usedAt?: string | undefined;
338
+ }[];
339
+ balance: number;
340
+ membershipLabel?: string | undefined;
341
+ }, {
342
+ userId: string;
343
+ total: number;
344
+ items: {
345
+ title: string;
346
+ usageRecordRef: string;
347
+ amount: string;
348
+ description?: string | undefined;
349
+ usedAt?: string | undefined;
350
+ }[];
351
+ balance: number;
352
+ membershipLabel?: string | undefined;
353
+ }>>;
354
+ readonly 'member-enrollment-form': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
355
+ userId: zod.ZodString;
356
+ state: zod.ZodEnum<["unknown", "active", "not_enrolled", "closed"]>;
357
+ formVersion: zod.ZodString;
358
+ fields: zod.ZodArray<zod.ZodObject<{
359
+ fieldId: zod.ZodString;
360
+ label: zod.ZodString;
361
+ type: zod.ZodEnum<["text", "tel", "select", "date"]>;
362
+ required: zod.ZodBoolean;
363
+ readOnly: zod.ZodOptional<zod.ZodBoolean>;
364
+ prefill: zod.ZodOptional<zod.ZodString>;
365
+ placeholder: zod.ZodOptional<zod.ZodString>;
366
+ options: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
367
+ }, "strip", zod.ZodTypeAny, {
368
+ type: "date" | "text" | "tel" | "select";
369
+ required: boolean;
370
+ label: string;
371
+ fieldId: string;
372
+ options?: string[] | undefined;
373
+ readOnly?: boolean | undefined;
374
+ prefill?: string | undefined;
375
+ placeholder?: string | undefined;
376
+ }, {
377
+ type: "date" | "text" | "tel" | "select";
378
+ required: boolean;
379
+ label: string;
380
+ fieldId: string;
381
+ options?: string[] | undefined;
382
+ readOnly?: boolean | undefined;
383
+ prefill?: string | undefined;
384
+ placeholder?: string | undefined;
385
+ }>, "many">;
386
+ consents: zod.ZodArray<zod.ZodObject<{
387
+ consentId: zod.ZodString;
388
+ version: zod.ZodString;
389
+ title: zod.ZodString;
390
+ required: zod.ZodBoolean;
391
+ url: zod.ZodOptional<zod.ZodString>;
392
+ }, "strip", zod.ZodTypeAny, {
393
+ required: boolean;
394
+ version: string;
395
+ title: string;
396
+ consentId: string;
397
+ url?: string | undefined;
398
+ }, {
399
+ required: boolean;
400
+ version: string;
401
+ title: string;
402
+ consentId: string;
403
+ url?: string | undefined;
404
+ }>, "many">;
405
+ authorization: zod.ZodObject<{
406
+ status: zod.ZodEnum<["required", "authorized", "unavailable"]>;
407
+ mobileMasked: zod.ZodOptional<zod.ZodString>;
408
+ }, "strip", zod.ZodTypeAny, {
409
+ status: "required" | "unavailable" | "authorized";
410
+ mobileMasked?: string | undefined;
411
+ }, {
412
+ status: "required" | "unavailable" | "authorized";
413
+ mobileMasked?: string | undefined;
414
+ }>;
415
+ manualNotice: zod.ZodOptional<zod.ZodString>;
416
+ }, "strip", zod.ZodTypeAny, {
417
+ userId: string;
418
+ authorization: {
419
+ status: "required" | "unavailable" | "authorized";
420
+ mobileMasked?: string | undefined;
421
+ };
422
+ state: "unknown" | "active" | "not_enrolled" | "closed";
423
+ formVersion: string;
424
+ fields: {
425
+ type: "date" | "text" | "tel" | "select";
426
+ required: boolean;
427
+ label: string;
428
+ fieldId: string;
429
+ options?: string[] | undefined;
430
+ readOnly?: boolean | undefined;
431
+ prefill?: string | undefined;
432
+ placeholder?: string | undefined;
433
+ }[];
434
+ consents: {
435
+ required: boolean;
436
+ version: string;
437
+ title: string;
438
+ consentId: string;
439
+ url?: string | undefined;
440
+ }[];
441
+ manualNotice?: string | undefined;
442
+ }, {
443
+ userId: string;
444
+ authorization: {
445
+ status: "required" | "unavailable" | "authorized";
446
+ mobileMasked?: string | undefined;
447
+ };
448
+ state: "unknown" | "active" | "not_enrolled" | "closed";
449
+ formVersion: string;
450
+ fields: {
451
+ type: "date" | "text" | "tel" | "select";
452
+ required: boolean;
453
+ label: string;
454
+ fieldId: string;
455
+ options?: string[] | undefined;
456
+ readOnly?: boolean | undefined;
457
+ prefill?: string | undefined;
458
+ placeholder?: string | undefined;
459
+ }[];
460
+ consents: {
461
+ required: boolean;
462
+ version: string;
463
+ title: string;
464
+ consentId: string;
465
+ url?: string | undefined;
466
+ }[];
467
+ manualNotice?: string | undefined;
468
+ }>>;
469
+ readonly 'member-enrollment-status': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
470
+ userId: zod.ZodString;
471
+ attemptRef: zod.ZodOptional<zod.ZodString>;
472
+ state: zod.ZodEnum<["pending_confirmation", "confirmation_timeout", "active", "failed"]>;
473
+ memberRef: zod.ZodOptional<zod.ZodString>;
474
+ message: zod.ZodOptional<zod.ZodString>;
475
+ }, "strip", zod.ZodTypeAny, {
476
+ userId: string;
477
+ state: "failed" | "active" | "pending_confirmation" | "confirmation_timeout";
478
+ message?: string | undefined;
479
+ memberRef?: string | undefined;
480
+ attemptRef?: string | undefined;
481
+ }, {
482
+ userId: string;
483
+ state: "failed" | "active" | "pending_confirmation" | "confirmation_timeout";
484
+ message?: string | undefined;
485
+ memberRef?: string | undefined;
486
+ attemptRef?: string | undefined;
487
+ }>>;
488
+ readonly 'member-enrollment-cta': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
489
+ userId: zod.ZodString;
490
+ authState: zod.ZodLiteral<"authenticated">;
491
+ state: zod.ZodEnum<["not_enrolled", "closed"]>;
492
+ enrollUrl: zod.ZodOptional<zod.ZodEffects<zod.ZodString, string, string>>;
493
+ title: zod.ZodOptional<zod.ZodString>;
494
+ subtitle: zod.ZodOptional<zod.ZodString>;
495
+ perks: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
496
+ }, "strip", zod.ZodTypeAny, {
497
+ userId: string;
498
+ state: "not_enrolled" | "closed";
499
+ authState: "authenticated";
500
+ title?: string | undefined;
501
+ subtitle?: string | undefined;
502
+ enrollUrl?: string | undefined;
503
+ perks?: string[] | undefined;
504
+ }, {
505
+ userId: string;
506
+ state: "not_enrolled" | "closed";
507
+ authState: "authenticated";
508
+ title?: string | undefined;
509
+ subtitle?: string | undefined;
510
+ enrollUrl?: string | undefined;
511
+ perks?: string[] | undefined;
512
+ }>>;
513
+ readonly 'member-login-cta': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
514
+ loginUrl: zod.ZodOptional<zod.ZodEffects<zod.ZodString, string, string>>;
515
+ title: zod.ZodOptional<zod.ZodString>;
516
+ }, "strip", zod.ZodTypeAny, {
517
+ title?: string | undefined;
518
+ loginUrl?: string | undefined;
519
+ }, {
520
+ title?: string | undefined;
521
+ loginUrl?: string | undefined;
522
+ }>>;
523
+ };
61
524
 
62
525
  /** 模块注册入口:自注册闭环(与客户端 clientModule 对称) */
63
526
  declare const serverModule: {
527
+ declaration: {
528
+ moduleId: string;
529
+ };
64
530
  cards: {
65
- readonly points: _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
531
+ readonly 'member-info': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
532
+ userId: zod.ZodString;
533
+ authState: zod.ZodEnum<["authenticated", "unauthenticated"]>;
534
+ state: zod.ZodEnum<["unknown", "active", "not_enrolled", "closed"]>;
535
+ displayName: zod.ZodOptional<zod.ZodString>;
536
+ avatarUrl: zod.ZodOptional<zod.ZodString>;
537
+ contactDisplay: zod.ZodOptional<zod.ZodString>;
538
+ memberRef: zod.ZodOptional<zod.ZodString>;
539
+ registeredAt: zod.ZodOptional<zod.ZodString>;
540
+ labels: zod.ZodArray<zod.ZodObject<{
541
+ labelRef: zod.ZodString;
542
+ name: zod.ZodString;
543
+ }, "strip", zod.ZodTypeAny, {
544
+ name: string;
545
+ labelRef: string;
546
+ }, {
547
+ name: string;
548
+ labelRef: string;
549
+ }>, "many">;
550
+ }, "strip", zod.ZodTypeAny, {
551
+ userId: string;
552
+ state: "unknown" | "active" | "not_enrolled" | "closed";
553
+ authState: "authenticated" | "unauthenticated";
554
+ labels: {
555
+ name: string;
556
+ labelRef: string;
557
+ }[];
558
+ displayName?: string | undefined;
559
+ avatarUrl?: string | undefined;
560
+ contactDisplay?: string | undefined;
561
+ memberRef?: string | undefined;
562
+ registeredAt?: string | undefined;
563
+ }, {
564
+ userId: string;
565
+ state: "unknown" | "active" | "not_enrolled" | "closed";
566
+ authState: "authenticated" | "unauthenticated";
567
+ labels: {
568
+ name: string;
569
+ labelRef: string;
570
+ }[];
571
+ displayName?: string | undefined;
572
+ avatarUrl?: string | undefined;
573
+ contactDisplay?: string | undefined;
574
+ memberRef?: string | undefined;
575
+ registeredAt?: string | undefined;
576
+ }>>;
577
+ readonly 'member-card-summary': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
578
+ userId: zod.ZodString;
579
+ cardRef: zod.ZodString;
580
+ cardDisplay: zod.ZodString;
581
+ status: zod.ZodEnum<["active", "inactive", "frozen", "expired", "unknown"]>;
582
+ levelName: zod.ZodOptional<zod.ZodString>;
583
+ availablePoints: zod.ZodNumber;
584
+ cardImageUrl: zod.ZodOptional<zod.ZodString>;
585
+ pointsRuleImageUrl: zod.ZodOptional<zod.ZodString>;
586
+ pointsRuleContent: zod.ZodOptional<zod.ZodString>;
587
+ pointsUrl: zod.ZodOptional<zod.ZodString>;
588
+ presentation: zod.ZodOptional<zod.ZodObject<{
589
+ variant: zod.ZodEnum<["blue", "silver", "gold", "black"]>;
590
+ labelsEmbedded: zod.ZodOptional<zod.ZodBoolean>;
591
+ }, "strip", zod.ZodTypeAny, {
592
+ variant: "silver" | "gold" | "blue" | "black";
593
+ labelsEmbedded?: boolean | undefined;
594
+ }, {
595
+ variant: "silver" | "gold" | "blue" | "black";
596
+ labelsEmbedded?: boolean | undefined;
597
+ }>>;
598
+ progress: zod.ZodOptional<zod.ZodObject<{
599
+ daySpentCents: zod.ZodNumber;
600
+ yearSpentCents: zod.ZodNumber;
601
+ percent: zod.ZodNumber;
602
+ message: zod.ZodString;
603
+ }, "strip", zod.ZodTypeAny, {
604
+ message: string;
605
+ daySpentCents: number;
606
+ yearSpentCents: number;
607
+ percent: number;
608
+ }, {
609
+ message: string;
610
+ daySpentCents: number;
611
+ yearSpentCents: number;
612
+ percent: number;
613
+ }>>;
614
+ benefits: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
615
+ benefitRef: zod.ZodString;
616
+ name: zod.ZodString;
617
+ iconUrl: zod.ZodOptional<zod.ZodString>;
618
+ description: zod.ZodOptional<zod.ZodString>;
619
+ action: zod.ZodOptional<zod.ZodObject<{
620
+ kind: zod.ZodEnum<["miniapp", "dialog", "toast"]>;
621
+ url: zod.ZodOptional<zod.ZodString>;
622
+ title: zod.ZodOptional<zod.ZodString>;
623
+ text: zod.ZodOptional<zod.ZodString>;
624
+ }, "strip", zod.ZodTypeAny, {
625
+ kind: "toast" | "miniapp" | "dialog";
626
+ url?: string | undefined;
627
+ text?: string | undefined;
628
+ title?: string | undefined;
629
+ }, {
630
+ kind: "toast" | "miniapp" | "dialog";
631
+ url?: string | undefined;
632
+ text?: string | undefined;
633
+ title?: string | undefined;
634
+ }>>;
635
+ }, "strip", zod.ZodTypeAny, {
636
+ name: string;
637
+ benefitRef: string;
638
+ description?: string | undefined;
639
+ action?: {
640
+ kind: "toast" | "miniapp" | "dialog";
641
+ url?: string | undefined;
642
+ text?: string | undefined;
643
+ title?: string | undefined;
644
+ } | undefined;
645
+ iconUrl?: string | undefined;
646
+ }, {
647
+ name: string;
648
+ benefitRef: string;
649
+ description?: string | undefined;
650
+ action?: {
651
+ kind: "toast" | "miniapp" | "dialog";
652
+ url?: string | undefined;
653
+ text?: string | undefined;
654
+ title?: string | undefined;
655
+ } | undefined;
656
+ iconUrl?: string | undefined;
657
+ }>, "many">>;
658
+ preferencePrompts: zod.ZodOptional<zod.ZodArray<zod.ZodObject<{
659
+ value: zod.ZodEnum<["我常来买衣服", "我常带娃来玩", "我常来吃美食"]>;
660
+ query: zod.ZodString;
661
+ }, "strip", zod.ZodTypeAny, {
662
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
663
+ query: string;
664
+ }, {
665
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
666
+ query: string;
667
+ }>, "many">>;
668
+ }, "strip", zod.ZodTypeAny, {
669
+ status: "unknown" | "active" | "inactive" | "frozen" | "expired";
670
+ userId: string;
671
+ cardRef: string;
672
+ cardDisplay: string;
673
+ availablePoints: number;
674
+ presentation?: {
675
+ variant: "silver" | "gold" | "blue" | "black";
676
+ labelsEmbedded?: boolean | undefined;
677
+ } | undefined;
678
+ levelName?: string | undefined;
679
+ cardImageUrl?: string | undefined;
680
+ pointsRuleImageUrl?: string | undefined;
681
+ pointsRuleContent?: string | undefined;
682
+ pointsUrl?: string | undefined;
683
+ progress?: {
684
+ message: string;
685
+ daySpentCents: number;
686
+ yearSpentCents: number;
687
+ percent: number;
688
+ } | undefined;
689
+ benefits?: {
690
+ name: string;
691
+ benefitRef: string;
692
+ description?: string | undefined;
693
+ action?: {
694
+ kind: "toast" | "miniapp" | "dialog";
695
+ url?: string | undefined;
696
+ text?: string | undefined;
697
+ title?: string | undefined;
698
+ } | undefined;
699
+ iconUrl?: string | undefined;
700
+ }[] | undefined;
701
+ preferencePrompts?: {
702
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
703
+ query: string;
704
+ }[] | undefined;
705
+ }, {
706
+ status: "unknown" | "active" | "inactive" | "frozen" | "expired";
707
+ userId: string;
708
+ cardRef: string;
709
+ cardDisplay: string;
710
+ availablePoints: number;
711
+ presentation?: {
712
+ variant: "silver" | "gold" | "blue" | "black";
713
+ labelsEmbedded?: boolean | undefined;
714
+ } | undefined;
715
+ levelName?: string | undefined;
716
+ cardImageUrl?: string | undefined;
717
+ pointsRuleImageUrl?: string | undefined;
718
+ pointsRuleContent?: string | undefined;
719
+ pointsUrl?: string | undefined;
720
+ progress?: {
721
+ message: string;
722
+ daySpentCents: number;
723
+ yearSpentCents: number;
724
+ percent: number;
725
+ } | undefined;
726
+ benefits?: {
727
+ name: string;
728
+ benefitRef: string;
729
+ description?: string | undefined;
730
+ action?: {
731
+ kind: "toast" | "miniapp" | "dialog";
732
+ url?: string | undefined;
733
+ text?: string | undefined;
734
+ title?: string | undefined;
735
+ } | undefined;
736
+ iconUrl?: string | undefined;
737
+ }[] | undefined;
738
+ preferencePrompts?: {
739
+ value: "我常来买衣服" | "我常带娃来玩" | "我常来吃美食";
740
+ query: string;
741
+ }[] | undefined;
742
+ }>>;
743
+ readonly 'member-point-usage-list': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
66
744
  userId: zod.ZodString;
67
745
  balance: zod.ZodNumber;
68
- level: zod.ZodEnum<["silver", "gold", "platinum"]>;
746
+ membershipLabel: zod.ZodOptional<zod.ZodString>;
747
+ items: zod.ZodArray<zod.ZodObject<{
748
+ usageRecordRef: zod.ZodString;
749
+ title: zod.ZodString;
750
+ amount: zod.ZodString;
751
+ usedAt: zod.ZodOptional<zod.ZodString>;
752
+ description: zod.ZodOptional<zod.ZodString>;
753
+ }, "strip", zod.ZodTypeAny, {
754
+ title: string;
755
+ usageRecordRef: string;
756
+ amount: string;
757
+ description?: string | undefined;
758
+ usedAt?: string | undefined;
759
+ }, {
760
+ title: string;
761
+ usageRecordRef: string;
762
+ amount: string;
763
+ description?: string | undefined;
764
+ usedAt?: string | undefined;
765
+ }>, "many">;
766
+ total: zod.ZodNumber;
69
767
  }, "strip", zod.ZodTypeAny, {
70
768
  userId: string;
769
+ total: number;
770
+ items: {
771
+ title: string;
772
+ usageRecordRef: string;
773
+ amount: string;
774
+ description?: string | undefined;
775
+ usedAt?: string | undefined;
776
+ }[];
71
777
  balance: number;
72
- level: "silver" | "gold" | "platinum";
778
+ membershipLabel?: string | undefined;
73
779
  }, {
74
780
  userId: string;
781
+ total: number;
782
+ items: {
783
+ title: string;
784
+ usageRecordRef: string;
785
+ amount: string;
786
+ description?: string | undefined;
787
+ usedAt?: string | undefined;
788
+ }[];
75
789
  balance: number;
76
- level: "silver" | "gold" | "platinum";
790
+ membershipLabel?: string | undefined;
77
791
  }>>;
792
+ readonly 'member-enrollment-form': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
793
+ userId: zod.ZodString;
794
+ state: zod.ZodEnum<["unknown", "active", "not_enrolled", "closed"]>;
795
+ formVersion: zod.ZodString;
796
+ fields: zod.ZodArray<zod.ZodObject<{
797
+ fieldId: zod.ZodString;
798
+ label: zod.ZodString;
799
+ type: zod.ZodEnum<["text", "tel", "select", "date"]>;
800
+ required: zod.ZodBoolean;
801
+ readOnly: zod.ZodOptional<zod.ZodBoolean>;
802
+ prefill: zod.ZodOptional<zod.ZodString>;
803
+ placeholder: zod.ZodOptional<zod.ZodString>;
804
+ options: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
805
+ }, "strip", zod.ZodTypeAny, {
806
+ type: "date" | "text" | "tel" | "select";
807
+ required: boolean;
808
+ label: string;
809
+ fieldId: string;
810
+ options?: string[] | undefined;
811
+ readOnly?: boolean | undefined;
812
+ prefill?: string | undefined;
813
+ placeholder?: string | undefined;
814
+ }, {
815
+ type: "date" | "text" | "tel" | "select";
816
+ required: boolean;
817
+ label: string;
818
+ fieldId: string;
819
+ options?: string[] | undefined;
820
+ readOnly?: boolean | undefined;
821
+ prefill?: string | undefined;
822
+ placeholder?: string | undefined;
823
+ }>, "many">;
824
+ consents: zod.ZodArray<zod.ZodObject<{
825
+ consentId: zod.ZodString;
826
+ version: zod.ZodString;
827
+ title: zod.ZodString;
828
+ required: zod.ZodBoolean;
829
+ url: zod.ZodOptional<zod.ZodString>;
830
+ }, "strip", zod.ZodTypeAny, {
831
+ required: boolean;
832
+ version: string;
833
+ title: string;
834
+ consentId: string;
835
+ url?: string | undefined;
836
+ }, {
837
+ required: boolean;
838
+ version: string;
839
+ title: string;
840
+ consentId: string;
841
+ url?: string | undefined;
842
+ }>, "many">;
843
+ authorization: zod.ZodObject<{
844
+ status: zod.ZodEnum<["required", "authorized", "unavailable"]>;
845
+ mobileMasked: zod.ZodOptional<zod.ZodString>;
846
+ }, "strip", zod.ZodTypeAny, {
847
+ status: "required" | "unavailable" | "authorized";
848
+ mobileMasked?: string | undefined;
849
+ }, {
850
+ status: "required" | "unavailable" | "authorized";
851
+ mobileMasked?: string | undefined;
852
+ }>;
853
+ manualNotice: zod.ZodOptional<zod.ZodString>;
854
+ }, "strip", zod.ZodTypeAny, {
855
+ userId: string;
856
+ authorization: {
857
+ status: "required" | "unavailable" | "authorized";
858
+ mobileMasked?: string | undefined;
859
+ };
860
+ state: "unknown" | "active" | "not_enrolled" | "closed";
861
+ formVersion: string;
862
+ fields: {
863
+ type: "date" | "text" | "tel" | "select";
864
+ required: boolean;
865
+ label: string;
866
+ fieldId: string;
867
+ options?: string[] | undefined;
868
+ readOnly?: boolean | undefined;
869
+ prefill?: string | undefined;
870
+ placeholder?: string | undefined;
871
+ }[];
872
+ consents: {
873
+ required: boolean;
874
+ version: string;
875
+ title: string;
876
+ consentId: string;
877
+ url?: string | undefined;
878
+ }[];
879
+ manualNotice?: string | undefined;
880
+ }, {
881
+ userId: string;
882
+ authorization: {
883
+ status: "required" | "unavailable" | "authorized";
884
+ mobileMasked?: string | undefined;
885
+ };
886
+ state: "unknown" | "active" | "not_enrolled" | "closed";
887
+ formVersion: string;
888
+ fields: {
889
+ type: "date" | "text" | "tel" | "select";
890
+ required: boolean;
891
+ label: string;
892
+ fieldId: string;
893
+ options?: string[] | undefined;
894
+ readOnly?: boolean | undefined;
895
+ prefill?: string | undefined;
896
+ placeholder?: string | undefined;
897
+ }[];
898
+ consents: {
899
+ required: boolean;
900
+ version: string;
901
+ title: string;
902
+ consentId: string;
903
+ url?: string | undefined;
904
+ }[];
905
+ manualNotice?: string | undefined;
906
+ }>>;
907
+ readonly 'member-enrollment-status': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
908
+ userId: zod.ZodString;
909
+ attemptRef: zod.ZodOptional<zod.ZodString>;
910
+ state: zod.ZodEnum<["pending_confirmation", "confirmation_timeout", "active", "failed"]>;
911
+ memberRef: zod.ZodOptional<zod.ZodString>;
912
+ message: zod.ZodOptional<zod.ZodString>;
913
+ }, "strip", zod.ZodTypeAny, {
914
+ userId: string;
915
+ state: "failed" | "active" | "pending_confirmation" | "confirmation_timeout";
916
+ message?: string | undefined;
917
+ memberRef?: string | undefined;
918
+ attemptRef?: string | undefined;
919
+ }, {
920
+ userId: string;
921
+ state: "failed" | "active" | "pending_confirmation" | "confirmation_timeout";
922
+ message?: string | undefined;
923
+ memberRef?: string | undefined;
924
+ attemptRef?: string | undefined;
925
+ }>>;
926
+ readonly 'member-enrollment-cta': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
927
+ userId: zod.ZodString;
928
+ authState: zod.ZodLiteral<"authenticated">;
929
+ state: zod.ZodEnum<["not_enrolled", "closed"]>;
930
+ enrollUrl: zod.ZodOptional<zod.ZodEffects<zod.ZodString, string, string>>;
931
+ title: zod.ZodOptional<zod.ZodString>;
932
+ subtitle: zod.ZodOptional<zod.ZodString>;
933
+ perks: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
934
+ }, "strip", zod.ZodTypeAny, {
935
+ userId: string;
936
+ state: "not_enrolled" | "closed";
937
+ authState: "authenticated";
938
+ title?: string | undefined;
939
+ subtitle?: string | undefined;
940
+ enrollUrl?: string | undefined;
941
+ perks?: string[] | undefined;
942
+ }, {
943
+ userId: string;
944
+ state: "not_enrolled" | "closed";
945
+ authState: "authenticated";
946
+ title?: string | undefined;
947
+ subtitle?: string | undefined;
948
+ enrollUrl?: string | undefined;
949
+ perks?: string[] | undefined;
950
+ }>>;
951
+ readonly 'member-login-cta': _tbox_cn_app_contracts.CardMeta<zod.ZodObject<{
952
+ loginUrl: zod.ZodOptional<zod.ZodEffects<zod.ZodString, string, string>>;
953
+ title: zod.ZodOptional<zod.ZodString>;
954
+ }, "strip", zod.ZodTypeAny, {
955
+ title?: string | undefined;
956
+ loginUrl?: string | undefined;
957
+ }, {
958
+ title?: string | undefined;
959
+ loginUrl?: string | undefined;
960
+ }>>;
961
+ };
962
+ preTools: {};
963
+ skills: {
964
+ [k: string]: _tbox_cn_app_sdk_server.LocalSkill;
78
965
  };
79
966
  register(ctx: ServerContext): void;
80
967
  };
81
968
 
82
- export { InMemoryMemberService, type MemberService, meta as pointsMeta, serverModule };
969
+ export { InMemoryMemberService, type MemberAccountService, type MemberEnrollmentService, type MemberService, memberCards, resolveMemberAccountPort, resolveMemberBenefitsPort, resolveMemberCardPort, resolveMemberEnrollmentPort, resolveMemberProfilePort, serverModule };