@domino-sdk/relay 1.53.1 → 1.54.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.
@@ -48,7 +48,7 @@ import {
48
48
  participantExchangeSchema,
49
49
  questConfiguration,
50
50
  sequenceCursorSchema
51
- } from "../chunk-MP2ZF5U6.js";
51
+ } from "../chunk-TL5TL5RD.js";
52
52
  import {
53
53
  parseImageExtraction,
54
54
  parseImageResult
@@ -152,7 +152,7 @@ import {
152
152
  telegramChatsSchema
153
153
  } from "../chunk-2NUD237O.js";
154
154
  import "../chunk-XFAYQFRO.js";
155
- import "../chunk-JYJAS4E3.js";
155
+ import "../chunk-RP4LLEON.js";
156
156
  import "../chunk-53JMTUWG.js";
157
157
  import {
158
158
  CompletionSourceKind,
@@ -496,6 +496,10 @@ var testMemberAcceptAnywaySchema = z6.object({
496
496
  actionId: identifier,
497
497
  attempt: identifier
498
498
  }).strict();
499
+ var testMemberReferralAcceptSchema = z6.union([
500
+ z6.object({ actionId: identifier, code: identifier }).strict(),
501
+ z6.object({ actionId: identifier, inviter: identifier }).strict()
502
+ ]);
499
503
  var testMemberResetSchema = z6.object({ actionId: identifier }).strict();
500
504
  var testMemberAdvanceSchema = z6.object({
501
505
  actionId: identifier,
@@ -1081,35 +1085,204 @@ var promotionHistoryPageSchema = z10.object({
1081
1085
  nextCursor: pageCursorSchema.nullable()
1082
1086
  });
1083
1087
 
1088
+ // src/server/analytics.ts
1089
+ import * as z11 from "zod";
1090
+ function once(build) {
1091
+ let built;
1092
+ return () => built ??= build();
1093
+ }
1094
+ function lazyShape(builders) {
1095
+ const shape = {};
1096
+ for (const [key, build] of Object.entries(builders)) {
1097
+ Object.defineProperty(shape, key, {
1098
+ get: once(build),
1099
+ enumerable: true,
1100
+ configurable: true
1101
+ });
1102
+ }
1103
+ return shape;
1104
+ }
1105
+ var analyticsRanges = ["7d", "30d", "90d", "all"];
1106
+ var amount = once(() => z11.number().int().safe());
1107
+ var amounts = once(() => z11.array(amount()));
1108
+ var instant = once(() => z11.iso.datetime({ offset: true }));
1109
+ var analyticsQuerySchema = z11.strictObject(
1110
+ lazyShape({
1111
+ range: () => z11.enum(analyticsRanges),
1112
+ /** A point ledger's key or ID. Defaults to the first ledger that is not archived. */
1113
+ ledger: () => identifier.optional()
1114
+ })
1115
+ );
1116
+ var metric2 = once(
1117
+ () => z11.object({
1118
+ total: amount(),
1119
+ previousTotal: amount().optional(),
1120
+ series: amounts()
1121
+ })
1122
+ );
1123
+ var optionalMetric = once(() => metric2().optional());
1124
+ var bucket = once(
1125
+ () => z11.object({
1126
+ /** The period's label in its time zone, such as `2026-10-08@Europe/Budapest` or `2026-W41@UTC`. */
1127
+ key: z11.string(),
1128
+ start: instant(),
1129
+ end: instant()
1130
+ })
1131
+ );
1132
+ var quest = once(
1133
+ () => z11.object({
1134
+ quest: identifier,
1135
+ title: z11.string(),
1136
+ /** Attempts created in the range. */
1137
+ attempts: amount(),
1138
+ /** Completions in the range that were never revoked. */
1139
+ completions: amount(),
1140
+ /** Attempts decided in the range: accepted, progressed or rejected. */
1141
+ decided: amount(),
1142
+ /** Attempts rejected in the range. */
1143
+ rejected: amount(),
1144
+ /** Attempts created in the range that went to staff review. */
1145
+ needsReview: amount(),
1146
+ /** `rejected ÷ decided`, or null below 10 decided attempts. */
1147
+ rejectionRate: z11.number().min(0).max(1).nullable(),
1148
+ /**
1149
+ * The 5 most common rejections, most frequent first. Rejections with a code (an evaluator's
1150
+ * reject code or one Relay writes, such as `budget-exhausted`) group by it, and `reason` is the
1151
+ * latest rejection's reason; rejections without one group by their exact reason.
1152
+ */
1153
+ topReasons: z11.array(
1154
+ z11.object({
1155
+ reason: z11.string(),
1156
+ code: z11.string().nullable(),
1157
+ count: amount()
1158
+ })
1159
+ ),
1160
+ /** Rejections by who made them: the evaluator, staff, an exhausted budget, an expired deferral. */
1161
+ rejectionsBySource: z11.object({
1162
+ evaluator: amount(),
1163
+ staff: amount(),
1164
+ budget: amount(),
1165
+ expired: amount()
1166
+ }),
1167
+ /** Attempts and completions per bucket. */
1168
+ series: z11.object({ attempts: amounts(), completions: amounts() })
1169
+ })
1170
+ );
1171
+ var analyticsReadSchema = z11.object(
1172
+ lazyShape({
1173
+ range: () => z11.object({
1174
+ key: z11.enum(analyticsRanges),
1175
+ from: instant(),
1176
+ /** Now, by the database's clock, when the read ran. */
1177
+ to: instant(),
1178
+ bucket: z11.enum(["day", "week"]),
1179
+ /** The project calendar's time zone now. Buckets before a time zone change follow the old one. */
1180
+ timeZone: z11.string(),
1181
+ buckets: z11.array(bucket())
1182
+ }),
1183
+ /** The range of equal length before this one, which `previousTotal` covers. Absent for `all`. */
1184
+ previous: () => z11.object({ from: instant(), to: instant() }).optional(),
1185
+ members: () => z11.object({
1186
+ /** Members who joined the project. */
1187
+ signUps: metric2(),
1188
+ /** Distinct members with an attempt; the total counts each member once over the range. */
1189
+ active: metric2()
1190
+ }),
1191
+ quests: () => z11.object({
1192
+ attempts: metric2(),
1193
+ completions: metric2(),
1194
+ rejections: metric2(),
1195
+ needsReview: metric2(),
1196
+ /** Quests with activity in the range, most attempted first. */
1197
+ byQuest: z11.array(quest())
1198
+ }),
1199
+ points: () => z11.object({
1200
+ /** The project's point ledgers, oldest first. */
1201
+ ledgers: z11.array(
1202
+ z11.object({ key: identifier, name: z11.string(), archived: z11.boolean() })
1203
+ ),
1204
+ /** The ledger this section reads, or null when the project has none to read. */
1205
+ ledger: identifier.nullable(),
1206
+ /** Whether the ledger has a spend entry. `spent` and `net` are present only when it does. */
1207
+ hasSpending: z11.boolean(),
1208
+ /** Points in award entries. */
1209
+ awarded: metric2(),
1210
+ /** Points in spend entries, as a positive number. */
1211
+ spent: optionalMetric(),
1212
+ /** Every entry's signed amount: awards, spends, adjustments and reversals. */
1213
+ net: optionalMetric(),
1214
+ /** Distinct members awarded points; the total counts each member once over the range. */
1215
+ membersEarning: metric2()
1216
+ }),
1217
+ /** Fulfilled offer redemptions. Present only when the project has an offer. */
1218
+ offers: () => z11.object({
1219
+ redemptions: metric2(),
1220
+ /** Every offer, most redeemed first. */
1221
+ byOffer: z11.array(
1222
+ z11.object({
1223
+ offer: identifier,
1224
+ title: z11.string(),
1225
+ redemptions: amount(),
1226
+ series: amounts()
1227
+ })
1228
+ )
1229
+ }).optional(),
1230
+ /** Present only when the project has a referral program. */
1231
+ referrals: () => z11.object({
1232
+ /** Referrals accepted. */
1233
+ accepted: metric2(),
1234
+ /** Active qualifications, by when they first qualified; suspended referrals still count. */
1235
+ qualified: metric2(),
1236
+ /**
1237
+ * Of the referrals accepted in the range (and in the range before), how many have an
1238
+ * active qualification now, each counted once; suspended referrals still count.
1239
+ * `acceptedQualified.total ÷ accepted.total` is the share of the range's friends who have
1240
+ * qualified since, never above 1.
1241
+ */
1242
+ acceptedQualified: z11.object({
1243
+ total: amount(),
1244
+ previousTotal: amount().optional()
1245
+ })
1246
+ }).optional(),
1247
+ /** Present only in the test environment. */
1248
+ testEnvironment: () => z11.object({
1249
+ /** When a test member was last reset, deleting their history, or null. */
1250
+ lastResetAt: instant().nullable(),
1251
+ /** Test members whose clock is advanced, so their activity can be dated in the future. */
1252
+ shiftedClockMembers: amount()
1253
+ }).optional()
1254
+ })
1255
+ );
1256
+
1084
1257
  // src/server/index.ts
1085
- import * as z16 from "zod";
1258
+ import * as z17 from "zod";
1086
1259
 
1087
1260
  // src/server/hosting.ts
1088
- import * as z13 from "zod";
1261
+ import * as z14 from "zod";
1089
1262
 
1090
1263
  // src/server/schedules.ts
1091
- import * as z11 from "zod";
1264
+ import * as z12 from "zod";
1092
1265
  import { Cron } from "croner";
1093
1266
  var APP_SCHEDULE_LIMIT = 10;
1094
1267
  var APP_SCHEDULE_MIN_INTERVAL = 3e5;
1095
1268
  var APP_SCHEDULE_TIMEOUT = 3e4;
1096
- var appScheduleNameSchema = z11.string().regex(/^[a-z][a-z0-9-]{0,63}$/);
1097
- var appSchedulePathSchema = z11.string().min(2).max(512).refine((path) => {
1269
+ var appScheduleNameSchema = z12.string().regex(/^[a-z][a-z0-9-]{0,63}$/);
1270
+ var appSchedulePathSchema = z12.string().min(2).max(512).refine((path) => {
1098
1271
  if (!/^\/[a-zA-Z0-9_/-]+$/.test(path) || path.startsWith("//")) {
1099
1272
  return false;
1100
1273
  }
1101
1274
  return path.split("/").slice(1).every((part) => part.length > 0) && new URL(path, "https://app.invalid").pathname === path;
1102
1275
  }, "Expected an absolute route path without a query or hidden segments");
1103
1276
  function interval(value) {
1104
- const amount = Number(value.slice(0, -1));
1277
+ const amount2 = Number(value.slice(0, -1));
1105
1278
  const unit = value.slice(-1);
1106
- return amount * (unit === "m" ? 6e4 : unit === "h" ? 36e5 : 864e5);
1279
+ return amount2 * (unit === "m" ? 6e4 : unit === "h" ? 36e5 : 864e5);
1107
1280
  }
1108
- var everySchema = z11.string().regex(/^[1-9]\d{0,3}[mhd]$/).refine(
1281
+ var everySchema = z12.string().regex(/^[1-9]\d{0,3}[mhd]$/).refine(
1109
1282
  (value) => interval(value) >= APP_SCHEDULE_MIN_INTERVAL && interval(value) <= 365 * 864e5,
1110
1283
  "Use an interval from 5 minutes to 365 days, such as 5m, 1h or 1d"
1111
1284
  );
1112
- var cronSchema = z11.string().max(120).refine((value) => {
1285
+ var cronSchema = z12.string().max(120).refine((value) => {
1113
1286
  const fields = value.trim().split(/\s+/);
1114
1287
  if (fields.length !== 5 || fields.some((field) => !/^[\d*,/-]+$/.test(field))) {
1115
1288
  return false;
@@ -1134,15 +1307,15 @@ var cronSchema = z11.string().max(120).refine((value) => {
1134
1307
  var declaration = {
1135
1308
  name: appScheduleNameSchema,
1136
1309
  path: appSchedulePathSchema,
1137
- description: z11.string().min(1).max(500)
1310
+ description: z12.string().min(1).max(500)
1138
1311
  };
1139
- var everySchedule = z11.object({ ...declaration, every: everySchema });
1140
- var cronSchedule = z11.object({ ...declaration, cron: cronSchema });
1141
- var appScheduleSchema = z11.union([
1312
+ var everySchedule = z12.object({ ...declaration, every: everySchema });
1313
+ var cronSchedule = z12.object({ ...declaration, cron: cronSchema });
1314
+ var appScheduleSchema = z12.union([
1142
1315
  everySchedule.strict(),
1143
1316
  cronSchedule.strict()
1144
1317
  ]);
1145
- var appSchedulesSchema = z11.array(appScheduleSchema).max(APP_SCHEDULE_LIMIT).refine(
1318
+ var appSchedulesSchema = z12.array(appScheduleSchema).max(APP_SCHEDULE_LIMIT).refine(
1146
1319
  (items) => new Set(items.map((item) => item.name)).size === items.length,
1147
1320
  "Schedule names must be unique"
1148
1321
  );
@@ -1159,25 +1332,25 @@ function nextScheduleRun(schedule, after) {
1159
1332
  }
1160
1333
  return next.getTime();
1161
1334
  }
1162
- var appScheduleStateSchema = z11.enum(["active", "paused", "archived"]);
1335
+ var appScheduleStateSchema = z12.enum(["active", "paused", "archived"]);
1163
1336
  var APP_SCHEDULE_RESULT_BYTES = 16384;
1164
- var appScheduleDiagnosticSchema = z11.object({
1165
- level: z11.enum(["error", "warning", "info"]),
1166
- message: z11.string().min(1).max(500),
1337
+ var appScheduleDiagnosticSchema = z12.object({
1338
+ level: z12.enum(["error", "warning", "info"]),
1339
+ message: z12.string().min(1).max(500),
1167
1340
  /** What the line is about, such as a member, record or tracker ID. */
1168
- subject: z11.string().min(1).max(200).optional(),
1341
+ subject: z12.string().min(1).max(200).optional(),
1169
1342
  /** A stable code the app chooses, such as `ingest-timeout`. */
1170
- code: z11.string().min(1).max(100).optional()
1343
+ code: z12.string().min(1).max(100).optional()
1171
1344
  });
1172
- var appScheduleResultSchema = z11.object({
1173
- outcome: z11.enum(["succeeded", "partial", "failed"]),
1174
- summary: z11.string().min(1).max(500).optional(),
1345
+ var appScheduleResultSchema = z12.object({
1346
+ outcome: z12.enum(["succeeded", "partial", "failed"]),
1347
+ summary: z12.string().min(1).max(500).optional(),
1175
1348
  /** Counts and gauges, such as processed and failed members. */
1176
- metrics: z11.record(z11.string().regex(/^[A-Za-z][\w.-]{0,63}$/), z11.number()).refine(
1349
+ metrics: z12.record(z12.string().regex(/^[A-Za-z][\w.-]{0,63}$/), z12.number()).refine(
1177
1350
  (metrics) => Object.keys(metrics).length <= 50,
1178
1351
  "Report at most 50 metrics"
1179
1352
  ).optional(),
1180
- diagnostics: z11.array(appScheduleDiagnosticSchema).max(50).optional()
1353
+ diagnostics: z12.array(appScheduleDiagnosticSchema).max(50).optional()
1181
1354
  });
1182
1355
  function scheduleResult(result) {
1183
1356
  const body = JSON.stringify(appScheduleResultSchema.parse(result));
@@ -1190,41 +1363,41 @@ function scheduleResult(result) {
1190
1363
  headers: { "Content-Type": "application/json" }
1191
1364
  });
1192
1365
  }
1193
- var appScheduleRunSchema = z11.object({
1194
- id: z11.string().uuid(),
1195
- build: z11.string().uuid(),
1196
- startedAt: z11.number(),
1197
- scheduledAt: z11.number(),
1198
- manual: z11.boolean(),
1199
- status: z11.enum(["queued", "running", "succeeded", "failed", "uncertain"]),
1200
- duration: z11.number().nullable(),
1366
+ var appScheduleRunSchema = z12.object({
1367
+ id: z12.string().uuid(),
1368
+ build: z12.string().uuid(),
1369
+ startedAt: z12.number(),
1370
+ scheduledAt: z12.number(),
1371
+ manual: z12.boolean(),
1372
+ status: z12.enum(["queued", "running", "succeeded", "failed", "uncertain"]),
1373
+ duration: z12.number().nullable(),
1201
1374
  /** Why the run failed or is uncertain, or why Relay ignored the app's result. */
1202
- error: z11.string().nullable(),
1375
+ error: z12.string().nullable(),
1203
1376
  /** The app's JSON answer when it sent a valid result. Absent on runs from before results. */
1204
1377
  result: appScheduleResultSchema.nullable().optional()
1205
1378
  });
1206
- var appScheduleRunsSchema = z11.object({
1379
+ var appScheduleRunsSchema = z12.object({
1207
1380
  /** Newest first: the latest twenty runs of one schedule, including a queued or running one. */
1208
- runs: z11.array(appScheduleRunSchema)
1381
+ runs: z12.array(appScheduleRunSchema)
1209
1382
  });
1210
- var appScheduleListSchema = z11.object({
1383
+ var appScheduleListSchema = z12.object({
1211
1384
  state: appScheduleStateSchema,
1212
- schedules: z11.array(
1213
- z11.object({
1214
- declaration: z11.union([everySchedule, cronSchedule]),
1215
- nextRun: z11.number().nullable(),
1216
- blocked: z11.boolean(),
1385
+ schedules: z12.array(
1386
+ z12.object({
1387
+ declaration: z12.union([everySchedule, cronSchedule]),
1388
+ nextRun: z12.number().nullable(),
1389
+ blocked: z12.boolean(),
1217
1390
  lastRun: appScheduleRunSchema.nullable()
1218
1391
  })
1219
1392
  )
1220
1393
  });
1221
- var scheduledInvocationSchema = z11.object({
1222
- id: z11.string().uuid(),
1223
- build: z11.string().uuid(),
1394
+ var scheduledInvocationSchema = z12.object({
1395
+ id: z12.string().uuid(),
1396
+ build: z12.string().uuid(),
1224
1397
  name: appScheduleNameSchema,
1225
- scheduledAt: z11.number().int(),
1226
- startedAt: z11.number().int(),
1227
- manual: z11.boolean()
1398
+ scheduledAt: z12.number().int(),
1399
+ startedAt: z12.number().int(),
1400
+ manual: z12.boolean()
1228
1401
  }).strict();
1229
1402
  async function verifyScheduledRequest(request, key) {
1230
1403
  const signature = request.headers.get("X-Domino-Schedule-Signature");
@@ -1289,7 +1462,7 @@ ${body}`)
1289
1462
  }
1290
1463
 
1291
1464
  // src/server/starters.ts
1292
- import * as z12 from "zod";
1465
+ import * as z13 from "zod";
1293
1466
  var starterTemplates = [
1294
1467
  {
1295
1468
  id: "campaign",
@@ -1322,63 +1495,63 @@ var starterTemplates = [
1322
1495
  summary: "A headless Worker with typed routes and interactive API docs, for plugging Domino into your own product."
1323
1496
  }
1324
1497
  ];
1325
- var starterIdSchema = z12.enum(
1498
+ var starterIdSchema = z13.enum(
1326
1499
  starterTemplates.map((template) => template.id)
1327
1500
  );
1328
1501
 
1329
1502
  // src/server/hosting.ts
1330
- var outputPathSchema = z13.string().min(1).max(512).refine(
1503
+ var outputPathSchema = z14.string().min(1).max(512).refine(
1331
1504
  (path) => path.split("/").every(
1332
1505
  (part) => /^[\w-][\w.-]*$/.test(part) && part !== "node_modules"
1333
1506
  ),
1334
1507
  "Expected a relative build output path without hidden segments"
1335
1508
  );
1336
- var appRoutingSchema = z13.enum(["legacy", "transparent"]).default("legacy");
1509
+ var appRoutingSchema = z14.enum(["legacy", "transparent"]).default("legacy");
1337
1510
  var APP_SECRET_LIMIT = 50;
1338
1511
  var APP_KV_LIMIT = 5;
1339
1512
  var APP_SQL_LIMIT = 5;
1340
1513
  var APP_MIGRATION_LIMIT = 100;
1341
1514
  var APP_MIGRATION_FILE_BYTES = 9e4;
1342
1515
  var APP_MIGRATION_TOTAL_BYTES = 1e6;
1343
- var appSecretNameSchema = z13.string().regex(
1516
+ var appSecretNameSchema = z14.string().regex(
1344
1517
  /^[A-Z_][A-Z0-9_]{0,63}$/,
1345
1518
  "Use 1-64 uppercase letters, digits, and underscores, not starting with a digit"
1346
1519
  ).refine(
1347
1520
  (name) => !name.startsWith("DOMINO_") && name !== "ASSETS",
1348
1521
  "DOMINO_ names and ASSETS are reserved for Domino's own bindings"
1349
1522
  );
1350
- var appSecretValueSchema = z13.string().min(1).refine(
1523
+ var appSecretValueSchema = z14.string().min(1).refine(
1351
1524
  (value) => new TextEncoder().encode(value).length <= 5120,
1352
1525
  "Secret values can be at most 5 KiB"
1353
1526
  );
1354
- var appSecretInputSchema = z13.object({ value: appSecretValueSchema }).strict();
1355
- var appSecretSchema = z13.object({
1527
+ var appSecretInputSchema = z14.object({ value: appSecretValueSchema }).strict();
1528
+ var appSecretSchema = z14.object({
1356
1529
  name: appSecretNameSchema,
1357
- updatedAt: z13.number(),
1358
- updatedBy: z13.string()
1530
+ updatedAt: z14.number(),
1531
+ updatedBy: z14.string()
1359
1532
  });
1360
- var appSecretDeclarationSchema = z13.object({
1361
- description: z13.string().trim().min(1).max(500),
1362
- required: z13.boolean().default(true)
1533
+ var appSecretDeclarationSchema = z14.object({
1534
+ description: z14.string().trim().min(1).max(500),
1535
+ required: z14.boolean().default(true)
1363
1536
  }).strict();
1364
- var appSecretDeclarationsSchema = z13.record(appSecretNameSchema, appSecretDeclarationSchema).refine(
1537
+ var appSecretDeclarationsSchema = z14.record(appSecretNameSchema, appSecretDeclarationSchema).refine(
1365
1538
  (secrets) => Object.keys(secrets).length <= APP_SECRET_LIMIT,
1366
1539
  `Declare at most ${APP_SECRET_LIMIT} app secrets`
1367
1540
  );
1368
- var appSecretListSchema = z13.object({
1369
- secrets: z13.array(appSecretSchema),
1370
- declared: z13.array(appSecretDeclarationSchema.extend({ name: appSecretNameSchema })).default([])
1541
+ var appSecretListSchema = z14.object({
1542
+ secrets: z14.array(appSecretSchema),
1543
+ declared: z14.array(appSecretDeclarationSchema.extend({ name: appSecretNameSchema })).default([])
1371
1544
  });
1372
- var hostedAppSecretsSchema = z13.object({ secrets: z13.record(appSecretNameSchema, appSecretValueSchema) }).strict();
1373
- var storageDescription = z13.object({
1374
- description: z13.string().trim().min(1).max(500)
1545
+ var hostedAppSecretsSchema = z14.object({ secrets: z14.record(appSecretNameSchema, appSecretValueSchema) }).strict();
1546
+ var storageDescription = z14.object({
1547
+ description: z14.string().trim().min(1).max(500)
1375
1548
  }).strict();
1376
- var appStorageSchema = z13.object({
1377
- kv: z13.record(appSecretNameSchema, storageDescription).refine(
1549
+ var appStorageSchema = z14.object({
1550
+ kv: z14.record(appSecretNameSchema, storageDescription).refine(
1378
1551
  (stores) => Object.keys(stores).length <= APP_KV_LIMIT,
1379
1552
  `Declare at most ${APP_KV_LIMIT} KV stores`
1380
1553
  ).default({}),
1381
- sql: z13.record(
1554
+ sql: z14.record(
1382
1555
  appSecretNameSchema,
1383
1556
  storageDescription.extend({
1384
1557
  migrations: outputPathSchema.optional()
@@ -1388,77 +1561,77 @@ var appStorageSchema = z13.object({
1388
1561
  `Declare at most ${APP_SQL_LIMIT} SQL stores`
1389
1562
  ).default({})
1390
1563
  }).strict();
1391
- var appStorageKindSchema = z13.enum(["kv", "sql"]);
1392
- var appStorageListSchema = z13.object({
1393
- stores: z13.array(
1394
- z13.object({
1395
- kind: z13.string(),
1564
+ var appStorageKindSchema = z14.enum(["kv", "sql"]);
1565
+ var appStorageListSchema = z14.object({
1566
+ stores: z14.array(
1567
+ z14.object({
1568
+ kind: z14.string(),
1396
1569
  name: appSecretNameSchema,
1397
- createdAt: z13.number().nullable(),
1398
- declared: z13.boolean(),
1399
- description: z13.string().optional()
1570
+ createdAt: z14.number().nullable(),
1571
+ declared: z14.boolean(),
1572
+ description: z14.string().optional()
1400
1573
  })
1401
1574
  )
1402
1575
  });
1403
1576
  var APP_STORAGE_ROW_LIMIT = 50;
1404
1577
  var APP_STORAGE_PREVIEW_CHARACTERS = 2e3;
1405
- var appStorageCellSchema = z13.union([
1406
- z13.string(),
1407
- z13.number(),
1408
- z13.null(),
1409
- z13.object({ text: z13.string(), truncated: z13.literal(true) }),
1410
- z13.object({ blob: z13.number().int().min(0) })
1578
+ var appStorageCellSchema = z14.union([
1579
+ z14.string(),
1580
+ z14.number(),
1581
+ z14.null(),
1582
+ z14.object({ text: z14.string(), truncated: z14.literal(true) }),
1583
+ z14.object({ blob: z14.number().int().min(0) })
1411
1584
  ]);
1412
- var appStorageTablesSchema = z13.object({
1413
- tables: z13.array(
1585
+ var appStorageTablesSchema = z14.object({
1586
+ tables: z14.array(
1414
1587
  /** `kind` is SQLite's: `table` or `view`. */
1415
- z13.object({ name: z13.string(), kind: z13.string() })
1588
+ z14.object({ name: z14.string(), kind: z14.string() })
1416
1589
  )
1417
1590
  });
1418
- var appStorageRowsSchema = z13.object({
1419
- table: z13.string(),
1420
- columns: z13.array(z13.string()),
1421
- rows: z13.array(z13.array(appStorageCellSchema)),
1591
+ var appStorageRowsSchema = z14.object({
1592
+ table: z14.string(),
1593
+ columns: z14.array(z14.string()),
1594
+ rows: z14.array(z14.array(appStorageCellSchema)),
1422
1595
  /** How many rows come before this page in storage order. */
1423
- offset: z13.number().int().min(0),
1424
- total: z13.number().int().min(0),
1596
+ offset: z14.number().int().min(0),
1597
+ total: z14.number().int().min(0),
1425
1598
  /** Pass back as `cursor` for the next page; null on the last one. */
1426
1599
  nextCursor: pageCursorSchema.nullable().default(null)
1427
1600
  });
1428
- var appStorageKeysSchema = z13.object({
1429
- keys: z13.array(
1430
- z13.object({ name: z13.string(), expiration: z13.number().nullable() })
1601
+ var appStorageKeysSchema = z14.object({
1602
+ keys: z14.array(
1603
+ z14.object({ name: z14.string(), expiration: z14.number().nullable() })
1431
1604
  ),
1432
1605
  /** Pass back as `cursor` for the next page; null on the last one. */
1433
1606
  nextCursor: pageCursorSchema.nullable().default(null),
1434
1607
  /** @deprecated Use `nextCursor`. Removed in 2.0.0. */
1435
- cursor: z13.string().nullable()
1608
+ cursor: z14.string().nullable()
1436
1609
  });
1437
- var appStorageValueSchema = z13.object({
1438
- key: z13.string(),
1439
- size: z13.number().int().min(0),
1610
+ var appStorageValueSchema = z14.object({
1611
+ key: z14.string(),
1612
+ size: z14.number().int().min(0),
1440
1613
  /** Null when the value is not UTF-8 text. */
1441
- text: z13.string().nullable(),
1442
- truncated: z13.boolean()
1614
+ text: z14.string().nullable(),
1615
+ truncated: z14.boolean()
1443
1616
  });
1444
1617
  var APP_STORAGE_CELL_CHARACTERS = 1e5;
1445
- var appStorageCellPageSchema = z13.object({
1446
- table: z13.string(),
1447
- column: z13.string(),
1618
+ var appStorageCellPageSchema = z14.object({
1619
+ table: z14.string(),
1620
+ column: z14.string(),
1448
1621
  /** The row's position in storage order: a rows page's `offset` plus its index on that page. */
1449
- row: z13.number().int().min(0),
1622
+ row: z14.number().int().min(0),
1450
1623
  /** SQLite's storage class. */
1451
- type: z13.enum(["text", "integer", "real", "blob", "null"]),
1624
+ type: z14.enum(["text", "integer", "real", "blob", "null"]),
1452
1625
  /** Characters of text, or of a number's text form; bytes of a BLOB; null for NULL. */
1453
- length: z13.number().int().min(0).nullable(),
1626
+ length: z14.number().int().min(0).nullable(),
1454
1627
  /** How many characters come before this page. */
1455
- offset: z13.number().int().min(0),
1628
+ offset: z14.number().int().min(0),
1456
1629
  /** Up to 100,000 characters from `offset`. Null for a BLOB, whose bytes are never read, and NULL. */
1457
- text: z13.string().nullable(),
1630
+ text: z14.string().nullable(),
1458
1631
  /** Pass back as `cursor` for the next page; null on the last one. */
1459
1632
  nextCursor: pageCursorSchema.nullable().default(null)
1460
1633
  });
1461
- var appMigrationNameSchema = z13.string().max(255).regex(/^[\w-][\w.-]*\.sql$/);
1634
+ var appMigrationNameSchema = z14.string().max(255).regex(/^[\w-][\w.-]*\.sql$/);
1462
1635
  function compareAppMigrations(a, b) {
1463
1636
  const left = Number.parseInt(a.split("_")[0], 10);
1464
1637
  const right = Number.parseInt(b.split("_")[0], 10);
@@ -1475,12 +1648,12 @@ function compareAppMigrations(a, b) {
1475
1648
  }
1476
1649
  return a < b ? -1 : a > b ? 1 : 0;
1477
1650
  }
1478
- var appMigrationsSchema = z13.record(
1651
+ var appMigrationsSchema = z14.record(
1479
1652
  appSecretNameSchema,
1480
- z13.array(
1481
- z13.object({
1653
+ z14.array(
1654
+ z14.object({
1482
1655
  name: appMigrationNameSchema,
1483
- sql: z13.string().min(1).refine(
1656
+ sql: z14.string().min(1).refine(
1484
1657
  (sql) => new TextEncoder().encode(sql).length <= APP_MIGRATION_FILE_BYTES,
1485
1658
  `A migration file must not exceed ${APP_MIGRATION_FILE_BYTES} bytes`
1486
1659
  )
@@ -1498,21 +1671,21 @@ var appMigrationsSchema = z13.record(
1498
1671
  );
1499
1672
  var appScripts = {
1500
1673
  routing: appRoutingSchema,
1501
- devScript: z13.string().regex(/^[\w:-]+$/),
1502
- checkScript: z13.string().regex(/^[\w:-]+$/),
1503
- buildScript: z13.string().regex(/^[\w:-]+$/)
1674
+ devScript: z14.string().regex(/^[\w:-]+$/),
1675
+ checkScript: z14.string().regex(/^[\w:-]+$/),
1676
+ buildScript: z14.string().regex(/^[\w:-]+$/)
1504
1677
  };
1505
1678
  var workerSettings = {
1506
- runWorkerFirst: z13.boolean().default(false),
1679
+ runWorkerFirst: z14.boolean().default(false),
1507
1680
  main: outputPathSchema.refine(
1508
1681
  (path) => /\.m?js$/.test(path),
1509
1682
  "Expected a compiled JavaScript entry"
1510
1683
  ),
1511
- compatibilityDate: z13.string().regex(/^\d{4}-\d{2}-\d{2}$/),
1512
- compatibilityFlags: z13.array(z13.string().min(1)).max(50).default([]),
1513
- vars: z13.record(
1514
- z13.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/).refine((name) => name !== "ASSETS"),
1515
- z13.string()
1684
+ compatibilityDate: z14.string().regex(/^\d{4}-\d{2}-\d{2}$/),
1685
+ compatibilityFlags: z14.array(z14.string().min(1)).max(50).default([]),
1686
+ vars: z14.record(
1687
+ z14.string().regex(/^[A-Za-z_][A-Za-z0-9_]*$/).refine((name) => name !== "ASSETS"),
1688
+ z14.string()
1516
1689
  ).default({}),
1517
1690
  secrets: appSecretDeclarationsSchema.default({}),
1518
1691
  storage: appStorageSchema.optional(),
@@ -1541,62 +1714,62 @@ var distinctBindings = (worker, ctx) => {
1541
1714
  }
1542
1715
  }
1543
1716
  };
1544
- var hostedAppSchema = z13.discriminatedUnion("kind", [
1545
- z13.object({
1546
- kind: z13.literal("static"),
1717
+ var hostedAppSchema = z14.discriminatedUnion("kind", [
1718
+ z14.object({
1719
+ kind: z14.literal("static"),
1547
1720
  directory: outputPathSchema,
1548
1721
  ...appScripts
1549
1722
  }).strict(),
1550
- z13.object({
1551
- kind: z13.literal("worker"),
1723
+ z14.object({
1724
+ kind: z14.literal("worker"),
1552
1725
  directory: outputPathSchema,
1553
1726
  assetsDirectory: outputPathSchema.optional(),
1554
1727
  ...appScripts,
1555
1728
  ...workerSettings
1556
1729
  }).strict().superRefine(distinctBindings)
1557
1730
  ]);
1558
- var repositorySchema = z13.object({
1559
- id: z13.string().uuid(),
1731
+ var repositorySchema = z14.object({
1732
+ id: z14.string().uuid(),
1560
1733
  organization: identifier,
1561
1734
  project: identifier,
1562
- remote: z13.string().url(),
1563
- defaultBranch: z13.string(),
1564
- status: z13.enum(["provisioning", "ready"])
1735
+ remote: z14.string().url(),
1736
+ defaultBranch: z14.string(),
1737
+ status: z14.enum(["provisioning", "ready"])
1565
1738
  });
1566
- var createRepositorySchema = z13.object({
1739
+ var createRepositorySchema = z14.object({
1567
1740
  /** Omitted: the starter chosen at project setup, else `campaign`. */
1568
1741
  starter: starterIdSchema.optional()
1569
1742
  }).strict();
1570
- var deviceStartSchema = z13.object({
1571
- challenge: z13.string().regex(/^[a-f0-9]{64}$/)
1743
+ var deviceStartSchema = z14.object({
1744
+ challenge: z14.string().regex(/^[a-f0-9]{64}$/)
1572
1745
  }).strict();
1573
- var deviceRedeemSchema = z13.object({
1574
- id: z13.string().uuid(),
1575
- verifier: z13.string().min(43).max(128)
1746
+ var deviceRedeemSchema = z14.object({
1747
+ id: z14.string().uuid(),
1748
+ verifier: z14.string().min(43).max(128)
1576
1749
  }).strict();
1577
- var deviceApproveSchema = z13.object({
1578
- id: z13.string().uuid(),
1579
- code: z13.string().regex(/^[A-F0-9]{4}-[A-F0-9]{4}$/)
1750
+ var deviceApproveSchema = z14.object({
1751
+ id: z14.string().uuid(),
1752
+ code: z14.string().regex(/^[A-F0-9]{4}-[A-F0-9]{4}$/)
1580
1753
  }).strict();
1581
- var commitSchema = z13.string().regex(/^[a-f0-9]{40}$/);
1582
- var stageRequestSchema = z13.object({
1754
+ var commitSchema = z14.string().regex(/^[a-f0-9]{40}$/);
1755
+ var stageRequestSchema = z14.object({
1583
1756
  commit: commitSchema,
1584
- requestId: z13.string().uuid()
1757
+ requestId: z14.string().uuid()
1585
1758
  }).strict();
1586
- var buildIdentitySchema = z13.object({
1759
+ var buildIdentitySchema = z14.object({
1587
1760
  routing: appRoutingSchema,
1588
- slug: z13.string().min(1).max(35).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/).optional(),
1589
- runtime: z13.enum(["simulation", "hosted-test"]).default("simulation"),
1590
- id: z13.string().uuid(),
1591
- repository: z13.string().uuid(),
1761
+ slug: z14.string().min(1).max(35).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/).optional(),
1762
+ runtime: z14.enum(["simulation", "hosted-test"]).default("simulation"),
1763
+ id: z14.string().uuid(),
1764
+ repository: z14.string().uuid(),
1592
1765
  organization: identifier,
1593
1766
  project: identifier,
1594
1767
  commit: commitSchema,
1595
- createdAt: z13.number(),
1596
- actor: z13.string(),
1597
- commitMessage: z13.string().max(500).optional()
1768
+ createdAt: z14.number(),
1769
+ actor: z14.string(),
1770
+ commitMessage: z14.string().max(500).optional()
1598
1771
  });
1599
- var buildPhaseSchema = z13.enum([
1772
+ var buildPhaseSchema = z14.enum([
1600
1773
  "queued",
1601
1774
  "source",
1602
1775
  "install",
@@ -1606,120 +1779,120 @@ var buildPhaseSchema = z13.enum([
1606
1779
  "ready",
1607
1780
  "failed"
1608
1781
  ]);
1609
- var buildStatusSchema = z13.object({
1782
+ var buildStatusSchema = z14.object({
1610
1783
  phase: buildPhaseSchema,
1611
1784
  failedPhase: buildPhaseSchema.optional(),
1612
- updatedAt: z13.number(),
1613
- message: z13.string()
1785
+ updatedAt: z14.number(),
1786
+ message: z14.string()
1614
1787
  });
1615
1788
  var hostedBuildSchema = buildIdentitySchema.extend({
1616
1789
  ...buildStatusSchema.shape,
1617
- finished: z13.boolean(),
1618
- current: z13.boolean(),
1619
- stagingUrl: z13.string().url()
1790
+ finished: z14.boolean(),
1791
+ current: z14.boolean(),
1792
+ stagingUrl: z14.string().url()
1620
1793
  });
1621
- var liveAppSchema = z13.object({
1622
- url: z13.string().url().nullable(),
1623
- state: z13.enum(["none", "deploying", "live", "failed"]),
1794
+ var liveAppSchema = z14.object({
1795
+ url: z14.string().url().nullable(),
1796
+ state: z14.enum(["none", "deploying", "live", "failed"]),
1624
1797
  /** The build the address serves, or null before the first one goes live. */
1625
- build: z13.string().uuid().nullable(),
1798
+ build: z14.string().uuid().nullable(),
1626
1799
  /** The build the last approved promotion asked for, while it differs from `build`. */
1627
- requested: z13.string().uuid().nullable(),
1628
- failure: z13.string().nullable()
1800
+ requested: z14.string().uuid().nullable(),
1801
+ failure: z14.string().nullable()
1629
1802
  });
1630
- var customDomainStateSchema = z13.enum([
1803
+ var customDomainStateSchema = z14.enum([
1631
1804
  "awaiting-dns",
1632
1805
  "provisioning",
1633
1806
  "active",
1634
1807
  "attention",
1635
1808
  "suspended"
1636
1809
  ]);
1637
- var customDomainRecordSchema = z13.object({
1638
- type: z13.enum(["CNAME", "TXT"]),
1639
- name: z13.string(),
1640
- value: z13.string(),
1810
+ var customDomainRecordSchema = z14.object({
1811
+ type: z14.enum(["CNAME", "TXT"]),
1812
+ name: z14.string(),
1813
+ value: z14.string(),
1641
1814
  /** The values public DNS returned: empty when it had none, null before Domino looked. */
1642
- found: z13.array(z13.string()).nullable(),
1643
- matches: z13.boolean()
1815
+ found: z14.array(z14.string()).nullable(),
1816
+ matches: z14.boolean()
1644
1817
  });
1645
- var customDomainSchema = z13.object({
1646
- id: z13.string().uuid(),
1647
- hostname: z13.string(),
1648
- url: z13.string().url(),
1818
+ var customDomainSchema = z14.object({
1819
+ id: z14.string().uuid(),
1820
+ hostname: z14.string(),
1821
+ url: z14.string().url(),
1649
1822
  state: customDomainStateSchema,
1650
1823
  /** What to fix, in plain words, while the domain needs attention or is suspended. */
1651
- issue: z13.object({ code: z13.string(), message: z13.string() }).nullable(),
1652
- records: z13.array(customDomainRecordSchema),
1824
+ issue: z14.object({ code: z14.string(), message: z14.string() }).nullable(),
1825
+ records: z14.array(customDomainRecordSchema),
1653
1826
  /** Cloudflare's statuses and errors in its own words, once the domain is proven. */
1654
- cloudflare: z13.object({
1655
- hostnameStatus: z13.string(),
1656
- certificateStatus: z13.string().nullable(),
1657
- validationErrors: z13.array(z13.string()),
1658
- verificationErrors: z13.array(z13.string()),
1659
- certificateExpiresAt: z13.string().nullable()
1827
+ cloudflare: z14.object({
1828
+ hostnameStatus: z14.string(),
1829
+ certificateStatus: z14.string().nullable(),
1830
+ validationErrors: z14.array(z14.string()),
1831
+ verificationErrors: z14.array(z14.string()),
1832
+ certificateExpiresAt: z14.string().nullable()
1660
1833
  }).nullable(),
1661
- checkedAt: z13.string().nullable(),
1662
- nextCheckAt: z13.string().nullable(),
1663
- createdAt: z13.string()
1834
+ checkedAt: z14.string().nullable(),
1835
+ nextCheckAt: z14.string().nullable(),
1836
+ createdAt: z14.string()
1664
1837
  });
1665
- var customDomainListSchema = z13.object({
1666
- domains: z13.array(customDomainSchema)
1838
+ var customDomainListSchema = z14.object({
1839
+ domains: z14.array(customDomainSchema)
1667
1840
  });
1668
- var customDomainInputSchema = z13.object({ hostname: z13.string().min(1).max(300) }).strict();
1669
- var stagingAccessModeSchema = z13.enum(["console", "password"]);
1670
- var stagingAccessSchema = z13.object({ mode: stagingAccessModeSchema });
1671
- var stagingAccessInputSchema = z13.discriminatedUnion("mode", [
1672
- z13.object({ mode: z13.literal("console") }).strict(),
1673
- z13.object({
1674
- mode: z13.literal("password"),
1675
- password: z13.string().min(8).max(128)
1841
+ var customDomainInputSchema = z14.object({ hostname: z14.string().min(1).max(300) }).strict();
1842
+ var stagingAccessModeSchema = z14.enum(["console", "password"]);
1843
+ var stagingAccessSchema = z14.object({ mode: stagingAccessModeSchema });
1844
+ var stagingAccessInputSchema = z14.discriminatedUnion("mode", [
1845
+ z14.object({ mode: z14.literal("console") }).strict(),
1846
+ z14.object({
1847
+ mode: z14.literal("password"),
1848
+ password: z14.string().min(8).max(128)
1676
1849
  }).strict()
1677
1850
  ]);
1678
- var stagingPathSchema = z13.string().max(2048).refine(
1851
+ var stagingPathSchema = z14.string().max(2048).refine(
1679
1852
  (path) => path.startsWith("/") && !path.startsWith("//") && !path.includes("\\"),
1680
1853
  "Expected a path on the staging host"
1681
1854
  );
1682
- var stagingLinkSchema = z13.object({
1683
- url: z13.string().url(),
1684
- expiresAt: z13.number()
1855
+ var stagingLinkSchema = z14.object({
1856
+ url: z14.string().url(),
1857
+ expiresAt: z14.number()
1685
1858
  });
1686
- var buildSnapshotSchema = z13.object({
1687
- builds: z13.array(hostedBuildSchema),
1859
+ var buildSnapshotSchema = z14.object({
1860
+ builds: z14.array(hostedBuildSchema),
1688
1861
  current: hostedBuildSchema.nullable(),
1689
1862
  selected: hostedBuildSchema.nullable(),
1690
- logs: z13.string()
1863
+ logs: z14.string()
1691
1864
  });
1692
- var assetPathSchema = z13.string().max(512).refine(
1865
+ var assetPathSchema = z14.string().max(512).refine(
1693
1866
  (path) => path.startsWith("/") && // oxlint-disable-next-line no-control-regex -- Asset paths must reject control characters.
1694
1867
  !/[\\\u0000-\u001f?#%]/.test(path) && path.slice(1).split("/").every((part) => part.length > 0 && !part.startsWith(".")),
1695
1868
  "Expected a public asset path without hidden segments"
1696
1869
  );
1697
- var base64Schema = z13.string().regex(/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/);
1870
+ var base64Schema = z14.string().regex(/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/);
1698
1871
  var stagedDeploymentLimits = {
1699
1872
  /** Bytes of JSON, uncompressed. */
1700
1873
  size: 64e6,
1701
1874
  /** Bytes of the Brotli-compressed object. */
1702
1875
  compressedSize: 1e7
1703
1876
  };
1704
- var stagedDeploymentSchema = z13.object({
1705
- encoding: z13.literal("br"),
1706
- sha256: z13.string().regex(/^[0-9a-f]{64}$/),
1707
- compressedSize: z13.number().int().positive().max(stagedDeploymentLimits.compressedSize),
1708
- size: z13.number().int().positive().max(stagedDeploymentLimits.size)
1877
+ var stagedDeploymentSchema = z14.object({
1878
+ encoding: z14.literal("br"),
1879
+ sha256: z14.string().regex(/^[0-9a-f]{64}$/),
1880
+ compressedSize: z14.number().int().positive().max(stagedDeploymentLimits.compressedSize),
1881
+ size: z14.number().int().positive().max(stagedDeploymentLimits.size)
1709
1882
  }).strict();
1710
1883
  var stagedDeploymentContentSchema = stagedDeploymentSchema.extend({
1711
- content: z13.string().max(Math.ceil(stagedDeploymentLimits.compressedSize / 3) * 4)
1884
+ content: z14.string().max(Math.ceil(stagedDeploymentLimits.compressedSize / 3) * 4)
1712
1885
  }).strict();
1713
1886
  var stagedDeploymentKey = (build, sha256) => `builds/${build}/deployment/${sha256}.br`;
1714
1887
  var artifactFields = {
1715
1888
  routing: appRoutingSchema,
1716
- worker: z13.object({
1889
+ worker: z14.object({
1717
1890
  ...workerSettings,
1718
1891
  migrations: appMigrationsSchema.optional(),
1719
- modules: z13.array(
1720
- z13.object({
1892
+ modules: z14.array(
1893
+ z14.object({
1721
1894
  path: outputPathSchema.refine((path) => path !== "metadata"),
1722
- type: z13.enum([
1895
+ type: z14.enum([
1723
1896
  "application/javascript+module",
1724
1897
  "application/wasm",
1725
1898
  "text/plain",
@@ -1729,26 +1902,26 @@ var artifactFields = {
1729
1902
  }).strict()
1730
1903
  ).min(1).max(500)
1731
1904
  }).strict().superRefine(distinctBindings).optional(),
1732
- assets: z13.array(
1733
- z13.object({
1905
+ assets: z14.array(
1906
+ z14.object({
1734
1907
  path: assetPathSchema,
1735
1908
  content: base64Schema.max(14e6),
1736
- size: z13.number().int().min(0).max(1e7)
1909
+ size: z14.number().int().min(0).max(1e7)
1737
1910
  }).strict()
1738
1911
  ).max(500)
1739
1912
  };
1740
- var buildArtifactsSchema = z13.discriminatedUnion("format", [
1741
- z13.object({
1742
- format: z13.literal(1),
1913
+ var buildArtifactsSchema = z14.discriminatedUnion("format", [
1914
+ z14.object({
1915
+ format: z14.literal(1),
1743
1916
  ...artifactFields,
1744
- quests: z13.unknown(),
1745
- catalog: z13.unknown()
1917
+ quests: z14.unknown(),
1918
+ catalog: z14.unknown()
1746
1919
  }).strict(),
1747
- z13.object({
1748
- format: z13.literal(2),
1920
+ z14.object({
1921
+ format: z14.literal(2),
1749
1922
  ...artifactFields,
1750
1923
  deployment: stagedDeploymentSchema,
1751
- images: z13.array(imageAssetArtifactSchema).max(10)
1924
+ images: z14.array(imageAssetArtifactSchema).max(10)
1752
1925
  }).strict()
1753
1926
  ]).superRefine((value, ctx) => {
1754
1927
  if (value.worker) {
@@ -1800,39 +1973,39 @@ var buildArtifactsSchema = z13.discriminatedUnion("format", [
1800
1973
  });
1801
1974
 
1802
1975
  // src/server/development.ts
1803
- import * as z14 from "zod";
1804
- var developmentPreflightSchema = z14.object({
1805
- organization: z14.string(),
1806
- project: z14.string(),
1807
- environment: z14.enum(["test", "live"]),
1808
- identity: z14.object({
1809
- exchange: z14.literal("supported"),
1810
- activeIntegrations: z14.number().int().nonnegative()
1976
+ import * as z15 from "zod";
1977
+ var developmentPreflightSchema = z15.object({
1978
+ organization: z15.string(),
1979
+ project: z15.string(),
1980
+ environment: z15.enum(["test", "live"]),
1981
+ identity: z15.object({
1982
+ exchange: z15.literal("supported"),
1983
+ activeIntegrations: z15.number().int().nonnegative()
1811
1984
  }).optional(),
1812
- staging: z14.enum(["configured", "blocked"]),
1813
- development: z14.object({
1814
- status: z14.enum(["configured", "blocked"]),
1985
+ staging: z15.enum(["configured", "blocked"]),
1986
+ development: z15.object({
1987
+ status: z15.enum(["configured", "blocked"]),
1815
1988
  // How `domino dev` reaches the preview origin: a Cloudflare tunnel, or a direct route on a
1816
1989
  // local development stack. APIs that predate the field use tunnels.
1817
- transport: z14.enum(["tunnel", "direct"]).default("tunnel"),
1818
- missing: z14.array(z14.string()),
1819
- authentication: z14.array(z14.string())
1990
+ transport: z15.enum(["tunnel", "direct"]).default("tunnel"),
1991
+ missing: z15.array(z15.string()),
1992
+ authentication: z15.array(z15.string())
1820
1993
  }),
1821
- checks: z14.array(
1822
- z14.object({
1823
- id: z14.string(),
1824
- status: z14.enum(["ok", "error"]),
1825
- message: z14.string(),
1826
- missing: z14.array(z14.string()).optional(),
1827
- issues: z14.array(z14.string()).optional()
1994
+ checks: z15.array(
1995
+ z15.object({
1996
+ id: z15.string(),
1997
+ status: z15.enum(["ok", "error"]),
1998
+ message: z15.string(),
1999
+ missing: z15.array(z15.string()).optional(),
2000
+ issues: z15.array(z15.string()).optional()
1828
2001
  })
1829
2002
  )
1830
2003
  });
1831
2004
 
1832
2005
  // src/server/hosted.ts
1833
- import * as z15 from "zod";
2006
+ import * as z16 from "zod";
1834
2007
  var hostedKeyPermissions = ["read", "points", "ingest"];
1835
- var hostedKeyPermissionList = z15.array(z15.string()).transform(
2008
+ var hostedKeyPermissionList = z16.array(z16.string()).transform(
1836
2009
  (values) => values.filter(
1837
2010
  (value) => hostedKeyPermissions.includes(value)
1838
2011
  )
@@ -1844,17 +2017,17 @@ var hostedManagementBindings = [
1844
2017
  "DOMINO_PROJECT",
1845
2018
  "DOMINO_ENVIRONMENT"
1846
2019
  ];
1847
- var hostedKeySecretSchema = z15.string().regex(/^dhk_[A-Za-z0-9_-]{43}$/, "Expected a hosted app key");
1848
- var hostedKeySchema = z15.object({
1849
- id: z15.string().uuid(),
2020
+ var hostedKeySecretSchema = z16.string().regex(/^dhk_[A-Za-z0-9_-]{43}$/, "Expected a hosted app key");
2021
+ var hostedKeySchema = z16.object({
2022
+ id: z16.string().uuid(),
1850
2023
  token: hostedKeySecretSchema,
1851
2024
  organization: identifier,
1852
2025
  project: identifier,
1853
- environment: z15.enum(["test", "live"]),
2026
+ environment: z16.enum(["test", "live"]),
1854
2027
  permissions: hostedKeyPermissionList,
1855
- expiresAt: z15.number().nullable()
2028
+ expiresAt: z16.number().nullable()
1856
2029
  }).strict();
1857
- var hostedDeploymentKeySchema = hostedKeySchema.extend({ apiUrl: z15.string().url() }).strict();
2030
+ var hostedDeploymentKeySchema = hostedKeySchema.extend({ apiUrl: z16.string().url() }).strict();
1858
2031
  function hostedManagementClient(env) {
1859
2032
  const missing = hostedManagementBindings.filter((name) => !env[name]);
1860
2033
  if (missing.length) {
@@ -1862,7 +2035,7 @@ function hostedManagementClient(env) {
1862
2035
  `Missing ${missing.join(", ")}. Domino sets these for hosted apps and domino dev; update the project's vite.config.ts to forward them in development.`
1863
2036
  );
1864
2037
  }
1865
- const environment = z15.enum(["test", "live"]).parse(env.DOMINO_ENVIRONMENT);
2038
+ const environment = z16.enum(["test", "live"]).parse(env.DOMINO_ENVIRONMENT);
1866
2039
  const token = env.DOMINO_MANAGEMENT_KEY;
1867
2040
  return createManagementClient({
1868
2041
  baseUrl: env.DOMINO_API_URL.replace(/\/+$/, ""),
@@ -1874,9 +2047,9 @@ function hostedManagementClient(env) {
1874
2047
  }
1875
2048
 
1876
2049
  // src/server/index.ts
1877
- var environmentSchema = z16.enum(["test", "live"]);
1878
- var roleSchema = z16.enum(["editor", "reviewer", "staff"]);
1879
- var permissionSchema = z16.enum([
2050
+ var environmentSchema = z17.enum(["test", "live"]);
2051
+ var roleSchema = z17.enum(["editor", "reviewer", "staff"]);
2052
+ var permissionSchema = z17.enum([
1880
2053
  "read",
1881
2054
  "publish",
1882
2055
  "review",
@@ -1896,7 +2069,7 @@ var permissionSchema = z16.enum([
1896
2069
  */
1897
2070
  "enroll"
1898
2071
  ]);
1899
- var permissionListSchema = z16.array(z16.string()).transform(
2072
+ var permissionListSchema = z17.array(z17.string()).transform(
1900
2073
  (values) => values.filter(
1901
2074
  (value) => permissionSchema.safeParse(value).success
1902
2075
  )
@@ -1906,38 +2079,38 @@ var rolePermissions = {
1906
2079
  reviewer: ["read", "review"],
1907
2080
  staff: ["read", "confirm", "handover"]
1908
2081
  };
1909
- var projectSetupSchema = z16.object({
1910
- mode: z16.enum(["new", "existing"]),
1911
- brief: z16.string().trim().min(1).max(4e3)
2082
+ var projectSetupSchema = z17.object({
2083
+ mode: z17.enum(["new", "existing"]),
2084
+ brief: z17.string().trim().min(1).max(4e3)
1912
2085
  }).strict();
1913
- var operatorUserSchema = z16.object({
1914
- id: z16.string(),
1915
- name: z16.string().nullable(),
1916
- email: z16.string().nullable(),
1917
- avatar: z16.string().nullable()
2086
+ var operatorUserSchema = z17.object({
2087
+ id: z17.string(),
2088
+ name: z17.string().nullable(),
2089
+ email: z17.string().nullable(),
2090
+ avatar: z17.string().nullable()
1918
2091
  });
1919
- var projectSchema = z16.object({
2092
+ var projectSchema = z17.object({
1920
2093
  /**
1921
2094
  * Names the project's hosted addresses. The server gives a new project, and accepts in a
1922
2095
  * slug change, only slugs of at least 3 characters that Domino does not reserve. This schema
1923
2096
  * checks only the format, so it parses every slug that exists.
1924
2097
  */
1925
- slug: z16.string().min(1).max(35).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/),
1926
- createdBy: z16.string().nullable().optional(),
2098
+ slug: z17.string().min(1).max(35).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/),
2099
+ createdBy: z17.string().nullable().optional(),
1927
2100
  creator: operatorUserSchema.nullable().optional(),
1928
2101
  /** A response, so fields a newer server adds to the setup are dropped, not rejected. */
1929
- setup: z16.object(projectSetupSchema.shape).optional(),
2102
+ setup: z17.object(projectSetupSchema.shape).optional(),
1930
2103
  /** The starter chosen at setup. A plain string, so later starters still parse. */
1931
- starter: z16.string().optional(),
1932
- id: z16.string().min(1),
2104
+ starter: z17.string().optional(),
2105
+ id: z17.string().min(1),
1933
2106
  organization: identifier,
1934
2107
  project: identifier,
1935
- name: z16.string(),
1936
- subtitle: z16.string(),
1937
- initials: z16.string(),
1938
- color: z16.string(),
2108
+ name: z17.string(),
2109
+ subtitle: z17.string(),
2110
+ initials: z17.string(),
2111
+ color: z17.string(),
1939
2112
  permissions: permissionListSchema,
1940
- environments: z16.array(environmentSchema)
2113
+ environments: z17.array(environmentSchema)
1941
2114
  }).refine(
1942
2115
  (project) => !project.creator || project.creator.id === project.createdBy,
1943
2116
  {
@@ -1945,45 +2118,45 @@ var projectSchema = z16.object({
1945
2118
  path: ["creator"]
1946
2119
  }
1947
2120
  );
1948
- var projectInputSchema = z16.object({
2121
+ var projectInputSchema = z17.object({
1949
2122
  actionId: identifier,
1950
- name: z16.string().trim().min(1).max(80),
2123
+ name: z17.string().trim().min(1).max(80),
1951
2124
  setup: projectSetupSchema.optional(),
1952
2125
  /** The starter a new hosted app begins from, with `setup.mode` "new". */
1953
2126
  starter: starterIdSchema.optional()
1954
2127
  }).strict();
1955
- var projectUpdateInputSchema = z16.union([
1956
- z16.object({ name: projectInputSchema.shape.name }).strict(),
1957
- z16.object({
2128
+ var projectUpdateInputSchema = z17.union([
2129
+ z17.object({ name: projectInputSchema.shape.name }).strict(),
2130
+ z17.object({
1958
2131
  slug: projectSchema.shape.slug,
1959
- confirm: z16.string().min(1).max(80)
2132
+ confirm: z17.string().min(1).max(80)
1960
2133
  }).strict()
1961
2134
  ]);
1962
- var projectDeletionInputSchema = z16.object({ confirm: z16.string().min(1).max(80) }).strict();
1963
- var projectDeletionSchema = z16.object({
2135
+ var projectDeletionInputSchema = z17.object({ confirm: z17.string().min(1).max(80) }).strict();
2136
+ var projectDeletionSchema = z17.object({
1964
2137
  project: identifier,
1965
- purgeAfter: z16.number().int()
2138
+ purgeAfter: z17.number().int()
1966
2139
  });
1967
- var projectTransferInputSchema = z16.object({ organization: identifier, confirm: z16.string().min(1).max(80) }).strict();
1968
- var projectTransferSchema = z16.object({
2140
+ var projectTransferInputSchema = z17.object({ organization: identifier, confirm: z17.string().min(1).max(80) }).strict();
2141
+ var projectTransferSchema = z17.object({
1969
2142
  organization: identifier,
1970
2143
  project: identifier
1971
2144
  });
1972
- var grantSchema = z16.object({
1973
- subject: z16.string().min(1).max(200),
1974
- roles: z16.array(roleSchema),
1975
- environments: z16.array(environmentSchema)
2145
+ var grantSchema = z17.object({
2146
+ subject: z17.string().min(1).max(200),
2147
+ roles: z17.array(roleSchema),
2148
+ environments: z17.array(environmentSchema)
1976
2149
  }).strict();
1977
- var grantRecordSchema = z16.object(grantSchema.shape);
1978
- var stockAdditionSchema = z16.object({
2150
+ var grantRecordSchema = z17.object(grantSchema.shape);
2151
+ var stockAdditionSchema = z17.object({
1979
2152
  item: identifier,
1980
- quantity: z16.number().int(),
2153
+ quantity: z17.number().int(),
1981
2154
  actionId: identifier
1982
2155
  });
1983
- var completionRevokeSchema = z16.object({
2156
+ var completionRevokeSchema = z17.object({
1984
2157
  actionId: identifier,
1985
- reason: z16.string().trim().min(1).max(500),
1986
- freeOccurrence: z16.boolean().default(false)
2158
+ reason: z17.string().trim().min(1).max(500),
2159
+ freeOccurrence: z17.boolean().default(false)
1987
2160
  }).strict();
1988
2161
  var RevokedEntitlementOutcome = {
1989
2162
  /** No other completion grants the reward: it is void, after cancelling a handover in progress. */
@@ -2011,227 +2184,227 @@ var RevokedReferralOutcome = {
2011
2184
  /** Qualified on another accepted completion of the program's quest instead. */
2012
2185
  Requalified: "requalified"
2013
2186
  };
2014
- var entitlementOutcomeSchema = z16.string().min(1).max(64);
2015
- var deliveryOutcomeSchema = z16.string().min(1).max(64);
2016
- var referralOutcomeSchema = z16.string().min(1).max(64);
2017
- var completionRevocationSchema = z16.object({
2187
+ var entitlementOutcomeSchema = z17.string().min(1).max(64);
2188
+ var deliveryOutcomeSchema = z17.string().min(1).max(64);
2189
+ var referralOutcomeSchema = z17.string().min(1).max(64);
2190
+ var completionRevocationSchema = z17.object({
2018
2191
  completion: identifier,
2019
2192
  /** The quest ID, or the board ID when `source.kind` is `leaderboard`. */
2020
2193
  quest: identifier,
2021
2194
  member: identifier,
2022
2195
  /** What paid the revoked completion. `source.id` repeats `quest`. */
2023
2196
  source: completionSourceSchema.optional(),
2024
- revokedAt: z16.number(),
2025
- occurrenceFreed: z16.boolean(),
2026
- badges: z16.array(z16.object({ badge: identifier, stillAwarded: z16.boolean() })).optional(),
2027
- groups: z16.array(z16.object({ group: identifier, stillMember: z16.boolean() })).optional(),
2028
- points: z16.array(
2029
- z16.object({
2197
+ revokedAt: z17.number(),
2198
+ occurrenceFreed: z17.boolean(),
2199
+ badges: z17.array(z17.object({ badge: identifier, stillAwarded: z17.boolean() })).optional(),
2200
+ groups: z17.array(z17.object({ group: identifier, stillMember: z17.boolean() })).optional(),
2201
+ points: z17.array(
2202
+ z17.object({
2030
2203
  entry: identifier,
2031
2204
  balance: identifier,
2032
2205
  reversal: identifier.nullable(),
2033
- reversed: z16.number().int(),
2034
- unreversed: z16.number().int()
2206
+ reversed: z17.number().int(),
2207
+ unreversed: z17.number().int()
2035
2208
  })
2036
2209
  ),
2037
- entitlements: z16.array(
2038
- z16.object({
2210
+ entitlements: z17.array(
2211
+ z17.object({
2039
2212
  entitlement: identifier,
2040
2213
  reward: identifier,
2041
2214
  outcome: entitlementOutcomeSchema,
2042
- status: z16.string()
2215
+ status: z17.string()
2043
2216
  })
2044
2217
  ),
2045
- deliveries: z16.array(
2046
- z16.object({
2047
- delivery: z16.string(),
2048
- roleId: z16.string(),
2218
+ deliveries: z17.array(
2219
+ z17.object({
2220
+ delivery: z17.string(),
2221
+ roleId: z17.string(),
2049
2222
  outcome: deliveryOutcomeSchema,
2050
2223
  /**
2051
2224
  * By Relay's records, another accepted, unrevoked completion of the member also granted this
2052
2225
  * role to the same Discord account and server. Relay does not read Discord's membership.
2053
2226
  */
2054
- stillGranted: z16.boolean()
2227
+ stillGranted: z17.boolean()
2055
2228
  })
2056
2229
  ),
2057
- referrals: z16.array(
2058
- z16.object({
2230
+ referrals: z17.array(
2231
+ z17.object({
2059
2232
  program: identifier,
2060
2233
  outcome: referralOutcomeSchema
2061
2234
  })
2062
2235
  ),
2063
- streakMilestone: z16.boolean()
2236
+ streakMilestone: z17.boolean()
2064
2237
  });
2065
- var accessSchema = z16.object({
2066
- actor: z16.string(),
2067
- organization: z16.string(),
2068
- admin: z16.boolean(),
2069
- local: z16.boolean(),
2070
- projects: z16.array(projectSchema)
2238
+ var accessSchema = z17.object({
2239
+ actor: z17.string(),
2240
+ organization: z17.string(),
2241
+ admin: z17.boolean(),
2242
+ local: z17.boolean(),
2243
+ projects: z17.array(projectSchema)
2071
2244
  });
2072
- var querySchema = z16.object({
2073
- q: z16.string().max(200).default(""),
2074
- filter: z16.string().max(50).default("all"),
2075
- offset: z16.coerce.number().int().min(0).max(1e6).default(0),
2076
- limit: z16.coerce.number().int().min(1).max(100).default(25)
2245
+ var querySchema = z17.object({
2246
+ q: z17.string().max(200).default(""),
2247
+ filter: z17.string().max(50).default("all"),
2248
+ offset: z17.coerce.number().int().min(0).max(1e6).default(0),
2249
+ limit: z17.coerce.number().int().min(1).max(100).default(25)
2077
2250
  });
2078
- var accountProfileSchema = z16.object({
2079
- name: z16.string().optional(),
2251
+ var accountProfileSchema = z17.object({
2252
+ name: z17.string().optional(),
2080
2253
  /** The account's handle, where the provider has one (X and Discord). */
2081
- username: z16.string().optional(),
2082
- email: z16.string().optional(),
2083
- emailVerified: z16.boolean().default(false),
2084
- imageUrl: z16.string().url().optional()
2254
+ username: z17.string().optional(),
2255
+ email: z17.string().optional(),
2256
+ emailVerified: z17.boolean().default(false),
2257
+ imageUrl: z17.string().url().optional()
2085
2258
  });
2086
- var memberAccountSchema = z16.object({
2259
+ var memberAccountSchema = z17.object({
2087
2260
  /** `wallet` for wallet sign-in, `account` for every other connected account. */
2088
- kind: z16.enum(["account", "wallet"]),
2089
- provider: z16.string(),
2090
- subject: z16.string(),
2091
- signInEnabled: z16.boolean(),
2261
+ kind: z17.enum(["account", "wallet"]),
2262
+ provider: z17.string(),
2263
+ subject: z17.string(),
2264
+ signInEnabled: z17.boolean(),
2092
2265
  profile: accountProfileSchema.optional()
2093
2266
  });
2094
- var operationSchema = z16.object({
2095
- target: z16.string(),
2096
- paused: z16.boolean(),
2097
- revision: z16.number().int(),
2098
- reason: z16.string(),
2099
- actor: z16.string().nullable(),
2100
- changedAt: z16.number()
2267
+ var operationSchema = z17.object({
2268
+ target: z17.string(),
2269
+ paused: z17.boolean(),
2270
+ revision: z17.number().int(),
2271
+ reason: z17.string(),
2272
+ actor: z17.string().nullable(),
2273
+ changedAt: z17.number()
2101
2274
  });
2102
- var operationInputSchema = z16.object({
2103
- target: z16.union([
2104
- z16.literal("redemptions"),
2105
- z16.string().regex(/^quest:[\w-]+$/)
2275
+ var operationInputSchema = z17.object({
2276
+ target: z17.union([
2277
+ z17.literal("redemptions"),
2278
+ z17.string().regex(/^quest:[\w-]+$/)
2106
2279
  ]),
2107
- paused: z16.boolean(),
2108
- revision: z16.number().int().nonnegative(),
2109
- reason: z16.string().trim().min(1).max(500),
2280
+ paused: z17.boolean(),
2281
+ revision: z17.number().int().nonnegative(),
2282
+ reason: z17.string().trim().min(1).max(500),
2110
2283
  actionId: identifier
2111
2284
  }).strict();
2112
- var questLifecycleInputSchema = z16.object({
2285
+ var questLifecycleInputSchema = z17.object({
2113
2286
  quest: identifier,
2114
2287
  expectedRelease: identifier.optional(),
2115
- archived: z16.boolean(),
2116
- reason: z16.string().trim().min(1).max(500),
2288
+ archived: z17.boolean(),
2289
+ reason: z17.string().trim().min(1).max(500),
2117
2290
  actionId: identifier
2118
2291
  }).strict();
2119
- var questLifecycleSchema = z16.object({
2292
+ var questLifecycleSchema = z17.object({
2120
2293
  quest: identifier,
2121
2294
  key: identifier.nullable(),
2122
- title: z16.string(),
2295
+ title: z17.string(),
2123
2296
  release: identifier,
2124
- lifecycle: z16.enum(["active", "paused", "archived"]),
2125
- changed: z16.boolean()
2297
+ lifecycle: z17.enum(["active", "paused", "archived"]),
2298
+ changed: z17.boolean()
2126
2299
  });
2127
- var memberSchema = z16.object({
2128
- id: z16.string(),
2129
- test: z16.boolean().optional(),
2130
- name: z16.string().nullable().optional(),
2131
- accounts: z16.array(memberAccountSchema).default([]),
2132
- attempts: z16.number(),
2133
- completions: z16.number(),
2134
- rewards: z16.number(),
2135
- lastActivity: z16.number().nullable()
2300
+ var memberSchema = z17.object({
2301
+ id: z17.string(),
2302
+ test: z17.boolean().optional(),
2303
+ name: z17.string().nullable().optional(),
2304
+ accounts: z17.array(memberAccountSchema).default([]),
2305
+ attempts: z17.number(),
2306
+ completions: z17.number(),
2307
+ rewards: z17.number(),
2308
+ lastActivity: z17.number().nullable()
2136
2309
  });
2137
- var personSchema = z16.object({
2138
- id: z16.string(),
2139
- test: z16.boolean().optional(),
2140
- name: z16.string().nullable().optional(),
2141
- accounts: z16.array(memberAccountSchema).default([])
2310
+ var personSchema = z17.object({
2311
+ id: z17.string(),
2312
+ test: z17.boolean().optional(),
2313
+ name: z17.string().nullable().optional(),
2314
+ accounts: z17.array(memberAccountSchema).default([])
2142
2315
  });
2143
- var metricsSchema = z16.object({
2144
- quests: z16.number(),
2145
- members: z16.number(),
2146
- attempts: z16.number(),
2147
- completions: z16.number(),
2148
- review: z16.number(),
2149
- failed: z16.number(),
2150
- entitlements: z16.number()
2316
+ var metricsSchema = z17.object({
2317
+ quests: z17.number(),
2318
+ members: z17.number(),
2319
+ attempts: z17.number(),
2320
+ completions: z17.number(),
2321
+ review: z17.number(),
2322
+ failed: z17.number(),
2323
+ entitlements: z17.number()
2151
2324
  });
2152
- var readinessSchema = z16.object({
2153
- checks: z16.array(
2154
- z16.object({
2155
- id: z16.string(),
2156
- status: z16.enum(["ready", "blocked"]),
2157
- title: z16.string(),
2158
- detail: z16.string()
2325
+ var readinessSchema = z17.object({
2326
+ checks: z17.array(
2327
+ z17.object({
2328
+ id: z17.string(),
2329
+ status: z17.enum(["ready", "blocked"]),
2330
+ title: z17.string(),
2331
+ detail: z17.string()
2159
2332
  })
2160
2333
  )
2161
2334
  });
2162
- var inventorySchema = z16.object({
2163
- item: z16.string(),
2164
- name: z16.string().nullable().default(null),
2165
- available: z16.number(),
2166
- reserved: z16.number(),
2167
- allocated: z16.number().default(0)
2335
+ var inventorySchema = z17.object({
2336
+ item: z17.string(),
2337
+ name: z17.string().nullable().default(null),
2338
+ available: z17.number(),
2339
+ reserved: z17.number(),
2340
+ allocated: z17.number().default(0)
2168
2341
  });
2169
- var auditRecordSchema = z16.object({
2170
- id: z16.string(),
2171
- action: z16.string(),
2172
- actor: z16.string().nullable(),
2342
+ var auditRecordSchema = z17.object({
2343
+ id: z17.string(),
2344
+ action: z17.string(),
2345
+ actor: z17.string().nullable(),
2173
2346
  user: operatorUserSchema.nullable().optional(),
2174
- detail: z16.string(),
2175
- at: z16.number(),
2176
- attempt: z16.string().nullable()
2347
+ detail: z17.string(),
2348
+ at: z17.number(),
2349
+ attempt: z17.string().nullable()
2177
2350
  }).refine((record6) => !record6.user || record6.user.id === record6.actor, {
2178
2351
  message: "User profile must match the recorded actor",
2179
2352
  path: ["user"]
2180
2353
  });
2181
- var pageSchema = z16.object({
2354
+ var pageSchema = z17.object({
2182
2355
  snapshot: snapshotSchema,
2183
- members: z16.array(memberSchema),
2184
- people: z16.array(personSchema).default([]),
2356
+ members: z17.array(memberSchema),
2357
+ people: z17.array(personSchema).default([]),
2185
2358
  metrics: metricsSchema,
2186
- total: z16.number(),
2187
- offset: z16.number(),
2188
- limit: z16.number(),
2189
- inventory: z16.array(inventorySchema),
2190
- operations: z16.array(operationSchema).default([]),
2191
- audit: z16.array(auditRecordSchema).default([]),
2192
- questCounts: z16.record(z16.string(), z16.number())
2359
+ total: z17.number(),
2360
+ offset: z17.number(),
2361
+ limit: z17.number(),
2362
+ inventory: z17.array(inventorySchema),
2363
+ operations: z17.array(operationSchema).default([]),
2364
+ audit: z17.array(auditRecordSchema).default([]),
2365
+ questCounts: z17.record(z17.string(), z17.number())
2193
2366
  });
2194
- var managedOAuthAccountBaseSchema = z16.object({
2195
- provider: z16.enum(["x", "discord"]),
2196
- revision: z16.number().int().nonnegative()
2367
+ var managedOAuthAccountBaseSchema = z17.object({
2368
+ provider: z17.enum(["x", "discord"]),
2369
+ revision: z17.number().int().nonnegative()
2197
2370
  });
2198
- var managedOAuthAccountSchema = z16.discriminatedUnion("status", [
2371
+ var managedOAuthAccountSchema = z17.discriminatedUnion("status", [
2199
2372
  managedOAuthAccountBaseSchema.extend({
2200
- status: z16.literal("connected"),
2201
- subject: z16.string().min(1),
2202
- linkedAt: z16.number(),
2373
+ status: z17.literal("connected"),
2374
+ subject: z17.string().min(1),
2375
+ linkedAt: z17.number(),
2203
2376
  /**
2204
2377
  * True when a member import attached the account with the organization's word for it, not the
2205
2378
  * member's proof. Absent from Relay versions without imports.
2206
2379
  */
2207
- imported: z16.boolean().optional(),
2380
+ imported: z17.boolean().optional(),
2208
2381
  /**
2209
2382
  * True for a real account an operator linked to a test member without OAuth
2210
2383
  * (`testMembers.linkAccount`). Absent from Relay versions without it.
2211
2384
  */
2212
- testLinked: z16.boolean().optional()
2385
+ testLinked: z17.boolean().optional()
2213
2386
  }),
2214
- managedOAuthAccountBaseSchema.extend({ status: z16.literal("disconnected") })
2387
+ managedOAuthAccountBaseSchema.extend({ status: z17.literal("disconnected") })
2215
2388
  ]);
2216
2389
  var managedTelegramAccountBaseSchema = managedOAuthAccountBaseSchema.extend({
2217
- provider: z16.literal("telegram")
2390
+ provider: z17.literal("telegram")
2218
2391
  });
2219
- var managedTelegramAccountSchema = z16.discriminatedUnion("status", [
2392
+ var managedTelegramAccountSchema = z17.discriminatedUnion("status", [
2220
2393
  managedTelegramAccountBaseSchema.extend({
2221
- status: z16.literal("connected"),
2394
+ status: z17.literal("connected"),
2222
2395
  /** The numeric Telegram user ID. */
2223
- subject: z16.string().min(1),
2224
- linkedAt: z16.number()
2396
+ subject: z17.string().min(1),
2397
+ linkedAt: z17.number()
2225
2398
  }),
2226
2399
  managedTelegramAccountBaseSchema.extend({
2227
- status: z16.literal("disconnected")
2400
+ status: z17.literal("disconnected")
2228
2401
  })
2229
2402
  ]);
2230
- var memberOAuthUnlinkInputSchema = z16.object({
2231
- provider: z16.enum(["x", "discord"]),
2232
- subject: z16.string().min(1).max(4096),
2233
- revision: z16.number().int().nonnegative().max(Number.MAX_SAFE_INTEGER - 1),
2234
- reason: z16.string().trim().min(1).max(500)
2403
+ var memberOAuthUnlinkInputSchema = z17.object({
2404
+ provider: z17.enum(["x", "discord"]),
2405
+ subject: z17.string().min(1).max(4096),
2406
+ revision: z17.number().int().nonnegative().max(Number.MAX_SAFE_INTEGER - 1),
2407
+ reason: z17.string().trim().min(1).max(500)
2235
2408
  }).strict();
2236
2409
  var memberTelegramUnlinkInputSchema = memberOAuthUnlinkInputSchema.omit({ provider: true }).strict();
2237
2410
  var managedWalletSchema = linkedWalletSchema.extend({
@@ -2239,32 +2412,32 @@ var managedWalletSchema = linkedWalletSchema.extend({
2239
2412
  * True when a member import attached the wallet with the organization's word for it, and the
2240
2413
  * member has not proved it since. Absent from Relay versions without imports.
2241
2414
  */
2242
- imported: z16.boolean().optional(),
2243
- status: z16.enum(["linked", "unlinked"]),
2244
- unlinkedAt: z16.number().int().nullable(),
2415
+ imported: z17.boolean().optional(),
2416
+ status: z17.enum(["linked", "unlinked"]),
2417
+ unlinkedAt: z17.number().int().nullable(),
2245
2418
  /** "member", or the operator or key that unlinked it. */
2246
- unlinkedBy: z16.string().nullable()
2419
+ unlinkedBy: z17.string().nullable()
2247
2420
  });
2248
2421
  var managedMemberIdentitySchema = memberIdentitySchema.extend({
2249
2422
  /**
2250
2423
  * True for an X account a member import attached, until the member links or signs in with it
2251
2424
  * through X. Absent from Relay versions without imports.
2252
2425
  */
2253
- imported: z16.boolean().optional(),
2426
+ imported: z17.boolean().optional(),
2254
2427
  /**
2255
2428
  * True for a real X or Discord account an operator linked to a test member without OAuth
2256
2429
  * (`testMembers.linkAccount`). Absent from Relay versions without it.
2257
2430
  */
2258
- testLinked: z16.boolean().optional(),
2259
- status: z16.enum(["linked", "unlinked"]),
2260
- unlinkedAt: z16.number().int().nullable(),
2431
+ testLinked: z17.boolean().optional(),
2432
+ status: z17.enum(["linked", "unlinked"]),
2433
+ unlinkedAt: z17.number().int().nullable(),
2261
2434
  /** The operator or key that unlinked it. */
2262
- unlinkedBy: z16.string().nullable()
2435
+ unlinkedBy: z17.string().nullable()
2263
2436
  });
2264
- var memberIdentityChangeInputSchema = z16.object({
2437
+ var memberIdentityChangeInputSchema = z17.object({
2265
2438
  kind: appIdentityKindSchema,
2266
- subject: z16.string().min(1).max(256),
2267
- reason: z16.string().trim().min(1).max(500)
2439
+ subject: z17.string().min(1).max(256),
2440
+ reason: z17.string().trim().min(1).max(500)
2268
2441
  }).strict();
2269
2442
  var balanceCheckSchema = walletBalanceSchema.pick({
2270
2443
  chain: true,
@@ -2274,76 +2447,76 @@ var balanceCheckSchema = walletBalanceSchema.pick({
2274
2447
  wallets: true,
2275
2448
  observedAt: true
2276
2449
  }).extend({ attempt: identifier });
2277
- var walletBalanceChainsSchema = z16.object({
2278
- chains: z16.array(
2279
- z16.object({
2280
- chain: z16.union([
2281
- z16.literal(solanaMainnet),
2450
+ var walletBalanceChainsSchema = z17.object({
2451
+ chains: z17.array(
2452
+ z17.object({
2453
+ chain: z17.union([
2454
+ z17.literal(solanaMainnet),
2282
2455
  cosmosNetworkSchema,
2283
2456
  evmChainIdSchema
2284
2457
  ]),
2285
- name: z16.string(),
2286
- testnet: z16.boolean()
2458
+ name: z17.string(),
2459
+ testnet: z17.boolean()
2287
2460
  })
2288
2461
  )
2289
2462
  });
2290
- var memberWalletUnlinkInputSchema = walletUnlinkInputSchema.extend({ reason: z16.string().trim().min(1).max(500) }).strict();
2463
+ var memberWalletUnlinkInputSchema = walletUnlinkInputSchema.extend({ reason: z17.string().trim().min(1).max(500) }).strict();
2291
2464
  var memberWalletSignInInputSchema = walletUnlinkInputSchema.extend({
2292
- enabled: z16.boolean(),
2293
- reason: z16.string().trim().min(1).max(500)
2465
+ enabled: z17.boolean(),
2466
+ reason: z17.string().trim().min(1).max(500)
2294
2467
  }).strict();
2295
- var telegramBotIdSchema = z16.string().regex(/^[1-9][0-9]{0,19}$/, "Enter the bot's numeric ID, such as 123456789");
2296
- var participantSignInSchema = z16.object({
2297
- providers: z16.array(
2298
- z16.object({ provider: authProviderSchema, configured: z16.boolean() })
2468
+ var telegramBotIdSchema = z17.string().regex(/^[1-9][0-9]{0,19}$/, "Enter the bot's numeric ID, such as 123456789");
2469
+ var participantSignInSchema = z17.object({
2470
+ providers: z17.array(
2471
+ z17.object({ provider: authProviderSchema, configured: z17.boolean() })
2299
2472
  ),
2300
- email: z16.boolean(),
2473
+ email: z17.boolean(),
2301
2474
  /** Wallet families: `"solana"`, `"eip155"`, `"cosmos"`. */
2302
2475
  wallets: walletSignInNetworksSchema,
2303
2476
  /** Why participants cannot sign in to this project, or null. */
2304
- issue: z16.string().nullable(),
2477
+ issue: z17.string().nullable(),
2305
2478
  /**
2306
2479
  * Telegram, outside `providers` in SDK 1.x: whether Domino configured Telegram Login, and the
2307
2480
  * bot whose Mini App participants sign in from, or null when Mini App sign-in is off. Absent
2308
2481
  * from Relay versions without Telegram.
2309
2482
  */
2310
- telegram: z16.object({
2311
- login: z16.boolean(),
2483
+ telegram: z17.object({
2484
+ login: z17.boolean(),
2312
2485
  miniAppBotId: telegramBotIdSchema.nullable()
2313
2486
  }).optional(),
2314
- updatedAt: z16.number().nullable(),
2315
- updatedBy: z16.string().nullable()
2487
+ updatedAt: z17.number().nullable(),
2488
+ updatedBy: z17.string().nullable()
2316
2489
  });
2317
- var participantSignInInputSchema = z16.object({
2490
+ var participantSignInInputSchema = z17.object({
2318
2491
  wallets: walletSignInNetworksSchema,
2319
- telegram: z16.object({ miniAppBotId: telegramBotIdSchema.nullable() }).strict().optional()
2492
+ telegram: z17.object({ miniAppBotId: telegramBotIdSchema.nullable() }).strict().optional()
2320
2493
  }).strict();
2321
- var completionRevocationShortfallSchema = z16.object({
2494
+ var completionRevocationShortfallSchema = z17.object({
2322
2495
  completion: identifier,
2323
2496
  quest: identifier,
2324
- revokedAt: z16.number().int().nonnegative().safe(),
2325
- unreversedPoints: z16.record(identifier, z16.number().int().positive().safe())
2497
+ revokedAt: z17.number().int().nonnegative().safe(),
2498
+ unreversedPoints: z17.record(identifier, z17.number().int().positive().safe())
2326
2499
  });
2327
- var memberDetailSchema = z16.object({
2500
+ var memberDetailSchema = z17.object({
2328
2501
  snapshot: snapshotSchema,
2329
2502
  member: memberSchema,
2330
2503
  progress: memberProgressSchema,
2331
2504
  /** Up to 25 revoked completions with an unreversed point remainder, newest first. */
2332
- revocationShortfalls: z16.array(completionRevocationShortfallSchema).default([]),
2505
+ revocationShortfalls: z17.array(completionRevocationShortfallSchema).default([]),
2333
2506
  /** Current and historical campaign enrollment state, including inactive enrollments. */
2334
- campaignEnrollments: z16.array(campaignEnrollmentSchema).default([]),
2335
- passes: z16.array(
2336
- z16.object({
2337
- provider: z16.string(),
2338
- event: z16.string(),
2339
- subject: z16.string(),
2507
+ campaignEnrollments: z17.array(campaignEnrollmentSchema).default([]),
2508
+ passes: z17.array(
2509
+ z17.object({
2510
+ provider: z17.string(),
2511
+ event: z17.string(),
2512
+ subject: z17.string(),
2340
2513
  attempt: identifier.nullable()
2341
2514
  })
2342
2515
  ).default([]),
2343
2516
  /** Linked and unlinked wallets. */
2344
- wallets: z16.array(managedWalletSchema),
2517
+ wallets: z17.array(managedWalletSchema),
2345
2518
  /** The member's 10 most recent recorded balance reads, newest first. */
2346
- balanceChecks: z16.array(balanceCheckSchema),
2519
+ balanceChecks: z17.array(balanceCheckSchema),
2347
2520
  /** The member's participant profile in this project. */
2348
2521
  profile: managedProfileSchema.nullable(),
2349
2522
  /**
@@ -2351,11 +2524,11 @@ var memberDetailSchema = z16.object({
2351
2524
  * member ID: their selected X and Discord accounts and their `app:<name>` identities in this
2352
2525
  * project, including app identities an operator unlinked, by kind.
2353
2526
  */
2354
- identities: z16.array(managedMemberIdentitySchema)
2527
+ identities: z17.array(managedMemberIdentitySchema)
2355
2528
  });
2356
- var managedMemberProgressSchema = z16.object({
2529
+ var managedMemberProgressSchema = z17.object({
2357
2530
  member: identifier,
2358
- quests: z16.array(
2531
+ quests: z17.array(
2359
2532
  memberProgressSchema.shape.quests.element.extend({
2360
2533
  /** The streak as `members.get` reports it, without the list of qualifying days. */
2361
2534
  streak: streakProgressSchema.omit({ days: true }).nullable().optional()
@@ -2366,156 +2539,156 @@ var managedMemberProgressSchema = z16.object({
2366
2539
  /** Each point balance the member has, by balance ID. */
2367
2540
  balances: snapshotSchema.shape.balances
2368
2541
  });
2369
- var stockInputSchema = z16.object({
2542
+ var stockInputSchema = z17.object({
2370
2543
  item: identifier,
2371
- quantity: z16.number().int().positive().max(1e6),
2544
+ quantity: z17.number().int().positive().max(1e6),
2372
2545
  actionId: identifier
2373
2546
  }).strict();
2374
- var ingestTrackerScopeSchema = z16.array(identifier).min(1).max(100).nullable();
2375
- var tokenScopeInputSchema = z16.object({ ingestTrackers: ingestTrackerScopeSchema }).strict();
2376
- var tokenInputSchema = z16.object({
2377
- name: z16.string().trim().min(1).max(80),
2547
+ var ingestTrackerScopeSchema = z17.array(identifier).min(1).max(100).nullable();
2548
+ var tokenScopeInputSchema = z17.object({ ingestTrackers: ingestTrackerScopeSchema }).strict();
2549
+ var tokenInputSchema = z17.object({
2550
+ name: z17.string().trim().min(1).max(80),
2378
2551
  project: identifier,
2379
2552
  environment: environmentSchema,
2380
- permissions: z16.array(permissionSchema).min(1),
2553
+ permissions: z17.array(permissionSchema).min(1),
2381
2554
  ingestTrackers: ingestTrackerScopeSchema.optional(),
2382
- days: z16.number().int().min(1).max(90).default(30)
2555
+ days: z17.number().int().min(1).max(90).default(30)
2383
2556
  }).strict();
2384
- var tokenSchema = z16.object({
2385
- id: z16.string(),
2386
- name: z16.string(),
2387
- project: z16.string(),
2557
+ var tokenSchema = z17.object({
2558
+ id: z17.string(),
2559
+ name: z17.string(),
2560
+ project: z17.string(),
2388
2561
  environment: environmentSchema,
2389
2562
  permissions: permissionListSchema,
2390
2563
  ingestTrackers: ingestTrackerScopeSchema.optional(),
2391
- expiresAt: z16.number()
2564
+ expiresAt: z17.number()
2392
2565
  });
2393
- var issuedTokenSchema = tokenSchema.extend({ token: z16.string() });
2394
- var serviceKeyInputSchema = z16.object({
2395
- name: z16.string().trim().min(1).max(80),
2396
- permissions: z16.array(permissionSchema).min(1).refine(
2566
+ var issuedTokenSchema = tokenSchema.extend({ token: z17.string() });
2567
+ var serviceKeyInputSchema = z17.object({
2568
+ name: z17.string().trim().min(1).max(80),
2569
+ permissions: z17.array(permissionSchema).min(1).refine(
2397
2570
  (permissions) => !permissions.includes("access"),
2398
2571
  "Service keys cannot hold the access permission"
2399
2572
  ),
2400
2573
  /** Days until the first secret expires. Omit it for a key that never expires. */
2401
- expiresInDays: z16.number().int().min(1).max(3650).optional()
2574
+ expiresInDays: z17.number().int().min(1).max(3650).optional()
2402
2575
  }).strict();
2403
- var serviceKeySchema = z16.object({
2404
- id: z16.string().uuid(),
2405
- organization: z16.string(),
2406
- project: z16.string(),
2576
+ var serviceKeySchema = z17.object({
2577
+ id: z17.string().uuid(),
2578
+ organization: z17.string(),
2579
+ project: z17.string(),
2407
2580
  environment: environmentSchema,
2408
- name: z16.string(),
2581
+ name: z17.string(),
2409
2582
  permissions: permissionListSchema,
2410
2583
  /** The Clerk user ID of the administrator who created it. */
2411
- createdBy: z16.string(),
2412
- createdAt: z16.number(),
2584
+ createdBy: z17.string(),
2585
+ createdAt: z17.number(),
2413
2586
  /** The latest use of any of its secrets, revoked ones included; null when none was used. */
2414
- lastUsedAt: z16.number().nullable(),
2587
+ lastUsedAt: z17.number().nullable(),
2415
2588
  /** Its working secrets, oldest first. Any of them authenticates the key. */
2416
- secrets: z16.array(credentialSecretSchema)
2589
+ secrets: z17.array(credentialSecretSchema)
2417
2590
  });
2418
2591
  var issuedServiceKeySchema = serviceKeySchema.extend({
2419
- secret: z16.string().uuid(),
2420
- token: z16.string()
2592
+ secret: z17.string().uuid(),
2593
+ token: z17.string()
2421
2594
  });
2422
- var teamSchema = z16.array(
2423
- z16.object({ id: z16.string(), label: z16.string() })
2595
+ var teamSchema = z17.array(
2596
+ z17.object({ id: z17.string(), label: z17.string() })
2424
2597
  );
2425
- var memberLookupSchema = z16.object({
2426
- provider: z16.string().min(1).max(200),
2427
- subject: z16.string().min(1).max(2048)
2598
+ var memberLookupSchema = z17.object({
2599
+ provider: z17.string().min(1).max(200),
2600
+ subject: z17.string().min(1).max(2048)
2428
2601
  }).strict();
2429
- var booleanQuery = z16.union([
2430
- z16.boolean(),
2431
- z16.enum(["true", "false"]).transform((v) => v === "true")
2602
+ var booleanQuery = z17.union([
2603
+ z17.boolean(),
2604
+ z17.enum(["true", "false"]).transform((v) => v === "true")
2432
2605
  ]);
2433
- var managedMemberQuerySchema = z16.strictObject({
2434
- q: z16.string().max(200).optional(),
2606
+ var managedMemberQuerySchema = z17.strictObject({
2607
+ q: z17.string().max(200).optional(),
2435
2608
  needsReview: booleanQuery.optional(),
2436
- limit: z16.coerce.number().int().min(1).max(100).optional(),
2609
+ limit: z17.coerce.number().int().min(1).max(100).optional(),
2437
2610
  cursor: pageCursorSchema.optional()
2438
2611
  });
2439
- var managedMemberPageSchema = z16.object({
2440
- items: z16.array(memberSchema),
2441
- total: z16.number().int().nonnegative(),
2442
- nextCursor: z16.string().nullable()
2612
+ var managedMemberPageSchema = z17.object({
2613
+ items: z17.array(memberSchema),
2614
+ total: z17.number().int().nonnegative(),
2615
+ nextCursor: z17.string().nullable()
2443
2616
  });
2444
2617
  var projectMetricsSchema = metricsSchema.extend({
2445
- completionsByQuest: z16.array(
2446
- z16.object({ quest: identifier, completions: z16.number() })
2618
+ completionsByQuest: z17.array(
2619
+ z17.object({ quest: identifier, completions: z17.number() })
2447
2620
  )
2448
2621
  });
2449
- var pageLimit = z16.coerce.number().int().min(1).max(100).optional();
2450
- var managedAttemptQuerySchema = z16.strictObject({
2451
- q: z16.string().max(200).optional(),
2622
+ var pageLimit = z17.coerce.number().int().min(1).max(100).optional();
2623
+ var managedAttemptQuerySchema = z17.strictObject({
2624
+ q: z17.string().max(200).optional(),
2452
2625
  quest: identifier.optional(),
2453
- status: z16.string().min(1).max(50).optional(),
2626
+ status: z17.string().min(1).max(50).optional(),
2454
2627
  limit: pageLimit,
2455
2628
  cursor: pageCursorSchema.optional()
2456
2629
  });
2457
- var managedAttemptPageSchema = z16.object({
2458
- items: z16.array(attemptSchema),
2459
- releases: z16.array(publishedReleaseSchema),
2460
- people: z16.array(personSchema),
2461
- total: z16.number().int().nonnegative(),
2462
- nextCursor: z16.string().nullable()
2630
+ var managedAttemptPageSchema = z17.object({
2631
+ items: z17.array(attemptSchema),
2632
+ releases: z17.array(publishedReleaseSchema),
2633
+ people: z17.array(personSchema),
2634
+ total: z17.number().int().nonnegative(),
2635
+ nextCursor: z17.string().nullable()
2463
2636
  });
2464
- var managedReleaseQuerySchema = z16.strictObject({
2637
+ var managedReleaseQuerySchema = z17.strictObject({
2465
2638
  quest: identifier.optional(),
2466
2639
  limit: pageLimit,
2467
2640
  cursor: pageCursorSchema.optional()
2468
2641
  });
2469
- var managedReleasePageSchema = z16.object({
2470
- items: z16.array(publishedReleaseSchema),
2471
- nextCursor: z16.string().nullable()
2642
+ var managedReleasePageSchema = z17.object({
2643
+ items: z17.array(publishedReleaseSchema),
2644
+ nextCursor: z17.string().nullable()
2472
2645
  });
2473
- var managedAttemptSchema = z16.object({
2646
+ var managedAttemptSchema = z17.object({
2474
2647
  attempt: attemptSchema,
2475
2648
  release: publishedReleaseSchema.nullable(),
2476
- events: z16.array(eventSchema),
2649
+ events: z17.array(eventSchema),
2477
2650
  person: personSchema
2478
2651
  });
2479
- var managedEntitlementQuerySchema = z16.strictObject({
2480
- q: z16.string().max(200).optional(),
2481
- status: z16.string().min(1).max(50).optional(),
2652
+ var managedEntitlementQuerySchema = z17.strictObject({
2653
+ q: z17.string().max(200).optional(),
2654
+ status: z17.string().min(1).max(50).optional(),
2482
2655
  limit: pageLimit,
2483
2656
  cursor: pageCursorSchema.optional()
2484
2657
  });
2485
- var managedEntitlementPageSchema = z16.object({
2486
- items: z16.array(entitlementSchema),
2487
- people: z16.array(personSchema),
2488
- total: z16.number().int().nonnegative(),
2489
- nextCursor: z16.string().nullable()
2658
+ var managedEntitlementPageSchema = z17.object({
2659
+ items: z17.array(entitlementSchema),
2660
+ people: z17.array(personSchema),
2661
+ total: z17.number().int().nonnegative(),
2662
+ nextCursor: z17.string().nullable()
2490
2663
  });
2491
- var managedEntitlementSchema = z16.object({
2664
+ var managedEntitlementSchema = z17.object({
2492
2665
  entitlement: entitlementSchema,
2493
2666
  person: personSchema
2494
2667
  });
2495
2668
  var managedStockItemSchema = inventorySchema.extend({
2496
- offers: z16.array(identifier)
2669
+ offers: z17.array(identifier)
2497
2670
  });
2498
- var auditQuerySchema = z16.strictObject({
2499
- category: z16.enum(["reviews", "rewards", "configuration"]).optional(),
2500
- q: z16.string().max(200).optional(),
2671
+ var auditQuerySchema = z17.strictObject({
2672
+ category: z17.enum(["reviews", "rewards", "configuration"]).optional(),
2673
+ q: z17.string().max(200).optional(),
2501
2674
  limit: pageLimit,
2502
2675
  cursor: pageCursorSchema.optional()
2503
2676
  });
2504
2677
  var auditListQuerySchema = auditQuerySchema.extend({
2505
- category: z16.enum(["reviews", "rewards", "configuration", "test-members"]).optional()
2678
+ category: z17.enum(["reviews", "rewards", "configuration", "test-members"]).optional()
2506
2679
  });
2507
2680
  var accessHistoryQuerySchema = auditQuerySchema.omit({
2508
2681
  category: true
2509
2682
  });
2510
- var auditPageSchema = z16.object({
2511
- items: z16.array(auditRecordSchema),
2512
- total: z16.number().int().nonnegative(),
2513
- nextCursor: z16.string().nullable()
2683
+ var auditPageSchema = z17.object({
2684
+ items: z17.array(auditRecordSchema),
2685
+ total: z17.number().int().nonnegative(),
2686
+ nextCursor: z17.string().nullable()
2514
2687
  });
2515
- var verifiedPassSchema = z16.object({
2688
+ var verifiedPassSchema = z17.object({
2516
2689
  provider: identifier,
2517
2690
  event: identifier,
2518
- subject: z16.string().min(1).max(2048),
2691
+ subject: z17.string().min(1).max(2048),
2519
2692
  member: identifier,
2520
2693
  quest: identifier
2521
2694
  }).strict();
@@ -2539,7 +2712,7 @@ function clientFailure(error) {
2539
2712
  return new ManagementError({
2540
2713
  kind: "client",
2541
2714
  code: ManagementErrorCode.InvalidInput,
2542
- message: error instanceof z16.ZodError ? `Invalid management request: ${z16.prettifyError(error)}` : error instanceof Error ? error.message : "Invalid management request",
2715
+ message: error instanceof z17.ZodError ? `Invalid management request: ${z17.prettifyError(error)}` : error instanceof Error ? error.message : "Invalid management request",
2543
2716
  cause: error
2544
2717
  });
2545
2718
  }
@@ -2577,7 +2750,7 @@ function managementClient(options) {
2577
2750
  call
2578
2751
  );
2579
2752
  }
2580
- const ok = z16.object({ ok: z16.literal(true) });
2753
+ const ok = z17.object({ ok: z17.literal(true) });
2581
2754
  function pointHistory(member, ledger, query = {}, call) {
2582
2755
  return get(
2583
2756
  `/points/${identifier.parse(member)}/${identifier.parse(ledger)}/history${queryString(typeof query === "number" ? { before: query } : pageQuerySchema.parse(query))}`,
@@ -2662,7 +2835,7 @@ function managementClient(options) {
2662
2835
  const input = isInput ? inputOrCall ?? {} : {};
2663
2836
  const options2 = isInput ? call : inputOrCall;
2664
2837
  return post(
2665
- `/webhooks/${z16.string().uuid().parse(id)}/rotate-secret`,
2838
+ `/webhooks/${z17.string().uuid().parse(id)}/rotate-secret`,
2666
2839
  webhookSecretSchema,
2667
2840
  webhookRotateInputSchema.parse(withActionId(input)),
2668
2841
  options2
@@ -2710,8 +2883,8 @@ function managementClient(options) {
2710
2883
  }
2711
2884
  return exchange(
2712
2885
  path,
2713
- z16.object({
2714
- status: z16.number(),
2886
+ z17.object({
2887
+ status: z17.number(),
2715
2888
  operationId: identifier.optional(),
2716
2889
  result: schema
2717
2890
  }),
@@ -2766,7 +2939,7 @@ function managementClient(options) {
2766
2939
  call
2767
2940
  ),
2768
2941
  ...resourceArchiveMethods("tracker"),
2769
- list: (call) => get("/trackers", z16.array(trackerStatusSchema), call),
2942
+ list: (call) => get("/trackers", z17.array(trackerStatusSchema), call),
2770
2943
  get: (reference, call) => get(
2771
2944
  `/trackers/${identifier.parse(reference)}`,
2772
2945
  trackerStatusSchema,
@@ -2882,7 +3055,7 @@ function managementClient(options) {
2882
3055
  engagementPublishSchema.parse(withActionId(input)),
2883
3056
  call
2884
3057
  ),
2885
- list: (call) => get("/engagement", z16.array(engagementRuleSchema), call),
3058
+ list: (call) => get("/engagement", z17.array(engagementRuleSchema), call),
2886
3059
  page: (input, call) => get(
2887
3060
  "/engagement/history" + queryString(engagementPageQuerySchema.parse(input)),
2888
3061
  engagementPageSchema,
@@ -2902,7 +3075,7 @@ function managementClient(options) {
2902
3075
  )
2903
3076
  },
2904
3077
  badges: {
2905
- list: (call) => get("/badges", z16.array(managedBadgeSchema), call),
3078
+ list: (call) => get("/badges", z17.array(managedBadgeSchema), call),
2906
3079
  create: (input, call) => create("/badges", managedBadgeSchema, createBadgeSchema, input, call),
2907
3080
  update: (badge, input, call) => {
2908
3081
  const body = badgePropertiesSchema.extend(badgeMutationSchema.shape).parse(withActionId(input));
@@ -2945,7 +3118,7 @@ function managementClient(options) {
2945
3118
  },
2946
3119
  pointLedgers: {
2947
3120
  unarchive: (ledger, input, call) => archiveResource("point-ledger", ledger, false, input, call),
2948
- list: (call) => get("/point-ledgers", z16.array(managedPointLedgerSchema), call),
3121
+ list: (call) => get("/point-ledgers", z17.array(managedPointLedgerSchema), call),
2949
3122
  /**
2950
3123
  * Creates a point ledger, with a stable `key` when code refers to it; requires `publish`. In
2951
3124
  * live, only a person in Console can create one.
@@ -2975,7 +3148,7 @@ function managementClient(options) {
2975
3148
  },
2976
3149
  points: {
2977
3150
  /** @deprecated Use `pointLedgers.list()`, which reads the same ledgers. Removed in 2.0.0. */
2978
- ledgers: (call) => get("/point-ledgers", z16.array(managedPointLedgerSchema), call),
3151
+ ledgers: (call) => get("/point-ledgers", z17.array(managedPointLedgerSchema), call),
2979
3152
  /** @deprecated Use `pointLedgers.create(input)`. Removed in 2.0.0. */
2980
3153
  createLedger: createPointLedger,
2981
3154
  /**
@@ -3013,7 +3186,7 @@ function managementClient(options) {
3013
3186
  referralHistorySchema,
3014
3187
  call
3015
3188
  ),
3016
- list: (call) => get("/referrals", z16.array(publishedReferralSchema), call),
3189
+ list: (call) => get("/referrals", z17.array(publishedReferralSchema), call),
3017
3190
  participants: referralParticipants,
3018
3191
  /**
3019
3192
  * Suspends or restores a member's referral relationship, with a reason; requires `publish`.
@@ -3076,7 +3249,7 @@ function managementClient(options) {
3076
3249
  },
3077
3250
  leaderboards: {
3078
3251
  ...resourceArchiveMethods("leaderboard"),
3079
- list: (call) => get("/leaderboards", z16.array(publishedLeaderboardSchema), call),
3252
+ list: (call) => get("/leaderboards", z17.array(publishedLeaderboardSchema), call),
3080
3253
  standings: (board, input = {}, call) => {
3081
3254
  const query = leaderboardQuerySchema.parse(input);
3082
3255
  return get(
@@ -3090,13 +3263,13 @@ function managementClient(options) {
3090
3263
  },
3091
3264
  history: (board, call) => get(
3092
3265
  `/leaderboards/${identifier.parse(board)}/history`,
3093
- z16.array(publishedLeaderboardSchema),
3266
+ z17.array(publishedLeaderboardSchema),
3094
3267
  call
3095
3268
  ),
3096
3269
  /** Current members of the board's exclusion group (`exclusionGroup`), by member ID. */
3097
3270
  exclusions: (board, call) => get(
3098
3271
  `/leaderboards/${identifier.parse(board)}/exclusions`,
3099
- z16.array(z16.object({ member: identifier })),
3272
+ z17.array(z17.object({ member: identifier })),
3100
3273
  call
3101
3274
  ),
3102
3275
  /**
@@ -3161,7 +3334,7 @@ function managementClient(options) {
3161
3334
  ),
3162
3335
  settlements: (board, call) => get(
3163
3336
  `/leaderboards/${identifier.parse(board)}/settlements`,
3164
- z16.array(leaderboardSettlementSummarySchema),
3337
+ z17.array(leaderboardSettlementSummarySchema),
3165
3338
  call
3166
3339
  ),
3167
3340
  settlement: (settlement, call) => get(
@@ -3246,7 +3419,7 @@ function managementClient(options) {
3246
3419
  *
3247
3420
  * @deprecated Use `history`, which pages by `cursor` and `nextCursor`. Removed in 2.0.0.
3248
3421
  */
3249
- list: (call) => get("/deployments", z16.array(deploymentRecordSchema), call),
3422
+ list: (call) => get("/deployments", z17.array(deploymentRecordSchema), call),
3250
3423
  /**
3251
3424
  * The project environment's deployments, newest first, one page at a time, with the two
3252
3425
  * newest published deployments beside every page. Pass a page's `nextCursor` back as
@@ -3385,6 +3558,20 @@ function managementClient(options) {
3385
3558
  metrics: {
3386
3559
  read: (call) => get("/metrics", projectMetricsSchema, call)
3387
3560
  },
3561
+ /** The project's activity over time, as Console's Analytics page shows it. */
3562
+ analytics: {
3563
+ /**
3564
+ * The project's members, quests, points, offers and referrals over one range (`7d`, `30d`,
3565
+ * `90d` or `all`), bucketed by project-calendar day or week, with totals for the range of
3566
+ * equal length before it; `ledger` picks the point ledger by key or ID. Requires `read`
3567
+ * permission.
3568
+ */
3569
+ read: (query, call) => get(
3570
+ `/analytics${queryString(analyticsQuerySchema.parse(query))}`,
3571
+ analyticsReadSchema,
3572
+ call
3573
+ )
3574
+ },
3388
3575
  /** Release history: every version a quest has been published as. */
3389
3576
  releases: {
3390
3577
  /**
@@ -3587,7 +3774,7 @@ function managementClient(options) {
3587
3774
  },
3588
3775
  operations: {
3589
3776
  /** Every paused or resumed operation: redemptions and each quest's participation; requires `read`. */
3590
- list: (call) => get("/operations", z16.array(operationSchema), call),
3777
+ list: (call) => get("/operations", z17.array(operationSchema), call),
3591
3778
  /**
3592
3779
  * Pauses or resumes redemptions or one quest's participation, against the `revision` the
3593
3780
  * operator saw, with a reason; requires `publish` permission.
@@ -3645,7 +3832,7 @@ function managementClient(options) {
3645
3832
  call
3646
3833
  ),
3647
3834
  /** Every stock item with its counts and the offers that sell it; requires `read` permission. */
3648
- list: (call) => get("/stock-items", z16.array(managedStockItemSchema), call),
3835
+ list: (call) => get("/stock-items", z17.array(managedStockItemSchema), call),
3649
3836
  createItem: (input, call) => create(
3650
3837
  "/stock-items",
3651
3838
  stockItemSchema,
@@ -3660,7 +3847,7 @@ function managementClient(options) {
3660
3847
  stockInputSchema.parse(withActionId(input)),
3661
3848
  call
3662
3849
  ),
3663
- catalog: (call) => get("/pickup-inventory", z16.array(pickupCatalogSchema), call),
3850
+ catalog: (call) => get("/pickup-inventory", z17.array(pickupCatalogSchema), call),
3664
3851
  configure: (input, call) => post(
3665
3852
  "/pickup-inventory",
3666
3853
  pickupCatalogSchema,
@@ -3686,7 +3873,7 @@ function managementClient(options) {
3686
3873
  offerControlSchema.omit({ enabled: true }).parse(withActionId(input)),
3687
3874
  call
3688
3875
  ),
3689
- list: (call) => get("/offers", z16.array(offerSchema), call),
3876
+ list: (call) => get("/offers", z17.array(offerSchema), call),
3690
3877
  /**
3691
3878
  * Every redemption, or one member's, newest first, in one unbounded response.
3692
3879
  *
@@ -3694,7 +3881,7 @@ function managementClient(options) {
3694
3881
  */
3695
3882
  redemptions: (input = {}, call) => get(
3696
3883
  `/redemptions${queryString({ member: input.member })}`,
3697
- z16.array(redemptionSchema),
3884
+ z17.array(redemptionSchema),
3698
3885
  call
3699
3886
  ),
3700
3887
  /** Pauses or resumes an offer at the revision the operator saw. */
@@ -3743,7 +3930,7 @@ function managementClient(options) {
3743
3930
  * them; API keys and project-scoped playground sessions cannot.
3744
3931
  */
3745
3932
  tokens: {
3746
- list: (call) => get("/tokens", z16.array(tokenSchema), call),
3933
+ list: (call) => get("/tokens", z17.array(tokenSchema), call),
3747
3934
  /**
3748
3935
  * Issues a key for one project and environment, limited to permissions the caller holds
3749
3936
  * there. The secret `token` is in this response only.
@@ -3751,14 +3938,14 @@ function managementClient(options) {
3751
3938
  create: (input, call) => post("/tokens", issuedTokenSchema, tokenInputSchema.parse(input), call),
3752
3939
  /** Replace a personal key's ingestion restriction without changing its secret. */
3753
3940
  scope: (id, input, call) => request(
3754
- `/tokens/${encodeURIComponent(z16.string().min(1).parse(id))}/scope`,
3941
+ `/tokens/${encodeURIComponent(z17.string().min(1).parse(id))}/scope`,
3755
3942
  tokenSchema,
3756
3943
  tokenScopeInputSchema.parse(input),
3757
3944
  "PUT",
3758
3945
  call
3759
3946
  ),
3760
3947
  revoke: (id, call) => request(
3761
- `/tokens/${encodeURIComponent(z16.string().min(1).parse(id))}`,
3948
+ `/tokens/${encodeURIComponent(z17.string().min(1).parse(id))}`,
3762
3949
  ok,
3763
3950
  void 0,
3764
3951
  "DELETE",
@@ -3770,7 +3957,7 @@ function managementClient(options) {
3770
3957
  * environment, owned by no person. Only an organization administrator in Console manages them.
3771
3958
  */
3772
3959
  serviceKeys: {
3773
- list: (call) => get("/service-keys", z16.array(serviceKeySchema), call),
3960
+ list: (call) => get("/service-keys", z17.array(serviceKeySchema), call),
3774
3961
  /** The secret `token` is in this response only. */
3775
3962
  create: (input, call) => post(
3776
3963
  "/service-keys",
@@ -3783,14 +3970,14 @@ function managementClient(options) {
3783
3970
  * them with `revokeSecret`. The new `token` is in this response only.
3784
3971
  */
3785
3972
  addSecret: (id, input = {}, call) => post(
3786
- `/service-keys/${z16.string().uuid().parse(id)}/secrets`,
3973
+ `/service-keys/${z17.string().uuid().parse(id)}/secrets`,
3787
3974
  issuedServiceKeySchema,
3788
3975
  credentialSecretInputSchema.parse(input),
3789
3976
  call
3790
3977
  ),
3791
3978
  /** Stops one secret working. A key's last secret cannot be revoked; revoke the key instead. */
3792
3979
  revokeSecret: (id, secret, call) => request(
3793
- `/service-keys/${z16.string().uuid().parse(id)}/secrets/${z16.string().uuid().parse(secret)}`,
3980
+ `/service-keys/${z17.string().uuid().parse(id)}/secrets/${z17.string().uuid().parse(secret)}`,
3794
3981
  serviceKeySchema,
3795
3982
  void 0,
3796
3983
  "DELETE",
@@ -3798,8 +3985,8 @@ function managementClient(options) {
3798
3985
  ),
3799
3986
  /** Deletes the key; every secret stops working. */
3800
3987
  revoke: (id, call) => request(
3801
- `/service-keys/${z16.string().uuid().parse(id)}`,
3802
- z16.null(),
3988
+ `/service-keys/${z17.string().uuid().parse(id)}`,
3989
+ z17.null(),
3803
3990
  void 0,
3804
3991
  "DELETE",
3805
3992
  call
@@ -3807,7 +3994,7 @@ function managementClient(options) {
3807
3994
  },
3808
3995
  /** Who holds which roles on the client's project; organization administrators only. */
3809
3996
  grants: {
3810
- list: (call) => get("/grants", z16.array(grantRecordSchema), call),
3997
+ list: (call) => get("/grants", z17.array(grantRecordSchema), call),
3811
3998
  /** Replaces one person's roles and environments on the project. The audit log records it. */
3812
3999
  set: (input, call) => request(
3813
4000
  "/grants",
@@ -3824,7 +4011,7 @@ function managementClient(options) {
3824
4011
  /** Signed activity notifications for one project/environment; writes require publish permission. */
3825
4012
  webhooks: {
3826
4013
  state: (id, call) => get(
3827
- `/webhooks/${z16.string().uuid().parse(id)}/state`,
4014
+ `/webhooks/${z17.string().uuid().parse(id)}/state`,
3828
4015
  webhookEndpointStateSchema,
3829
4016
  call
3830
4017
  ),
@@ -3835,24 +4022,24 @@ function managementClient(options) {
3835
4022
  call
3836
4023
  ),
3837
4024
  delete: (id, input, call) => post(
3838
- `/webhooks/${z16.string().uuid().parse(id)}/delete`,
4025
+ `/webhooks/${z17.string().uuid().parse(id)}/delete`,
3839
4026
  webhookEndpointStateSchema,
3840
4027
  webhookDeleteInputSchema.parse(withActionId(input)),
3841
4028
  call
3842
4029
  ),
3843
4030
  pause: (id, input = {}, call) => post(
3844
- `/webhooks/${z16.string().uuid().parse(id)}/pause`,
4031
+ `/webhooks/${z17.string().uuid().parse(id)}/pause`,
3845
4032
  webhookEndpointSchema,
3846
4033
  webhookControlInputSchema.parse(withActionId(input)),
3847
4034
  call
3848
4035
  ),
3849
4036
  resume: (id, input = {}, call) => post(
3850
- `/webhooks/${z16.string().uuid().parse(id)}/resume`,
4037
+ `/webhooks/${z17.string().uuid().parse(id)}/resume`,
3851
4038
  webhookEndpointSchema,
3852
4039
  webhookControlInputSchema.parse(withActionId(input)),
3853
4040
  call
3854
4041
  ),
3855
- list: (call) => get("/webhooks", z16.array(webhookEndpointSchema), call),
4042
+ list: (call) => get("/webhooks", z17.array(webhookEndpointSchema), call),
3856
4043
  /** Pass an `actionId` to recover the endpoint and its secret after a lost answer. */
3857
4044
  create: (input, call) => post(
3858
4045
  "/webhooks",
@@ -3861,7 +4048,7 @@ function managementClient(options) {
3861
4048
  call
3862
4049
  ),
3863
4050
  update: (id, input, call) => request(
3864
- `/webhooks/${z16.string().uuid().parse(id)}`,
4051
+ `/webhooks/${z17.string().uuid().parse(id)}`,
3865
4052
  webhookEndpointSchema,
3866
4053
  webhookUpdateSchema.parse(input),
3867
4054
  "PUT",
@@ -3869,19 +4056,19 @@ function managementClient(options) {
3869
4056
  ),
3870
4057
  /** @deprecated Use pause. Removed in 2.0.0. */
3871
4058
  disable: (id, call) => post(
3872
- `/webhooks/${z16.string().uuid().parse(id)}/disable`,
4059
+ `/webhooks/${z17.string().uuid().parse(id)}/disable`,
3873
4060
  webhookEndpointSchema,
3874
4061
  {},
3875
4062
  call
3876
4063
  ),
3877
4064
  rotateSecret: rotateWebhookSecret,
3878
4065
  deliveries: (id, query = {}, call) => get(
3879
- `/webhooks/${z16.string().uuid().parse(id)}/deliveries${queryString(webhookQuerySchema.parse(query))}`,
4066
+ `/webhooks/${z17.string().uuid().parse(id)}/deliveries${queryString(webhookQuerySchema.parse(query))}`,
3880
4067
  webhookDeliveryPageSchema,
3881
4068
  call
3882
4069
  ),
3883
4070
  replay: (id, delivery, call) => post(
3884
- `/webhooks/${z16.string().uuid().parse(id)}/deliveries/${z16.string().uuid().parse(delivery)}/replay`,
4071
+ `/webhooks/${z17.string().uuid().parse(id)}/deliveries/${z17.string().uuid().parse(delivery)}/replay`,
3885
4072
  webhookDeliverySchema,
3886
4073
  {},
3887
4074
  call
@@ -3892,7 +4079,7 @@ function managementClient(options) {
3892
4079
  * environment. Organization administrators, from a Console session only.
3893
4080
  */
3894
4081
  identityIntegrations: {
3895
- list: (call) => get("/identity-integrations", z16.array(identityIntegrationSchema), call),
4082
+ list: (call) => get("/identity-integrations", z17.array(identityIntegrationSchema), call),
3896
4083
  /** The secret `token` is in this response only. */
3897
4084
  create: (input, call) => post(
3898
4085
  "/identity-integrations",
@@ -3907,7 +4094,7 @@ function managementClient(options) {
3907
4094
  * @deprecated Use `addSecret`, then `revokeSecret` the old secret once your app uses the new one.
3908
4095
  */
3909
4096
  rotate: (id, call) => post(
3910
- `/identity-integrations/${z16.string().uuid().parse(id)}/rotate`,
4097
+ `/identity-integrations/${z17.string().uuid().parse(id)}/rotate`,
3911
4098
  identityIntegrationSecretSchema,
3912
4099
  {},
3913
4100
  call
@@ -3917,7 +4104,7 @@ function managementClient(options) {
3917
4104
  * revoke them with `revokeSecret`. The new `token` is in this response only.
3918
4105
  */
3919
4106
  addSecret: (id, input = {}, call) => post(
3920
- `/identity-integrations/${z16.string().uuid().parse(id)}/secrets`,
4107
+ `/identity-integrations/${z17.string().uuid().parse(id)}/secrets`,
3921
4108
  identityIntegrationSecretSchema,
3922
4109
  credentialSecretInputSchema.parse(input),
3923
4110
  call
@@ -3927,7 +4114,7 @@ function managementClient(options) {
3927
4114
  * revoked; disconnect the integration with `revoke` instead.
3928
4115
  */
3929
4116
  revokeSecret: (id, secret, call) => request(
3930
- `/identity-integrations/${z16.string().uuid().parse(id)}/secrets/${z16.string().uuid().parse(secret)}`,
4117
+ `/identity-integrations/${z17.string().uuid().parse(id)}/secrets/${z17.string().uuid().parse(secret)}`,
3931
4118
  identityIntegrationSchema,
3932
4119
  void 0,
3933
4120
  "DELETE",
@@ -3935,7 +4122,7 @@ function managementClient(options) {
3935
4122
  ),
3936
4123
  /** Makes one secret never expire. */
3937
4124
  removeSecretExpiry: (id, secret, call) => request(
3938
- `/identity-integrations/${z16.string().uuid().parse(id)}/secrets/${z16.string().uuid().parse(secret)}/expiry`,
4125
+ `/identity-integrations/${z17.string().uuid().parse(id)}/secrets/${z17.string().uuid().parse(secret)}/expiry`,
3939
4126
  identityIntegrationSchema,
3940
4127
  void 0,
3941
4128
  "DELETE",
@@ -3948,7 +4135,7 @@ function managementClient(options) {
3948
4135
  */
3949
4136
  kinds: (call) => get(
3950
4137
  "/identity-integrations/kinds",
3951
- z16.array(identityKindClaimSchema),
4138
+ z17.array(identityKindClaimSchema),
3952
4139
  call
3953
4140
  ),
3954
4141
  /**
@@ -3956,8 +4143,8 @@ function managementClient(options) {
3956
4143
  * and keep attributing tracker records; unlink them on the member to stop that.
3957
4144
  */
3958
4145
  revoke: (id, call) => request(
3959
- `/identity-integrations/${z16.string().uuid().parse(id)}`,
3960
- z16.null(),
4146
+ `/identity-integrations/${z17.string().uuid().parse(id)}`,
4147
+ z17.null(),
3961
4148
  void 0,
3962
4149
  "DELETE",
3963
4150
  call
@@ -4008,7 +4195,7 @@ function managementClient(options) {
4008
4195
  resources: {
4009
4196
  list: (call) => get(
4010
4197
  "/resources",
4011
- z16.object({ resources: z16.array(managedResourceSchema) }),
4198
+ z17.object({ resources: z17.array(managedResourceSchema) }),
4012
4199
  call
4013
4200
  ),
4014
4201
  /** @deprecated Use the resource archive/unarchive methods. Removed in 2.0.0. */
@@ -4079,7 +4266,7 @@ function managementClient(options) {
4079
4266
  testMemberCreateSchema.parse(withActionId(input)),
4080
4267
  call
4081
4268
  ),
4082
- list: (call) => get("/test-members", z16.array(testMemberSchema), call),
4269
+ list: (call) => get("/test-members", z17.array(testMemberSchema), call),
4083
4270
  history: (member, query = {}, call) => get(
4084
4271
  `/test-members/${identifier.parse(member)}/history${queryString(testMemberHistoryQuerySchema.parse(query))}`,
4085
4272
  testMemberHistorySchema,
@@ -4121,6 +4308,18 @@ function managementClient(options) {
4121
4308
  testMemberAdvanceSchema.parse(withActionId(input)),
4122
4309
  call
4123
4310
  ),
4311
+ /**
4312
+ * Accepts a referral invitation as the test member, as a signed-in member accepting it
4313
+ * would: by `code`, or by `inviter`, another test member. The program's qualification and
4314
+ * rewards apply, and the participant route's refusals: `self-referral`,
4315
+ * `inviter-already-accepted`, `invitation-closed`, `referral-cycle`, `invitation-not-found`.
4316
+ */
4317
+ acceptReferral: (member, input, call) => post(
4318
+ `/test-members/${identifier.parse(member)}/referrals/accept`,
4319
+ ok,
4320
+ testMemberReferralAcceptSchema.parse(withActionId(input)),
4321
+ call
4322
+ ),
4124
4323
  /**
4125
4324
  * Gives the test member a wallet address with no signature; quest code reads it like a
4126
4325
  * member's linked wallet. Answers the test member with its wallets.
@@ -4303,13 +4502,13 @@ function managementClient(options) {
4303
4502
  )
4304
4503
  },
4305
4504
  counters: {
4306
- history: (member, quest, query = {}, call) => get(
4307
- `/members/${identifier.parse(member)}/counters/${identifier.parse(quest)}${queryString(counterHistoryQuerySchema.parse(query))}`,
4505
+ history: (member, quest2, query = {}, call) => get(
4506
+ `/members/${identifier.parse(member)}/counters/${identifier.parse(quest2)}${queryString(counterHistoryQuerySchema.parse(query))}`,
4308
4507
  counterHistorySchema,
4309
4508
  call
4310
4509
  ),
4311
- moderate: (member, quest, contribution, input, call) => post(
4312
- `/members/${identifier.parse(member)}/counters/${identifier.parse(quest)}/${identifier.parse(contribution)}/moderate`,
4510
+ moderate: (member, quest2, contribution, input, call) => post(
4511
+ `/members/${identifier.parse(member)}/counters/${identifier.parse(quest2)}/${identifier.parse(contribution)}/moderate`,
4313
4512
  counterModerationResultSchema,
4314
4513
  counterModerationSchema.parse(withActionId(input)),
4315
4514
  call
@@ -4351,7 +4550,7 @@ function managementClient(options) {
4351
4550
  /** Who each member is: up to 100 distinct IDs; unknown IDs come back without accounts. */
4352
4551
  people: (members, call) => get(
4353
4552
  `/people${queryString({ ids: members.join(",") })}`,
4354
- z16.array(personSchema),
4553
+ z17.array(personSchema),
4355
4554
  call
4356
4555
  ),
4357
4556
  /**
@@ -4361,7 +4560,7 @@ function managementClient(options) {
4361
4560
  */
4362
4561
  oauthAccounts: (member, call) => get(
4363
4562
  `/members/${encodeURIComponent(member)}/oauth-accounts`,
4364
- z16.array(managedOAuthAccountSchema),
4563
+ z17.array(managedOAuthAccountSchema),
4365
4564
  call
4366
4565
  ),
4367
4566
  /**
@@ -4371,7 +4570,7 @@ function managementClient(options) {
4371
4570
  */
4372
4571
  unlinkOAuthAccount: (member, input, call) => post(
4373
4572
  `/members/${encodeURIComponent(member)}/oauth-accounts/unlink`,
4374
- z16.array(managedOAuthAccountSchema),
4573
+ z17.array(managedOAuthAccountSchema),
4375
4574
  memberOAuthUnlinkInputSchema.parse(input),
4376
4575
  call
4377
4576
  ),
@@ -4404,7 +4603,7 @@ function managementClient(options) {
4404
4603
  */
4405
4604
  unlinkWallet: (member, input, call) => post(
4406
4605
  `/members/${encodeURIComponent(member)}/wallets/unlink`,
4407
- z16.array(managedWalletSchema),
4606
+ z17.array(managedWalletSchema),
4408
4607
  memberWalletUnlinkInputSchema.parse(input),
4409
4608
  call
4410
4609
  ),
@@ -4417,7 +4616,7 @@ function managementClient(options) {
4417
4616
  */
4418
4617
  unlinkIdentity: (member, input, call) => post(
4419
4618
  `/members/${encodeURIComponent(member)}/identities/unlink`,
4420
- z16.array(managedMemberIdentitySchema),
4619
+ z17.array(managedMemberIdentitySchema),
4421
4620
  memberIdentityChangeInputSchema.parse(input),
4422
4621
  call
4423
4622
  ),
@@ -4428,7 +4627,7 @@ function managementClient(options) {
4428
4627
  */
4429
4628
  relinkIdentity: (member, input, call) => post(
4430
4629
  `/members/${encodeURIComponent(member)}/identities/relink`,
4431
- z16.array(managedMemberIdentitySchema),
4630
+ z17.array(managedMemberIdentitySchema),
4432
4631
  memberIdentityChangeInputSchema.parse(input),
4433
4632
  call
4434
4633
  ),
@@ -4440,7 +4639,7 @@ function managementClient(options) {
4440
4639
  */
4441
4640
  setWalletSignIn: (member, input, call) => post(
4442
4641
  `/members/${encodeURIComponent(member)}/wallets/sign-in`,
4443
- z16.array(managedWalletSchema),
4642
+ z17.array(managedWalletSchema),
4444
4643
  memberWalletSignInInputSchema.parse(input),
4445
4644
  call
4446
4645
  )
@@ -4452,6 +4651,40 @@ function managementClient(options) {
4452
4651
  liveApp: {
4453
4652
  get: (call) => get("/live-app", liveAppSchema, call)
4454
4653
  },
4654
+ /**
4655
+ * The live app's custom domains (docs/public/concepts/hosting.md, "Custom domains"). Reading
4656
+ * needs `read`, from either environment. Adding, re-checking and removing need an organization
4657
+ * admin signed in to Console or the CLI; API keys cannot. A deployment without custom domains
4658
+ * answers 503 `custom-domains-unavailable`.
4659
+ */
4660
+ domains: {
4661
+ list: async (call) => (await get("/domains", customDomainListSchema, call)).domains,
4662
+ get: (id, call) => get(`/domains/${encodeURIComponent(id)}`, customDomainSchema, call),
4663
+ /**
4664
+ * Attaches `hostname`, such as `quests.example.com`, as `awaiting-dns`, with the CNAME and
4665
+ * TXT records to add at its DNS provider. A project has one custom domain.
4666
+ */
4667
+ add: (hostname, call) => post(
4668
+ "/domains",
4669
+ customDomainSchema,
4670
+ customDomainInputSchema.parse({ hostname }),
4671
+ call
4672
+ ),
4673
+ /** Checks DNS and the certificate now and returns what Domino saw. At most every 10 seconds. */
4674
+ recheck: (id, call) => post(
4675
+ `/domains/${encodeURIComponent(id)}/recheck`,
4676
+ customDomainSchema,
4677
+ {},
4678
+ call
4679
+ ),
4680
+ /** Detaches the domain; it stops serving within about a minute. */
4681
+ remove: async (id, call) => {
4682
+ await raw(`/domains/${encodeURIComponent(id)}`, {
4683
+ ...call,
4684
+ method: "DELETE"
4685
+ });
4686
+ }
4687
+ },
4455
4688
  /** The hosted app's secrets. Values are write-only; builds staged after a change receive it. */
4456
4689
  secrets: {
4457
4690
  list: (call) => get("/secrets", appSecretListSchema, call),
@@ -4530,7 +4763,7 @@ function managementClient(options) {
4530
4763
  `/storage/sql/${appSecretNameSchema.parse(name)}/cell?${new URLSearchParams(
4531
4764
  {
4532
4765
  table,
4533
- row: String(z16.number().int().min(0).parse(options2.row)),
4766
+ row: String(z17.number().int().min(0).parse(options2.row)),
4534
4767
  column: options2.column,
4535
4768
  ...options2.cursor === void 0 ? {} : { cursor: pageCursorSchema.parse(options2.cursor) }
4536
4769
  }
@@ -4636,13 +4869,13 @@ function managementClient(options) {
4636
4869
  )
4637
4870
  },
4638
4871
  quests: {
4639
- pause: (quest, input, call) => operationVerb(`quest:${identifier.parse(quest)}`, true, input, call),
4640
- resume: (quest, input, call) => operationVerb(`quest:${identifier.parse(quest)}`, false, input, call),
4872
+ pause: (quest2, input, call) => operationVerb(`quest:${identifier.parse(quest2)}`, true, input, call),
4873
+ resume: (quest2, input, call) => operationVerb(`quest:${identifier.parse(quest2)}`, false, input, call),
4641
4874
  /**
4642
4875
  * Each quest's current release, the most recently published first, archived quests
4643
4876
  * included; requires `read` permission.
4644
4877
  */
4645
- list: (call) => get("/quests/list", z16.array(publishedReleaseSchema), call),
4878
+ list: (call) => get("/quests/list", z17.array(publishedReleaseSchema), call),
4646
4879
  /** Pending and exhausted asynchronous balance checks. Requires read. */
4647
4880
  automaticScheduling: (query = {}, call) => get(
4648
4881
  `/quests/automatic-scheduling${queryString(automaticSchedulingQuerySchema.parse(query))}`,
@@ -4687,7 +4920,7 @@ function managementClient(options) {
4687
4920
  */
4688
4921
  submissions: (member, call) => get(
4689
4922
  `/members/${encodeURIComponent(member)}/quest-submissions`,
4690
- z16.object({ items: z16.array(questSubmissionSchema) }),
4923
+ z17.object({ items: z17.array(questSubmissionSchema) }),
4691
4924
  call
4692
4925
  ),
4693
4926
  /**
@@ -4700,8 +4933,8 @@ function managementClient(options) {
4700
4933
  {},
4701
4934
  call
4702
4935
  ),
4703
- withdraw: (quest, member, input, call) => post(
4704
- `/quests/${encodeURIComponent(quest)}/enrollments/${encodeURIComponent(member)}/withdraw`,
4936
+ withdraw: (quest2, member, input, call) => post(
4937
+ `/quests/${encodeURIComponent(quest2)}/enrollments/${encodeURIComponent(member)}/withdraw`,
4705
4938
  questEnrollmentStateSchema,
4706
4939
  questEnrollmentWithdrawalInputSchema.parse(withActionId(input)),
4707
4940
  call
@@ -4722,8 +4955,8 @@ function managementClient(options) {
4722
4955
  * Stops new participation and hides the quest from collections, with a reason. Completions,
4723
4956
  * attempts and rewards stay. Deploying the quest's code again keeps it archived.
4724
4957
  */
4725
- archive: (quest, input, call) => post(
4726
- `/quests/${identifier.parse(quest)}/archive`,
4958
+ archive: (quest2, input, call) => post(
4959
+ `/quests/${identifier.parse(quest2)}/archive`,
4727
4960
  questLifecycleSchema,
4728
4961
  questLifecycleInputSchema.omit({ quest: true, archived: true }).parse(withActionId(input)),
4729
4962
  call
@@ -4732,8 +4965,8 @@ function managementClient(options) {
4732
4965
  * Opens an archived quest again, with a reason. It must pass the prerequisite graph and the
4733
4966
  * app's supported interactions; it stays paused while a resource setting is empty.
4734
4967
  */
4735
- unarchive: (quest, input, call) => post(
4736
- `/quests/${identifier.parse(quest)}/unarchive`,
4968
+ unarchive: (quest2, input, call) => post(
4969
+ `/quests/${identifier.parse(quest2)}/unarchive`,
4737
4970
  questLifecycleSchema,
4738
4971
  questLifecycleInputSchema.omit({ quest: true, archived: true }).parse(withActionId(input)),
4739
4972
  call
@@ -5120,6 +5353,9 @@ var managementResponseSchemas = lazyResponseReaders({
5120
5353
  get projectMetricsSchema() {
5121
5354
  return knownResponse(projectMetricsSchema);
5122
5355
  },
5356
+ get analyticsReadSchema() {
5357
+ return knownResponse(analyticsReadSchema);
5358
+ },
5123
5359
  get projectSchema() {
5124
5360
  return knownResponse(projectSchema);
5125
5361
  },
@@ -5244,172 +5480,443 @@ var managementResponseSchemas = lazyResponseReaders({
5244
5480
  return knownResponse(xUserSchema);
5245
5481
  }
5246
5482
  });
5247
- var managementResponses = {
5248
- managedBadgeSchema: responseSchema(managedBadgeSchema),
5249
- memberBadgesSchema: responseSchema(memberBadgesSchema),
5250
- badgeMutationResultSchema: responseSchema(badgeMutationResultSchema),
5251
- memberIdentityLinkPageSchema: responseSchema(memberIdentityLinkPageSchema),
5252
- memberIdentityStatePageSchema: responseSchema(memberIdentityStatePageSchema),
5253
- memberIdentityStateSchema: responseSchema(memberIdentityStateSchema),
5254
- managedQuestEnrollmentPageSchema: responseSchema(
5255
- managedQuestEnrollmentPageSchema
5256
- ),
5257
- inventoryItemPageSchema: responseSchema(inventoryItemPageSchema),
5258
- inventoryItemStateSchema: responseSchema(inventoryItemStateSchema),
5259
- questEnrollmentStateSchema: responseSchema(questEnrollmentStateSchema),
5260
- managedQuestEnrollmentSchema: responseSchema(managedQuestEnrollmentSchema),
5261
- memberIdentityLinkSchema: responseSchema(memberIdentityLinkSchema),
5262
- leaderboardSettlementReviewSchema: responseSchema(
5263
- leaderboardSettlementReviewSchema
5264
- ),
5265
- leaderboardSettlementReviewSummarySchema: responseSchema(
5266
- leaderboardSettlementReviewSummarySchema
5267
- ),
5268
- leaderboardSettlementReviewPageSchema: responseSchema(
5269
- leaderboardSettlementReviewPageSchema
5270
- ),
5271
- webhookEndpointStateSchema: responseSchema(webhookEndpointStateSchema),
5272
- webhookStatePageSchema: responseSchema(webhookStatePageSchema),
5273
- accessSchema: responseSchema(accessSchema),
5274
- allocatedQuestSchema: responseSchema(allocatedQuestSchema),
5275
- appSecretListSchema: responseSchema(appSecretListSchema),
5276
- appSecretSchema: responseSchema(appSecretSchema),
5277
- appStorageCellPageSchema: responseSchema(appStorageCellPageSchema),
5278
- appStorageKeysSchema: responseSchema(appStorageKeysSchema),
5279
- appStorageListSchema: responseSchema(appStorageListSchema),
5280
- appStorageRowsSchema: responseSchema(appStorageRowsSchema),
5281
- appStorageTablesSchema: responseSchema(appStorageTablesSchema),
5282
- appStorageValueSchema: responseSchema(appStorageValueSchema),
5283
- attemptSchema: responseSchema(attemptSchema),
5284
- auditPageSchema: responseSchema(auditPageSchema),
5285
- automaticCatchUpPreviewSchema: responseSchema(automaticCatchUpPreviewSchema),
5286
- automaticCatchUpResultSchema: responseSchema(automaticCatchUpResultSchema),
5287
- automaticOutcomePageSchema: responseSchema(automaticOutcomePageSchema),
5288
- automaticSchedulingPageSchema: responseSchema(automaticSchedulingPageSchema),
5289
- automaticSchedulingSchema: responseSchema(automaticSchedulingSchema),
5290
- campaignEnrollmentSchema: responseSchema(campaignEnrollmentSchema),
5291
- catalogDeploymentPreviewSchema: responseSchema(
5292
- catalogDeploymentPreviewSchema
5293
- ),
5294
- collectionPreviewSchema: responseSchema(collectionPreviewSchema),
5295
- completionRevocationSchema: responseSchema(completionRevocationSchema),
5296
- contentPerformancePageSchema: responseSchema(contentPerformancePageSchema),
5297
- contentQualificationPageSchema: responseSchema(
5298
- contentQualificationPageSchema
5299
- ),
5300
- counterHistorySchema: responseSchema(counterHistorySchema),
5301
- counterModerationResultSchema: responseSchema(counterModerationResultSchema),
5302
- deploymentHistoryPageSchema: responseSchema(deploymentHistoryPageSchema),
5303
- deploymentPreviewSchema: responseSchema(deploymentPreviewSchema),
5304
- deploymentRecordSchema: responseSchema(deploymentRecordSchema),
5305
- deploymentResultSchema: responseSchema(deploymentResultSchema),
5306
- engagementBoundaryPageSchema: responseSchema(engagementBoundaryPageSchema),
5307
- engagementChangePreviewSchema: responseSchema(engagementChangePreviewSchema),
5308
- engagementPageSchema: responseSchema(engagementPageSchema),
5309
- engagementRuleSchema: responseSchema(engagementRuleSchema),
5310
- engagementRuleVersionPageSchema: responseSchema(
5311
- engagementRuleVersionPageSchema
5312
- ),
5313
- engagementVersionPageSchema: responseSchema(engagementVersionPageSchema),
5314
- entitlementSchema: responseSchema(entitlementSchema),
5315
- grantRecordSchema: responseSchema(grantRecordSchema),
5316
- groupMemberPageSchema: responseSchema(groupMemberPageSchema),
5317
- groupMemberSchema: responseSchema(groupMemberSchema),
5318
- groupPageSchema: responseSchema(groupPageSchema),
5319
- identityIntegrationSchema: responseSchema(identityIntegrationSchema),
5320
- identityIntegrationSecretSchema: responseSchema(
5321
- identityIntegrationSecretSchema
5322
- ),
5323
- identityKindClaimSchema: responseSchema(identityKindClaimSchema),
5324
- issuedTokenSchema: responseSchema(issuedTokenSchema),
5325
- serviceKeySchema: responseSchema(serviceKeySchema),
5326
- issuedServiceKeySchema: responseSchema(issuedServiceKeySchema),
5327
- leaderboardPageSchema: responseSchema(leaderboardPageSchema),
5328
- leaderboardSettlementSchema: responseSchema(leaderboardSettlementSchema),
5329
- leaderboardSettlementSummarySchema: responseSchema(
5330
- leaderboardSettlementSummarySchema
5331
- ),
5332
- managedAttemptPageSchema: responseSchema(managedAttemptPageSchema),
5333
- managedReleasePageSchema: responseSchema(managedReleasePageSchema),
5334
- managedAttemptSchema: responseSchema(managedAttemptSchema),
5335
- managedEntitlementPageSchema: responseSchema(managedEntitlementPageSchema),
5336
- managedEntitlementSchema: responseSchema(managedEntitlementSchema),
5337
- managedGroupSchema: responseSchema(managedGroupSchema),
5338
- managedMemberIdentitySchema: responseSchema(managedMemberIdentitySchema),
5339
- managedMemberPageSchema: responseSchema(managedMemberPageSchema),
5340
- managedMemberProgressSchema: responseSchema(managedMemberProgressSchema),
5341
- memberImportPageSchema: responseSchema(memberImportPageSchema),
5342
- memberImportRowPageSchema: responseSchema(memberImportRowPageSchema),
5343
- memberImportSchema: responseSchema(memberImportSchema),
5344
- managedOAuthAccountSchema: responseSchema(managedOAuthAccountSchema),
5345
- managedTelegramAccountSchema: responseSchema(managedTelegramAccountSchema),
5346
- telegramChatsSchema: responseSchema(telegramChatsSchema),
5347
- telegramChatConnectionSchema: responseSchema(telegramChatConnectionSchema),
5348
- managedPointHistoryPageSchema: responseSchema(managedPointHistoryPageSchema),
5349
- managedPointLedgerSchema: responseSchema(managedPointLedgerSchema),
5350
- managedProfileSchema: responseSchema(managedProfileSchema),
5351
- managedResourceSchema: responseSchema(managedResourceSchema),
5352
- managedStockItemSchema: responseSchema(managedStockItemSchema),
5353
- managedWalletSchema: responseSchema(managedWalletSchema),
5354
- memberDetailSchema: responseSchema(memberDetailSchema),
5355
- offerSchema: responseSchema(offerSchema),
5356
- operationSchema: responseSchema(operationSchema),
5357
- pageSchema: responseSchema(pageSchema),
5358
- participantSignInSchema: responseSchema(participantSignInSchema),
5359
- personSchema: responseSchema(personSchema),
5360
- pickupAvailabilitySchema: responseSchema(pickupAvailabilitySchema),
5361
- pickupCatalogSchema: responseSchema(pickupCatalogSchema),
5362
- pointLedgerSchema: responseSchema(pointLedgerSchema),
5363
- pointsAccountSchema: responseSchema(pointsAccountSchema),
5364
- pointsResultSchema: responseSchema(pointsResultSchema),
5365
- profileSettingsSchema: responseSchema(profileSettingsSchema),
5366
- projectCalendarSchema: responseSchema(projectCalendarSchema),
5367
- projectDeletionSchema: responseSchema(projectDeletionSchema),
5368
- projectMetricsSchema: responseSchema(projectMetricsSchema),
5369
- projectSchema: responseSchema(projectSchema),
5370
- projectTransferSchema: responseSchema(projectTransferSchema),
5371
- publishedLeaderboardSchema: responseSchema(publishedLeaderboardSchema),
5372
- publishedReferralSchema: responseSchema(publishedReferralSchema),
5373
- publishedReleaseSchema: responseSchema(publishedReleaseSchema),
5374
- questCatalogSchema: responseSchema(questCatalogSchema),
5375
- questDraftSchema: responseSchema(questDraftSchema),
5376
- questEnrollmentSchema: responseSchema(questEnrollmentSchema),
5377
- questLifecycleSchema: responseSchema(questLifecycleSchema),
5378
- questPublicationPreviewSchema: responseSchema(questPublicationPreviewSchema),
5379
- readinessSchema: responseSchema(readinessSchema),
5380
- redemptionSchema: responseSchema(redemptionSchema),
5381
- redemptionPageSchema: responseSchema(redemptionPageSchema),
5382
- referralHistorySchema: responseSchema(referralHistorySchema),
5383
- referralManagementSchema: responseSchema(referralManagementSchema),
5384
- resourceLifecycleResultSchema: responseSchema(resourceLifecycleResultSchema),
5385
- rewardDeliveriesSchema: responseSchema(rewardDeliveriesSchema),
5386
- rewardDeliverySchema: responseSchema(rewardDeliverySchema),
5387
- stockAdditionSchema: responseSchema(stockAdditionSchema),
5388
- stockItemSchema: responseSchema(stockItemSchema),
5389
- teamSchema: responseSchema(teamSchema),
5390
- testMemberHistorySchema: responseSchema(testMemberHistorySchema),
5391
- testMemberRecordResultSchema: responseSchema(testMemberRecordResultSchema),
5392
- testMemberResetResultSchema: responseSchema(testMemberResetResultSchema),
5393
- testMemberSchema: responseSchema(testMemberSchema),
5394
- tokenSchema: responseSchema(tokenSchema),
5395
- trackerContentSchema: responseSchema(trackerContentSchema),
5396
- trackerIngestResultSchema: responseSchema(trackerIngestResultSchema),
5397
- trackerOutcomePageSchema: responseSchema(trackerOutcomePageSchema),
5398
- trackerOutcomeSchema: responseSchema(trackerOutcomeSchema),
5399
- trackerPageSchema: responseSchema(trackerPageSchema),
5400
- trackerPreviewSchema: responseSchema(trackerPreviewSchema),
5401
- trackerStatusSchema: responseSchema(trackerStatusSchema),
5402
- trackerSummarySchema: responseSchema(trackerSummarySchema),
5403
- trackerTriggerOutcomePageSchema: responseSchema(
5404
- trackerTriggerOutcomePageSchema
5405
- ),
5406
- walletBalanceChainsSchema: responseSchema(walletBalanceChainsSchema),
5407
- webhookDeliveryPageSchema: responseSchema(webhookDeliveryPageSchema),
5408
- webhookDeliverySchema: responseSchema(webhookDeliverySchema),
5409
- webhookEndpointSchema: responseSchema(webhookEndpointSchema),
5410
- webhookSecretSchema: responseSchema(webhookSecretSchema),
5411
- xUserSchema: responseSchema(xUserSchema)
5412
- };
5483
+ var managementResponses = lazyResponseReaders({
5484
+ get managedBadgeSchema() {
5485
+ return responseSchema(managedBadgeSchema);
5486
+ },
5487
+ get memberBadgesSchema() {
5488
+ return responseSchema(memberBadgesSchema);
5489
+ },
5490
+ get badgeMutationResultSchema() {
5491
+ return responseSchema(badgeMutationResultSchema);
5492
+ },
5493
+ get memberIdentityLinkPageSchema() {
5494
+ return responseSchema(memberIdentityLinkPageSchema);
5495
+ },
5496
+ get memberIdentityStatePageSchema() {
5497
+ return responseSchema(memberIdentityStatePageSchema);
5498
+ },
5499
+ get memberIdentityStateSchema() {
5500
+ return responseSchema(memberIdentityStateSchema);
5501
+ },
5502
+ get managedQuestEnrollmentPageSchema() {
5503
+ return responseSchema(managedQuestEnrollmentPageSchema);
5504
+ },
5505
+ get inventoryItemPageSchema() {
5506
+ return responseSchema(inventoryItemPageSchema);
5507
+ },
5508
+ get inventoryItemStateSchema() {
5509
+ return responseSchema(inventoryItemStateSchema);
5510
+ },
5511
+ get questEnrollmentStateSchema() {
5512
+ return responseSchema(questEnrollmentStateSchema);
5513
+ },
5514
+ get managedQuestEnrollmentSchema() {
5515
+ return responseSchema(managedQuestEnrollmentSchema);
5516
+ },
5517
+ get memberIdentityLinkSchema() {
5518
+ return responseSchema(memberIdentityLinkSchema);
5519
+ },
5520
+ get leaderboardSettlementReviewSchema() {
5521
+ return responseSchema(leaderboardSettlementReviewSchema);
5522
+ },
5523
+ get leaderboardSettlementReviewSummarySchema() {
5524
+ return responseSchema(leaderboardSettlementReviewSummarySchema);
5525
+ },
5526
+ get leaderboardSettlementReviewPageSchema() {
5527
+ return responseSchema(leaderboardSettlementReviewPageSchema);
5528
+ },
5529
+ get webhookEndpointStateSchema() {
5530
+ return responseSchema(webhookEndpointStateSchema);
5531
+ },
5532
+ get webhookStatePageSchema() {
5533
+ return responseSchema(webhookStatePageSchema);
5534
+ },
5535
+ get accessSchema() {
5536
+ return responseSchema(accessSchema);
5537
+ },
5538
+ get allocatedQuestSchema() {
5539
+ return responseSchema(allocatedQuestSchema);
5540
+ },
5541
+ get appSecretListSchema() {
5542
+ return responseSchema(appSecretListSchema);
5543
+ },
5544
+ get appSecretSchema() {
5545
+ return responseSchema(appSecretSchema);
5546
+ },
5547
+ get appStorageCellPageSchema() {
5548
+ return responseSchema(appStorageCellPageSchema);
5549
+ },
5550
+ get appStorageKeysSchema() {
5551
+ return responseSchema(appStorageKeysSchema);
5552
+ },
5553
+ get appStorageListSchema() {
5554
+ return responseSchema(appStorageListSchema);
5555
+ },
5556
+ get appStorageRowsSchema() {
5557
+ return responseSchema(appStorageRowsSchema);
5558
+ },
5559
+ get appStorageTablesSchema() {
5560
+ return responseSchema(appStorageTablesSchema);
5561
+ },
5562
+ get appStorageValueSchema() {
5563
+ return responseSchema(appStorageValueSchema);
5564
+ },
5565
+ get attemptSchema() {
5566
+ return responseSchema(attemptSchema);
5567
+ },
5568
+ get auditPageSchema() {
5569
+ return responseSchema(auditPageSchema);
5570
+ },
5571
+ get automaticCatchUpPreviewSchema() {
5572
+ return responseSchema(automaticCatchUpPreviewSchema);
5573
+ },
5574
+ get automaticCatchUpResultSchema() {
5575
+ return responseSchema(automaticCatchUpResultSchema);
5576
+ },
5577
+ get automaticOutcomePageSchema() {
5578
+ return responseSchema(automaticOutcomePageSchema);
5579
+ },
5580
+ get automaticSchedulingPageSchema() {
5581
+ return responseSchema(automaticSchedulingPageSchema);
5582
+ },
5583
+ get automaticSchedulingSchema() {
5584
+ return responseSchema(automaticSchedulingSchema);
5585
+ },
5586
+ get campaignEnrollmentSchema() {
5587
+ return responseSchema(campaignEnrollmentSchema);
5588
+ },
5589
+ get catalogDeploymentPreviewSchema() {
5590
+ return responseSchema(catalogDeploymentPreviewSchema);
5591
+ },
5592
+ get collectionPreviewSchema() {
5593
+ return responseSchema(collectionPreviewSchema);
5594
+ },
5595
+ get completionRevocationSchema() {
5596
+ return responseSchema(completionRevocationSchema);
5597
+ },
5598
+ get contentPerformancePageSchema() {
5599
+ return responseSchema(contentPerformancePageSchema);
5600
+ },
5601
+ get contentQualificationPageSchema() {
5602
+ return responseSchema(contentQualificationPageSchema);
5603
+ },
5604
+ get counterHistorySchema() {
5605
+ return responseSchema(counterHistorySchema);
5606
+ },
5607
+ get counterModerationResultSchema() {
5608
+ return responseSchema(counterModerationResultSchema);
5609
+ },
5610
+ get deploymentHistoryPageSchema() {
5611
+ return responseSchema(deploymentHistoryPageSchema);
5612
+ },
5613
+ get deploymentPreviewSchema() {
5614
+ return responseSchema(deploymentPreviewSchema);
5615
+ },
5616
+ get deploymentRecordSchema() {
5617
+ return responseSchema(deploymentRecordSchema);
5618
+ },
5619
+ get deploymentResultSchema() {
5620
+ return responseSchema(deploymentResultSchema);
5621
+ },
5622
+ get engagementBoundaryPageSchema() {
5623
+ return responseSchema(engagementBoundaryPageSchema);
5624
+ },
5625
+ get engagementChangePreviewSchema() {
5626
+ return responseSchema(engagementChangePreviewSchema);
5627
+ },
5628
+ get engagementPageSchema() {
5629
+ return responseSchema(engagementPageSchema);
5630
+ },
5631
+ get engagementRuleSchema() {
5632
+ return responseSchema(engagementRuleSchema);
5633
+ },
5634
+ get engagementRuleVersionPageSchema() {
5635
+ return responseSchema(engagementRuleVersionPageSchema);
5636
+ },
5637
+ get engagementVersionPageSchema() {
5638
+ return responseSchema(engagementVersionPageSchema);
5639
+ },
5640
+ get entitlementSchema() {
5641
+ return responseSchema(entitlementSchema);
5642
+ },
5643
+ get grantRecordSchema() {
5644
+ return responseSchema(grantRecordSchema);
5645
+ },
5646
+ get groupMemberPageSchema() {
5647
+ return responseSchema(groupMemberPageSchema);
5648
+ },
5649
+ get groupMemberSchema() {
5650
+ return responseSchema(groupMemberSchema);
5651
+ },
5652
+ get groupPageSchema() {
5653
+ return responseSchema(groupPageSchema);
5654
+ },
5655
+ get identityIntegrationSchema() {
5656
+ return responseSchema(identityIntegrationSchema);
5657
+ },
5658
+ get identityIntegrationSecretSchema() {
5659
+ return responseSchema(identityIntegrationSecretSchema);
5660
+ },
5661
+ get identityKindClaimSchema() {
5662
+ return responseSchema(identityKindClaimSchema);
5663
+ },
5664
+ get issuedTokenSchema() {
5665
+ return responseSchema(issuedTokenSchema);
5666
+ },
5667
+ get serviceKeySchema() {
5668
+ return responseSchema(serviceKeySchema);
5669
+ },
5670
+ get issuedServiceKeySchema() {
5671
+ return responseSchema(issuedServiceKeySchema);
5672
+ },
5673
+ get leaderboardPageSchema() {
5674
+ return responseSchema(leaderboardPageSchema);
5675
+ },
5676
+ get leaderboardSettlementSchema() {
5677
+ return responseSchema(leaderboardSettlementSchema);
5678
+ },
5679
+ get leaderboardSettlementSummarySchema() {
5680
+ return responseSchema(leaderboardSettlementSummarySchema);
5681
+ },
5682
+ get managedAttemptPageSchema() {
5683
+ return responseSchema(managedAttemptPageSchema);
5684
+ },
5685
+ get managedReleasePageSchema() {
5686
+ return responseSchema(managedReleasePageSchema);
5687
+ },
5688
+ get managedAttemptSchema() {
5689
+ return responseSchema(managedAttemptSchema);
5690
+ },
5691
+ get managedEntitlementPageSchema() {
5692
+ return responseSchema(managedEntitlementPageSchema);
5693
+ },
5694
+ get managedEntitlementSchema() {
5695
+ return responseSchema(managedEntitlementSchema);
5696
+ },
5697
+ get managedGroupSchema() {
5698
+ return responseSchema(managedGroupSchema);
5699
+ },
5700
+ get managedMemberIdentitySchema() {
5701
+ return responseSchema(managedMemberIdentitySchema);
5702
+ },
5703
+ get managedMemberPageSchema() {
5704
+ return responseSchema(managedMemberPageSchema);
5705
+ },
5706
+ get managedMemberProgressSchema() {
5707
+ return responseSchema(managedMemberProgressSchema);
5708
+ },
5709
+ get memberImportPageSchema() {
5710
+ return responseSchema(memberImportPageSchema);
5711
+ },
5712
+ get memberImportRowPageSchema() {
5713
+ return responseSchema(memberImportRowPageSchema);
5714
+ },
5715
+ get memberImportSchema() {
5716
+ return responseSchema(memberImportSchema);
5717
+ },
5718
+ get managedOAuthAccountSchema() {
5719
+ return responseSchema(managedOAuthAccountSchema);
5720
+ },
5721
+ get managedTelegramAccountSchema() {
5722
+ return responseSchema(managedTelegramAccountSchema);
5723
+ },
5724
+ get telegramChatsSchema() {
5725
+ return responseSchema(telegramChatsSchema);
5726
+ },
5727
+ get telegramChatConnectionSchema() {
5728
+ return responseSchema(telegramChatConnectionSchema);
5729
+ },
5730
+ get managedPointHistoryPageSchema() {
5731
+ return responseSchema(managedPointHistoryPageSchema);
5732
+ },
5733
+ get managedPointLedgerSchema() {
5734
+ return responseSchema(managedPointLedgerSchema);
5735
+ },
5736
+ get managedProfileSchema() {
5737
+ return responseSchema(managedProfileSchema);
5738
+ },
5739
+ get managedResourceSchema() {
5740
+ return responseSchema(managedResourceSchema);
5741
+ },
5742
+ get managedStockItemSchema() {
5743
+ return responseSchema(managedStockItemSchema);
5744
+ },
5745
+ get managedWalletSchema() {
5746
+ return responseSchema(managedWalletSchema);
5747
+ },
5748
+ get memberDetailSchema() {
5749
+ return responseSchema(memberDetailSchema);
5750
+ },
5751
+ get offerSchema() {
5752
+ return responseSchema(offerSchema);
5753
+ },
5754
+ get operationSchema() {
5755
+ return responseSchema(operationSchema);
5756
+ },
5757
+ get pageSchema() {
5758
+ return responseSchema(pageSchema);
5759
+ },
5760
+ get participantSignInSchema() {
5761
+ return responseSchema(participantSignInSchema);
5762
+ },
5763
+ get personSchema() {
5764
+ return responseSchema(personSchema);
5765
+ },
5766
+ get pickupAvailabilitySchema() {
5767
+ return responseSchema(pickupAvailabilitySchema);
5768
+ },
5769
+ get pickupCatalogSchema() {
5770
+ return responseSchema(pickupCatalogSchema);
5771
+ },
5772
+ get pointLedgerSchema() {
5773
+ return responseSchema(pointLedgerSchema);
5774
+ },
5775
+ get pointsAccountSchema() {
5776
+ return responseSchema(pointsAccountSchema);
5777
+ },
5778
+ get pointsResultSchema() {
5779
+ return responseSchema(pointsResultSchema);
5780
+ },
5781
+ get profileSettingsSchema() {
5782
+ return responseSchema(profileSettingsSchema);
5783
+ },
5784
+ get projectCalendarSchema() {
5785
+ return responseSchema(projectCalendarSchema);
5786
+ },
5787
+ get projectDeletionSchema() {
5788
+ return responseSchema(projectDeletionSchema);
5789
+ },
5790
+ get projectMetricsSchema() {
5791
+ return responseSchema(projectMetricsSchema);
5792
+ },
5793
+ get analyticsReadSchema() {
5794
+ return responseSchema(analyticsReadSchema);
5795
+ },
5796
+ get projectSchema() {
5797
+ return responseSchema(projectSchema);
5798
+ },
5799
+ get projectTransferSchema() {
5800
+ return responseSchema(projectTransferSchema);
5801
+ },
5802
+ get publishedLeaderboardSchema() {
5803
+ return responseSchema(publishedLeaderboardSchema);
5804
+ },
5805
+ get publishedReferralSchema() {
5806
+ return responseSchema(publishedReferralSchema);
5807
+ },
5808
+ get publishedReleaseSchema() {
5809
+ return responseSchema(publishedReleaseSchema);
5810
+ },
5811
+ get questCatalogSchema() {
5812
+ return responseSchema(questCatalogSchema);
5813
+ },
5814
+ get questDraftSchema() {
5815
+ return responseSchema(questDraftSchema);
5816
+ },
5817
+ get questEnrollmentSchema() {
5818
+ return responseSchema(questEnrollmentSchema);
5819
+ },
5820
+ get questLifecycleSchema() {
5821
+ return responseSchema(questLifecycleSchema);
5822
+ },
5823
+ get questPublicationPreviewSchema() {
5824
+ return responseSchema(questPublicationPreviewSchema);
5825
+ },
5826
+ get readinessSchema() {
5827
+ return responseSchema(readinessSchema);
5828
+ },
5829
+ get redemptionSchema() {
5830
+ return responseSchema(redemptionSchema);
5831
+ },
5832
+ get redemptionPageSchema() {
5833
+ return responseSchema(redemptionPageSchema);
5834
+ },
5835
+ get referralHistorySchema() {
5836
+ return responseSchema(referralHistorySchema);
5837
+ },
5838
+ get referralManagementSchema() {
5839
+ return responseSchema(referralManagementSchema);
5840
+ },
5841
+ get resourceLifecycleResultSchema() {
5842
+ return responseSchema(resourceLifecycleResultSchema);
5843
+ },
5844
+ get rewardDeliveriesSchema() {
5845
+ return responseSchema(rewardDeliveriesSchema);
5846
+ },
5847
+ get rewardDeliverySchema() {
5848
+ return responseSchema(rewardDeliverySchema);
5849
+ },
5850
+ get stockAdditionSchema() {
5851
+ return responseSchema(stockAdditionSchema);
5852
+ },
5853
+ get stockItemSchema() {
5854
+ return responseSchema(stockItemSchema);
5855
+ },
5856
+ get teamSchema() {
5857
+ return responseSchema(teamSchema);
5858
+ },
5859
+ get testMemberHistorySchema() {
5860
+ return responseSchema(testMemberHistorySchema);
5861
+ },
5862
+ get testMemberRecordResultSchema() {
5863
+ return responseSchema(testMemberRecordResultSchema);
5864
+ },
5865
+ get testMemberResetResultSchema() {
5866
+ return responseSchema(testMemberResetResultSchema);
5867
+ },
5868
+ get testMemberSchema() {
5869
+ return responseSchema(testMemberSchema);
5870
+ },
5871
+ get tokenSchema() {
5872
+ return responseSchema(tokenSchema);
5873
+ },
5874
+ get trackerContentSchema() {
5875
+ return responseSchema(trackerContentSchema);
5876
+ },
5877
+ get trackerIngestResultSchema() {
5878
+ return responseSchema(trackerIngestResultSchema);
5879
+ },
5880
+ get trackerOutcomePageSchema() {
5881
+ return responseSchema(trackerOutcomePageSchema);
5882
+ },
5883
+ get trackerOutcomeSchema() {
5884
+ return responseSchema(trackerOutcomeSchema);
5885
+ },
5886
+ get trackerPageSchema() {
5887
+ return responseSchema(trackerPageSchema);
5888
+ },
5889
+ get trackerPreviewSchema() {
5890
+ return responseSchema(trackerPreviewSchema);
5891
+ },
5892
+ get trackerStatusSchema() {
5893
+ return responseSchema(trackerStatusSchema);
5894
+ },
5895
+ get trackerSummarySchema() {
5896
+ return responseSchema(trackerSummarySchema);
5897
+ },
5898
+ get trackerTriggerOutcomePageSchema() {
5899
+ return responseSchema(trackerTriggerOutcomePageSchema);
5900
+ },
5901
+ get walletBalanceChainsSchema() {
5902
+ return responseSchema(walletBalanceChainsSchema);
5903
+ },
5904
+ get webhookDeliveryPageSchema() {
5905
+ return responseSchema(webhookDeliveryPageSchema);
5906
+ },
5907
+ get webhookDeliverySchema() {
5908
+ return responseSchema(webhookDeliverySchema);
5909
+ },
5910
+ get webhookEndpointSchema() {
5911
+ return responseSchema(webhookEndpointSchema);
5912
+ },
5913
+ get webhookSecretSchema() {
5914
+ return responseSchema(webhookSecretSchema);
5915
+ },
5916
+ get xUserSchema() {
5917
+ return responseSchema(xUserSchema);
5918
+ }
5919
+ });
5413
5920
  export {
5414
5921
  APP_KV_LIMIT,
5415
5922
  APP_MIGRATION_FILE_BYTES,
@@ -5442,6 +5949,9 @@ export {
5442
5949
  activityTypeSchema,
5443
5950
  activityTypes,
5444
5951
  addGroupMemberSchema,
5952
+ analyticsQuerySchema,
5953
+ analyticsRanges,
5954
+ analyticsReadSchema,
5445
5955
  appIdentitySelectorSchema,
5446
5956
  appMigrationNameSchema,
5447
5957
  appRoutingSchema,
@@ -5699,6 +6209,7 @@ export {
5699
6209
  testMemberPassSchema,
5700
6210
  testMemberRecordResultSchema,
5701
6211
  testMemberRecordSchema,
6212
+ testMemberReferralAcceptSchema,
5702
6213
  testMemberResetResultSchema,
5703
6214
  testMemberResetSchema,
5704
6215
  testMemberSchema,