@domino-sdk/relay 1.68.0 → 1.69.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.
Files changed (77) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/dist/{accounts-DnpKoJCo.d.ts → accounts-DD4gAOCe.d.ts} +25 -3
  3. package/dist/{action-9Xl0StBg.d.ts → action-BDFKqGlH.d.ts} +3 -2
  4. package/dist/{attempt-captures-DMNFMYFb.d.ts → attempt-captures-CbuCmthd.d.ts} +4 -3
  5. package/dist/authoring.d.ts +218 -43
  6. package/dist/authoring.js +73 -17
  7. package/dist/{automatic-outcomes-CQ3vpiQl.d.ts → automatic-outcomes-DE3vfi8g.d.ts} +11 -3
  8. package/dist/avatar.d.ts +2 -1
  9. package/dist/browser.d.ts +15 -14
  10. package/dist/browser.js +11 -11
  11. package/dist/{capability-error-CuI_F7yM.d.ts → capability-error-db7kO8-P.d.ts} +2 -1
  12. package/dist/{catalog-BLGie8Lh.d.ts → catalog-Cf3fHDNn.d.ts} +11 -3
  13. package/dist/{chunk-55WJVFWC.js → chunk-2A3BJ262.js} +2 -2
  14. package/dist/{chunk-P4TPW4SY.js → chunk-5RLIPTL7.js} +1 -1
  15. package/dist/{chunk-HXTKI34N.js → chunk-AZDZEQFK.js} +1 -1
  16. package/dist/{chunk-TYZFVL73.js → chunk-BRROI4CH.js} +4 -4
  17. package/dist/{chunk-6YTSRWRB.js → chunk-CQVKOD3B.js} +71 -4
  18. package/dist/{chunk-MEUAJIVO.js → chunk-CZ23KRVK.js} +2 -2
  19. package/dist/{chunk-DDJN2T5A.js → chunk-DIXYVGXO.js} +1 -1
  20. package/dist/{chunk-75KF633N.js → chunk-GEVARKEV.js} +1 -1
  21. package/dist/{chunk-VRZZB7CQ.js → chunk-LDO5GP7G.js} +1 -1
  22. package/dist/{chunk-SD74HD75.js → chunk-LGGD7S5T.js} +9 -9
  23. package/dist/{chunk-R3MNZKNJ.js → chunk-ME2KUAVJ.js} +1 -1
  24. package/dist/{chunk-DNPDR4Z7.js → chunk-ODJGTFPY.js} +6 -6
  25. package/dist/{chunk-6UBFSMCM.js → chunk-PO2ZDY27.js} +1 -1
  26. package/dist/{chunk-EXZVWQOQ.js → chunk-RKTMSTT7.js} +2 -2
  27. package/dist/{chunk-KKHENO57.js → chunk-SWLW4VN3.js} +2 -2
  28. package/dist/{chunk-CZ7NQ7W7.js → chunk-TCREFRPK.js} +3 -3
  29. package/dist/{chunk-5AKD4ZF3.js → chunk-UGM6DUB2.js} +8 -3
  30. package/dist/{chunk-IW46TW3A.js → chunk-VNEJH4NT.js} +26 -2
  31. package/dist/{chunk-4JSPMFO2.js → chunk-WNEQEDMU.js} +2 -2
  32. package/dist/{chunk-7YSVZA7A.js → chunk-WVK3G2J2.js} +1 -1
  33. package/dist/{client-BMif22WQ.d.ts → client-6eSYOl8h.d.ts} +33 -11
  34. package/dist/{dashboards-DMk-vL1q.d.ts → dashboards-DCOAXL54.d.ts} +6 -5
  35. package/dist/{deployments-BCr418BX.d.ts → deployments-BIfdCMd5.d.ts} +530 -337
  36. package/dist/{host-environment-FN4zg3hw.d.ts → host-environment-DUw5-Cvj.d.ts} +2 -1
  37. package/dist/{identity-integration-r76xaAax.d.ts → identity-integration-BlfOn8rc.d.ts} +3 -2
  38. package/dist/index.d.ts +16 -15
  39. package/dist/index.js +10 -10
  40. package/dist/internal.d.ts +34 -19
  41. package/dist/internal.js +40 -14
  42. package/dist/{limits-ByVRQePO.d.ts → limits-Ctaeq23J.d.ts} +3 -2
  43. package/dist/{offers-xcPbYaEv.d.ts → offers-COqHGbHm.d.ts} +4 -3
  44. package/dist/{participant-activity-DXRq4s6K.d.ts → participant-activity-BznrcePT.d.ts} +2 -1
  45. package/dist/{participant-rewards-BcWkBRn_.d.ts → participant-rewards-s5Gn23qb.d.ts} +23 -1
  46. package/dist/portal-proxy.d.ts +7 -4
  47. package/dist/portal-proxy.js +13 -17
  48. package/dist/profiles-CLDKZVFx.d.ts +370 -0
  49. package/dist/react/index.d.ts +50 -31
  50. package/dist/react/index.js +11 -11
  51. package/dist/{request-error-D_dUPLwo.d.ts → request-error-C24SY7n9.d.ts} +2 -1
  52. package/dist/{reward-deliveries-0VvT6LMj.d.ts → reward-deliveries-DFhYGJdx.d.ts} +3 -2
  53. package/dist/runtime/authoring.js +1 -1
  54. package/dist/runtime/chunks/HKAI5OQA.js +1 -0
  55. package/dist/runtime/manifest.json +3 -3
  56. package/dist/runtime/schema.js +1 -1
  57. package/dist/schema.d.ts +258 -176
  58. package/dist/schema.js +16 -8
  59. package/dist/server/index.d.ts +15 -14
  60. package/dist/server/index.js +45 -45
  61. package/dist/{sign-in-providers-C5_753DZ.d.ts → sign-in-providers-C97mRNbG.d.ts} +4 -3
  62. package/dist/solana.d.ts +142 -26
  63. package/dist/solana.js +449 -114
  64. package/dist/{streaks-0YuipsUQ.d.ts → streaks-MAqKHbHC.d.ts} +2 -1
  65. package/dist/{submission-input-CaL8drIh.d.ts → submission-input-BD7nORuh.d.ts} +4 -3
  66. package/dist/{telegram-browser-DLtHPRBI.d.ts → telegram-browser-gRMgGs7B.d.ts} +8 -7
  67. package/dist/telegram.d.ts +14 -12
  68. package/dist/telegram.js +2 -2
  69. package/dist/testing.d.ts +24 -15
  70. package/dist/testing.js +6 -6
  71. package/dist/{tracker-data-CAK942sx.d.ts → tracker-data-DQgX3FIc.d.ts} +198 -3
  72. package/dist/{transport-CkidqTOk.d.ts → transport-BLU8jrhg.d.ts} +3415 -2233
  73. package/dist/vite.d.ts +2 -1
  74. package/dist/{wallet-DQtJelQQ.d.ts → wallet-CPAjrW4k.d.ts} +52 -375
  75. package/dist/{wallet-browser-dpmr22Xv.d.ts → wallet-browser-BzPt_Qb5.d.ts} +3 -2
  76. package/package.json +6 -3
  77. package/dist/runtime/chunks/2UDZ6TPL.js +0 -1
package/dist/authoring.js CHANGED
@@ -6,14 +6,14 @@ import {
6
6
  sourceDataSchema,
7
7
  sourceRoles,
8
8
  validateQuestShape
9
- } from "./chunk-HXTKI34N.js";
9
+ } from "./chunk-AZDZEQFK.js";
10
10
  import {
11
11
  defineDashboard,
12
12
  tiktokVideoBodySchema,
13
13
  tiktokVideoMetrics,
14
14
  youtubeShortBodySchema,
15
15
  youtubeShortMetrics
16
- } from "./chunk-MEUAJIVO.js";
16
+ } from "./chunk-CZ23KRVK.js";
17
17
  import {
18
18
  CapabilityError,
19
19
  capabilityErrorCodes
@@ -24,7 +24,7 @@ import {
24
24
  engagementScoreSchema,
25
25
  offerAuthoringSchema,
26
26
  referralAuthoringSchema
27
- } from "./chunk-55WJVFWC.js";
27
+ } from "./chunk-2A3BJ262.js";
28
28
  import {
29
29
  announcementSchema,
30
30
  authorBudgetSchema,
@@ -120,6 +120,9 @@ import {
120
120
  walletBalancesNamespace,
121
121
  walletNftSampleSchema,
122
122
  walletNftsNamespace,
123
+ walletProgramAccountSampleSchema,
124
+ walletProgramAccountSourceSchema,
125
+ walletProgramAccountsNamespace,
123
126
  walletProgramActivityNamespace,
124
127
  walletProgramActivitySchema,
125
128
  walletProgramActivitySourceSchema,
@@ -130,10 +133,12 @@ import {
130
133
  whereSettings,
131
134
  xSearchSourceSchema,
132
135
  youtubeShortsNamespace
133
- } from "./chunk-6YTSRWRB.js";
136
+ } from "./chunk-CQVKOD3B.js";
134
137
  import {
135
- parseDefinition
136
- } from "./chunk-IW46TW3A.js";
138
+ namedSchemaFailure,
139
+ parseDefinition,
140
+ parseField
141
+ } from "./chunk-VNEJH4NT.js";
137
142
 
138
143
  // src/builders.ts
139
144
  import * as z from "zod";
@@ -601,6 +606,31 @@ var wallet = {
601
606
  ...source,
602
607
  stake: stake.data
603
608
  });
609
+ },
610
+ programAccounts(query) {
611
+ const {
612
+ chain = "solana",
613
+ idl,
614
+ ...rest
615
+ } = query;
616
+ const programAccount = walletProgramAccountSourceSchema.safeParse({
617
+ ...rest,
618
+ chain: chain === "solana" ? solanaMainnet : chain,
619
+ ...idl === void 0 ? {} : { idl: { program: rest.program, source: "pasted", idl } }
620
+ });
621
+ if (!programAccount.success) {
622
+ throw new Error(
623
+ `wallet.programAccounts() ${programAccount.error.issues[0].path.join(".")}: ${programAccount.error.issues[0].message}`
624
+ );
625
+ }
626
+ const source = customSource(walletProgramAccountsNamespace, {
627
+ identities: ["wallet"],
628
+ data: walletProgramAccountSampleSchema
629
+ });
630
+ return customSourceSchema.parse({
631
+ ...source,
632
+ programAccount: programAccount.data
633
+ });
604
634
  }
605
635
  };
606
636
  var pointLedgers = () => ({
@@ -748,7 +778,7 @@ var settings = {
748
778
  * on mainnet or `"solana:EtWTRABZaYq6iMfeYKouRu166VU2xqa1/nft:<address>"` on devnet. Relay checks
749
779
  * it when the collection is published or edited: an EVM chain must be one `ctx.wallet.balance()`
750
780
  * reads and the contract must report the standard through ERC-165 `supportsInterface`; a Solana
751
- * address must be a Core collection or a Metaplex collection NFT on its cluster. Typed as the query's collection, so it passes to
781
+ * address must be a Core collection, a Metaplex collection NFT or a Token-2022 token group's mint on its cluster. Typed as the query's collection, so it passes to
752
782
  * `ctx.wallet.nfts({ collection })` as it is.
753
783
  */
754
784
  nft(options) {
@@ -1146,6 +1176,12 @@ var completionPolicies = { once, keyed, streak, progress, perStation };
1146
1176
  function questBuilder(template) {
1147
1177
  return function defineQuest2(definition) {
1148
1178
  const key = authoringKey(definition);
1179
+ const name = `${template ? "Quest type" : "Quest"} "${key}"`;
1180
+ if (definition.rewards === void 0) {
1181
+ throw new Error(
1182
+ `${name}: rewards is missing. Return [] for a quest that gives none.`
1183
+ );
1184
+ }
1149
1185
  const integrationModules = [
1150
1186
  ...new Set(
1151
1187
  (definition.integrations ?? []).map(
@@ -1239,13 +1275,30 @@ function questBuilder(template) {
1239
1275
  }
1240
1276
  }
1241
1277
  function describe(input) {
1242
- const settings2 = definition.settings.parse(input);
1278
+ try {
1279
+ return describeWith(input);
1280
+ } catch (error) {
1281
+ throw namedSchemaFailure(name, error);
1282
+ }
1283
+ }
1284
+ function describeWith(input) {
1285
+ const { performance } = definition;
1286
+ const settings2 = parseField(
1287
+ "settings",
1288
+ () => definition.settings.parse(input)
1289
+ );
1243
1290
  const values = parseSettings(fields, settings2);
1244
- const rewards = rewardBundleSchema.parse(
1245
- typeof definition.rewards === "function" ? definition.rewards({ settings: settings2 }) : definition.rewards
1291
+ const rewards = parseField(
1292
+ "rewards",
1293
+ () => rewardBundleSchema.parse(
1294
+ typeof definition.rewards === "function" ? definition.rewards({ settings: settings2 }) : definition.rewards
1295
+ )
1246
1296
  );
1247
- const announcements = z3.array(announcementSchema).max(3, "A quest posts at most three announcements").parse(
1248
- (typeof definition.announcements === "function" ? definition.announcements({ settings: settings2 }) : definition.announcements) ?? []
1297
+ const announcements = parseField(
1298
+ "announcements",
1299
+ () => z3.array(announcementSchema).max(3, "A quest posts at most three announcements").parse(
1300
+ (typeof definition.announcements === "function" ? definition.announcements({ settings: settings2 }) : definition.announcements) ?? []
1301
+ )
1249
1302
  );
1250
1303
  const trackerTrigger3 = definition.trigger.kind === "automatic" && definition.trigger.tracker !== void 0;
1251
1304
  for (const announcement of announcements) {
@@ -1291,11 +1344,14 @@ function questBuilder(template) {
1291
1344
  ...announcements.length ? { announcements } : {},
1292
1345
  humanReview: definition.review?.({ settings: settings2 })?.enabled ?? true,
1293
1346
  trigger: definition.trigger,
1294
- ...definition.performance ? {
1295
- performance: contentPerformancePolicySchema.parse({
1296
- metrics: definition.performance.metrics,
1297
- maxAgeMs: definition.performance.maxAgeMs
1298
- })
1347
+ ...performance ? {
1348
+ performance: parseField(
1349
+ "performance",
1350
+ () => contentPerformancePolicySchema.parse({
1351
+ metrics: performance.metrics,
1352
+ maxAgeMs: performance.maxAgeMs
1353
+ })
1354
+ )
1299
1355
  } : {},
1300
1356
  integrations,
1301
1357
  // Written only when it holds a module `integrations` lacks, so a quest declaring known
@@ -1,6 +1,6 @@
1
1
  import * as z from 'zod';
2
- import { b as AttemptStatus, Y as RewardType } from './accounts-DnpKoJCo.js';
3
- import { S as SkipEnrollment } from './tracker-data-CAK942sx.js';
2
+ import { b as AttemptStatus, Y as RewardType } from './accounts-DD4gAOCe.js';
3
+ import { S as SkipEnrollment } from './tracker-data-DQgX3FIc.js';
4
4
 
5
5
  declare const collectionCodeSchema: z.ZodString;
6
6
  declare const collectionPassSchema: z.ZodObject<{
@@ -39,6 +39,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
39
39
  fulfillment: z.ZodObject<{
40
40
  kind: z.ZodString;
41
41
  }, z.core.$loose>;
42
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
42
43
  }, z.core.$loose>;
43
44
  earnedTier: z.ZodString;
44
45
  tier: z.ZodString;
@@ -66,6 +67,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
66
67
  fulfillment: z.ZodObject<{
67
68
  kind: z.ZodString;
68
69
  }, z.core.$loose>;
70
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
69
71
  }, z.core.$loose>;
70
72
  earnedTier: z.ZodString;
71
73
  tier: z.ZodString;
@@ -100,6 +102,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
100
102
  fulfillment: z.ZodObject<{
101
103
  kind: z.ZodString;
102
104
  }, z.core.$loose>;
105
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
103
106
  }, z.core.$loose>;
104
107
  earnedTier: z.ZodString;
105
108
  tier: z.ZodString;
@@ -122,6 +125,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
122
125
  fulfillment: z.ZodObject<{
123
126
  kind: z.ZodString;
124
127
  }, z.core.$loose>;
128
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
125
129
  }, z.core.$loose>;
126
130
  earnedTier: z.ZodString;
127
131
  tier: z.ZodString;
@@ -143,6 +147,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
143
147
  fulfillment: z.ZodObject<{
144
148
  kind: z.ZodString;
145
149
  }, z.core.$loose>;
150
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
146
151
  }, z.core.$loose>;
147
152
  earnedTier: z.ZodString;
148
153
  tier: z.ZodString;
@@ -169,6 +174,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
169
174
  [x: string]: unknown;
170
175
  kind: string;
171
176
  };
177
+ key?: string | null | undefined;
172
178
  };
173
179
  earnedTier: string;
174
180
  tier: string;
@@ -195,6 +201,7 @@ declare const collectionPreviewSchema: z.ZodObject<{
195
201
  [x: string]: unknown;
196
202
  kind: string;
197
203
  };
204
+ key?: string | null | undefined;
198
205
  };
199
206
  earnedTier: string;
200
207
  tier: string;
@@ -985,4 +992,5 @@ declare const automaticSchedulingRetrySchema: z.ZodObject<{
985
992
  reason: z.ZodString;
986
993
  }, z.core.$strict>;
987
994
 
988
- export { type AutomaticCatchUpPreview as A, counterHistorySchema as B, type CollectionPass as C, counterModerationResultSchema as D, counterModerationSchema as E, counterPolicySchema as F, counterProgressSchema as G, counterWindowSchema as H, isRetryableAutomaticOutcome as I, type AutomaticEvent as a, type AutomaticOutcome as b, type CounterAchievement as c, type CounterPolicy as d, type CounterProgress as e, automaticCatchUpConfirmSchema as f, automaticCatchUpInputSchema as g, automaticCatchUpPreviewSchema as h, automaticCatchUpResultSchema as i, automaticEventSchema as j, automaticOutcomePageSchema as k, automaticOutcomeQuerySchema as l, automaticOutcomeSchema as m, automaticSchedulingPageSchema as n, automaticSchedulingQuerySchema as o, automaticSchedulingRetrySchema as p, automaticSchedulingSchema as q, collectionBeginSchema as r, collectionCodeSchema as s, collectionPassSchema as t, collectionPreviewSchema as u, collectionResolveSchema as v, counterAchievementSchema as w, counterContributionSchema as x, counterGoalSchema as y, counterHistoryQuerySchema as z };
995
+ export { counterHistorySchema as B, counterModerationResultSchema as D, counterModerationSchema as E, counterPolicySchema as F, counterProgressSchema as G, counterWindowSchema as H, isRetryableAutomaticOutcome as I, automaticCatchUpConfirmSchema as f, automaticCatchUpInputSchema as g, automaticCatchUpPreviewSchema as h, automaticCatchUpResultSchema as i, automaticEventSchema as j, automaticOutcomePageSchema as k, automaticOutcomeQuerySchema as l, automaticOutcomeSchema as m, automaticSchedulingPageSchema as n, automaticSchedulingQuerySchema as o, automaticSchedulingRetrySchema as p, automaticSchedulingSchema as q, collectionBeginSchema as r, collectionCodeSchema as s, collectionPassSchema as t, collectionPreviewSchema as u, collectionResolveSchema as v, counterAchievementSchema as w, counterContributionSchema as x, counterGoalSchema as y, counterHistoryQuerySchema as z };
996
+ export type { AutomaticCatchUpPreview as A, CollectionPass as C, AutomaticEvent as a, AutomaticOutcome as b, CounterAchievement as c, CounterPolicy as d, CounterProgress as e };
package/dist/avatar.d.ts CHANGED
@@ -1,4 +1,5 @@
1
- import { P as ProfileAvatar, L as LinkedWallet } from './wallet-DQtJelQQ.js';
1
+ import { LinkedWallet } from './index.js';
2
+ import { ProfileAvatar } from './index.js';
2
3
  import 'zod';
3
4
 
4
5
  /**
package/dist/browser.d.ts CHANGED
@@ -1,18 +1,19 @@
1
- import { o as SubmissionStore, f as RelayClientOptions, R as RelayClient } from './client-BMif22WQ.js';
2
- export { C as CosmosChains, D as DiscoveredWallet, E as Eip1193Provider, K as KeplrLike, S as SignInWallet, a as SolanaInjectedProvider, b as StandardWallet, c as StandardWalletAccount, d as cosmosChainList, e as cosmosSigner, f as discoverCosmosWallets, g as discoverEvmWallets, h as discoverSignInWallets, i as discoverSolanaWallets, j as evmSigner, s as solanaSigner, w as walletStandardSolanaSigner } from './wallet-browser-dpmr22Xv.js';
3
- export { E as EmailSignInOption, O as OAuthSignInOption, P as ProviderSignInOption, S as SignInClient, a as SignInIcon, b as SignInMethods, c as SignInOption, d as SignInOptions, e as SignInUnavailable, T as TelegramSignInOption, W as WalletSignInOption, s as signInOptions, t as telegramMiniAppInitData } from './telegram-browser-DLtHPRBI.js';
4
- export { H as HostEnvironment, g as getHostEnvironment } from './host-environment-FN4zg3hw.js';
5
- import { M as MemberSummary } from './participant-activity-DXRq4s6K.js';
6
- import './accounts-DnpKoJCo.js';
1
+ import { SubmissionStore, RelayClientOptions, RelayClient } from './index.js';
2
+ export { C as CosmosChains, D as DiscoveredWallet, E as Eip1193Provider, K as KeplrLike, S as SignInWallet, a as SolanaInjectedProvider, b as StandardWallet, c as StandardWalletAccount, d as cosmosChainList, e as cosmosSigner, f as discoverCosmosWallets, g as discoverEvmWallets, h as discoverSignInWallets, i as discoverSolanaWallets, j as evmSigner, s as solanaSigner, w as walletStandardSolanaSigner } from './wallet-browser-BzPt_Qb5.js';
3
+ export { E as EmailSignInOption, O as OAuthSignInOption, P as ProviderSignInOption, S as SignInClient, a as SignInIcon, b as SignInMethods, c as SignInOption, d as SignInOptions, e as SignInUnavailable, T as TelegramSignInOption, W as WalletSignInOption, s as signInOptions, t as telegramMiniAppInitData } from './telegram-browser-gRMgGs7B.js';
4
+ export { H as HostEnvironment, g as getHostEnvironment } from './host-environment-DUw5-Cvj.js';
5
+ import { MemberSummary } from './index.js';
6
+ import './accounts-DD4gAOCe.js';
7
7
  import 'zod';
8
- import './tracker-data-CAK942sx.js';
9
- import './wallet-DQtJelQQ.js';
10
- import './submission-input-CaL8drIh.js';
11
- import './request-error-D_dUPLwo.js';
12
- import './reward-deliveries-0VvT6LMj.js';
13
- import './catalog-BLGie8Lh.js';
14
- import './action-9Xl0StBg.js';
15
- import './sign-in-providers-C5_753DZ.js';
8
+ import './tracker-data-DQgX3FIc.js';
9
+ import './wallet-CPAjrW4k.js';
10
+ import './submission-input-BD7nORuh.js';
11
+ import './request-error-C24SY7n9.js';
12
+ import './reward-deliveries-DFhYGJdx.js';
13
+ import './catalog-Cf3fHDNn.js';
14
+ import './action-BDFKqGlH.js';
15
+ import './sign-in-providers-C97mRNbG.js';
16
+ import './profiles-CLDKZVFx.js';
16
17
 
17
18
  /**
18
19
  * The member's time at the real instant `at` (default now), in epoch milliseconds: what an app
package/dist/browser.js CHANGED
@@ -12,23 +12,23 @@ import {
12
12
  signInOptions,
13
13
  solanaSigner,
14
14
  walletStandardSolanaSigner
15
- } from "./chunk-CZ7NQ7W7.js";
15
+ } from "./chunk-TCREFRPK.js";
16
16
  import {
17
17
  telegramMiniAppInitData
18
18
  } from "./chunk-FWLQ5XCS.js";
19
- import "./chunk-SD74HD75.js";
20
- import "./chunk-P4TPW4SY.js";
21
- import "./chunk-VRZZB7CQ.js";
19
+ import "./chunk-LGGD7S5T.js";
20
+ import "./chunk-5RLIPTL7.js";
21
+ import "./chunk-LDO5GP7G.js";
22
22
  import {
23
23
  getHostEnvironment
24
24
  } from "./chunk-VAGGGB6B.js";
25
- import "./chunk-7YSVZA7A.js";
26
- import "./chunk-KKHENO57.js";
27
- import "./chunk-R3MNZKNJ.js";
28
- import "./chunk-6UBFSMCM.js";
29
- import "./chunk-55WJVFWC.js";
30
- import "./chunk-6YTSRWRB.js";
31
- import "./chunk-IW46TW3A.js";
25
+ import "./chunk-WVK3G2J2.js";
26
+ import "./chunk-SWLW4VN3.js";
27
+ import "./chunk-ME2KUAVJ.js";
28
+ import "./chunk-PO2ZDY27.js";
29
+ import "./chunk-2A3BJ262.js";
30
+ import "./chunk-CQVKOD3B.js";
31
+ import "./chunk-VNEJH4NT.js";
32
32
  export {
33
33
  browserSubmissionStore,
34
34
  cosmosChainList,
@@ -293,4 +293,5 @@ declare class CapabilityError extends Error {
293
293
  static from(failure: CapabilityFailure): CapabilityError;
294
294
  }
295
295
 
296
- export { type AuthorBudget as A, type Budget as B, CapabilityError as C, type KnownCapabilityErrorCode as K, type MemberCompletion as M, type ResourceSource as R, type TikTokVideoBody as T, type YouTubeShortBody as Y, type Announcement as a, type CapabilityErrorCode as b, type TikTokVideoMetric as c, type YouTubeShortMetric as d, capabilityErrorCodes as e, type CapabilityFailure as f, type ResourceOption as g, announcementSchema as h, announcementTextSchema as i, authorBudgetSchema as j, budgetSchema as k, capabilityFailureSchema as l, completionKeySchema as m, completionPolicySchema as n, discordAnnouncementSchema as o, maxMemberCompletions as p, memberCompletionSchema as q, resourceOptionsSchema as r, resourceRequestSchema as s, resourceSourceSchema as t, telegramAnnouncementSchema as u, tiktokVideoBodySchema as v, tiktokVideoMetrics as w, youtubeShortMetrics as x, youtubeShortBodySchema as y };
296
+ export { CapabilityError as C, capabilityErrorCodes as e, announcementSchema as h, announcementTextSchema as i, authorBudgetSchema as j, budgetSchema as k, capabilityFailureSchema as l, completionKeySchema as m, completionPolicySchema as n, discordAnnouncementSchema as o, maxMemberCompletions as p, memberCompletionSchema as q, resourceOptionsSchema as r, resourceRequestSchema as s, resourceSourceSchema as t, telegramAnnouncementSchema as u, tiktokVideoBodySchema as v, tiktokVideoMetrics as w, youtubeShortMetrics as x, youtubeShortBodySchema as y };
297
+ export type { AuthorBudget as A, Budget as B, KnownCapabilityErrorCode as K, MemberCompletion as M, ResourceSource as R, TikTokVideoBody as T, YouTubeShortBody as Y, Announcement as a, CapabilityErrorCode as b, TikTokVideoMetric as c, YouTubeShortMetric as d, CapabilityFailure as f, ResourceOption as g };
@@ -1,5 +1,5 @@
1
- import { b as AttemptStatus, W as AttemptCodeSource, V as KnownAttemptActionKind, X as IntegrationModuleProvider, Y as RewardType, Z as questDescriptionSchema } from './accounts-DnpKoJCo.js';
2
- import { u as SolanaIdlSource } from './wallet-DQtJelQQ.js';
1
+ import { b as AttemptStatus, W as AttemptCodeSource, V as KnownAttemptActionKind, X as IntegrationModuleProvider, Y as RewardType, Z as questDescriptionSchema } from './accounts-DD4gAOCe.js';
2
+ import { S as SolanaIdlSource } from './wallet-CPAjrW4k.js';
3
3
  import * as z from 'zod';
4
4
 
5
5
  /**
@@ -3703,6 +3703,7 @@ declare const questExperienceSchema: z.ZodObject<{
3703
3703
  fulfillment: z.ZodObject<{
3704
3704
  kind: z.ZodString;
3705
3705
  }, z.core.$loose>;
3706
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3706
3707
  }, z.core.$loose>;
3707
3708
  earnedTier: z.ZodString;
3708
3709
  tier: z.ZodString;
@@ -3730,6 +3731,7 @@ declare const questExperienceSchema: z.ZodObject<{
3730
3731
  fulfillment: z.ZodObject<{
3731
3732
  kind: z.ZodString;
3732
3733
  }, z.core.$loose>;
3734
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3733
3735
  }, z.core.$loose>;
3734
3736
  earnedTier: z.ZodString;
3735
3737
  tier: z.ZodString;
@@ -3764,6 +3766,7 @@ declare const questExperienceSchema: z.ZodObject<{
3764
3766
  fulfillment: z.ZodObject<{
3765
3767
  kind: z.ZodString;
3766
3768
  }, z.core.$loose>;
3769
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3767
3770
  }, z.core.$loose>;
3768
3771
  earnedTier: z.ZodString;
3769
3772
  tier: z.ZodString;
@@ -3786,6 +3789,7 @@ declare const questExperienceSchema: z.ZodObject<{
3786
3789
  fulfillment: z.ZodObject<{
3787
3790
  kind: z.ZodString;
3788
3791
  }, z.core.$loose>;
3792
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3789
3793
  }, z.core.$loose>;
3790
3794
  earnedTier: z.ZodString;
3791
3795
  tier: z.ZodString;
@@ -3807,6 +3811,7 @@ declare const questExperienceSchema: z.ZodObject<{
3807
3811
  fulfillment: z.ZodObject<{
3808
3812
  kind: z.ZodString;
3809
3813
  }, z.core.$loose>;
3814
+ key: z.ZodOptional<z.ZodNullable<z.ZodString>>;
3810
3815
  }, z.core.$loose>;
3811
3816
  earnedTier: z.ZodString;
3812
3817
  tier: z.ZodString;
@@ -3833,6 +3838,7 @@ declare const questExperienceSchema: z.ZodObject<{
3833
3838
  [x: string]: unknown;
3834
3839
  kind: string;
3835
3840
  };
3841
+ key?: string | null | undefined;
3836
3842
  };
3837
3843
  earnedTier: string;
3838
3844
  tier: string;
@@ -3859,6 +3865,7 @@ declare const questExperienceSchema: z.ZodObject<{
3859
3865
  [x: string]: unknown;
3860
3866
  kind: string;
3861
3867
  };
3868
+ key?: string | null | undefined;
3862
3869
  };
3863
3870
  earnedTier: string;
3864
3871
  tier: string;
@@ -5640,4 +5647,5 @@ declare const allocatedQuestSchema: z.ZodObject<{
5640
5647
  id: z.ZodString;
5641
5648
  }, z.core.$strip>;
5642
5649
 
5643
- export { type QuestInteraction as Q, type QuestRewardView as a, type QuestView as b, type QuestCatalog as c, type QuestDraft as d, type QuestInstance as e, allocateQuestSchema as f, allocatedQuestSchema as g, catalogDeploymentPreviewSchema as h, catalogDeploymentSchema as i, collectionSlotDeclarationSchema as j, collectionSlotSchema as k, collectionViewSchema as l, interactionSchema as m, questCatalogSchema as n, questCollectionSchema as o, publishQuestDraftSchema as p, questExperienceSchema as q, questDraftChangesSchema as r, questDraftSchema as s, questInstanceSchema as t, questInteraction as u, questPublicationPreviewSchema as v, questRewardViewSchema as w, questTypeVersionSchema as x, questViewSchema as y, saveQuestDraftSchema as z };
5650
+ export { allocateQuestSchema as f, allocatedQuestSchema as g, catalogDeploymentPreviewSchema as h, catalogDeploymentSchema as i, collectionSlotDeclarationSchema as j, collectionSlotSchema as k, collectionViewSchema as l, interactionSchema as m, questCatalogSchema as n, questCollectionSchema as o, publishQuestDraftSchema as p, questExperienceSchema as q, questDraftChangesSchema as r, questDraftSchema as s, questInstanceSchema as t, questInteraction as u, questPublicationPreviewSchema as v, questRewardViewSchema as w, questTypeVersionSchema as x, questViewSchema as y, saveQuestDraftSchema as z };
5651
+ export type { QuestInteraction as Q, QuestRewardView as a, QuestView as b, QuestCatalog as c, QuestDraft as d, QuestInstance as e };
@@ -12,10 +12,10 @@ import {
12
12
  resourceHandle,
13
13
  responseShape,
14
14
  tierRewardSchema
15
- } from "./chunk-6YTSRWRB.js";
15
+ } from "./chunk-CQVKOD3B.js";
16
16
  import {
17
17
  parseDefinition
18
- } from "./chunk-IW46TW3A.js";
18
+ } from "./chunk-VNEJH4NT.js";
19
19
 
20
20
  // src/engagement.ts
21
21
  import * as z from "zod";
@@ -2,7 +2,7 @@ import {
2
2
  RelayErrorCode,
3
3
  clientError,
4
4
  isRequestError
5
- } from "./chunk-IW46TW3A.js";
5
+ } from "./chunk-VNEJH4NT.js";
6
6
 
7
7
  // src/action.ts
8
8
  function withActionId(value) {
@@ -6,7 +6,7 @@ import {
6
6
  takesSolanaTransaction,
7
7
  trackerDataSchema,
8
8
  xAccountRoles
9
- } from "./chunk-6YTSRWRB.js";
9
+ } from "./chunk-CQVKOD3B.js";
10
10
 
11
11
  // src/quest-shape.ts
12
12
  function validateQuestShape(description, options = {}) {
@@ -1,24 +1,24 @@
1
1
  import {
2
2
  createHttpExchange,
3
3
  uncertainStatuses
4
- } from "./chunk-7YSVZA7A.js";
4
+ } from "./chunk-WVK3G2J2.js";
5
5
  import {
6
6
  MANAGEMENT_TIMEOUT,
7
7
  lifetime,
8
8
  retrying,
9
9
  validTimeout
10
- } from "./chunk-KKHENO57.js";
10
+ } from "./chunk-SWLW4VN3.js";
11
11
  import {
12
12
  base58Bytes,
13
13
  evmAddressSchema,
14
14
  knownResponse,
15
15
  solanaDevnet,
16
16
  solanaMainnet
17
- } from "./chunk-6YTSRWRB.js";
17
+ } from "./chunk-CQVKOD3B.js";
18
18
  import {
19
19
  RequestError,
20
20
  isRequestError
21
- } from "./chunk-IW46TW3A.js";
21
+ } from "./chunk-VNEJH4NT.js";
22
22
 
23
23
  // src/configuration.ts
24
24
  function questConfiguration(release) {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  RelayErrorCode,
3
3
  clientError
4
- } from "./chunk-IW46TW3A.js";
4
+ } from "./chunk-VNEJH4NT.js";
5
5
 
6
6
  // src/identifier.ts
7
7
  import * as z from "zod";
@@ -355,6 +355,7 @@ var walletBalancesNamespace = "wallet-balances";
355
355
  var walletProgramActivityNamespace = "wallet-program-activity";
356
356
  var walletNftsNamespace = "wallet-nfts";
357
357
  var walletStakeNamespace = "wallet-stake";
358
+ var walletProgramAccountsNamespace = "wallet-program-accounts";
358
359
 
359
360
  // src/telegram.ts
360
361
  import * as z6 from "zod";
@@ -848,7 +849,15 @@ var walletNftsSchema = /* @__PURE__ */ (() => responseShape(
848
849
  collection: z7.string(),
849
850
  /** The collection's chain, canonical CAIP-2. */
850
851
  chain: z7.string(),
852
+ /** `metaplex` for every Solana collection, token groups included: `kind` says which kind. */
851
853
  standard: z7.enum(["erc721", "erc1155", "metaplex"]),
854
+ /**
855
+ * Solana only: the kind of collection read. `core` is a Metaplex Core collection,
856
+ * `token-metadata` a Metaplex Token Metadata collection NFT, and `token-group` a Token-2022
857
+ * token group, such as the Seeker Genesis Token's. Absent on EVM collections, and from Relay
858
+ * versions before it.
859
+ */
860
+ kind: z7.string().optional(),
852
861
  /** How many the wallets hold together: the sum over `wallets`. */
853
862
  total: units,
854
863
  wallets: z7.array(
@@ -1259,6 +1268,20 @@ var walletStakeSampleSchema = /* @__PURE__ */ (() => z7.object({
1259
1268
  */
1260
1269
  block: z7.string()
1261
1270
  }))();
1271
+ var walletProgramAccountSampleSchema = /* @__PURE__ */ (() => z7.object({
1272
+ /**
1273
+ * The field's value as a decimal integer string, or null when the wallet has no account at
1274
+ * `pda`: no position.
1275
+ */
1276
+ amount: z7.string().nullable(),
1277
+ /** The program-derived address the tracker's seeds give for this wallet: the account read. */
1278
+ pda: z7.string(),
1279
+ /**
1280
+ * The slot this wallet's answer reflects, at or after the run's pinned slot, as a decimal
1281
+ * integer string.
1282
+ */
1283
+ block: z7.string()
1284
+ }))();
1262
1285
 
1263
1286
  // src/discord.ts
1264
1287
  import * as z8 from "zod";
@@ -2124,6 +2147,17 @@ var walletStakeSourceSchema = /* @__PURE__ */ (() => z12.strictObject({
2124
2147
  "Use a base58 vote account address"
2125
2148
  ).nullable()
2126
2149
  }))();
2150
+ var walletProgramAccountSourceSchema = /* @__PURE__ */ (() => z12.strictObject({
2151
+ chain: solanaClusterSchema,
2152
+ program: z12.string().regex(/^[1-9A-HJ-NP-Za-km-z]{32,44}$/, "Use a base58 program address"),
2153
+ account: z12.string().min(1).max(128),
2154
+ seeds: z12.array(solanaSeedSchema).min(1).max(maxSolanaSeeds).refine(
2155
+ (seeds) => seeds.some((seed) => typeof seed === "object" && "wallet" in seed),
2156
+ "Place the member's wallet in the seeds with { wallet: true }"
2157
+ ),
2158
+ field: z12.string().min(1).max(128),
2159
+ idl: solanaProgramIdlSchema.optional()
2160
+ }))();
2127
2161
  var xSearchSourceSchema = /* @__PURE__ */ (() => z12.object({
2128
2162
  kind: z12.literal("x-search"),
2129
2163
  query: z12.string().trim().min(1).max(2e3)
@@ -2173,7 +2207,12 @@ var customSourceSchema = /* @__PURE__ */ (() => z12.object({
2173
2207
  * The cluster and vote account Relay samples stake for, on `wallet.stake()`'s reserved
2174
2208
  * namespace only. `wallet.stake()` sets it.
2175
2209
  */
2176
- stake: walletStakeSourceSchema.optional()
2210
+ stake: walletStakeSourceSchema.optional(),
2211
+ /**
2212
+ * The program account field Relay samples, on `wallet.programAccounts()`'s reserved namespace
2213
+ * only. `wallet.programAccounts()` sets it.
2214
+ */
2215
+ programAccount: walletProgramAccountSourceSchema.optional()
2177
2216
  }).strict().refine(
2178
2217
  (source) => source.balance === void 0 || source.namespace === walletBalancesNamespace,
2179
2218
  "Only wallet.balances() samples a balance"
@@ -2186,6 +2225,9 @@ var customSourceSchema = /* @__PURE__ */ (() => z12.object({
2186
2225
  ).refine(
2187
2226
  (source) => source.stake === void 0 || source.namespace === walletStakeNamespace,
2188
2227
  "Only wallet.stake() samples stake"
2228
+ ).refine(
2229
+ (source) => source.programAccount === void 0 || source.namespace === walletProgramAccountsNamespace,
2230
+ "Only wallet.programAccounts() samples program accounts"
2189
2231
  ).refine(
2190
2232
  (source) => !source.content || source.data?.properties?.body?.type === "object" && (source.data.required ?? []).includes("body"),
2191
2233
  "A content source's data schema has a required object body"
@@ -2256,7 +2298,16 @@ var knownTrackerSourceResponseSchema = /* @__PURE__ */ (() => z12.discriminatedU
2256
2298
  // Read as stored: a later Relay may sample collections this SDK does not parse.
2257
2299
  nfts: z12.object({ collection: z12.string() }).optional(),
2258
2300
  // Read as stored: a later Relay may sample clusters this SDK does not name.
2259
- stake: z12.object({ chain: z12.string(), voteAccount: z12.string().nullable() }).optional()
2301
+ stake: z12.object({ chain: z12.string(), voteAccount: z12.string().nullable() }).optional(),
2302
+ // Read as stored: a later Relay may sample clusters, seeds or IDLs this SDK does not parse.
2303
+ programAccount: z12.object({
2304
+ chain: z12.string(),
2305
+ program: z12.string(),
2306
+ account: z12.string(),
2307
+ seeds: z12.array(z12.json()),
2308
+ field: z12.string(),
2309
+ idl: z12.object({ program: z12.string(), source: z12.string(), idl: z12.json() }).optional()
2310
+ }).optional()
2260
2311
  }),
2261
2312
  z12.object(discordMessagesSourceSchema.shape),
2262
2313
  z12.object(discordReactionsSourceSchema.shape)
@@ -2408,6 +2459,12 @@ var walletStakeTrackerSourceSchema = /* @__PURE__ */ (() => z12.strictObject({
2408
2459
  ...walletStakeSourceSchema.shape
2409
2460
  }))();
2410
2461
  var stakeTrackerCreateSchema = /* @__PURE__ */ (() => trackerCreateSchema.omit({ query: true }).extend({ source: walletStakeTrackerSourceSchema }))();
2462
+ var walletProgramAccountsTrackerSourceSchema = /* @__PURE__ */ (() => z12.strictObject({
2463
+ kind: z12.literal("wallet-program-accounts"),
2464
+ ...walletProgramAccountSourceSchema.shape,
2465
+ idl: anchorIdlSchema.optional()
2466
+ }))();
2467
+ var programAccountTrackerCreateSchema = /* @__PURE__ */ (() => trackerCreateSchema.omit({ query: true }).extend({ source: walletProgramAccountsTrackerSourceSchema }))();
2411
2468
  var trackerUpdateSchema = /* @__PURE__ */ (() => trackerPropertiesSchema.partial().extend({
2412
2469
  source: managedTrackerSourceSchema.optional(),
2413
2470
  actionId: identifier
@@ -4603,7 +4660,12 @@ var tieredRewardReadSchema = /* @__PURE__ */ (() => z34.object({
4603
4660
  title: z34.string(),
4604
4661
  tiers: z34.array(z34.object({ id: identifier, title: z34.string() }).loose()),
4605
4662
  inventory: z34.object({ kind: z34.string() }).loose(),
4606
- fulfillment: z34.object({ kind: z34.string() }).loose()
4663
+ fulfillment: z34.object({ kind: z34.string() }).loose(),
4664
+ /**
4665
+ * The key given to defineTieredReward, or null for a reward created without one. Management
4666
+ * reads carry it; participant reads and Relay versions before it leave it out.
4667
+ */
4668
+ key: identifier.nullish()
4607
4669
  }).loose())();
4608
4670
  var entitlementReadBase = /* @__PURE__ */ (() => ({
4609
4671
  id: identifier,
@@ -5623,6 +5685,7 @@ export {
5623
5685
  walletProgramActivityNamespace,
5624
5686
  walletNftsNamespace,
5625
5687
  walletStakeNamespace,
5688
+ walletProgramAccountsNamespace,
5626
5689
  telegramSignInMethodsSchema,
5627
5690
  telegramAccountConnectionSchema,
5628
5691
  telegramInitDataSchema,
@@ -5698,6 +5761,7 @@ export {
5698
5761
  walletProgramAccountSchema,
5699
5762
  walletStakeSchema,
5700
5763
  walletStakeSampleSchema,
5764
+ walletProgramAccountSampleSchema,
5701
5765
  lifecycleReasonSchema,
5702
5766
  offsetDateTimeSchema,
5703
5767
  discordMessageSchema,
@@ -5740,6 +5804,7 @@ export {
5740
5804
  walletProgramActivitySourceSchema,
5741
5805
  walletNftSourceSchema,
5742
5806
  walletStakeSourceSchema,
5807
+ walletProgramAccountSourceSchema,
5743
5808
  xSearchSourceSchema,
5744
5809
  customSourceSchema,
5745
5810
  trackerSourceSchema,
@@ -5765,6 +5830,8 @@ export {
5765
5830
  nftTrackerCreateSchema,
5766
5831
  walletStakeTrackerSourceSchema,
5767
5832
  stakeTrackerCreateSchema,
5833
+ walletProgramAccountsTrackerSourceSchema,
5834
+ programAccountTrackerCreateSchema,
5768
5835
  trackerUpdateSchema,
5769
5836
  trackerControlSchema,
5770
5837
  trackerAccountSchema,
@@ -3,10 +3,10 @@ import {
3
3
  limits,
4
4
  resourceHandle,
5
5
  responseShape
6
- } from "./chunk-6YTSRWRB.js";
6
+ } from "./chunk-CQVKOD3B.js";
7
7
  import {
8
8
  parseDefinition
9
- } from "./chunk-IW46TW3A.js";
9
+ } from "./chunk-VNEJH4NT.js";
10
10
 
11
11
  // src/server/analytics.ts
12
12
  import * as z from "zod";
@@ -2,7 +2,7 @@ import {
2
2
  identifier,
3
3
  responseShape,
4
4
  xTweetSchema
5
- } from "./chunk-6YTSRWRB.js";
5
+ } from "./chunk-CQVKOD3B.js";
6
6
 
7
7
  // src/x.ts
8
8
  import * as z from "zod";
@@ -9,7 +9,7 @@ import {
9
9
  rewardBundleSchema,
10
10
  settingsValuesSchema,
11
11
  trackerTriggerContextSchema
12
- } from "./chunk-6YTSRWRB.js";
12
+ } from "./chunk-CQVKOD3B.js";
13
13
 
14
14
  // src/server/attempt-captures.ts
15
15
  import * as z from "zod";