@domino-sdk/relay 1.5.2 → 1.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{activity-DeKJsRry.d.ts → activity-Br6vyYze.d.ts} +147 -116
- package/dist/authoring.d.ts +59 -47
- package/dist/authoring.js +3 -3
- package/dist/{automatic-outcomes-B1xrETxm.d.ts → automatic-outcomes-C1Q9LrDb.d.ts} +224 -13
- package/dist/browser.d.ts +22 -10
- package/dist/browser.js +6 -6
- package/dist/{capability-error-DNMwKmlL.d.ts → capability-error-Bv996M-h.d.ts} +2 -0
- package/dist/{chunk-GQKYAQM6.js → chunk-23QJ7WH4.js} +1 -1
- package/dist/{chunk-WJSSJ7AF.js → chunk-5ECM6AWV.js} +24 -4
- package/dist/{chunk-XFMSUPNS.js → chunk-6ON4RMEN.js} +1 -1
- package/dist/{chunk-VFHHLN6A.js → chunk-6RBF3UDA.js} +49 -6
- package/dist/chunk-AXRMT33W.js +112 -0
- package/dist/{chunk-24AFCBZN.js → chunk-BFZHJA2B.js} +2 -2
- package/dist/{chunk-EYH5RDIE.js → chunk-C25TDFHN.js} +4 -2
- package/dist/{chunk-36HTX2BM.js → chunk-GMPPLZKH.js} +61 -4
- package/dist/{chunk-BGGKNIRP.js → chunk-JW4G3SY5.js} +1 -1
- package/dist/{chunk-JON5SESL.js → chunk-KGJSKGKI.js} +84 -6
- package/dist/{chunk-DGWMLN35.js → chunk-ZOUEEK5L.js} +16 -5
- package/dist/{client-gqnRUHpC.d.ts → client-pfml_XAa.d.ts} +88 -41
- package/dist/{groups-Ck-OxzjD.d.ts → groups-BpWEqaPn.d.ts} +175 -3
- package/dist/{images-Dv-P5VBw.d.ts → images-BaKYd0fl.d.ts} +1 -1
- package/dist/index.d.ts +9 -9
- package/dist/index.js +5 -5
- package/dist/internal.d.ts +6 -113
- package/dist/internal.js +18 -24
- package/dist/{offers-Cy-e4o5x.d.ts → offers-CYtal8jO.d.ts} +3 -2
- package/dist/{outcomes-kVB-Juzs.d.ts → pages-CixTNnF4.d.ts} +142 -99
- package/dist/{pages-BBYD21IE.d.ts → participant-activity-DkL3nY5a.d.ts} +1 -14
- package/dist/portal-proxy.js +48 -36
- package/dist/react/index.d.ts +25 -3949
- package/dist/react/index.js +8 -7
- package/dist/referral-reward-kinds-ClxAuCGx.d.ts +171 -0
- package/dist/{request-error-DWduJCGV.d.ts → request-error-D_dUPLwo.d.ts} +5 -0
- package/dist/{schema-DfJzH2ci.d.ts → schema-CQydLqw4.d.ts} +122 -37
- package/dist/schema.d.ts +10 -10
- package/dist/schema.js +48 -6
- package/dist/server/index.d.ts +9673 -66110
- package/dist/server/index.js +1048 -550
- package/dist/sign-in-options-CtXUFV7E.d.ts +202 -0
- package/dist/{submission-input-BZkm6ohU.d.ts → submission-input-CLefHTrj.d.ts} +2 -2
- package/package.json +1 -1
- package/dist/browser-D_3s8B5e.d.ts +0 -4154
- package/dist/chunk-GUP7YRR4.js +0 -42
- package/dist/identity-integration-GxAHdKR2.d.ts +0 -58
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import {
|
|
2
|
+
import { cV as ResourceHandle, cY as GroupHandle } from './schema-CQydLqw4.js';
|
|
3
3
|
|
|
4
4
|
declare const pointLedgerPropertiesSchema: z.ZodObject<{
|
|
5
5
|
name: z.ZodString;
|
|
@@ -72,6 +72,7 @@ declare const pointBalancesSchema: z.ZodObject<{
|
|
|
72
72
|
available: z.ZodNumber;
|
|
73
73
|
}, z.core.$strip>>;
|
|
74
74
|
}, z.core.$strip>;
|
|
75
|
+
/** @compat open */
|
|
75
76
|
type KnownPointEntryKind = (typeof PointEntryKind)[keyof typeof PointEntryKind];
|
|
76
77
|
/**
|
|
77
78
|
* The point entry kinds this SDK knows. `PointEntry.kind` is an open string: Relay can add kinds,
|
|
@@ -333,6 +334,42 @@ declare const engagementChangePreviewSchema: z.ZodObject<{
|
|
|
333
334
|
pending: z.ZodString;
|
|
334
335
|
}, z.core.$strict>;
|
|
335
336
|
}, z.core.$strict>;
|
|
337
|
+
/**
|
|
338
|
+
* One page of an engagement rule's published versions, newest first. Unlike the strict definition
|
|
339
|
+
* authoring validates, a published version as read keeps parsing when a newer server adds fields.
|
|
340
|
+
*/
|
|
341
|
+
declare const engagementRuleVersionPageSchema: z.ZodObject<{
|
|
342
|
+
items: z.ZodArray<z.ZodObject<{
|
|
343
|
+
version: z.ZodString;
|
|
344
|
+
definition: z.ZodObject<{
|
|
345
|
+
budgets: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
346
|
+
scope: z.ZodEnum<{
|
|
347
|
+
member: "member";
|
|
348
|
+
project: "project";
|
|
349
|
+
}>;
|
|
350
|
+
period: z.ZodEnum<{
|
|
351
|
+
lifetime: "lifetime";
|
|
352
|
+
day: "day";
|
|
353
|
+
week: "week";
|
|
354
|
+
month: "month";
|
|
355
|
+
}>;
|
|
356
|
+
limit: z.ZodNumber;
|
|
357
|
+
}, z.core.$strip>>>;
|
|
358
|
+
key: z.ZodString;
|
|
359
|
+
qualifiedBy: z.ZodString;
|
|
360
|
+
balance: z.ZodString;
|
|
361
|
+
metrics: z.ZodArray<z.ZodString>;
|
|
362
|
+
baseline: z.ZodLiteral<"historical">;
|
|
363
|
+
maxAgeMs: z.ZodDefault<z.ZodNumber>;
|
|
364
|
+
}, z.core.$strip>;
|
|
365
|
+
publishedAt: z.ZodNumber;
|
|
366
|
+
previousVersion: z.ZodNullable<z.ZodString>;
|
|
367
|
+
}, z.core.$strip>>;
|
|
368
|
+
nextCursor: z.ZodNullable<z.ZodString>;
|
|
369
|
+
}, z.core.$strip>;
|
|
370
|
+
/** @compat output */
|
|
371
|
+
type EngagementRuleVersionPage = z.infer<typeof engagementRuleVersionPageSchema>;
|
|
372
|
+
/** @deprecated Use `engagementRuleVersionPageSchema`. Removed in 2.0.0. */
|
|
336
373
|
declare const engagementVersionPageSchema: z.ZodObject<{
|
|
337
374
|
items: z.ZodArray<z.ZodObject<{
|
|
338
375
|
version: z.ZodString;
|
|
@@ -362,6 +399,7 @@ declare const engagementVersionPageSchema: z.ZodObject<{
|
|
|
362
399
|
}, z.core.$strict>>;
|
|
363
400
|
next: z.ZodNullable<z.ZodNumber>;
|
|
364
401
|
}, z.core.$strict>;
|
|
402
|
+
/** @deprecated Use `management.engagement.ruleVersions(rule, { cursor })`. Removed in 2.0.0. */
|
|
365
403
|
declare const engagementVersionQuerySchema: z.ZodObject<{
|
|
366
404
|
rule: z.ZodString;
|
|
367
405
|
before: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
@@ -1539,6 +1577,35 @@ declare const pointsEntrySchema: z.ZodObject<{
|
|
|
1539
1577
|
reason: z.ZodString;
|
|
1540
1578
|
actor: z.ZodNullable<z.ZodString>;
|
|
1541
1579
|
}, z.core.$strip>;
|
|
1580
|
+
/**
|
|
1581
|
+
* One page of a member's entries in one point ledger, as operators read them, the most recently
|
|
1582
|
+
* recorded first. Pass `nextCursor` back as `cursor` for the next page.
|
|
1583
|
+
*/
|
|
1584
|
+
declare const managedPointHistoryPageSchema: z.ZodObject<{
|
|
1585
|
+
items: z.ZodArray<z.ZodObject<{
|
|
1586
|
+
id: z.ZodString;
|
|
1587
|
+
completion: z.ZodNullable<z.ZodString>;
|
|
1588
|
+
member: z.ZodString;
|
|
1589
|
+
balance: z.ZodString;
|
|
1590
|
+
amount: z.ZodNumber;
|
|
1591
|
+
kind: z.ZodEnum<{
|
|
1592
|
+
reverse: "reverse";
|
|
1593
|
+
award: "award";
|
|
1594
|
+
spend: "spend";
|
|
1595
|
+
adjust: "adjust";
|
|
1596
|
+
}>;
|
|
1597
|
+
effectiveAt: z.ZodNumber;
|
|
1598
|
+
receivedAt: z.ZodNumber;
|
|
1599
|
+
quest: z.ZodNullable<z.ZodString>;
|
|
1600
|
+
original: z.ZodNullable<z.ZodString>;
|
|
1601
|
+
reason: z.ZodString;
|
|
1602
|
+
actor: z.ZodNullable<z.ZodString>;
|
|
1603
|
+
}, z.core.$strip>>;
|
|
1604
|
+
nextCursor: z.ZodNullable<z.ZodString>;
|
|
1605
|
+
next: z.ZodNullable<z.ZodNumber>;
|
|
1606
|
+
}, z.core.$strip>;
|
|
1607
|
+
/** @compat output */
|
|
1608
|
+
type ManagedPointHistoryPage = z.infer<typeof managedPointHistoryPageSchema>;
|
|
1542
1609
|
declare const pointsResultSchema: z.ZodObject<{
|
|
1543
1610
|
entry: z.ZodObject<{
|
|
1544
1611
|
id: z.ZodString;
|
|
@@ -1573,6 +1640,10 @@ declare const leaderboardExclusionSchema: z.ZodObject<{
|
|
|
1573
1640
|
excluded: z.ZodBoolean;
|
|
1574
1641
|
reason: z.ZodString;
|
|
1575
1642
|
}, z.core.$strict>;
|
|
1643
|
+
/**
|
|
1644
|
+
* @deprecated Use `addGroupMemberSchema` and `removeGroupMemberSchema` (`management.groups`)
|
|
1645
|
+
* instead. Removed in 2.0.0.
|
|
1646
|
+
*/
|
|
1576
1647
|
declare const leaderboardGroupSchema: z.ZodObject<{
|
|
1577
1648
|
actionId: z.ZodString;
|
|
1578
1649
|
member: z.ZodString;
|
|
@@ -2105,6 +2176,27 @@ declare const referralAcceptSchema: z.ZodObject<{
|
|
|
2105
2176
|
actionId: z.ZodString;
|
|
2106
2177
|
code: z.ZodString;
|
|
2107
2178
|
}, z.core.$strict>;
|
|
2179
|
+
/** `management.referrals.suspend(member, input)`: suspends or restores a member's referral. */
|
|
2180
|
+
declare const referralSuspensionSchema: z.ZodObject<{
|
|
2181
|
+
actionId: z.ZodString;
|
|
2182
|
+
suspended: z.ZodBoolean;
|
|
2183
|
+
reason: z.ZodString;
|
|
2184
|
+
}, z.core.$strict>;
|
|
2185
|
+
/** `management.referrals.qualify(program, member, input)`: qualifies or unqualifies a member. */
|
|
2186
|
+
declare const referralQualificationSchema: z.ZodObject<{
|
|
2187
|
+
actionId: z.ZodString;
|
|
2188
|
+
qualified: z.ZodBoolean;
|
|
2189
|
+
reason: z.ZodString;
|
|
2190
|
+
}, z.core.$strict>;
|
|
2191
|
+
/** `management.referrals.resolveReward(entitlement, input)`: clears a referral reward's review. */
|
|
2192
|
+
declare const referralRewardResolutionSchema: z.ZodObject<{
|
|
2193
|
+
actionId: z.ZodString;
|
|
2194
|
+
reason: z.ZodString;
|
|
2195
|
+
}, z.core.$strict>;
|
|
2196
|
+
/**
|
|
2197
|
+
* The 1.0 body of `POST /referrals/control`, with every ID in the body.
|
|
2198
|
+
* @deprecated Use `referralSuspensionSchema`, `referralQualificationSchema` or `referralRewardResolutionSchema` with `management.referrals.suspend`, `qualify` or `resolveReward`. Removed in 2.0.0.
|
|
2199
|
+
*/
|
|
2108
2200
|
declare const referralControlSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
2109
2201
|
kind: z.ZodLiteral<"suspend">;
|
|
2110
2202
|
actionId: z.ZodString;
|
|
@@ -2281,6 +2373,11 @@ declare const referralHistorySchema: z.ZodObject<{
|
|
|
2281
2373
|
}, z.core.$strip>>;
|
|
2282
2374
|
nextCursor: z.ZodNullable<z.ZodString>;
|
|
2283
2375
|
}, z.core.$strip>;
|
|
2376
|
+
/**
|
|
2377
|
+
* One page of the project's referral relationships, newest first, with the qualifications and
|
|
2378
|
+
* accounts of the members they name and the referral rewards waiting for review. Pass `nextCursor`
|
|
2379
|
+
* back as `cursor` for the next page.
|
|
2380
|
+
*/
|
|
2284
2381
|
declare const referralManagementSchema: z.ZodObject<{
|
|
2285
2382
|
relationships: z.ZodArray<z.ZodObject<{
|
|
2286
2383
|
member: z.ZodString;
|
|
@@ -2315,6 +2412,7 @@ declare const referralManagementSchema: z.ZodObject<{
|
|
|
2315
2412
|
program: z.ZodString;
|
|
2316
2413
|
reason: z.ZodString;
|
|
2317
2414
|
}, z.core.$strip>>;
|
|
2415
|
+
nextCursor: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
2318
2416
|
next: z.ZodNullable<z.ZodNumber>;
|
|
2319
2417
|
}, z.core.$strip>;
|
|
2320
2418
|
|
|
@@ -2438,12 +2536,86 @@ declare const projectGroupAuthoringSchema: z.ZodPipe<z.ZodObject<{
|
|
|
2438
2536
|
key: string;
|
|
2439
2537
|
title?: string | undefined;
|
|
2440
2538
|
}>>;
|
|
2441
|
-
/**
|
|
2539
|
+
/**
|
|
2540
|
+
* Define one project group for prerequisites, leaderboards, and referrals. The handle names the
|
|
2541
|
+
* group by its key; operators create the group and manage its members in Console or with
|
|
2542
|
+
* `management.groups`.
|
|
2543
|
+
*/
|
|
2442
2544
|
declare function defineGroup(input: Omit<z.input<typeof projectGroupAuthoringSchema>, "key" | "id"> & AuthoringIdentity): {
|
|
2443
2545
|
key: string;
|
|
2444
2546
|
title: string;
|
|
2445
2547
|
} & ResourceHandle<"group">;
|
|
2446
2548
|
type ProjectGroupReference = GroupHandle;
|
|
2447
2549
|
declare function projectGroupKey(group: ProjectGroupReference): string;
|
|
2550
|
+
/** Creates a group under `key`, the name prerequisites, leaderboards and referral rules use. */
|
|
2551
|
+
declare const createGroupSchema: z.ZodObject<{
|
|
2552
|
+
actionId: z.ZodString;
|
|
2553
|
+
key: z.ZodString;
|
|
2554
|
+
title: z.ZodString;
|
|
2555
|
+
}, z.core.$strict>;
|
|
2556
|
+
/** Renames a group. Its key, members and history stay. */
|
|
2557
|
+
declare const updateGroupSchema: z.ZodObject<{
|
|
2558
|
+
title: z.ZodString;
|
|
2559
|
+
}, z.core.$strict>;
|
|
2560
|
+
/** Adds `member` to a group, with a reason for the audit history. */
|
|
2561
|
+
declare const addGroupMemberSchema: z.ZodObject<{
|
|
2562
|
+
actionId: z.ZodString;
|
|
2563
|
+
member: z.ZodString;
|
|
2564
|
+
reason: z.ZodString;
|
|
2565
|
+
}, z.core.$strict>;
|
|
2566
|
+
/** Removes the member the path names from a group, with a reason for the audit history. */
|
|
2567
|
+
declare const removeGroupMemberSchema: z.ZodObject<{
|
|
2568
|
+
actionId: z.ZodString;
|
|
2569
|
+
reason: z.ZodString;
|
|
2570
|
+
}, z.core.$strict>;
|
|
2571
|
+
/** One page of groups or of a group's members: pass `nextCursor` back as `cursor`. */
|
|
2572
|
+
declare const groupPageQuerySchema: z.ZodObject<{
|
|
2573
|
+
cursor: z.ZodOptional<z.ZodString>;
|
|
2574
|
+
/** Items per page, 1–100; the default is 50. */
|
|
2575
|
+
limit: z.ZodOptional<z.ZodNumber>;
|
|
2576
|
+
}, z.core.$strict>;
|
|
2577
|
+
type GroupPageQuery = z.input<typeof groupPageQuerySchema>;
|
|
2578
|
+
/**
|
|
2579
|
+
* A group as operators manage it, with the number of its current members. An archived group
|
|
2580
|
+
* keeps its members, and prerequisites, leaderboards and referral rules still read them, but its
|
|
2581
|
+
* membership cannot change until it is unarchived.
|
|
2582
|
+
*/
|
|
2583
|
+
declare const managedGroupSchema: z.ZodObject<{
|
|
2584
|
+
key: z.ZodString;
|
|
2585
|
+
title: z.ZodString;
|
|
2586
|
+
members: z.ZodNumber;
|
|
2587
|
+
createdAt: z.ZodNumber;
|
|
2588
|
+
archivedAt: z.ZodNullable<z.ZodNumber>;
|
|
2589
|
+
}, z.core.$strip>;
|
|
2590
|
+
/** @compat output */
|
|
2591
|
+
type ManagedGroup = z.infer<typeof managedGroupSchema>;
|
|
2592
|
+
declare const groupPageSchema: z.ZodObject<{
|
|
2593
|
+
items: z.ZodArray<z.ZodObject<{
|
|
2594
|
+
key: z.ZodString;
|
|
2595
|
+
title: z.ZodString;
|
|
2596
|
+
members: z.ZodNumber;
|
|
2597
|
+
createdAt: z.ZodNumber;
|
|
2598
|
+
archivedAt: z.ZodNullable<z.ZodNumber>;
|
|
2599
|
+
}, z.core.$strip>>;
|
|
2600
|
+
nextCursor: z.ZodNullable<z.ZodString>;
|
|
2601
|
+
}, z.core.$strip>;
|
|
2602
|
+
/** @compat output */
|
|
2603
|
+
type GroupPage = z.infer<typeof groupPageSchema>;
|
|
2604
|
+
/** A current member of a group. `addedAt` is null when Relay has no record of when they joined. */
|
|
2605
|
+
declare const groupMemberSchema: z.ZodObject<{
|
|
2606
|
+
member: z.ZodString;
|
|
2607
|
+
addedAt: z.ZodNullable<z.ZodNumber>;
|
|
2608
|
+
}, z.core.$strip>;
|
|
2609
|
+
/** @compat output */
|
|
2610
|
+
type GroupMember = z.infer<typeof groupMemberSchema>;
|
|
2611
|
+
declare const groupMemberPageSchema: z.ZodObject<{
|
|
2612
|
+
items: z.ZodArray<z.ZodObject<{
|
|
2613
|
+
member: z.ZodString;
|
|
2614
|
+
addedAt: z.ZodNullable<z.ZodNumber>;
|
|
2615
|
+
}, z.core.$strip>>;
|
|
2616
|
+
nextCursor: z.ZodNullable<z.ZodString>;
|
|
2617
|
+
}, z.core.$strip>;
|
|
2618
|
+
/** @compat output */
|
|
2619
|
+
type GroupMemberPage = z.infer<typeof groupMemberPageSchema>;
|
|
2448
2620
|
|
|
2449
|
-
export {
|
|
2621
|
+
export { engagementChangeSchema as $, type AvailabilityWindow as A, type ManagedPointLedger as B, type CampaignDefinition as C, type PointLedger as D, type EngagementBudget as E, addGroupMemberSchema as F, type GroupMember as G, availabilityWindowSchema as H, campaignDefinitionSchema as I, campaignEnrollmentInputSchema as J, type KnownPointEntryKind as K, type LeaderboardDefinition as L, type MemberCampaignEnrollmentInput as M, campaignEnrollmentSchema as N, campaignViewSchema as O, type PointBalance as P, campaignWithdrawalInputSchema as Q, type ReferralDefinition as R, createGroupSchema as S, createPointLedgerSchema as T, defineCampaign as U, defineGroup as V, engagementArtifactSchema as W, engagementBoundaryPageSchema as X, engagementBudgetSchema as Y, engagementChangePreviewInputSchema as Z, engagementChangePreviewSchema as _, type CampaignEnrollment as a, referralDefinitionSchema as a$, engagementDefinitionSchema as a0, engagementDeploymentEntrySchema as a1, engagementPageQuerySchema as a2, engagementPageSchema as a3, engagementPublishSchema as a4, engagementRuleSchema as a5, engagementRuleVersionPageSchema as a6, engagementScoreInputSchema as a7, engagementScoreSchema as a8, engagementSettlementSchema as a9, managedPointHistoryPageSchema as aA, managedPointLedgerSchema as aB, memberCampaignEnrollmentInputSchema as aC, memberCampaignWithdrawalInputSchema as aD, pointBalanceSchema as aE, pointBalancesSchema as aF, pointEntrySchema as aG, pointHistoryPageSchema as aH, pointHistoryQuerySchema as aI, pointLedgerArtifactSchema as aJ, pointLedgerDeclarationSchema as aK, pointLedgerPropertiesSchema as aL, pointLedgerReferenceSchema as aM, pointLedgerSchema as aN, pointsAccountSchema as aO, pointsEntrySchema as aP, pointsMutationSchema as aQ, pointsResultSchema as aR, projectGroupKey as aS, projectGroupSchema as aT, publishedLeaderboardSchema as aU, publishedReferralSchema as aV, referralAcceptSchema as aW, referralAccountSchema as aX, referralArtifactSchema as aY, referralAuthoringSchema as aZ, referralControlSchema as a_, engagementVersionPageSchema as aa, engagementVersionQuerySchema as ab, groupMemberPageSchema as ac, groupMemberSchema as ad, groupPageQuerySchema as ae, groupPageSchema as af, leaderboardArtifactSchema as ag, leaderboardAuthoringSchema as ah, leaderboardDefinitionSchema as ai, leaderboardExclusionSchema as aj, leaderboardGroupSchema as ak, leaderboardPageSchema as al, leaderboardPlacementSchema as am, leaderboardPreviewSchema as an, leaderboardPrizeRewardSchema as ao, leaderboardPrizeSchema as ap, leaderboardQuerySchema as aq, leaderboardRowSchema as ar, leaderboardSettlementApprovalSchema as as, leaderboardSettlementPolicySchema as at, leaderboardSettlementRowSchema as au, leaderboardSettlementSchema as av, leaderboardSettlementStatusSchema as aw, leaderboardSettlementSummarySchema as ax, leaderboardWindowSchema as ay, managedGroupSchema as az, type CampaignEnrollmentInput as b, referralHistorySchema as b0, referralManagementSchema as b1, referralQualificationSchema as b2, referralRelationshipSchema as b3, referralRewardResolutionSchema as b4, referralSummarySchema as b5, referralSuspensionSchema as b6, removeGroupMemberSchema as b7, updateGroupSchema as b8, type AuthoringIdentity as b9, type CampaignView as c, type CampaignWithdrawalInput as d, type LeaderboardPage as e, type LeaderboardPlacement as f, type LeaderboardQuery as g, type MemberCampaignWithdrawalInput as h, type PointBalances as i, type PointEntry as j, PointEntryKind as k, type PointHistoryPage as l, type PointHistoryQuery as m, type PointLedgerReference as n, type ProjectGroup as o, type ProjectGroupReference as p, type EngagementDefinition as q, type EngagementRuleVersionPage as r, type GroupMemberPage as s, type GroupPage as t, type GroupPageQuery as u, type LeaderboardSettlement as v, type LeaderboardSettlementPolicy as w, type LeaderboardSettlementSummary as x, type ManagedGroup as y, type ManagedPointHistoryPage as z };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export { C as ClaimSubmission, K as KnownRelayErrorCode, P as PhotoSubmission, a as ProgressObservation, b as ProgressObserver, Q as QuestActionResult, c as QuestController, d as QuestUpdatedError, e as QuizSubmission, R as RelayClient, f as RelayClientOptions, g as RelayError, h as RelayErrorCode, i as RelayErrorDetails, j as RelayErrorKind, k as RelayRequestOptions, S as SubmissionDraft, l as SubmissionStatus, m as SubmissionStore, V as ValueSubmission, n as createRelayClient, o as isRelayError } from './client-
|
|
2
|
-
export { R as RequestError, a as RequestErrorDetails, b as RequestErrorKind, c as RequestRecovery, i as isRequestError } from './request-error-
|
|
3
|
-
export { A as Attempt, a as AttemptStatus, E as Entitlement, b as EvaluatorProgress, K as KnownAttemptStatus, c as KnownTrackerSkipCode, M as MemberProgress, Q as QuestBudgetView, d as QuestPresentation, e as QuestProfile, f as QuizEvidence, R as Reward, S as SubmissionEvidence, g as SubmitInput, T as TieredRewardReference, h as TrackerSkipCode } from './schema-
|
|
1
|
+
export { C as ClaimSubmission, K as KnownRelayErrorCode, P as PhotoSubmission, a as ProgressObservation, b as ProgressObserver, Q as QuestActionResult, c as QuestController, d as QuestUpdatedError, e as QuizSubmission, R as RelayClient, f as RelayClientOptions, g as RelayError, h as RelayErrorCode, i as RelayErrorDetails, j as RelayErrorKind, k as RelayRequestOptions, S as SubmissionDraft, l as SubmissionStatus, m as SubmissionStore, V as ValueSubmission, n as createRelayClient, o as isRelayError } from './client-pfml_XAa.js';
|
|
2
|
+
export { R as RequestError, a as RequestErrorDetails, b as RequestErrorKind, c as RequestRecovery, i as isRequestError } from './request-error-D_dUPLwo.js';
|
|
3
|
+
export { A as Attempt, a as AttemptStatus, E as Entitlement, b as EvaluatorProgress, K as KnownAttemptStatus, c as KnownTrackerSkipCode, M as MemberProgress, Q as QuestBudgetView, d as QuestPresentation, e as QuestProfile, f as QuizEvidence, R as Reward, S as SubmissionEvidence, g as SubmitInput, T as TieredRewardReference, h as TrackerSkipCode } from './schema-CQydLqw4.js';
|
|
4
4
|
export { f as formatUnits, p as parseUnits } from './units-CwgsPB_r.js';
|
|
5
|
-
export { A as AccountConnection, a as AuthProvider, M as MissingPrerequisite, P as Prerequisite, T as TextEvidence, b as TextOptions, U as UrlEvidence, c as UrlOptions, V as ValueEvidence } from './submission-input-
|
|
6
|
-
export { E as ExchangeInput, M as MemberSummary, P as
|
|
7
|
-
export { Q as QuestClaimInput,
|
|
8
|
-
export { A as AvailabilityWindow, C as CampaignDefinition, a as CampaignEnrollment, b as CampaignEnrollmentInput, c as CampaignView, d as CampaignWithdrawalInput, K as KnownPointEntryKind, L as LeaderboardDefinition, e as LeaderboardPage, f as LeaderboardPlacement, g as LeaderboardQuery, M as MemberCampaignEnrollmentInput, h as MemberCampaignWithdrawalInput, P as PointBalance, i as PointBalances, j as PointEntry, k as PointEntryKind, l as PointHistoryPage, m as PointHistoryQuery, n as PointLedgerReference, o as ProjectGroup, p as ProjectGroupReference, R as ReferralDefinition } from './groups-
|
|
9
|
-
export { A as AutomaticCatchUpPreview, a as AutomaticEvent, b as AutomaticOutcome, C as CollectionPass, c as CounterAchievement, d as CounterPolicy, e as CounterProgress } from './automatic-outcomes-
|
|
10
|
-
export { O as Offer, a as OfferDefinition, b as OfferPrice, R as RedeemOfferInput, c as Redemption } from './offers-
|
|
5
|
+
export { A as AccountConnection, a as AuthProvider, M as MissingPrerequisite, P as Prerequisite, T as TextEvidence, b as TextOptions, U as UrlEvidence, c as UrlOptions, V as ValueEvidence } from './submission-input-CLefHTrj.js';
|
|
6
|
+
export { E as ExchangeInput, M as MemberSummary, P as ParticipantActivity, a as ParticipantPrincipal, b as ParticipantSession, R as RelayEvent, S as Session, s as sessionMember } from './participant-activity-DkL3nY5a.js';
|
|
7
|
+
export { P as Page, a as PageQuery, Q as QuestClaimInput, b as QuestEnrollment, c as QuestEnrollmentInput, d as QuestInteraction, e as QuestOutcome, f as QuestOutcomePage, g as QuestOutcomeQuery, h as QuestOutcomeState, i as QuestRewardView, j as QuestView } from './pages-CixTNnF4.js';
|
|
8
|
+
export { A as AvailabilityWindow, C as CampaignDefinition, a as CampaignEnrollment, b as CampaignEnrollmentInput, c as CampaignView, d as CampaignWithdrawalInput, K as KnownPointEntryKind, L as LeaderboardDefinition, e as LeaderboardPage, f as LeaderboardPlacement, g as LeaderboardQuery, M as MemberCampaignEnrollmentInput, h as MemberCampaignWithdrawalInput, P as PointBalance, i as PointBalances, j as PointEntry, k as PointEntryKind, l as PointHistoryPage, m as PointHistoryQuery, n as PointLedgerReference, o as ProjectGroup, p as ProjectGroupReference, R as ReferralDefinition } from './groups-BpWEqaPn.js';
|
|
9
|
+
export { A as AutomaticCatchUpPreview, a as AutomaticEvent, b as AutomaticOutcome, C as CollectionPass, c as CounterAchievement, d as CounterPolicy, e as CounterProgress } from './automatic-outcomes-C1Q9LrDb.js';
|
|
10
|
+
export { O as Offer, a as OfferDefinition, b as OfferPrice, R as RedeemOfferInput, c as Redemption } from './offers-CYtal8jO.js';
|
|
11
11
|
export { A as AvatarProvider, O as OwnProfile, P as ProfileAvatar, a as ProfileCompletion, b as ProfileCompletionPage, c as ProfileCompletionQuery, d as ProfileReferral, e as ProfileSummary, f as ProfileUpdate, g as ProfileVisibility } from './profiles-D2aFcOxu.js';
|
|
12
12
|
export { Q as QuizContent, S as StreakProgress } from './streaks-CWyq8Px5.js';
|
|
13
13
|
export { C as CosmosChain, a as CosmosNetwork, L as LinkedWallet, W as WalletAddressInput, b as WalletChain, c as WalletMessageChallenge, d as WalletSignInNetwork, e as WalletSignature, f as WalletSigner, g as WalletUnlinkInput } from './wallet-YssWxGg8.js';
|
package/dist/index.js
CHANGED
|
@@ -5,16 +5,16 @@ import {
|
|
|
5
5
|
import {
|
|
6
6
|
QuestUpdatedError,
|
|
7
7
|
createRelayClient
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-ZOUEEK5L.js";
|
|
9
9
|
import {
|
|
10
10
|
QuestOutcomeState
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-C25TDFHN.js";
|
|
12
12
|
import {
|
|
13
13
|
PointEntryKind,
|
|
14
14
|
RelayError,
|
|
15
15
|
RelayErrorCode,
|
|
16
16
|
isRelayError
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-GMPPLZKH.js";
|
|
18
18
|
import "./chunk-6QJ3LADK.js";
|
|
19
19
|
import {
|
|
20
20
|
RequestError,
|
|
@@ -22,10 +22,10 @@ import {
|
|
|
22
22
|
} from "./chunk-NPGENI7K.js";
|
|
23
23
|
import {
|
|
24
24
|
sessionMember
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-6ON4RMEN.js";
|
|
26
26
|
import {
|
|
27
27
|
AttemptStatus
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-KGJSKGKI.js";
|
|
29
29
|
export {
|
|
30
30
|
AttemptStatus,
|
|
31
31
|
PointEntryKind,
|
package/dist/internal.d.ts
CHANGED
|
@@ -1,91 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
export {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import { b as RequestErrorKind } from './request-error-DWduJCGV.js';
|
|
7
|
-
import { z } from 'zod';
|
|
8
|
-
|
|
9
|
-
/** Older releases did not record ownership. Preserve every value, including defaults. */
|
|
10
|
-
declare function questConfiguration(release: PublishedRelease): {
|
|
11
|
-
defaults: Record<string, string | number | boolean | {
|
|
12
|
-
id: string;
|
|
13
|
-
prompt: string;
|
|
14
|
-
choices: {
|
|
15
|
-
id: string;
|
|
16
|
-
label: string;
|
|
17
|
-
}[];
|
|
18
|
-
correct: string;
|
|
19
|
-
}[]>;
|
|
20
|
-
overrides: Record<string, string | number | boolean | {
|
|
21
|
-
id: string;
|
|
22
|
-
prompt: string;
|
|
23
|
-
choices: {
|
|
24
|
-
id: string;
|
|
25
|
-
label: string;
|
|
26
|
-
}[];
|
|
27
|
-
correct: string;
|
|
28
|
-
}[]>;
|
|
29
|
-
preserved: string[];
|
|
30
|
-
};
|
|
31
|
-
|
|
32
|
-
/** Every declared field is present with its declared type or null; nothing else is returned. */
|
|
33
|
-
declare function parseImageExtraction(raw: ImageFields, value: unknown): {
|
|
34
|
-
values: Record<string, string | number | boolean | null>;
|
|
35
|
-
reason: string;
|
|
36
|
-
};
|
|
37
|
-
declare function parseImageResult(request: ImageRequest, value: unknown): {
|
|
38
|
-
kind: "pass" | "fail" | "unclear";
|
|
39
|
-
reason: string;
|
|
40
|
-
} | {
|
|
41
|
-
width: number;
|
|
42
|
-
height: number;
|
|
43
|
-
format: "jpeg" | "png" | "webp" | "gif" | "avif";
|
|
44
|
-
bytes: number;
|
|
45
|
-
sha256: string;
|
|
46
|
-
phash: string;
|
|
47
|
-
dhash: string;
|
|
48
|
-
} | {
|
|
49
|
-
identical: boolean;
|
|
50
|
-
phashDistance: number;
|
|
51
|
-
dhashDistance: number;
|
|
52
|
-
} | {
|
|
53
|
-
values: Record<string, string | number | boolean | null>;
|
|
54
|
-
reason: string;
|
|
55
|
-
} | {
|
|
56
|
-
matches: number;
|
|
57
|
-
closestDistance: number | null;
|
|
58
|
-
firstSeenAt: number | null;
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
/** Cursor polling of a participant's own committed activity. */
|
|
62
|
-
declare function isActivityParticipantRoute(path: string, method: string): boolean;
|
|
63
|
-
/** The signed-in participant's earned rewards and delivery states. */
|
|
64
|
-
declare function isRewardsParticipantRoute(path: string, method: string): boolean;
|
|
65
|
-
/** Content stage and engagement reads. */
|
|
66
|
-
declare function isContentParticipantRoute(path: string, method: string): boolean;
|
|
67
|
-
/**
|
|
68
|
-
* The member's automatic-quest outcomes, campaign and quest enrollment, and historical claims.
|
|
69
|
-
*/
|
|
70
|
-
declare function isQuestOutcomeParticipantRoute(path: string, method: string): boolean;
|
|
71
|
-
/** The member's own point balances and the history of one ledger (`me.balances`, `me.pointHistory`). */
|
|
72
|
-
declare function isPointsParticipantRoute(path: string, method: string): boolean;
|
|
73
|
-
declare function isOfferParticipantRoute(path: string, method: string): boolean;
|
|
74
|
-
/**
|
|
75
|
-
* The profile routes, with their methods: the member's own profile, and the reads keyed by a
|
|
76
|
-
* public profile ID.
|
|
77
|
-
*/
|
|
78
|
-
declare function isProfileParticipantRoute(path: string, method: string): boolean;
|
|
79
|
-
/**
|
|
80
|
-
* The participant wallet paths the client calls. The gates admit GET and POST; the API answers
|
|
81
|
-
* another method on a wallet path with 405.
|
|
82
|
-
*/
|
|
83
|
-
declare function isWalletParticipantRoute(path: string): boolean;
|
|
84
|
-
/**
|
|
85
|
-
* Wallet sign-in (`/v1/auth/wallet/start` and `/verify`). Hosted proxies admit it; identity
|
|
86
|
-
* integrations do not, because their apps have their own login.
|
|
87
|
-
*/
|
|
88
|
-
declare function isWalletSignInRoute(path: string): boolean;
|
|
1
|
+
export { I as IdentityKindClaim, P as ParticipantRoute, R as REFERRAL_INTEGRATION_REWARD_ERROR, c as containsReferralIntegrationReward, i as identityIntegrationInputSchema, a as identityIntegrationSchema, b as identityIntegrationSecretSchema, d as identityKindClaimSchema, e as isIntegrationParticipantPath, f as isParticipantRoute, p as parseImageExtraction, g as parseImageResult, h as participantExchangeSchema, j as participantRoutePattern, k as participantRoutes, q as questConfiguration, s as sequenceCursorSchema, l as sourceDataSchema, m as sourceRoles, v as validateQuestShape } from './referral-reward-kinds-ClxAuCGx.js';
|
|
2
|
+
export { E as Extracted } from './images-BaKYd0fl.js';
|
|
3
|
+
import { b as RequestErrorKind } from './request-error-D_dUPLwo.js';
|
|
4
|
+
export { i as TrackerDataBudget, s as schemaCheckedReader, t as trackerDataBatchSteps, j as trackerDataIssue, k as trackerDataIssues, l as trackerDataPathTypes, m as trackerDataRecordSteps, w as whereSchemaIssue } from './schema-CQydLqw4.js';
|
|
5
|
+
import 'zod';
|
|
89
6
|
|
|
90
7
|
/** The management client's and the CLI's default deadline per call. */
|
|
91
8
|
declare const MANAGEMENT_TIMEOUT = 30000;
|
|
@@ -132,28 +49,4 @@ type Rules = {
|
|
|
132
49
|
*/
|
|
133
50
|
declare function retrying<T>(life: Lifetime, rules: Rules, attempt: () => Promise<T>): Promise<T>;
|
|
134
51
|
|
|
135
|
-
|
|
136
|
-
* How Relay reads back a cursor it issued over a numeric position. Clients treat cursors as
|
|
137
|
-
* opaque strings (`pageCursorSchema`); only the server parses them, so the format can change.
|
|
138
|
-
*/
|
|
139
|
-
declare const sequenceCursorSchema: z.ZodPipe<z.ZodPipe<z.ZodString, z.ZodTransform<number, string>>, z.ZodNumber>;
|
|
140
|
-
|
|
141
|
-
/** The account roles a source's records can name: `author` and any others the source declares. */
|
|
142
|
-
declare function sourceRoles(source: TrackerSourceResponse): readonly string[];
|
|
143
|
-
/**
|
|
144
|
-
* The schema a source's record `data` matches: a custom source's declared schema, a Discord
|
|
145
|
-
* source's fixed one, or undefined for X (provider payloads) and untyped custom trackers.
|
|
146
|
-
*/
|
|
147
|
-
declare function sourceDataSchema(source: TrackerSource): TrackerDataSchema | undefined;
|
|
148
|
-
|
|
149
|
-
/** Rules independent of published resources, permissions and another release. */
|
|
150
|
-
type QuestShape = Pick<QuestDescription, "trigger" | "performance"> & {
|
|
151
|
-
completion: Pick<QuestDescription["completion"], "kind">;
|
|
152
|
-
requires: readonly unknown[];
|
|
153
|
-
};
|
|
154
|
-
/** The same trigger/completion matrix for authoring, publication and graph validation. */
|
|
155
|
-
declare function validateQuestShape(description: QuestShape, options?: {
|
|
156
|
-
template?: boolean;
|
|
157
|
-
}): void;
|
|
158
|
-
|
|
159
|
-
export { type AttemptFailure, type Lifetime, MANAGEMENT_TIMEOUT, isActivityParticipantRoute, isContentParticipantRoute, isOfferParticipantRoute, isPointsParticipantRoute, isProfileParticipantRoute, isQuestOutcomeParticipantRoute, isRewardsParticipantRoute, isWalletParticipantRoute, isWalletSignInRoute, lifetime, parseImageExtraction, parseImageResult, questConfiguration, retryAfter, retrying, sequenceCursorSchema, sourceDataSchema, sourceRoles, validateQuestShape };
|
|
52
|
+
export { type AttemptFailure, type Lifetime, MANAGEMENT_TIMEOUT, lifetime, retryAfter, retrying };
|
package/dist/internal.js
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
|
+
REFERRAL_INTEGRATION_REWARD_ERROR,
|
|
3
|
+
containsReferralIntegrationReward,
|
|
2
4
|
identityIntegrationInputSchema,
|
|
3
5
|
identityIntegrationSchema,
|
|
4
6
|
identityIntegrationSecretSchema,
|
|
@@ -8,24 +10,19 @@ import {
|
|
|
8
10
|
participantExchangeSchema,
|
|
9
11
|
questConfiguration,
|
|
10
12
|
sequenceCursorSchema
|
|
11
|
-
} from "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
+
} from "./chunk-5ECM6AWV.js";
|
|
14
|
+
import "./chunk-JW4G3SY5.js";
|
|
13
15
|
import {
|
|
14
16
|
sourceDataSchema,
|
|
15
17
|
sourceRoles,
|
|
16
18
|
validateQuestShape
|
|
17
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-23QJ7WH4.js";
|
|
18
20
|
import {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
isQuestOutcomeParticipantRoute,
|
|
25
|
-
isRewardsParticipantRoute,
|
|
26
|
-
isWalletParticipantRoute,
|
|
27
|
-
isWalletSignInRoute
|
|
28
|
-
} from "./chunk-GUP7YRR4.js";
|
|
21
|
+
isIntegrationParticipantPath,
|
|
22
|
+
isParticipantRoute,
|
|
23
|
+
participantRoutePattern,
|
|
24
|
+
participantRoutes
|
|
25
|
+
} from "./chunk-AXRMT33W.js";
|
|
29
26
|
import {
|
|
30
27
|
MANAGEMENT_TIMEOUT,
|
|
31
28
|
lifetime,
|
|
@@ -33,7 +30,7 @@ import {
|
|
|
33
30
|
retrying
|
|
34
31
|
} from "./chunk-6QJ3LADK.js";
|
|
35
32
|
import "./chunk-NPGENI7K.js";
|
|
36
|
-
import "./chunk-
|
|
33
|
+
import "./chunk-6ON4RMEN.js";
|
|
37
34
|
import {
|
|
38
35
|
schemaCheckedReader,
|
|
39
36
|
trackerDataBatchSteps,
|
|
@@ -42,26 +39,23 @@ import {
|
|
|
42
39
|
trackerDataPathTypes,
|
|
43
40
|
trackerDataRecordSteps,
|
|
44
41
|
whereSchemaIssue
|
|
45
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-KGJSKGKI.js";
|
|
46
43
|
export {
|
|
47
44
|
MANAGEMENT_TIMEOUT,
|
|
45
|
+
REFERRAL_INTEGRATION_REWARD_ERROR,
|
|
46
|
+
containsReferralIntegrationReward,
|
|
48
47
|
identityIntegrationInputSchema,
|
|
49
48
|
identityIntegrationSchema,
|
|
50
49
|
identityIntegrationSecretSchema,
|
|
51
50
|
identityKindClaimSchema,
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
isOfferParticipantRoute,
|
|
55
|
-
isPointsParticipantRoute,
|
|
56
|
-
isProfileParticipantRoute,
|
|
57
|
-
isQuestOutcomeParticipantRoute,
|
|
58
|
-
isRewardsParticipantRoute,
|
|
59
|
-
isWalletParticipantRoute,
|
|
60
|
-
isWalletSignInRoute,
|
|
51
|
+
isIntegrationParticipantPath,
|
|
52
|
+
isParticipantRoute,
|
|
61
53
|
lifetime,
|
|
62
54
|
parseImageExtraction,
|
|
63
55
|
parseImageResult,
|
|
64
56
|
participantExchangeSchema,
|
|
57
|
+
participantRoutePattern,
|
|
58
|
+
participantRoutes,
|
|
65
59
|
questConfiguration,
|
|
66
60
|
retryAfter,
|
|
67
61
|
retrying,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { cV as ResourceHandle } from './schema-CQydLqw4.js';
|
|
2
|
+
import { b9 as AuthoringIdentity } from './groups-BpWEqaPn.js';
|
|
3
3
|
import { z } from 'zod';
|
|
4
4
|
|
|
5
5
|
declare const offerPriceSchema: z.ZodObject<{
|
|
@@ -304,6 +304,7 @@ declare const offerSchema: z.ZodObject<{
|
|
|
304
304
|
kind: z.ZodLiteral<"paused">;
|
|
305
305
|
}, z.core.$strict>], "kind">;
|
|
306
306
|
}, z.core.$strict>;
|
|
307
|
+
/** @compat output */
|
|
307
308
|
type Offer = z.infer<typeof offerSchema>;
|
|
308
309
|
declare const redeemOfferSchema: z.ZodObject<{
|
|
309
310
|
actionId: z.ZodString;
|