@domino-sdk/relay 1.69.0 → 1.71.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/CHANGELOG.md +28 -0
- package/build.mjs +3 -0
- package/dist/{accounts-DD4gAOCe.d.ts → accounts-COLmXRbW.d.ts} +144 -13
- package/dist/{attempt-captures-CbuCmthd.d.ts → attempt-captures-CVl161qB.d.ts} +3 -2
- package/dist/authoring.d.ts +68 -25
- package/dist/authoring.js +15 -9
- package/dist/{automatic-outcomes-DE3vfi8g.d.ts → automatic-outcomes-5l68PGr1.d.ts} +2 -2
- package/dist/browser.d.ts +9 -9
- package/dist/browser.js +11 -9
- package/dist/{catalog-Cf3fHDNn.d.ts → catalog-BR3g-1H9.d.ts} +41 -2
- package/dist/{chunk-ME2KUAVJ.js → chunk-3KKRXN5E.js} +1 -1
- package/dist/{chunk-CQVKOD3B.js → chunk-74SMLZZ5.js} +723 -685
- package/dist/{chunk-CZ23KRVK.js → chunk-CVJTIVAP.js} +1 -1
- package/dist/{chunk-TCREFRPK.js → chunk-DDID5QX5.js} +153 -4
- package/dist/{chunk-WVK3G2J2.js → chunk-EMKYDGZ3.js} +1 -1
- package/dist/{chunk-2A3BJ262.js → chunk-FGZGL5PG.js} +1 -1
- package/dist/{chunk-GEVARKEV.js → chunk-GHBYWDEZ.js} +8 -1
- package/dist/{chunk-RKTMSTT7.js → chunk-HN7DE2UN.js} +2 -2
- package/dist/{chunk-LGGD7S5T.js → chunk-IDG2VPYG.js} +32 -6
- package/dist/{chunk-SWLW4VN3.js → chunk-KC4UB4ZX.js} +1 -1
- package/dist/{chunk-ODJGTFPY.js → chunk-KIRXE37T.js} +6 -6
- package/dist/{chunk-VAGGGB6B.js → chunk-MDSSIOBC.js} +58 -1
- package/dist/{chunk-BRROI4CH.js → chunk-OFSJYXGI.js} +12 -4
- package/dist/{chunk-LZXDYSUH.js → chunk-PYZSCFMJ.js} +4 -0
- package/dist/{chunk-UGM6DUB2.js → chunk-QMKTYPK6.js} +4 -3
- package/dist/{chunk-PO2ZDY27.js → chunk-TW4RABVS.js} +1 -1
- package/dist/{chunk-AZDZEQFK.js → chunk-UEVZ3TST.js} +29 -2
- package/dist/{chunk-DIXYVGXO.js → chunk-VFHLMNYV.js} +1 -1
- package/dist/{chunk-WNEQEDMU.js → chunk-W6DBNBMT.js} +2 -2
- package/dist/{client-6eSYOl8h.d.ts → client-B__hMWtK.d.ts} +104 -7
- package/dist/{dashboards-DCOAXL54.d.ts → dashboards-DXpjHnq-.d.ts} +3 -3
- package/dist/{deployments-BIfdCMd5.d.ts → deployments-CT2kQloT.d.ts} +199 -3
- package/dist/{identity-integration-BlfOn8rc.d.ts → identity-integration-ClX4oUAu.d.ts} +4 -4
- package/dist/index.d.ts +10 -10
- package/dist/index.js +7 -7
- package/dist/internal.d.ts +44 -26
- package/dist/internal.js +26 -50
- package/dist/{limits-Ctaeq23J.d.ts → limits-B7wbnWhd.d.ts} +1 -1
- package/dist/{offers-COqHGbHm.d.ts → offers-D4pyeY9b.d.ts} +2 -2
- package/dist/portal-proxy.d.ts +2 -2
- package/dist/portal-proxy.js +11 -10
- package/dist/react/index.d.ts +31 -12
- package/dist/react/index.js +116 -41
- package/dist/{reward-deliveries-DFhYGJdx.d.ts → reward-deliveries-HGpj1VFz.d.ts} +1 -1
- package/dist/runtime/authoring.js +1 -1
- package/dist/runtime/chunks/A7G5P76B.js +1 -0
- package/dist/runtime/manifest.json +3 -3
- package/dist/runtime/schema.js +1 -1
- package/dist/schema.d.ts +40 -16
- package/dist/schema.js +9 -7
- package/dist/server/index.d.ts +12 -12
- package/dist/server/index.js +944 -579
- package/dist/{sign-in-providers-C97mRNbG.d.ts → sign-in-providers-lbOXCF8N.d.ts} +2 -2
- package/dist/solana.d.ts +12 -12
- package/dist/solana.js +8 -8
- package/dist/{telegram-browser-gRMgGs7B.d.ts → station-check-in-qBiaftfE.d.ts} +89 -7
- package/dist/{submission-input-BD7nORuh.d.ts → submission-input-U4aIkJuT.d.ts} +2 -2
- package/dist/telegram.d.ts +7 -7
- package/dist/testing.d.ts +15 -11
- package/dist/testing.js +23 -12
- package/dist/{tracker-data-DQgX3FIc.d.ts → tracker-data-2BYXZjsN.d.ts} +3 -3
- package/dist/{transport-BLU8jrhg.d.ts → transport-fszraZPi.d.ts} +1736 -19
- package/dist/{wallet-CPAjrW4k.d.ts → wallet-BqswMAqZ.d.ts} +3 -1
- package/dist/{wallet-browser-BzPt_Qb5.d.ts → wallet-browser-B5r7u3xB.d.ts} +1 -1
- package/package.json +1 -1
- package/dist/runtime/chunks/HKAI5OQA.js +0 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { J as SignInProvider } from './accounts-
|
|
1
|
+
import { J as SignInProvider } from './accounts-COLmXRbW.js';
|
|
2
2
|
import * as z from 'zod';
|
|
3
|
-
import { a as TelegramSignInMethods } from './submission-input-
|
|
3
|
+
import { a as TelegramSignInMethods } from './submission-input-U4aIkJuT.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* `GET /v1/auth/providers`, as `relay.auth.providers()` reads it. Exported as a schema only, for the
|
package/dist/solana.d.ts
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { Rpc, GetAccountInfoApi, GetBlockHeightApi, GetLatestBlockhashApi, GetMinimumBalanceForRentExemptionApi, GetSignatureStatusesApi, SendTransactionApi, GetTransactionApi, TransactionSigner, KeyPairSigner, Address, Signature } from '@solana/kit';
|
|
2
|
-
import { l as SolanaNetwork } from './wallet-
|
|
3
|
-
export { s as solanaDevnet, m as solanaMainnet } from './wallet-
|
|
2
|
+
import { l as SolanaNetwork } from './wallet-BqswMAqZ.js';
|
|
3
|
+
export { s as solanaDevnet, m as solanaMainnet } from './wallet-BqswMAqZ.js';
|
|
4
4
|
import { ManagementClient, WebhookEvent, CompletionReceipt } from './server/index.js';
|
|
5
5
|
import 'zod';
|
|
6
|
-
import './accounts-
|
|
7
|
-
import './tracker-data-
|
|
8
|
-
import './identity-integration-
|
|
9
|
-
import './reward-deliveries-
|
|
6
|
+
import './accounts-COLmXRbW.js';
|
|
7
|
+
import './tracker-data-2BYXZjsN.js';
|
|
8
|
+
import './identity-integration-ClX4oUAu.js';
|
|
9
|
+
import './reward-deliveries-HGpj1VFz.js';
|
|
10
10
|
import './request-error-C24SY7n9.js';
|
|
11
11
|
import './action-BDFKqGlH.js';
|
|
12
|
-
import './limits-
|
|
13
|
-
import './automatic-outcomes-
|
|
12
|
+
import './limits-B7wbnWhd.js';
|
|
13
|
+
import './automatic-outcomes-5l68PGr1.js';
|
|
14
14
|
import './profiles-CLDKZVFx.js';
|
|
15
|
-
import './deployments-
|
|
16
|
-
import './offers-
|
|
17
|
-
import './catalog-
|
|
18
|
-
import './attempt-captures-
|
|
15
|
+
import './deployments-CT2kQloT.js';
|
|
16
|
+
import './offers-D4pyeY9b.js';
|
|
17
|
+
import './catalog-BR3g-1H9.js';
|
|
18
|
+
import './attempt-captures-CVl161qB.js';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The RPC methods the badge helpers call. `createSolanaRpc(url)` from `@solana/kit` answers all of
|
package/dist/solana.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import {
|
|
2
2
|
maxCompletionReceipts,
|
|
3
3
|
walletLinkedEventDataSchema
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
6
|
-
import "./chunk-
|
|
7
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-W6DBNBMT.js";
|
|
5
|
+
import "./chunk-KIRXE37T.js";
|
|
6
|
+
import "./chunk-VFHLMNYV.js";
|
|
7
|
+
import "./chunk-CVJTIVAP.js";
|
|
8
8
|
import "./chunk-MWMCQLCG.js";
|
|
9
|
-
import "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
9
|
+
import "./chunk-3KKRXN5E.js";
|
|
10
|
+
import "./chunk-TW4RABVS.js";
|
|
11
|
+
import "./chunk-FGZGL5PG.js";
|
|
12
12
|
import {
|
|
13
13
|
paginate,
|
|
14
14
|
solanaDevnet,
|
|
15
15
|
solanaMainnet,
|
|
16
16
|
solanaMemoProgram
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-74SMLZZ5.js";
|
|
18
18
|
import "./chunk-VNEJH4NT.js";
|
|
19
19
|
|
|
20
20
|
// src/solana.ts
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { c as AuthProvider, J as SignInProvider } from './accounts-
|
|
2
|
-
import { p as createRelayClient, k as RelayRequestOptions, g as RelayError } from './client-
|
|
3
|
-
import { a as TelegramSignInMethods } from './submission-input-
|
|
1
|
+
import { c as AuthProvider, J as SignInProvider, a as Attempt } from './accounts-COLmXRbW.js';
|
|
2
|
+
import { p as createRelayClient, k as RelayRequestOptions, g as RelayError, R as RelayClient } from './client-B__hMWtK.js';
|
|
3
|
+
import { a as TelegramSignInMethods } from './submission-input-U4aIkJuT.js';
|
|
4
4
|
import { b as ParticipantSession } from './participant-activity-BznrcePT.js';
|
|
5
|
-
import { e as WalletSignInNetwork, g as WalletSigner } from './wallet-
|
|
6
|
-
import { C as CosmosChains } from './wallet-browser-
|
|
5
|
+
import { e as WalletSignInNetwork, g as WalletSigner } from './wallet-BqswMAqZ.js';
|
|
6
|
+
import { C as CosmosChains } from './wallet-browser-B5r7u3xB.js';
|
|
7
7
|
|
|
8
8
|
type Auth = ReturnType<typeof createRelayClient>["auth"];
|
|
9
9
|
/**
|
|
@@ -184,5 +184,87 @@ declare function signInOptions(relay: SignInClient, input?: {
|
|
|
184
184
|
*/
|
|
185
185
|
declare function telegramMiniAppInitData(): string | null;
|
|
186
186
|
|
|
187
|
-
|
|
188
|
-
|
|
187
|
+
/**
|
|
188
|
+
* A station as the scan page names it: its key, and its label when the app gave one.
|
|
189
|
+
*
|
|
190
|
+
* @experimental A minor release can change check-in stations.
|
|
191
|
+
*/
|
|
192
|
+
type StationCheckInStation = {
|
|
193
|
+
key: string;
|
|
194
|
+
label: string;
|
|
195
|
+
};
|
|
196
|
+
/**
|
|
197
|
+
* Why Domino refused a check-in. `rate-limited` and `attempt-pending` pass with time, so the
|
|
198
|
+
* check-in is kept for `retry()`; the rest are final for this code.
|
|
199
|
+
*
|
|
200
|
+
* @experimental A minor release can change check-in stations.
|
|
201
|
+
*/
|
|
202
|
+
type KnownStationCheckInRefusal = "station-unknown" | "station-proof-mismatch" | "station-code-not-set" | "station-revoked" | "station-closed" | "station-code-invalid" | "rate-limited" | "attempt-pending" | "not-found";
|
|
203
|
+
/** @experimental A minor release can change check-in stations. */
|
|
204
|
+
type StationCheckInRefusal = KnownStationCheckInRefusal | (string & {});
|
|
205
|
+
/**
|
|
206
|
+
* Where a scan page's check-in stands. The code itself is never part of it.
|
|
207
|
+
*
|
|
208
|
+
* - `none`: the page was opened without a station's link, and no check-in is waiting.
|
|
209
|
+
* - `sign-in-required`: nobody is signed in. The check-in waits in the tab's session storage and
|
|
210
|
+
* is sent once a member signs in, even after a sign-in that leaves the page.
|
|
211
|
+
* - `checking`: reading the session or sending the check-in.
|
|
212
|
+
* - `checked-in`: Domino took it; `attempt` is the queued attempt, which the quest decides.
|
|
213
|
+
* - `refused`: Domino refused it, with `code`. `retryAfter` is in milliseconds, for `rate-limited`.
|
|
214
|
+
* - `failed`: the check-in could not be sent or its answer was lost (offline, a server error, a
|
|
215
|
+
* timeout). It is kept for `retry()`, which repeats the same action ID.
|
|
216
|
+
*
|
|
217
|
+
* @experimental A minor release can change check-in stations.
|
|
218
|
+
*/
|
|
219
|
+
type StationCheckInState = {
|
|
220
|
+
status: "none";
|
|
221
|
+
} | {
|
|
222
|
+
status: "sign-in-required" | "checking";
|
|
223
|
+
quest: string;
|
|
224
|
+
station: StationCheckInStation;
|
|
225
|
+
} | {
|
|
226
|
+
status: "checked-in";
|
|
227
|
+
quest: string;
|
|
228
|
+
station: StationCheckInStation;
|
|
229
|
+
attempt: Attempt;
|
|
230
|
+
} | {
|
|
231
|
+
status: "refused";
|
|
232
|
+
quest: string;
|
|
233
|
+
station: StationCheckInStation;
|
|
234
|
+
code: StationCheckInRefusal;
|
|
235
|
+
error: RelayError;
|
|
236
|
+
retryAfter?: number;
|
|
237
|
+
} | {
|
|
238
|
+
status: "failed";
|
|
239
|
+
quest: string;
|
|
240
|
+
station: StationCheckInStation;
|
|
241
|
+
error: RelayError;
|
|
242
|
+
};
|
|
243
|
+
/**
|
|
244
|
+
* What the scan page knows besides the link: the stations' labels, such as the `stations` list
|
|
245
|
+
* the quest declares, so a check-in names the station as people know it. A station without one is
|
|
246
|
+
* named by its key.
|
|
247
|
+
*
|
|
248
|
+
* @experimental A minor release can change check-in stations.
|
|
249
|
+
*/
|
|
250
|
+
type StationCheckInOptions = {
|
|
251
|
+
stations?: readonly {
|
|
252
|
+
key: string;
|
|
253
|
+
label: string;
|
|
254
|
+
}[];
|
|
255
|
+
};
|
|
256
|
+
/**
|
|
257
|
+
* A code station's scan page, without React: reads the check-in from the station's link (the
|
|
258
|
+
* address a printed QR code opens, with `quest`, `station` and `code` query parameters), takes the
|
|
259
|
+
* code out of the address bar, and checks the signed-in member in with `relay.quests.checkIn()`.
|
|
260
|
+
* With nobody signed in, it answers `sign-in-required` and keeps the check-in in the tab's session
|
|
261
|
+
* storage: call it again once the member signs in, on this page or on the one sign-in returns
|
|
262
|
+
* to, and it sends the kept check-in. Calling it again after `failed`, or a `rate-limited` or
|
|
263
|
+
* `attempt-pending` refusal, retries with the same action ID. Never rejects.
|
|
264
|
+
*
|
|
265
|
+
* @experimental A minor release can change check-in stations.
|
|
266
|
+
*/
|
|
267
|
+
declare function checkInAtStation(relay: RelayClient, options?: StationCheckInOptions): Promise<StationCheckInState>;
|
|
268
|
+
|
|
269
|
+
export { checkInAtStation as j, signInOptions as s, telegramMiniAppInitData as t };
|
|
270
|
+
export type { EmailSignInOption as E, KnownStationCheckInRefusal as K, OAuthSignInOption as O, ProviderSignInOption as P, SignInClient as S, TelegramSignInOption as T, WalletSignInOption as W, SignInIcon as a, SignInMethods as b, SignInOption as c, SignInOptions as d, SignInUnavailable as e, StationCheckInOptions as f, StationCheckInRefusal as g, StationCheckInState as h, StationCheckInStation as i };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as z from 'zod';
|
|
2
|
-
import { L as LedgerReference, Q as QuestHandle } from './tracker-data-
|
|
3
|
-
import { B as ProjectGroupReference } from './accounts-
|
|
2
|
+
import { L as LedgerReference, Q as QuestHandle } from './tracker-data-2BYXZjsN.js';
|
|
3
|
+
import { B as ProjectGroupReference } from './accounts-COLmXRbW.js';
|
|
4
4
|
|
|
5
5
|
declare const completionPrerequisiteSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
6
6
|
kind: z.ZodLiteral<"completion">;
|
package/dist/telegram.d.ts
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { RelayRequestOptions, RelayClient } from './index.js';
|
|
2
2
|
import { ParticipantSession } from './index.js';
|
|
3
|
-
import './accounts-
|
|
3
|
+
import './accounts-COLmXRbW.js';
|
|
4
4
|
import 'zod';
|
|
5
|
-
import './tracker-data-
|
|
6
|
-
import './wallet-
|
|
7
|
-
import './submission-input-
|
|
5
|
+
import './tracker-data-2BYXZjsN.js';
|
|
6
|
+
import './wallet-BqswMAqZ.js';
|
|
7
|
+
import './submission-input-U4aIkJuT.js';
|
|
8
8
|
import './request-error-C24SY7n9.js';
|
|
9
|
-
import './reward-deliveries-
|
|
10
|
-
import './catalog-
|
|
9
|
+
import './reward-deliveries-HGpj1VFz.js';
|
|
10
|
+
import './catalog-BR3g-1H9.js';
|
|
11
11
|
import './action-BDFKqGlH.js';
|
|
12
|
-
import './sign-in-providers-
|
|
12
|
+
import './sign-in-providers-lbOXCF8N.js';
|
|
13
13
|
import './profiles-CLDKZVFx.js';
|
|
14
14
|
|
|
15
15
|
/**
|
package/dist/testing.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { PointBalance } from './authoring.js';
|
|
1
|
+
import { ag as Decision } from './accounts-COLmXRbW.js';
|
|
2
|
+
import { StationCodeAction, PointBalance } from './authoring.js';
|
|
3
3
|
import { Reward, PointLedgerReference, PointEntry, LeaderboardPage } from './index.js';
|
|
4
4
|
import { pointBalanceSchema, discordMemberSchema, discordMessageSchema, photoResultSchema, TextReviewInput } from './schema.js';
|
|
5
5
|
import { NftCollection, SolanaSeed, WalletCallArgument, WalletEventCondition, WalletReader } from './authoring.js';
|
|
@@ -8,20 +8,20 @@ import * as z from 'zod';
|
|
|
8
8
|
import { CapabilityFailure, memberCompletionSchema } from './schema.js';
|
|
9
9
|
export { C as CapabilityError } from './capability-error-db7kO8-P.js';
|
|
10
10
|
import { xConnectionSchema, xProfileSchema, xPostSchema, ImageReference, imageInspectionSchema, imageComparisonSchema, imageSightingsSchema } from './schema.js';
|
|
11
|
-
export { L as Limits, l as limits } from './limits-
|
|
11
|
+
export { L as Limits, l as limits } from './limits-B7wbnWhd.js';
|
|
12
12
|
import { Tracker, TrackerData, ContentBody, TrackerTriggerContext, TrackerPage } from './authoring.js';
|
|
13
13
|
import { memberIdentitySchema, trackerQuerySchema, trackerPageSchema, trackerSummarySchema, TrackerContentQuery, trackerContentSchema, TrackerAttribution } from './schema.js';
|
|
14
14
|
import { TelegramReader } from './authoring.js';
|
|
15
15
|
import { telegramConnectionSchema, telegramChatMemberSchema } from './schema.js';
|
|
16
16
|
import { profileReferralSchema } from './schema.js';
|
|
17
17
|
import { EvaluationMember } from './authoring.js';
|
|
18
|
-
export { A as AttemptCapture, C as CapturedFact } from './attempt-captures-
|
|
18
|
+
export { A as AttemptCapture, C as CapturedFact } from './attempt-captures-CVl161qB.js';
|
|
19
19
|
import { ParticipantSession, RelayEvent } from './index.js';
|
|
20
20
|
import { Badge } from './index.js';
|
|
21
21
|
import { QuestView } from './index.js';
|
|
22
22
|
import { questExperienceSchema } from './schema.js';
|
|
23
23
|
import './streaks-MAqKHbHC.js';
|
|
24
|
-
import './dashboards-
|
|
24
|
+
import './dashboards-DXpjHnq-.js';
|
|
25
25
|
import './units-CwgsPB_r.js';
|
|
26
26
|
|
|
27
27
|
/** One project time-zone change: from `effectiveAt` on, days are counted in `timeZone`. */
|
|
@@ -736,20 +736,24 @@ type RunQuestOptions<Q extends TestableQuest = TestableQuest> = {
|
|
|
736
736
|
*/
|
|
737
737
|
tracker?: unknown;
|
|
738
738
|
/**
|
|
739
|
-
* The
|
|
740
|
-
* that signed it and the memo's `reference
|
|
741
|
-
*
|
|
742
|
-
*
|
|
743
|
-
*
|
|
739
|
+
* The action that started the attempt, `ctx.action`. A signed Solana transaction is the member's
|
|
740
|
+
* `wallet` that signed it and the memo's `reference`; `signature` and `chain` (mainnet) have
|
|
741
|
+
* defaults. A check-in with a station's code is `{ kind: "station-code", reference }`, with the
|
|
742
|
+
* station's key; the run takes the code as right, since Relay checks it before the quest runs.
|
|
743
|
+
* As in Relay, only a member-submitted `manual()` quest without input takes either. On a quest
|
|
744
|
+
* with `stations`, the reference must name a station that the action's proof proves and that is
|
|
745
|
+
* open at `now`, which stands in for the transaction's block time or the code's submission, and
|
|
746
|
+
* a run without an action is refused, as Relay refuses them.
|
|
744
747
|
*
|
|
745
748
|
* @experimental A minor release can change quest actions.
|
|
746
749
|
*/
|
|
747
750
|
action?: {
|
|
751
|
+
kind?: "solana-transaction";
|
|
748
752
|
wallet: string;
|
|
749
753
|
reference?: string | null;
|
|
750
754
|
signature?: string;
|
|
751
755
|
chain?: SolanaNetwork;
|
|
752
|
-
};
|
|
756
|
+
} | StationCodeAction;
|
|
753
757
|
/** A content quest's performance stage: the metric sample to evaluate. */
|
|
754
758
|
performance?: {
|
|
755
759
|
metrics: Record<string, number>;
|
package/dist/testing.js
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import {
|
|
2
2
|
attemptCaptureSchema
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-GHBYWDEZ.js";
|
|
4
4
|
import {
|
|
5
5
|
parseImageResult
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-HN7DE2UN.js";
|
|
7
7
|
import {
|
|
8
8
|
isParticipantRoute
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-PYZSCFMJ.js";
|
|
10
10
|
import {
|
|
11
11
|
imageRequestSchema,
|
|
12
12
|
xConnectionSchema,
|
|
13
13
|
xPostSchema,
|
|
14
14
|
xProfileSchema,
|
|
15
15
|
xRequestSchema
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-VFHLMNYV.js";
|
|
17
17
|
import {
|
|
18
18
|
CapabilityError
|
|
19
19
|
} from "./chunk-MWMCQLCG.js";
|
|
@@ -22,7 +22,7 @@ import {
|
|
|
22
22
|
participantActivitySchema,
|
|
23
23
|
participantSessionSchema,
|
|
24
24
|
questExperienceSchema
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-TW4RABVS.js";
|
|
26
26
|
import {
|
|
27
27
|
badgeCatalogSchema,
|
|
28
28
|
badgeSchema,
|
|
@@ -86,7 +86,7 @@ import {
|
|
|
86
86
|
walletProgramAccountSchema,
|
|
87
87
|
walletStakeSchema,
|
|
88
88
|
walletTransactionsSchema
|
|
89
|
-
} from "./chunk-
|
|
89
|
+
} from "./chunk-74SMLZZ5.js";
|
|
90
90
|
import {
|
|
91
91
|
RelayErrorCode
|
|
92
92
|
} from "./chunk-VNEJH4NT.js";
|
|
@@ -1360,23 +1360,34 @@ function hostedRun(quest, options) {
|
|
|
1360
1360
|
trigger,
|
|
1361
1361
|
options.input
|
|
1362
1362
|
);
|
|
1363
|
+
const code = options.action?.kind === "station-code";
|
|
1363
1364
|
if (options.action && !takesSolanaTransaction(trigger)) {
|
|
1364
1365
|
throw new TestSetupError(
|
|
1365
|
-
`Quest "${quest.key}" takes no Solana transaction: Relay accepts one only for a member-submitted manual() quest without input`
|
|
1366
|
+
code ? `Quest "${quest.key}" takes no check-in: Relay accepts a station's code only for a member-submitted manual() quest without input` : `Quest "${quest.key}" takes no Solana transaction: Relay accepts one only for a member-submitted manual() quest without input`
|
|
1366
1367
|
);
|
|
1367
1368
|
}
|
|
1368
1369
|
const stations = questStationsSchema.optional().parse(release.stations);
|
|
1369
|
-
|
|
1370
|
+
if (code && !stations) {
|
|
1371
|
+
throw new TestSetupError(
|
|
1372
|
+
`Quest "${quest.key}" has no stations, so it takes no check-in with a station's code (station-unknown)`
|
|
1373
|
+
);
|
|
1374
|
+
}
|
|
1375
|
+
const station = stations && stationRefusal(
|
|
1376
|
+
stations,
|
|
1377
|
+
options.action?.reference ?? null,
|
|
1378
|
+
now,
|
|
1379
|
+
code ? "code" : "transaction"
|
|
1380
|
+
);
|
|
1370
1381
|
if (station) {
|
|
1371
1382
|
throw new TestSetupError(`${station.message} (${station.code})`);
|
|
1372
1383
|
}
|
|
1373
|
-
const action = options.action ? {
|
|
1384
|
+
const action = !options.action ? null : options.action.kind === "station-code" ? { kind: "station-code", reference: options.action.reference } : {
|
|
1374
1385
|
kind: "solana-transaction",
|
|
1375
1386
|
chain: options.action.chain ?? solanaMainnet,
|
|
1376
1387
|
signature: options.action.signature ?? defaultSignature,
|
|
1377
1388
|
wallet: options.action.wallet,
|
|
1378
1389
|
reference: options.action.reference ?? null
|
|
1379
|
-
}
|
|
1390
|
+
};
|
|
1380
1391
|
const performance = options.performance ? contentPerformanceSnapshotSchema.parse({
|
|
1381
1392
|
contentAttempt: "attempt_content",
|
|
1382
1393
|
observation: "observation_test",
|
|
@@ -1936,8 +1947,8 @@ async function replayAttempt(quest, capture, options = {}) {
|
|
|
1936
1947
|
member: context.member,
|
|
1937
1948
|
input: context.input,
|
|
1938
1949
|
tracker: context.tracker,
|
|
1939
|
-
// Relay records
|
|
1940
|
-
action: context.action ?? null,
|
|
1950
|
+
// Relay records Solana transaction actions, and a code check-in as its station.
|
|
1951
|
+
action: context.station === void 0 ? context.action ?? null : { kind: "station-code", reference: context.station },
|
|
1941
1952
|
eligibleAt: context.eligibleAt,
|
|
1942
1953
|
segments: context.calendar.segments,
|
|
1943
1954
|
...context.performance ? { performance: context.performance } : {},
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as z from 'zod';
|
|
2
|
-
import { n as SolanaSeed, S as SolanaIdlSource } from './wallet-
|
|
2
|
+
import { n as SolanaSeed, S as SolanaIdlSource } from './wallet-BqswMAqZ.js';
|
|
3
3
|
|
|
4
4
|
declare const resourceKind: unique symbol;
|
|
5
5
|
/** A resource defined in code. The type-only marker never changes its serialized shape. */
|
|
@@ -2371,5 +2371,5 @@ declare function schemaCheckedReader(reader: TrackerReader): TrackerReader;
|
|
|
2371
2371
|
*/
|
|
2372
2372
|
declare function whereSchemaIssue(schema: TrackerDataSchema, where: TrackerWhere | undefined): string | null;
|
|
2373
2373
|
|
|
2374
|
-
export { trackerDataSchema as A, trackerTriggerContextSchema as D,
|
|
2375
|
-
export type {
|
|
2374
|
+
export { trackerDataSchema as A, trackerTriggerContextSchema as D, sourceContent as E, whereSettings as F, trackerContentSchema as a$, beneficiaryRole as aA, contentMetricNameSchema as aB, customContentSchema as aC, defaultTriggerMode as aD, identityKindSchema as aE, isAppIdentityKind as aF, isKnownTrackerSource as aG, knownIdentityKinds as aH, managedTrackerCreateSchema as aI, managedTrackerSource as aJ, managedTrackerSourceKinds as aK, managedTrackerSourceSchema as aL, memberIdentitySchema as aM, nftTrackerCreateSchema as aN, openIdentityKindSchema as aO, programAccountTrackerCreateSchema as aP, programActivityTrackerCreateSchema as aQ, publishedTrackerSchema as aR, sourceIdentities as aS, stakeTrackerCreateSchema as aT, trackerAccountSchema as aU, trackerArtifactSchema as aV, trackerAttributionSchema as aW, trackerBoundSchema as aX, trackerConditionSchema as aY, trackerContentQuerySchema as aZ, trackerContentReadSchema as a_, accountRoleSchema as ay, appIdentityKindSchema as az, trackerContentStageSchema as b0, trackerControlSchema as b1, trackerCreateSchema as b2, trackerDataMaxBranches as b3, trackerDataMaxEntries as b4, trackerDataSchemaSchema as b5, trackerDefinitionResponseSchema as b6, trackerEvidenceSchema as b7, trackerIngestResultSchema as b8, trackerIngestSchema as b9, triggerAdmission as bA, triggerEnrollmentSchema as bB, triggerHistoricalSchema as bC, triggerMode as bD, triggerSinceSchema as bE, walletBalanceSourceSchema as bF, walletNftSourceSchema as bG, walletNftsTrackerSourceSchema as bH, walletProgramAccountSourceSchema as bI, walletProgramAccountsTrackerSourceSchema as bJ, walletProgramActivitySourceSchema as bK, walletProgramActivityTrackerSourceSchema as bL, walletStakeSourceSchema as bM, walletStakeTrackerSourceSchema as bN, whereConditions as bO, xAccountRoles as bP, xContentMetrics as bQ, xTweetSchema as bR, schemaCheckedReader as bT, trackerDataBatchSteps as bU, trackerDataIssue as bV, trackerDataIssues as bW, trackerDataPathTypes as bX, trackerDataRecordSteps as bY, whereSchemaIssue as bZ, trackerOutcomePageSchema as ba, trackerOutcomeQuerySchema as bb, trackerOutcomeRetrySchema as bc, trackerOutcomeSchema as bd, trackerPageSchema as be, trackerPreviewInputSchema as bf, trackerPreviewLimits as bg, trackerPreviewSchema as bh, trackerPropertiesSchema as bi, trackerQuerySchema as bj, trackerRecordAccountSchema as bk, trackerRecordInputSchema as bl, trackerRecordSchema as bm, trackerSkipCodes as bn, trackerSourceKinds as bo, trackerSourceResponseSchema as bp, trackerSourceSchema as bq, trackerStatusSchema as br, trackerSummarySchema as bs, trackerTriggerModeSchema as bt, trackerTriggerOutcomePageSchema as bu, trackerTriggerOutcomeQuerySchema as bv, trackerTriggerPolicySchema as bw, trackerTriggerRecordSchema as bx, trackerUpdateSchema as by, trackerWhereSchema as bz, customSourceSchema as c, xSearchSourceSchema as k, trackerDefinitionSchema as t, xContentBodySchema as x };
|
|
2375
|
+
export type { NftTrackerCreateInput as $, BadgeHandle as B, ContentBody as C, GroupHandle as G, AccountRole as H, IdentityKind as I, AppIdentityKind as J, KnownSkipEnrollment as K, LedgerReference as L, MemberIdentity as M, Bound as N, OpenIdentityKind as O, Condition as P, QuestHandle as Q, ResourceHandle as R, SkipEnrollment as S, TrackerSkipCode as T, DataLeaves as U, KnownIdentityKind as V, WithRecordData as W, XTweet as X, ManagedTrackerCreateInput as Y, ManagedTrackerSource as Z, ManagedTrackerSourceKind as _, KnownTrackerSkipCode as a, ProgramAccountTrackerCreateInput as a0, ProgramActivityTrackerCreateInput as a1, StakeTrackerCreateInput as a2, TrackerAccount as a3, TrackerAttribution as a4, TrackerBound as a5, TrackerCondition as a6, TrackerContent as a7, TrackerContentQuery as a8, TrackerCreateInput as a9, TrackerDataIssue as aa, TrackerDefinition as ab, TrackerDefinitionResponse as ac, TrackerOutcome as ad, TrackerOutcomeQuery as ae, TrackerPreview as af, TrackerPreviewInput as ag, TrackerQuery as ah, TrackerRecord as ai, TrackerSourceKind as aj, TrackerSourceResponse as ak, TrackerStatus as al, TrackerTriggerOutcomePage as am, TrackerTriggerOutcomeQuery as an, TrackerUpdateInput as ao, TrackerWhere as ap, TriggerEnrollment as aq, TriggerHistorical as ar, TriggerSince as as, TypedTrackerRecord as at, WalletNftsTrackerSource as au, WalletProgramAccountsTrackerSource as av, WalletProgramActivityTrackerSource as aw, WalletStakeTrackerSource as ax, TrackerDataSchema as b, TrackerDataBudget as bS, WithContent as d, WithAccountRoles as e, TrackerSource as f, Tracker as g, TrackerData as h, SourceRoles as i, LedgerHandle as j, XContentMetric as l, TrackerTriggerPolicy as m, Where as n, ReferralHandle as o, TrackerTriggerContext as p, TrackerReader as q, TrackerTriggerMode as r, RoleOf as s, WhereSetting as u, ContentMetricName as v, LedgerSetting as w, TrackerPage as y, TrackerReadQuery as z };
|