@diffenderfer-games/hub-contract 2.0.0-next.1 → 2.0.0-next.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -123,6 +123,9 @@ declare const errorCode: z.ZodEnum<{
123
123
  bad_info: "bad_info";
124
124
  launch_invalid: "launch_invalid";
125
125
  not_joinable: "not_joinable";
126
+ link_invalid: "link_invalid";
127
+ link_room_gone: "link_room_gone";
128
+ too_many_links: "too_many_links";
126
129
  bad_quick: "bad_quick";
127
130
  room_not_found: "room_not_found";
128
131
  not_in_room: "not_in_room";
@@ -142,6 +145,14 @@ declare const errorCode: z.ZodEnum<{
142
145
  too_fast: "too_fast";
143
146
  bad_stats: "bad_stats";
144
147
  bad_param: "bad_param";
148
+ tournament_not_found: "tournament_not_found";
149
+ tournament_closed: "tournament_closed";
150
+ tournament_full: "tournament_full";
151
+ tournament_over: "tournament_over";
152
+ not_creator: "not_creator";
153
+ not_entered: "not_entered";
154
+ cannot_join: "cannot_join";
155
+ match_not_ready: "match_not_ready";
145
156
  }>;
146
157
  /** The type of the {@link ErrorCode} schema. */
147
158
  export interface ErrorCodeSchema extends Readonly<typeof errorCode> {}
@@ -150,11 +161,11 @@ export declare const ErrorCode: ErrorCodeSchema;
150
161
  /** A public error code. */
151
162
  export type ErrorCode = z.infer<ErrorCodeSchema>;
152
163
  declare const rejectReason: z.ZodEnum<{
153
- link: "link";
154
164
  suspended: "suspended";
155
165
  rate_limited: "rate_limited";
156
166
  not_friends: "not_friends";
157
167
  dms_closed: "dms_closed";
168
+ link: "link";
158
169
  personal_info: "personal_info";
159
170
  contact: "contact";
160
171
  language: "language";
@@ -224,6 +235,9 @@ declare const errorBody: z.ZodObject<{
224
235
  bad_info: "bad_info";
225
236
  launch_invalid: "launch_invalid";
226
237
  not_joinable: "not_joinable";
238
+ link_invalid: "link_invalid";
239
+ link_room_gone: "link_room_gone";
240
+ too_many_links: "too_many_links";
227
241
  bad_quick: "bad_quick";
228
242
  room_not_found: "room_not_found";
229
243
  not_in_room: "not_in_room";
@@ -243,13 +257,21 @@ declare const errorBody: z.ZodObject<{
243
257
  too_fast: "too_fast";
244
258
  bad_stats: "bad_stats";
245
259
  bad_param: "bad_param";
260
+ tournament_not_found: "tournament_not_found";
261
+ tournament_closed: "tournament_closed";
262
+ tournament_full: "tournament_full";
263
+ tournament_over: "tournament_over";
264
+ not_creator: "not_creator";
265
+ not_entered: "not_entered";
266
+ cannot_join: "cannot_join";
267
+ match_not_ready: "match_not_ready";
246
268
  }>>;
247
269
  reason: z.ZodOptional<z.ZodEnum<{
248
- link: "link";
249
270
  suspended: "suspended";
250
271
  rate_limited: "rate_limited";
251
272
  not_friends: "not_friends";
252
273
  dms_closed: "dms_closed";
274
+ link: "link";
253
275
  personal_info: "personal_info";
254
276
  contact: "contact";
255
277
  language: "language";
@@ -673,6 +695,88 @@ export declare const authEndpoints: {
673
695
  }, {}, import("@ayepi/core").EmptyObject>;
674
696
  };
675
697
  //#endregion
698
+ //#region src/api/catalog-activity.d.ts
699
+ /**
700
+ * How many people have a game open right now: claimed accounts and guests.
701
+ * Counts only, so no player is ever identified.
702
+ */
703
+ export declare const GamePlayerCount: z.ZodObject<{
704
+ accounts: z.ZodNumber;
705
+ guests: z.ZodNumber;
706
+ }, z.core.$strip>;
707
+ /** How many people have a game open right now. */
708
+ export type GamePlayerCount = z.infer<typeof GamePlayerCount>;
709
+ /** Head counts per game slug; games nobody has open are absent. */
710
+ export declare const GamePlayerCounts: z.ZodRecord<z.ZodString, z.ZodObject<{
711
+ accounts: z.ZodNumber;
712
+ guests: z.ZodNumber;
713
+ }, z.core.$strip>>;
714
+ /** Head counts per game slug. */
715
+ export type GamePlayerCounts = z.infer<typeof GamePlayerCounts>;
716
+ /** The caller's activity in one game, within the analytics retention window. */
717
+ export declare const MyGameActivity: z.ZodObject<{
718
+ plays: z.ZodNumber;
719
+ minutesPlayed: z.ZodNumber;
720
+ firstPlayedAt: z.ZodNullable<z.ZodNumber>;
721
+ lastPlayedAt: z.ZodNullable<z.ZodNumber>;
722
+ windowDays: z.ZodNumber;
723
+ }, z.core.$strip>;
724
+ /** The caller's activity in one game. */
725
+ export type MyGameActivity = z.infer<typeof MyGameActivity>;
726
+ /** The activity endpoints (part of the catalog area). */
727
+ export declare const catalogActivityEndpoints: {
728
+ getMyGameActivity: import("@ayepi/core").Endpoint<{
729
+ readonly method: "GET";
730
+ readonly path: "/me/activity";
731
+ readonly response: z.ZodObject<{
732
+ plays: z.ZodNumber;
733
+ minutesPlayed: z.ZodNumber;
734
+ firstPlayedAt: z.ZodNullable<z.ZodNumber>;
735
+ lastPlayedAt: z.ZodNullable<z.ZodNumber>;
736
+ windowDays: z.ZodNumber;
737
+ }, z.core.$strip>;
738
+ readonly errors: {
739
+ readonly 401: ErrorBodySchema;
740
+ readonly 404: ErrorBodySchema;
741
+ };
742
+ readonly doc: {
743
+ readonly summary: "The caller's plays and time played in this game";
744
+ readonly tags: readonly ["catalog"];
745
+ };
746
+ }, {
747
+ user: {
748
+ id: number;
749
+ username: string;
750
+ guest: boolean;
751
+ role: "" | "admin";
752
+ avatar: string;
753
+ chatLock: boolean;
754
+ mutedUntil: number;
755
+ suspendedUntil: number;
756
+ };
757
+ clientId: string;
758
+ }, {
759
+ slug: z.ZodString;
760
+ }, {}>;
761
+ getGamePlayerCounts: import("@ayepi/core").Endpoint<{
762
+ readonly method: "GET";
763
+ readonly path: "/catalog/players";
764
+ readonly response: z.ZodObject<{
765
+ games: z.ZodRecord<z.ZodString, z.ZodObject<{
766
+ accounts: z.ZodNumber;
767
+ guests: z.ZodNumber;
768
+ }, z.core.$strip>>;
769
+ }, z.core.$strip>;
770
+ readonly doc: {
771
+ readonly summary: "How many accounts and guests have each game open right now (counts only)";
772
+ readonly tags: readonly ["catalog"];
773
+ };
774
+ }, {
775
+ user: SessionUser | null;
776
+ clientId: string;
777
+ }, {}, import("@ayepi/core").EmptyObject>;
778
+ };
779
+ //#endregion
676
780
  //#region src/api/catalog.d.ts
677
781
  /** A `[min, max]` player count, each 1 to 8. */
678
782
  export declare const PlayerRange: z.ZodTuple<[z.ZodNumber, z.ZodNumber], null>;
@@ -772,6 +876,7 @@ export declare const GameInfo: z.ZodObject<{
772
876
  }>;
773
877
  }, z.core.$strip>>;
774
878
  }, z.core.$strip>>;
879
+ tournaments: z.ZodOptional<z.ZodLiteral<true>>;
775
880
  }, z.core.$strip>;
776
881
  /** A listed game. */
777
882
  export type GameInfo = z.infer<typeof GameInfo>;
@@ -904,6 +1009,7 @@ export declare const catalogEndpoints: {
904
1009
  }>;
905
1010
  }, z.core.$strip>>;
906
1011
  }, z.core.$strip>>;
1012
+ tournaments: z.ZodOptional<z.ZodLiteral<true>>;
907
1013
  }, z.core.$strip>>;
908
1014
  }, z.core.$strip>;
909
1015
  readonly doc: {
@@ -941,6 +1047,56 @@ export declare const catalogEndpoints: {
941
1047
  user: SessionUser | null;
942
1048
  clientId: string;
943
1049
  }, {}, import("@ayepi/core").EmptyObject>;
1050
+ getMyGameActivity: import("@ayepi/core").Endpoint<{
1051
+ readonly method: "GET";
1052
+ readonly path: "/me/activity";
1053
+ readonly response: z.ZodObject<{
1054
+ plays: z.ZodNumber;
1055
+ minutesPlayed: z.ZodNumber;
1056
+ firstPlayedAt: z.ZodNullable<z.ZodNumber>;
1057
+ lastPlayedAt: z.ZodNullable<z.ZodNumber>;
1058
+ windowDays: z.ZodNumber;
1059
+ }, z.core.$strip>;
1060
+ readonly errors: {
1061
+ readonly 401: ErrorBodySchema;
1062
+ readonly 404: ErrorBodySchema;
1063
+ };
1064
+ readonly doc: {
1065
+ readonly summary: "The caller's plays and time played in this game";
1066
+ readonly tags: readonly ["catalog"];
1067
+ };
1068
+ }, {
1069
+ user: {
1070
+ id: number;
1071
+ username: string;
1072
+ guest: boolean;
1073
+ role: "" | "admin";
1074
+ avatar: string;
1075
+ chatLock: boolean;
1076
+ mutedUntil: number;
1077
+ suspendedUntil: number;
1078
+ };
1079
+ clientId: string;
1080
+ }, {
1081
+ slug: z.ZodString;
1082
+ }, {}>;
1083
+ getGamePlayerCounts: import("@ayepi/core").Endpoint<{
1084
+ readonly method: "GET";
1085
+ readonly path: "/catalog/players";
1086
+ readonly response: z.ZodObject<{
1087
+ games: z.ZodRecord<z.ZodString, z.ZodObject<{
1088
+ accounts: z.ZodNumber;
1089
+ guests: z.ZodNumber;
1090
+ }, z.core.$strip>>;
1091
+ }, z.core.$strip>;
1092
+ readonly doc: {
1093
+ readonly summary: "How many accounts and guests have each game open right now (counts only)";
1094
+ readonly tags: readonly ["catalog"];
1095
+ };
1096
+ }, {
1097
+ user: SessionUser | null;
1098
+ clientId: string;
1099
+ }, {}, import("@ayepi/core").EmptyObject>;
944
1100
  };
945
1101
  //#endregion
946
1102
  //#region src/api/daily.d.ts
@@ -1144,12 +1300,12 @@ export type Bundle = z.infer<typeof Bundle>;
1144
1300
  //#region src/api/economy/trades.d.ts
1145
1301
  /** Where an offer is in its life. Only `pending` offers can change. */
1146
1302
  export declare const TradeStatus: z.ZodEnum<{
1147
- pending: "pending";
1148
1303
  accepted: "accepted";
1149
1304
  declined: "declined";
1150
1305
  cancelled: "cancelled";
1151
- countered: "countered";
1152
1306
  expired: "expired";
1307
+ pending: "pending";
1308
+ countered: "countered";
1153
1309
  }>;
1154
1310
  /** A trade status. */
1155
1311
  export type TradeStatus = z.infer<typeof TradeStatus>;
@@ -1165,12 +1321,12 @@ export declare const TradeOffer: z.ZodObject<{
1165
1321
  id: z.ZodNumber;
1166
1322
  game: z.ZodString;
1167
1323
  status: z.ZodEnum<{
1168
- pending: "pending";
1169
1324
  accepted: "accepted";
1170
1325
  declined: "declined";
1171
1326
  cancelled: "cancelled";
1172
- countered: "countered";
1173
1327
  expired: "expired";
1328
+ pending: "pending";
1329
+ countered: "countered";
1174
1330
  }>;
1175
1331
  direction: z.ZodEnum<{
1176
1332
  incoming: "incoming";
@@ -1258,12 +1414,12 @@ export declare const economyEndpoints: {
1258
1414
  id: import("zod").ZodNumber;
1259
1415
  game: import("zod").ZodString;
1260
1416
  status: import("zod").ZodEnum<{
1261
- pending: "pending";
1262
1417
  accepted: "accepted";
1263
1418
  declined: "declined";
1264
1419
  cancelled: "cancelled";
1265
- countered: "countered";
1266
1420
  expired: "expired";
1421
+ pending: "pending";
1422
+ countered: "countered";
1267
1423
  }>;
1268
1424
  direction: import("zod").ZodEnum<{
1269
1425
  incoming: "incoming";
@@ -1331,12 +1487,12 @@ export declare const economyEndpoints: {
1331
1487
  id: import("zod").ZodNumber;
1332
1488
  game: import("zod").ZodString;
1333
1489
  status: import("zod").ZodEnum<{
1334
- pending: "pending";
1335
1490
  accepted: "accepted";
1336
1491
  declined: "declined";
1337
1492
  cancelled: "cancelled";
1338
- countered: "countered";
1339
1493
  expired: "expired";
1494
+ pending: "pending";
1495
+ countered: "countered";
1340
1496
  }>;
1341
1497
  direction: import("zod").ZodEnum<{
1342
1498
  incoming: "incoming";
@@ -1413,12 +1569,12 @@ export declare const economyEndpoints: {
1413
1569
  id: import("zod").ZodNumber;
1414
1570
  game: import("zod").ZodString;
1415
1571
  status: import("zod").ZodEnum<{
1416
- pending: "pending";
1417
1572
  accepted: "accepted";
1418
1573
  declined: "declined";
1419
1574
  cancelled: "cancelled";
1420
- countered: "countered";
1421
1575
  expired: "expired";
1576
+ pending: "pending";
1577
+ countered: "countered";
1422
1578
  }>;
1423
1579
  direction: import("zod").ZodEnum<{
1424
1580
  incoming: "incoming";
@@ -1517,12 +1673,12 @@ export declare const economyEndpoints: {
1517
1673
  outgoing: "outgoing";
1518
1674
  }>>>;
1519
1675
  status: import("zod").ZodOptional<import("zod").ZodUnion<readonly [import("zod").ZodEnum<{
1520
- pending: "pending";
1521
1676
  accepted: "accepted";
1522
1677
  declined: "declined";
1523
1678
  cancelled: "cancelled";
1524
- countered: "countered";
1525
1679
  expired: "expired";
1680
+ pending: "pending";
1681
+ countered: "countered";
1526
1682
  }>, import("zod").ZodString]>>;
1527
1683
  }, import("zod/v4/core").$strip>;
1528
1684
  readonly response: import("zod").ZodObject<{
@@ -1530,12 +1686,12 @@ export declare const economyEndpoints: {
1530
1686
  id: import("zod").ZodNumber;
1531
1687
  game: import("zod").ZodString;
1532
1688
  status: import("zod").ZodEnum<{
1533
- pending: "pending";
1534
1689
  accepted: "accepted";
1535
1690
  declined: "declined";
1536
1691
  cancelled: "cancelled";
1537
- countered: "countered";
1538
1692
  expired: "expired";
1693
+ pending: "pending";
1694
+ countered: "countered";
1539
1695
  }>;
1540
1696
  direction: import("zod").ZodEnum<{
1541
1697
  incoming: "incoming";
@@ -1599,12 +1755,12 @@ export declare const economyEndpoints: {
1599
1755
  id: import("zod").ZodNumber;
1600
1756
  game: import("zod").ZodString;
1601
1757
  status: import("zod").ZodEnum<{
1602
- pending: "pending";
1603
1758
  accepted: "accepted";
1604
1759
  declined: "declined";
1605
1760
  cancelled: "cancelled";
1606
- countered: "countered";
1607
1761
  expired: "expired";
1762
+ pending: "pending";
1763
+ countered: "countered";
1608
1764
  }>;
1609
1765
  direction: import("zod").ZodEnum<{
1610
1766
  incoming: "incoming";
@@ -1669,12 +1825,12 @@ export declare const economyEndpoints: {
1669
1825
  id: import("zod").ZodNumber;
1670
1826
  game: import("zod").ZodString;
1671
1827
  status: import("zod").ZodEnum<{
1672
- pending: "pending";
1673
1828
  accepted: "accepted";
1674
1829
  declined: "declined";
1675
1830
  cancelled: "cancelled";
1676
- countered: "countered";
1677
1831
  expired: "expired";
1832
+ pending: "pending";
1833
+ countered: "countered";
1678
1834
  }>;
1679
1835
  direction: import("zod").ZodEnum<{
1680
1836
  incoming: "incoming";
@@ -2373,6 +2529,34 @@ export declare const ChatLineEvent: z.ZodObject<{
2373
2529
  /** The error codes a chat send can fail with (besides its surface's own). */
2374
2530
  export declare const CHAT_ERRORS: readonly ["rate_limited", "content_rejected", "bad_quick"];
2375
2531
  //#endregion
2532
+ //#region src/api/mp/invite-links.d.ts
2533
+ /** An invite link's token (base64url). */
2534
+ export declare const InviteLinkToken: z.ZodString;
2535
+ /** A live invite link. */
2536
+ export declare const InviteLink: z.ZodObject<{
2537
+ token: z.ZodString;
2538
+ url: z.ZodString;
2539
+ game: z.ZodString;
2540
+ mode: z.ZodOptional<z.ZodString>;
2541
+ room: z.ZodString;
2542
+ createdBy: z.ZodNumber;
2543
+ expiresAt: z.ZodNumber;
2544
+ }, z.core.$strip>;
2545
+ /** An invite link. */
2546
+ export type InviteLink = z.infer<typeof InviteLink>;
2547
+ /** `:token` of an invite link. */
2548
+ export declare const InviteLinkParams: z.ZodObject<{
2549
+ token: z.ZodString;
2550
+ }, z.core.$strip>;
2551
+ /** `POST /mp/links` body: a link to the room I'm in, in this game. */
2552
+ export declare const InviteLinkCreate: z.ZodObject<{
2553
+ game: z.ZodString;
2554
+ }, z.core.$strip>;
2555
+ /** `GET /mp/links` query: my links in a game (and the links to rooms I host). */
2556
+ export declare const InviteLinkQuery: z.ZodObject<{
2557
+ game: z.ZodString;
2558
+ }, z.core.$strip>;
2559
+ //#endregion
2376
2560
  //#region src/api/mp/parties.d.ts
2377
2561
  /** A game mode key, as the game's `multiplayer.modes[].key` declares it: `[A-Za-z0-9_-]{1,32}`. */
2378
2562
  export declare const GameMode: z.ZodString;
@@ -2445,8 +2629,8 @@ export type LaunchTicket = z.infer<typeof LaunchTicket>;
2445
2629
  /** Why the hub is bringing a player into a game. */
2446
2630
  export declare const LaunchKind: z.ZodEnum<{
2447
2631
  guest: "guest";
2448
- join: "join";
2449
2632
  host: "host";
2633
+ join: "join";
2450
2634
  watch: "watch";
2451
2635
  }>;
2452
2636
  /**
@@ -2456,8 +2640,8 @@ export declare const LaunchKind: z.ZodEnum<{
2456
2640
  export declare const Launch: z.ZodObject<{
2457
2641
  kind: z.ZodEnum<{
2458
2642
  guest: "guest";
2459
- join: "join";
2460
2643
  host: "host";
2644
+ join: "join";
2461
2645
  watch: "watch";
2462
2646
  }>;
2463
2647
  game: z.ZodString;
@@ -2491,6 +2675,21 @@ export declare const Launch: z.ZodObject<{
2491
2675
  avatar: z.ZodString;
2492
2676
  guest: z.ZodBoolean;
2493
2677
  }, z.core.$strip>>>;
2678
+ via: z.ZodOptional<z.ZodEnum<{
2679
+ link: "link";
2680
+ rejoin: "rejoin";
2681
+ }>>;
2682
+ tournament: z.ZodOptional<z.ZodObject<{
2683
+ id: z.ZodNumber;
2684
+ title: z.ZodString;
2685
+ match: z.ZodString;
2686
+ opponent: z.ZodNullable<z.ZodObject<{
2687
+ id: z.ZodNumber;
2688
+ username: z.ZodString;
2689
+ avatar: z.ZodString;
2690
+ guest: z.ZodBoolean;
2691
+ }, z.core.$strip>>;
2692
+ }, z.core.$strip>>;
2494
2693
  }, z.core.$strip>;
2495
2694
  /** A launch. */
2496
2695
  export type Launch = z.infer<typeof Launch>;
@@ -2526,18 +2725,18 @@ export type RaceStats = z.infer<typeof RaceStats>;
2526
2725
  export declare const RaceProgress: z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>;
2527
2726
  /** A race room's phase: waiting for racers → countdown → racing → done (→ countdown on a rematch). */
2528
2727
  export declare const RacePhase: z.ZodEnum<{
2529
- done: "done";
2530
2728
  waiting: "waiting";
2531
2729
  countdown: "countdown";
2532
2730
  racing: "racing";
2731
+ done: "done";
2533
2732
  }>;
2534
2733
  /** A racer's state while the race runs. */
2535
2734
  export declare const RacerState: z.ZodEnum<{
2735
+ racing: "racing";
2536
2736
  finished: "finished";
2537
2737
  lost: "lost";
2538
2738
  forfeit: "forfeit";
2539
2739
  disconnected: "disconnected";
2540
- racing: "racing";
2541
2740
  }>;
2542
2741
  /** A value of {@link RacerState}. */
2543
2742
  export type RacerState = z.infer<typeof RacerState>;
@@ -2570,11 +2769,11 @@ export declare const Racer: z.ZodObject<{
2570
2769
  stats: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>, z.ZodBoolean, z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>]>>;
2571
2770
  progress: z.ZodOptional<z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>>;
2572
2771
  state: z.ZodEnum<{
2772
+ racing: "racing";
2573
2773
  finished: "finished";
2574
2774
  lost: "lost";
2575
2775
  forfeit: "forfeit";
2576
2776
  disconnected: "disconnected";
2577
- racing: "racing";
2578
2777
  }>;
2579
2778
  ms: z.ZodOptional<z.ZodNumber>;
2580
2779
  }, z.core.$strip>;
@@ -2640,10 +2839,10 @@ export type RaceResult = z.infer<typeof RaceResult>;
2640
2839
  /** The referee's view of a race room (RoomInfo.race). */
2641
2840
  export declare const RaceState: z.ZodObject<{
2642
2841
  phase: z.ZodEnum<{
2643
- done: "done";
2644
2842
  waiting: "waiting";
2645
2843
  countdown: "countdown";
2646
2844
  racing: "racing";
2845
+ done: "done";
2647
2846
  }>;
2648
2847
  round: z.ZodNumber;
2649
2848
  params: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBoolean, z.ZodString]>>;
@@ -2655,11 +2854,11 @@ export declare const RaceState: z.ZodObject<{
2655
2854
  stats: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>, z.ZodBoolean, z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>]>>;
2656
2855
  progress: z.ZodOptional<z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>>;
2657
2856
  state: z.ZodEnum<{
2857
+ racing: "racing";
2658
2858
  finished: "finished";
2659
2859
  lost: "lost";
2660
2860
  forfeit: "forfeit";
2661
2861
  disconnected: "disconnected";
2662
- racing: "racing";
2663
2862
  }>;
2664
2863
  ms: z.ZodOptional<z.ZodNumber>;
2665
2864
  }, z.core.$strip>>;
@@ -2812,6 +3011,17 @@ export declare const RoomModel: z.ZodEnum<{
2812
3011
  host: "host";
2813
3012
  relay: "relay";
2814
3013
  }>;
3014
+ /**
3015
+ * When the host role moves on mid-game. `grace` (default): only once the
3016
+ * host's seat is freed (they left, or their reconnect grace ran out), so a
3017
+ * host whose browser holds hidden state can come back and carry on. `drop`:
3018
+ * as soon as the host drops, for games whose whole truth is in the shared
3019
+ * state, so the match never waits.
3020
+ */
3021
+ export declare const HostMigration: z.ZodEnum<{
3022
+ grace: "grace";
3023
+ drop: "drop";
3024
+ }>;
2815
3025
  /** A seat in a room, keyed by user (any tab of that user reclaims it). */
2816
3026
  export declare const RoomSeat: z.ZodObject<{
2817
3027
  userId: z.ZodNumber;
@@ -2819,6 +3029,7 @@ export declare const RoomSeat: z.ZodObject<{
2819
3029
  avatar: z.ZodString;
2820
3030
  ready: z.ZodBoolean;
2821
3031
  connected: z.ZodBoolean;
3032
+ graceEndsAt: z.ZodOptional<z.ZodNumber>;
2822
3033
  data: z.ZodOptional<z.ZodJSONSchema>;
2823
3034
  }, z.core.$strip>;
2824
3035
  /** The public description of a room (`room` event, room and race acks, the `hello` snapshot). */
@@ -2845,6 +3056,7 @@ export declare const RoomInfo: z.ZodObject<{
2845
3056
  avatar: z.ZodString;
2846
3057
  ready: z.ZodBoolean;
2847
3058
  connected: z.ZodBoolean;
3059
+ graceEndsAt: z.ZodOptional<z.ZodNumber>;
2848
3060
  data: z.ZodOptional<z.ZodJSONSchema>;
2849
3061
  }, z.core.$strip>>;
2850
3062
  spectators: z.ZodNumber;
@@ -2855,10 +3067,10 @@ export declare const RoomInfo: z.ZodObject<{
2855
3067
  }>;
2856
3068
  race: z.ZodOptional<z.ZodObject<{
2857
3069
  phase: z.ZodEnum<{
2858
- done: "done";
2859
3070
  waiting: "waiting";
2860
3071
  countdown: "countdown";
2861
3072
  racing: "racing";
3073
+ done: "done";
2862
3074
  }>;
2863
3075
  round: z.ZodNumber;
2864
3076
  params: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBoolean, z.ZodString]>>;
@@ -2870,11 +3082,11 @@ export declare const RoomInfo: z.ZodObject<{
2870
3082
  stats: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>, z.ZodBoolean, z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>]>>;
2871
3083
  progress: z.ZodOptional<z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>>;
2872
3084
  state: z.ZodEnum<{
3085
+ racing: "racing";
2873
3086
  finished: "finished";
2874
3087
  lost: "lost";
2875
3088
  forfeit: "forfeit";
2876
3089
  disconnected: "disconnected";
2877
- racing: "racing";
2878
3090
  }>;
2879
3091
  ms: z.ZodOptional<z.ZodNumber>;
2880
3092
  }, z.core.$strip>>;
@@ -2945,12 +3157,40 @@ export declare const RoomClosedReason: z.ZodEnum<{
2945
3157
  moved: "moved";
2946
3158
  other_tab: "other_tab";
2947
3159
  }>;
2948
- /** Why a seat was freed (`room.abandoned`). */
3160
+ /** Why a seat was freed (`room.abandoned`, `room.seat` `gone`). */
2949
3161
  export declare const SeatGoneReason: z.ZodEnum<{
2950
3162
  left: "left";
2951
3163
  abandoned: "abandoned";
2952
3164
  kicked: "kicked";
2953
3165
  }>;
3166
+ /**
3167
+ * What happened to a seat (`room.seat`): `away` (the player dropped; the seat
3168
+ * is held until `graceEndsAt`, so the game can hand it to its computer
3169
+ * player), `back` (they reclaimed it: give control back), `gone` (freed for
3170
+ * good: left, kicked, or the grace ran out).
3171
+ */
3172
+ export declare const SeatStatus: z.ZodEnum<{
3173
+ away: "away";
3174
+ back: "back";
3175
+ gone: "gone";
3176
+ }>;
3177
+ /** A seat change (`room.seat`). */
3178
+ export declare const SeatChange: z.ZodObject<{
3179
+ userId: z.ZodNumber;
3180
+ status: z.ZodEnum<{
3181
+ away: "away";
3182
+ back: "back";
3183
+ gone: "gone";
3184
+ }>;
3185
+ graceEndsAt: z.ZodOptional<z.ZodNumber>;
3186
+ reason: z.ZodOptional<z.ZodEnum<{
3187
+ left: "left";
3188
+ abandoned: "abandoned";
3189
+ kicked: "kicked";
3190
+ }>>;
3191
+ }, z.core.$strip>;
3192
+ /** A seat change. */
3193
+ export type SeatChange = z.infer<typeof SeatChange>;
2954
3194
  //#endregion
2955
3195
  //#region src/api/mp/snapshot.d.ts
2956
3196
  /**
@@ -3015,6 +3255,7 @@ export declare const MultiplayerSnapshot: z.ZodObject<{
3015
3255
  avatar: z.ZodString;
3016
3256
  ready: z.ZodBoolean;
3017
3257
  connected: z.ZodBoolean;
3258
+ graceEndsAt: z.ZodOptional<z.ZodNumber>;
3018
3259
  data: z.ZodOptional<z.ZodJSONSchema>;
3019
3260
  }, z.core.$strip>>;
3020
3261
  spectators: z.ZodNumber;
@@ -3025,10 +3266,10 @@ export declare const MultiplayerSnapshot: z.ZodObject<{
3025
3266
  }>;
3026
3267
  race: z.ZodOptional<z.ZodObject<{
3027
3268
  phase: z.ZodEnum<{
3028
- done: "done";
3029
3269
  waiting: "waiting";
3030
3270
  countdown: "countdown";
3031
3271
  racing: "racing";
3272
+ done: "done";
3032
3273
  }>;
3033
3274
  round: z.ZodNumber;
3034
3275
  params: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBoolean, z.ZodString]>>;
@@ -3040,11 +3281,11 @@ export declare const MultiplayerSnapshot: z.ZodObject<{
3040
3281
  stats: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>, z.ZodBoolean, z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>]>>;
3041
3282
  progress: z.ZodOptional<z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>>;
3042
3283
  state: z.ZodEnum<{
3284
+ racing: "racing";
3043
3285
  finished: "finished";
3044
3286
  lost: "lost";
3045
3287
  forfeit: "forfeit";
3046
3288
  disconnected: "disconnected";
3047
- racing: "racing";
3048
3289
  }>;
3049
3290
  ms: z.ZodOptional<z.ZodNumber>;
3050
3291
  }, z.core.$strip>>;
@@ -3134,8 +3375,8 @@ export declare const mpEndpoints: {
3134
3375
  launch: z.ZodObject<{
3135
3376
  kind: z.ZodEnum<{
3136
3377
  guest: "guest";
3137
- join: "join";
3138
3378
  host: "host";
3379
+ join: "join";
3139
3380
  watch: "watch";
3140
3381
  }>;
3141
3382
  game: z.ZodString;
@@ -3169,6 +3410,21 @@ export declare const mpEndpoints: {
3169
3410
  avatar: z.ZodString;
3170
3411
  guest: z.ZodBoolean;
3171
3412
  }, z.core.$strip>>>;
3413
+ via: z.ZodOptional<z.ZodEnum<{
3414
+ link: "link";
3415
+ rejoin: "rejoin";
3416
+ }>>;
3417
+ tournament: z.ZodOptional<z.ZodObject<{
3418
+ id: z.ZodNumber;
3419
+ title: z.ZodString;
3420
+ match: z.ZodString;
3421
+ opponent: z.ZodNullable<z.ZodObject<{
3422
+ id: z.ZodNumber;
3423
+ username: z.ZodString;
3424
+ avatar: z.ZodString;
3425
+ guest: z.ZodBoolean;
3426
+ }, z.core.$strip>>;
3427
+ }, z.core.$strip>>;
3172
3428
  }, z.core.$strip>;
3173
3429
  }, z.core.$strip>;
3174
3430
  readonly errors: {
@@ -3184,6 +3440,31 @@ export declare const mpEndpoints: {
3184
3440
  user: SessionUser;
3185
3441
  clientId: string;
3186
3442
  }, {}, import("@ayepi/core").EmptyObject>;
3443
+ openInviteLink: import("@ayepi/core").Endpoint<{
3444
+ readonly method: "POST";
3445
+ readonly path: "/mp/links/:token/open";
3446
+ readonly params: z.ZodObject<{
3447
+ token: z.ZodString;
3448
+ }, z.core.$strip>;
3449
+ readonly response: z.ZodObject<{
3450
+ launchToken: z.ZodString;
3451
+ url: z.ZodString;
3452
+ }, z.core.$strip>;
3453
+ readonly errors: {
3454
+ readonly 401: ErrorBodySchema;
3455
+ readonly 403: ErrorBodySchema;
3456
+ readonly 404: ErrorBodySchema;
3457
+ readonly 409: ErrorBodySchema;
3458
+ readonly 429: ErrorBodySchema;
3459
+ };
3460
+ readonly doc: {
3461
+ readonly summary: "Open an invite link: a join launch when a seat is free, else a watch launch";
3462
+ readonly tags: readonly ["mp"];
3463
+ };
3464
+ }, {
3465
+ user: SessionUser;
3466
+ clientId: string;
3467
+ }, {}, import("@ayepi/core").EmptyObject>;
3187
3468
  setPartyJoinInfo: import("@ayepi/core").Endpoint<{
3188
3469
  readonly method: "POST";
3189
3470
  readonly path: "/mp/parties/:id/join-info";
@@ -3378,53 +3659,135 @@ export declare const mpEndpoints: {
3378
3659
  user: SessionUser;
3379
3660
  clientId: string;
3380
3661
  }, {}, import("@ayepi/core").EmptyObject>;
3381
- cancelGameInvite: import("@ayepi/core").Endpoint<{
3382
- readonly method: "DELETE";
3383
- readonly path: "/mp/invites/:id";
3384
- readonly params: z.ZodObject<{
3385
- id: z.ZodString;
3662
+ createInviteLink: import("@ayepi/core").Endpoint<{
3663
+ readonly method: "POST";
3664
+ readonly path: "/mp/links";
3665
+ readonly body: z.ZodObject<{
3666
+ game: z.ZodString;
3386
3667
  }, z.core.$strip>;
3387
3668
  readonly response: z.ZodObject<{
3388
- ok: z.ZodLiteral<true>;
3669
+ token: z.ZodString;
3670
+ url: z.ZodString;
3671
+ game: z.ZodString;
3672
+ mode: z.ZodOptional<z.ZodString>;
3673
+ room: z.ZodString;
3674
+ createdBy: z.ZodNumber;
3675
+ expiresAt: z.ZodNumber;
3389
3676
  }, z.core.$strip>;
3390
3677
  readonly errors: {
3678
+ readonly 400: ErrorBodySchema;
3391
3679
  readonly 401: ErrorBodySchema;
3392
3680
  readonly 403: ErrorBodySchema;
3393
3681
  readonly 404: ErrorBodySchema;
3682
+ readonly 409: ErrorBodySchema;
3683
+ readonly 429: ErrorBodySchema;
3394
3684
  };
3395
3685
  readonly doc: {
3396
- readonly summary: "Cancel an invite you sent";
3686
+ readonly summary: "An invite link to the room I'm in (reused while it lives): anyone who opens it joins, or watches when it's full";
3397
3687
  readonly tags: readonly ["mp"];
3398
3688
  };
3399
3689
  }, {
3400
3690
  user: SessionUser;
3401
3691
  clientId: string;
3402
3692
  }, {}, import("@ayepi/core").EmptyObject>;
3403
- };
3404
- //#endregion
3405
- //#region src/api/notify.d.ts
3406
- /** Notification preferences (`GET`/`PUT /social/notify`, `GET /social/me`). */
3407
- export declare const NotifyPrefs: z.ZodObject<{
3408
- dm: z.ZodBoolean;
3409
- friend_request: z.ZodBoolean;
3410
- friendOnlineAll: z.ZodBoolean;
3411
- friendOnline: z.ZodArray<z.ZodNumber>;
3412
- lobbyOpen: z.ZodArray<z.ZodString>;
3413
- }, z.core.$strip>;
3414
- /** Notification preferences. */
3415
- export type NotifyPrefs = z.infer<typeof NotifyPrefs>;
3416
- /** The preference kinds `PUT /social/notify` can flip. */
3417
- export declare const NotifyPrefKind: z.ZodEnum<{
3418
- dm: "dm";
3419
- friend_request: "friend_request";
3420
- friend_online: "friend_online";
3421
- lobby_open: "lobby_open";
3422
- }>;
3423
- /** A preference kind. */
3424
- export type NotifyPrefKind = z.infer<typeof NotifyPrefKind>;
3425
- /**
3426
- * One `PUT /social/notify` change. `target`: for `friend_online`, a friend's
3427
- * id (a number, or its decimal string) for that friend's bell, or absent
3693
+ listInviteLinks: import("@ayepi/core").Endpoint<{
3694
+ readonly method: "GET";
3695
+ readonly path: "/mp/links";
3696
+ readonly query: z.ZodObject<{
3697
+ game: z.ZodString;
3698
+ }, z.core.$strip>;
3699
+ readonly response: z.ZodObject<{
3700
+ links: z.ZodArray<z.ZodObject<{
3701
+ token: z.ZodString;
3702
+ url: z.ZodString;
3703
+ game: z.ZodString;
3704
+ mode: z.ZodOptional<z.ZodString>;
3705
+ room: z.ZodString;
3706
+ createdBy: z.ZodNumber;
3707
+ expiresAt: z.ZodNumber;
3708
+ }, z.core.$strip>>;
3709
+ }, z.core.$strip>;
3710
+ readonly errors: {
3711
+ readonly 401: ErrorBodySchema;
3712
+ readonly 403: ErrorBodySchema;
3713
+ };
3714
+ readonly doc: {
3715
+ readonly summary: "My live invite links in a game, plus the links to rooms I host";
3716
+ readonly tags: readonly ["mp"];
3717
+ };
3718
+ }, {
3719
+ user: SessionUser;
3720
+ clientId: string;
3721
+ }, {}, import("@ayepi/core").EmptyObject>;
3722
+ revokeInviteLink: import("@ayepi/core").Endpoint<{
3723
+ readonly method: "DELETE";
3724
+ readonly path: "/mp/links/:token";
3725
+ readonly params: z.ZodObject<{
3726
+ token: z.ZodString;
3727
+ }, z.core.$strip>;
3728
+ readonly response: z.ZodObject<{
3729
+ ok: z.ZodLiteral<true>;
3730
+ }, z.core.$strip>;
3731
+ readonly errors: {
3732
+ readonly 401: ErrorBodySchema;
3733
+ readonly 403: ErrorBodySchema;
3734
+ readonly 404: ErrorBodySchema;
3735
+ };
3736
+ readonly doc: {
3737
+ readonly summary: "Revoke an invite link (its creator, or the host of the room it opens)";
3738
+ readonly tags: readonly ["mp"];
3739
+ };
3740
+ }, {
3741
+ user: SessionUser;
3742
+ clientId: string;
3743
+ }, {}, import("@ayepi/core").EmptyObject>;
3744
+ cancelGameInvite: import("@ayepi/core").Endpoint<{
3745
+ readonly method: "DELETE";
3746
+ readonly path: "/mp/invites/:id";
3747
+ readonly params: z.ZodObject<{
3748
+ id: z.ZodString;
3749
+ }, z.core.$strip>;
3750
+ readonly response: z.ZodObject<{
3751
+ ok: z.ZodLiteral<true>;
3752
+ }, z.core.$strip>;
3753
+ readonly errors: {
3754
+ readonly 401: ErrorBodySchema;
3755
+ readonly 403: ErrorBodySchema;
3756
+ readonly 404: ErrorBodySchema;
3757
+ };
3758
+ readonly doc: {
3759
+ readonly summary: "Cancel an invite you sent";
3760
+ readonly tags: readonly ["mp"];
3761
+ };
3762
+ }, {
3763
+ user: SessionUser;
3764
+ clientId: string;
3765
+ }, {}, import("@ayepi/core").EmptyObject>;
3766
+ };
3767
+ //#endregion
3768
+ //#region src/api/notify.d.ts
3769
+ /** Notification preferences (`GET`/`PUT /social/notify`, `GET /social/me`). */
3770
+ export declare const NotifyPrefs: z.ZodObject<{
3771
+ dm: z.ZodBoolean;
3772
+ friend_request: z.ZodBoolean;
3773
+ friendOnlineAll: z.ZodBoolean;
3774
+ friendOnline: z.ZodArray<z.ZodNumber>;
3775
+ lobbyOpen: z.ZodArray<z.ZodString>;
3776
+ }, z.core.$strip>;
3777
+ /** Notification preferences. */
3778
+ export type NotifyPrefs = z.infer<typeof NotifyPrefs>;
3779
+ /** The preference kinds `PUT /social/notify` can flip. */
3780
+ export declare const NotifyPrefKind: z.ZodEnum<{
3781
+ dm: "dm";
3782
+ friend_request: "friend_request";
3783
+ friend_online: "friend_online";
3784
+ lobby_open: "lobby_open";
3785
+ }>;
3786
+ /** A preference kind. */
3787
+ export type NotifyPrefKind = z.infer<typeof NotifyPrefKind>;
3788
+ /**
3789
+ * One `PUT /social/notify` change. `target`: for `friend_online`, a friend's
3790
+ * id (a number, or its decimal string) for that friend's bell, or absent
3428
3791
  * (`''`, `null`) for the "any friend" switch; for `lobby_open`, the game slug.
3429
3792
  * Ignored for `dm` and `friend_request`. Any other number or text is a 404
3430
3793
  * (not a friend, no such game), as on the old hub. `enabled` is checked
@@ -4232,8 +4595,8 @@ export declare const raceEndpoints: {
4232
4595
  export declare const ReportKind: z.ZodEnum<{
4233
4596
  message: "message";
4234
4597
  username: "username";
4235
- user: "user";
4236
4598
  presence: "presence";
4599
+ user: "user";
4237
4600
  suggestion: "suggestion";
4238
4601
  room_chat: "room_chat";
4239
4602
  }>;
@@ -4259,8 +4622,8 @@ export declare const ReportInput: z.ZodObject<{
4259
4622
  kind: z.ZodEnum<{
4260
4623
  message: "message";
4261
4624
  username: "username";
4262
- user: "user";
4263
4625
  presence: "presence";
4626
+ user: "user";
4264
4627
  suggestion: "suggestion";
4265
4628
  room_chat: "room_chat";
4266
4629
  }>;
@@ -4345,11 +4708,11 @@ export declare const ReportSnapshot: z.ZodObject<{
4345
4708
  export type ReportSnapshot = z.infer<typeof ReportSnapshot>;
4346
4709
  /** A suggestion's review status. Only `approved`, `planned` and `done` are on the public board. */
4347
4710
  export declare const SuggestionStatus: z.ZodEnum<{
4711
+ done: "done";
4712
+ removed: "removed";
4348
4713
  pending: "pending";
4349
4714
  approved: "approved";
4350
4715
  planned: "planned";
4351
- done: "done";
4352
- removed: "removed";
4353
4716
  withdrawn: "withdrawn";
4354
4717
  }>;
4355
4718
  /** A suggestion status. */
@@ -4362,11 +4725,11 @@ export declare const Suggestion: z.ZodObject<{
4362
4725
  title: z.ZodString;
4363
4726
  body: z.ZodString;
4364
4727
  status: z.ZodEnum<{
4728
+ done: "done";
4729
+ removed: "removed";
4365
4730
  pending: "pending";
4366
4731
  approved: "approved";
4367
4732
  planned: "planned";
4368
- done: "done";
4369
- removed: "removed";
4370
4733
  withdrawn: "withdrawn";
4371
4734
  }>;
4372
4735
  votes: z.ZodNumber;
@@ -4398,11 +4761,11 @@ export declare const reportsEndpoints: {
4398
4761
  title: z.ZodString;
4399
4762
  body: z.ZodString;
4400
4763
  status: z.ZodEnum<{
4764
+ done: "done";
4765
+ removed: "removed";
4401
4766
  pending: "pending";
4402
4767
  approved: "approved";
4403
4768
  planned: "planned";
4404
- done: "done";
4405
- removed: "removed";
4406
4769
  withdrawn: "withdrawn";
4407
4770
  }>;
4408
4771
  votes: z.ZodNumber;
@@ -4514,11 +4877,11 @@ export declare const reportsEndpoints: {
4514
4877
  title: z.ZodString;
4515
4878
  body: z.ZodString;
4516
4879
  status: z.ZodEnum<{
4880
+ done: "done";
4881
+ removed: "removed";
4517
4882
  pending: "pending";
4518
4883
  approved: "approved";
4519
4884
  planned: "planned";
4520
- done: "done";
4521
- removed: "removed";
4522
4885
  withdrawn: "withdrawn";
4523
4886
  }>;
4524
4887
  votes: z.ZodNumber;
@@ -4533,11 +4896,11 @@ export declare const reportsEndpoints: {
4533
4896
  title: z.ZodString;
4534
4897
  body: z.ZodString;
4535
4898
  status: z.ZodEnum<{
4899
+ done: "done";
4900
+ removed: "removed";
4536
4901
  pending: "pending";
4537
4902
  approved: "approved";
4538
4903
  planned: "planned";
4539
- done: "done";
4540
- removed: "removed";
4541
4904
  withdrawn: "withdrawn";
4542
4905
  }>;
4543
4906
  votes: z.ZodNumber;
@@ -4566,8 +4929,8 @@ export declare const reportsEndpoints: {
4566
4929
  kind: z.ZodEnum<{
4567
4930
  message: "message";
4568
4931
  username: "username";
4569
- user: "user";
4570
4932
  presence: "presence";
4933
+ user: "user";
4571
4934
  suggestion: "suggestion";
4572
4935
  room_chat: "room_chat";
4573
4936
  }>;
@@ -4859,11 +5222,11 @@ export type FriendsList = z.infer<typeof FriendsList>;
4859
5222
  */
4860
5223
  export declare const FriendChange: z.ZodEnum<{
4861
5224
  blocked: "blocked";
5225
+ request: "request";
4862
5226
  accepted: "accepted";
5227
+ removed: "removed";
4863
5228
  declined: "declined";
4864
5229
  cancelled: "cancelled";
4865
- removed: "removed";
4866
- request: "request";
4867
5230
  restored: "restored";
4868
5231
  }>;
4869
5232
  /** A friends-list change. */
@@ -5459,90 +5822,2028 @@ export declare const socialEndpoints: {
5459
5822
  readonly response: z.ZodObject<{
5460
5823
  me: z.ZodObject<{
5461
5824
  id: z.ZodNumber;
5462
- username: z.ZodString;
5463
- guest: z.ZodBoolean;
5464
- role: z.ZodEnum<{
5465
- "": "";
5466
- admin: "admin";
5825
+ username: z.ZodString;
5826
+ guest: z.ZodBoolean;
5827
+ role: z.ZodEnum<{
5828
+ "": "";
5829
+ admin: "admin";
5830
+ }>;
5831
+ chatLock: z.ZodBoolean;
5832
+ mutedUntil: z.ZodNumber;
5833
+ suspendedUntil: z.ZodNumber;
5834
+ avatar: z.ZodString;
5835
+ privacy: z.ZodEnum<{
5836
+ friends: "friends";
5837
+ nobody: "nobody";
5838
+ }>;
5839
+ dmPolicy: z.ZodEnum<{
5840
+ friends: "friends";
5841
+ nobody: "nobody";
5842
+ }>;
5843
+ }, z.core.$strip>;
5844
+ notify: z.ZodObject<{
5845
+ dm: z.ZodBoolean;
5846
+ friend_request: z.ZodBoolean;
5847
+ friendOnlineAll: z.ZodBoolean;
5848
+ friendOnline: z.ZodArray<z.ZodNumber>;
5849
+ lobbyOpen: z.ZodArray<z.ZodString>;
5850
+ }, z.core.$strip>;
5851
+ pushSubs: z.ZodNumber;
5852
+ }, z.core.$strip>;
5853
+ readonly errors: {
5854
+ readonly 401: ErrorBodySchema;
5855
+ };
5856
+ readonly doc: {
5857
+ readonly summary: "Your social settings, notification preferences and push subscription count";
5858
+ readonly tags: readonly ["social"];
5859
+ };
5860
+ }, {
5861
+ user: SessionUser;
5862
+ clientId: string;
5863
+ }, {}, import("@ayepi/core").EmptyObject>;
5864
+ getSocialConfig: import("@ayepi/core").Endpoint<{
5865
+ readonly method: "GET";
5866
+ readonly path: "/social/config";
5867
+ readonly response: z.ZodObject<{
5868
+ chatMode: z.ZodEnum<{
5869
+ on: "on";
5870
+ quick: "quick";
5871
+ off: "off";
5872
+ }>;
5873
+ ai: z.ZodBoolean;
5874
+ contactUrl: z.ZodString;
5875
+ parentsUrl: z.ZodString;
5876
+ vapidPublicKey: z.ZodString;
5877
+ quickChat: z.ZodRecord<z.ZodString, z.ZodString>;
5878
+ emotes: z.ZodArray<z.ZodString>;
5879
+ limits: z.ZodObject<{
5880
+ dmMaxChars: z.ZodNumber;
5881
+ roomChatMaxChars: z.ZodNumber;
5882
+ suggestionTitleMax: z.ZodNumber;
5883
+ suggestionBodyMax: z.ZodNumber;
5884
+ }, z.core.$strip>;
5885
+ avatars: z.ZodArray<z.ZodString>;
5886
+ test: z.ZodOptional<z.ZodLiteral<true>>;
5887
+ }, z.core.$strip>;
5888
+ readonly doc: {
5889
+ readonly summary: "The site-wide social configuration";
5890
+ readonly tags: readonly ["social"];
5891
+ };
5892
+ }, {
5893
+ user: SessionUser | null;
5894
+ clientId: string;
5895
+ }, {}, import("@ayepi/core").EmptyObject>;
5896
+ getOnlineCounts: import("@ayepi/core").Endpoint<{
5897
+ readonly method: "GET";
5898
+ readonly path: "/social/counts";
5899
+ readonly response: z.ZodObject<{
5900
+ online: z.ZodNumber;
5901
+ byGame: z.ZodRecord<z.ZodString, z.ZodNumber>;
5902
+ }, z.core.$strip>;
5903
+ readonly errors: {
5904
+ readonly 403: ErrorBodySchema;
5905
+ };
5906
+ readonly doc: {
5907
+ readonly summary: "Anonymous online counts, overall and per game";
5908
+ readonly tags: readonly ["social"];
5909
+ };
5910
+ }, {
5911
+ user: SessionUser | null;
5912
+ clientId: string;
5913
+ }, {}, import("@ayepi/core").EmptyObject>;
5914
+ };
5915
+ //#endregion
5916
+ //#region src/api/tournaments/shapes.d.ts
5917
+ /** A tournament's id. */
5918
+ export declare const TournamentId: z.ZodNumber;
5919
+ /** `open`: listed, anyone can sign up or follow. `closed`: only invited players see it. */
5920
+ export declare const TournamentVisibility: z.ZodEnum<{
5921
+ open: "open";
5922
+ closed: "closed";
5923
+ }>;
5924
+ /** How the bracket is seeded: by each player's wins in the tournament's games, or at random. */
5925
+ export declare const TournamentSeeding: z.ZodEnum<{
5926
+ rank: "rank";
5927
+ random: "random";
5928
+ }>;
5929
+ /** Which game each match is: the one game, one random pick from the set for the whole tournament, or a random pick per match. */
5930
+ export declare const TournamentGamePick: z.ZodEnum<{
5931
+ fixed: "fixed";
5932
+ "random-once": "random-once";
5933
+ "random-each": "random-each";
5934
+ }>;
5935
+ /** When a tournament starts: at a set time (with whoever signed up), or as soon as `minPlayers` sign up. */
5936
+ export declare const TournamentStart: z.ZodDiscriminatedUnion<[z.ZodObject<{
5937
+ kind: z.ZodLiteral<"scheduled">;
5938
+ at: z.ZodNumber;
5939
+ }, z.core.$strip>, z.ZodObject<{
5940
+ kind: z.ZodLiteral<"filled">;
5941
+ }, z.core.$strip>], "kind">;
5942
+ /** When a tournament starts. */
5943
+ export type TournamentStart = z.infer<typeof TournamentStart>;
5944
+ /** `signup` → `running` → `done`; or `cancelled` (by its creator, or too few players at the start). */
5945
+ export declare const TournamentPhase: z.ZodEnum<{
5946
+ done: "done";
5947
+ cancelled: "cancelled";
5948
+ signup: "signup";
5949
+ running: "running";
5950
+ }>;
5951
+ /** A tournament's phase. */
5952
+ export type TournamentPhase = z.infer<typeof TournamentPhase>;
5953
+ /** Where a match sits: the winners bracket, a redemption bracket (players with losses), or the final ladder. */
5954
+ export declare const TournamentStage: z.ZodEnum<{
5955
+ winners: "winners";
5956
+ redemption: "redemption";
5957
+ final: "final";
5958
+ }>;
5959
+ /** How a match was decided. */
5960
+ export declare const TournamentDecision: z.ZodEnum<{
5961
+ forfeit: "forfeit";
5962
+ timeout: "timeout";
5963
+ withdrawn: "withdrawn";
5964
+ played: "played";
5965
+ bye: "bye";
5966
+ }>;
5967
+ /** How a match was decided. */
5968
+ export type TournamentDecision = z.infer<typeof TournamentDecision>;
5969
+ /** `POST /tournaments`. Everything but `games` has a default: the quick "public 1v1, single elimination". */
5970
+ export declare const TournamentCreate: z.ZodObject<{
5971
+ title: z.ZodOptional<z.ZodString>;
5972
+ games: z.ZodArray<z.ZodString>;
5973
+ pick: z.ZodDefault<z.ZodEnum<{
5974
+ fixed: "fixed";
5975
+ "random-once": "random-once";
5976
+ "random-each": "random-each";
5977
+ }>>;
5978
+ lives: z.ZodDefault<z.ZodNumber>;
5979
+ seeding: z.ZodDefault<z.ZodEnum<{
5980
+ rank: "rank";
5981
+ random: "random";
5982
+ }>>;
5983
+ visibility: z.ZodDefault<z.ZodEnum<{
5984
+ open: "open";
5985
+ closed: "closed";
5986
+ }>>;
5987
+ start: z.ZodDefault<z.ZodDiscriminatedUnion<[z.ZodObject<{
5988
+ kind: z.ZodLiteral<"scheduled">;
5989
+ at: z.ZodNumber;
5990
+ }, z.core.$strip>, z.ZodObject<{
5991
+ kind: z.ZodLiteral<"filled">;
5992
+ }, z.core.$strip>], "kind">>;
5993
+ minPlayers: z.ZodDefault<z.ZodNumber>;
5994
+ maxPlayers: z.ZodDefault<z.ZodNumber>;
5995
+ readyMinutes: z.ZodDefault<z.ZodNumber>;
5996
+ invite: z.ZodOptional<z.ZodArray<z.ZodNumber>>;
5997
+ }, z.core.$strip>;
5998
+ /** What creating a tournament takes. */
5999
+ export type TournamentCreate = z.output<typeof TournamentCreate>;
6000
+ /** One entrant, as the bracket shows them. */
6001
+ export declare const TournamentPlayer: z.ZodObject<{
6002
+ user: z.ZodObject<{
6003
+ id: z.ZodNumber;
6004
+ username: z.ZodString;
6005
+ avatar: z.ZodString;
6006
+ guest: z.ZodBoolean;
6007
+ }, z.core.$strip>;
6008
+ seed: z.ZodNullable<z.ZodNumber>;
6009
+ wins: z.ZodNumber;
6010
+ losses: z.ZodNumber;
6011
+ out: z.ZodBoolean;
6012
+ }, z.core.$strip>;
6013
+ /** One entrant. */
6014
+ export type TournamentPlayer = z.infer<typeof TournamentPlayer>;
6015
+ /** One match in the bracket. Sides are user ids (see the detail's `players`). */
6016
+ export declare const TournamentMatch: z.ZodObject<{
6017
+ id: z.ZodString;
6018
+ stage: z.ZodEnum<{
6019
+ winners: "winners";
6020
+ redemption: "redemption";
6021
+ final: "final";
6022
+ }>;
6023
+ level: z.ZodNumber;
6024
+ round: z.ZodNumber;
6025
+ slot: z.ZodNumber;
6026
+ a: z.ZodNullable<z.ZodNumber>;
6027
+ b: z.ZodNullable<z.ZodNumber>;
6028
+ status: z.ZodEnum<{
6029
+ ready: "ready";
6030
+ waiting: "waiting";
6031
+ done: "done";
6032
+ }>;
6033
+ winnerId: z.ZodNullable<z.ZodNumber>;
6034
+ decision: z.ZodNullable<z.ZodEnum<{
6035
+ forfeit: "forfeit";
6036
+ timeout: "timeout";
6037
+ withdrawn: "withdrawn";
6038
+ played: "played";
6039
+ bye: "bye";
6040
+ }>>;
6041
+ game: z.ZodNullable<z.ZodString>;
6042
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
6043
+ started: z.ZodBoolean;
6044
+ }, z.core.$strip>;
6045
+ /** One match. */
6046
+ export type TournamentMatch = z.infer<typeof TournamentMatch>;
6047
+ /** A ready match of mine: who against, in which game, and until when. */
6048
+ export declare const MyTournamentMatch: z.ZodObject<{
6049
+ id: z.ZodString;
6050
+ opponent: z.ZodNullable<z.ZodObject<{
6051
+ id: z.ZodNumber;
6052
+ username: z.ZodString;
6053
+ avatar: z.ZodString;
6054
+ guest: z.ZodBoolean;
6055
+ }, z.core.$strip>>;
6056
+ game: z.ZodString;
6057
+ gameTitle: z.ZodString;
6058
+ deadlineAt: z.ZodNumber;
6059
+ started: z.ZodBoolean;
6060
+ }, z.core.$strip>;
6061
+ /** A ready match of mine. */
6062
+ export type MyTournamentMatch = z.infer<typeof MyTournamentMatch>;
6063
+ /** The viewer's own relation to a tournament. */
6064
+ export declare const TournamentMe: z.ZodObject<{
6065
+ joined: z.ZodBoolean;
6066
+ invited: z.ZodBoolean;
6067
+ following: z.ZodBoolean;
6068
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6069
+ isCreator: z.ZodBoolean;
6070
+ stillIn: z.ZodBoolean;
6071
+ nextMatch: z.ZodNullable<z.ZodObject<{
6072
+ id: z.ZodString;
6073
+ opponent: z.ZodNullable<z.ZodObject<{
6074
+ id: z.ZodNumber;
6075
+ username: z.ZodString;
6076
+ avatar: z.ZodString;
6077
+ guest: z.ZodBoolean;
6078
+ }, z.core.$strip>>;
6079
+ game: z.ZodString;
6080
+ gameTitle: z.ZodString;
6081
+ deadlineAt: z.ZodNumber;
6082
+ started: z.ZodBoolean;
6083
+ }, z.core.$strip>>;
6084
+ }, z.core.$strip>;
6085
+ /** A tournament in lists. */
6086
+ export declare const TournamentSummary: z.ZodObject<{
6087
+ id: z.ZodNumber;
6088
+ title: z.ZodString;
6089
+ creator: z.ZodNullable<z.ZodObject<{
6090
+ id: z.ZodNumber;
6091
+ username: z.ZodString;
6092
+ avatar: z.ZodString;
6093
+ guest: z.ZodBoolean;
6094
+ }, z.core.$strip>>;
6095
+ visibility: z.ZodEnum<{
6096
+ open: "open";
6097
+ closed: "closed";
6098
+ }>;
6099
+ phase: z.ZodEnum<{
6100
+ done: "done";
6101
+ cancelled: "cancelled";
6102
+ signup: "signup";
6103
+ running: "running";
6104
+ }>;
6105
+ games: z.ZodArray<z.ZodString>;
6106
+ pick: z.ZodEnum<{
6107
+ fixed: "fixed";
6108
+ "random-once": "random-once";
6109
+ "random-each": "random-each";
6110
+ }>;
6111
+ game: z.ZodNullable<z.ZodString>;
6112
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6113
+ lives: z.ZodNumber;
6114
+ seeding: z.ZodEnum<{
6115
+ rank: "rank";
6116
+ random: "random";
6117
+ }>;
6118
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6119
+ kind: z.ZodLiteral<"scheduled">;
6120
+ at: z.ZodNumber;
6121
+ }, z.core.$strip>, z.ZodObject<{
6122
+ kind: z.ZodLiteral<"filled">;
6123
+ }, z.core.$strip>], "kind">;
6124
+ minPlayers: z.ZodNumber;
6125
+ maxPlayers: z.ZodNumber;
6126
+ readyMinutes: z.ZodNumber;
6127
+ entrants: z.ZodNumber;
6128
+ createdAt: z.ZodNumber;
6129
+ startedAt: z.ZodNullable<z.ZodNumber>;
6130
+ endedAt: z.ZodNullable<z.ZodNumber>;
6131
+ champion: z.ZodNullable<z.ZodObject<{
6132
+ id: z.ZodNumber;
6133
+ username: z.ZodString;
6134
+ avatar: z.ZodString;
6135
+ guest: z.ZodBoolean;
6136
+ }, z.core.$strip>>;
6137
+ me: z.ZodObject<{
6138
+ joined: z.ZodBoolean;
6139
+ invited: z.ZodBoolean;
6140
+ following: z.ZodBoolean;
6141
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6142
+ isCreator: z.ZodBoolean;
6143
+ stillIn: z.ZodBoolean;
6144
+ nextMatch: z.ZodNullable<z.ZodObject<{
6145
+ id: z.ZodString;
6146
+ opponent: z.ZodNullable<z.ZodObject<{
6147
+ id: z.ZodNumber;
6148
+ username: z.ZodString;
6149
+ avatar: z.ZodString;
6150
+ guest: z.ZodBoolean;
6151
+ }, z.core.$strip>>;
6152
+ game: z.ZodString;
6153
+ gameTitle: z.ZodString;
6154
+ deadlineAt: z.ZodNumber;
6155
+ started: z.ZodBoolean;
6156
+ }, z.core.$strip>>;
6157
+ }, z.core.$strip>;
6158
+ }, z.core.$strip>;
6159
+ /** A tournament in lists. */
6160
+ export type TournamentSummary = z.infer<typeof TournamentSummary>;
6161
+ /** A tournament with its players and bracket. */
6162
+ export declare const TournamentDetail: z.ZodObject<{
6163
+ id: z.ZodNumber;
6164
+ title: z.ZodString;
6165
+ creator: z.ZodNullable<z.ZodObject<{
6166
+ id: z.ZodNumber;
6167
+ username: z.ZodString;
6168
+ avatar: z.ZodString;
6169
+ guest: z.ZodBoolean;
6170
+ }, z.core.$strip>>;
6171
+ visibility: z.ZodEnum<{
6172
+ open: "open";
6173
+ closed: "closed";
6174
+ }>;
6175
+ phase: z.ZodEnum<{
6176
+ done: "done";
6177
+ cancelled: "cancelled";
6178
+ signup: "signup";
6179
+ running: "running";
6180
+ }>;
6181
+ games: z.ZodArray<z.ZodString>;
6182
+ pick: z.ZodEnum<{
6183
+ fixed: "fixed";
6184
+ "random-once": "random-once";
6185
+ "random-each": "random-each";
6186
+ }>;
6187
+ game: z.ZodNullable<z.ZodString>;
6188
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6189
+ lives: z.ZodNumber;
6190
+ seeding: z.ZodEnum<{
6191
+ rank: "rank";
6192
+ random: "random";
6193
+ }>;
6194
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6195
+ kind: z.ZodLiteral<"scheduled">;
6196
+ at: z.ZodNumber;
6197
+ }, z.core.$strip>, z.ZodObject<{
6198
+ kind: z.ZodLiteral<"filled">;
6199
+ }, z.core.$strip>], "kind">;
6200
+ minPlayers: z.ZodNumber;
6201
+ maxPlayers: z.ZodNumber;
6202
+ readyMinutes: z.ZodNumber;
6203
+ entrants: z.ZodNumber;
6204
+ createdAt: z.ZodNumber;
6205
+ startedAt: z.ZodNullable<z.ZodNumber>;
6206
+ endedAt: z.ZodNullable<z.ZodNumber>;
6207
+ champion: z.ZodNullable<z.ZodObject<{
6208
+ id: z.ZodNumber;
6209
+ username: z.ZodString;
6210
+ avatar: z.ZodString;
6211
+ guest: z.ZodBoolean;
6212
+ }, z.core.$strip>>;
6213
+ me: z.ZodObject<{
6214
+ joined: z.ZodBoolean;
6215
+ invited: z.ZodBoolean;
6216
+ following: z.ZodBoolean;
6217
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6218
+ isCreator: z.ZodBoolean;
6219
+ stillIn: z.ZodBoolean;
6220
+ nextMatch: z.ZodNullable<z.ZodObject<{
6221
+ id: z.ZodString;
6222
+ opponent: z.ZodNullable<z.ZodObject<{
6223
+ id: z.ZodNumber;
6224
+ username: z.ZodString;
6225
+ avatar: z.ZodString;
6226
+ guest: z.ZodBoolean;
6227
+ }, z.core.$strip>>;
6228
+ game: z.ZodString;
6229
+ gameTitle: z.ZodString;
6230
+ deadlineAt: z.ZodNumber;
6231
+ started: z.ZodBoolean;
6232
+ }, z.core.$strip>>;
6233
+ }, z.core.$strip>;
6234
+ players: z.ZodArray<z.ZodObject<{
6235
+ user: z.ZodObject<{
6236
+ id: z.ZodNumber;
6237
+ username: z.ZodString;
6238
+ avatar: z.ZodString;
6239
+ guest: z.ZodBoolean;
6240
+ }, z.core.$strip>;
6241
+ seed: z.ZodNullable<z.ZodNumber>;
6242
+ wins: z.ZodNumber;
6243
+ losses: z.ZodNumber;
6244
+ out: z.ZodBoolean;
6245
+ }, z.core.$strip>>;
6246
+ matches: z.ZodArray<z.ZodObject<{
6247
+ id: z.ZodString;
6248
+ stage: z.ZodEnum<{
6249
+ winners: "winners";
6250
+ redemption: "redemption";
6251
+ final: "final";
6252
+ }>;
6253
+ level: z.ZodNumber;
6254
+ round: z.ZodNumber;
6255
+ slot: z.ZodNumber;
6256
+ a: z.ZodNullable<z.ZodNumber>;
6257
+ b: z.ZodNullable<z.ZodNumber>;
6258
+ status: z.ZodEnum<{
6259
+ ready: "ready";
6260
+ waiting: "waiting";
6261
+ done: "done";
6262
+ }>;
6263
+ winnerId: z.ZodNullable<z.ZodNumber>;
6264
+ decision: z.ZodNullable<z.ZodEnum<{
6265
+ forfeit: "forfeit";
6266
+ timeout: "timeout";
6267
+ withdrawn: "withdrawn";
6268
+ played: "played";
6269
+ bye: "bye";
6270
+ }>>;
6271
+ game: z.ZodNullable<z.ZodString>;
6272
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
6273
+ started: z.ZodBoolean;
6274
+ }, z.core.$strip>>;
6275
+ inviteUrl: z.ZodNullable<z.ZodString>;
6276
+ }, z.core.$strip>;
6277
+ /** A tournament with its bracket. */
6278
+ export type TournamentDetail = z.infer<typeof TournamentDetail>;
6279
+ /** What a launch into a tournament match carries (`launch.tournament`). */
6280
+ export declare const TournamentLaunch: z.ZodObject<{
6281
+ id: z.ZodNumber;
6282
+ title: z.ZodString;
6283
+ match: z.ZodString;
6284
+ opponent: z.ZodNullable<z.ZodObject<{
6285
+ id: z.ZodNumber;
6286
+ username: z.ZodString;
6287
+ avatar: z.ZodString;
6288
+ guest: z.ZodBoolean;
6289
+ }, z.core.$strip>>;
6290
+ }, z.core.$strip>;
6291
+ /** What a launch into a tournament match carries. */
6292
+ export type TournamentLaunch = z.infer<typeof TournamentLaunch>;
6293
+ //#endregion
6294
+ //#region src/api/tournaments/endpoints.d.ts
6295
+ /** `GET /tournaments` filters. */
6296
+ export declare const TournamentListQuery: z.ZodObject<{
6297
+ game: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"">, z.ZodString]>>;
6298
+ }, z.core.$strip>;
6299
+ /** The tournament endpoints. */
6300
+ export declare const tournamentEndpoints: {
6301
+ joinTournament: import("@ayepi/core").Endpoint<{
6302
+ readonly method: "POST";
6303
+ readonly path: "/tournaments/:id/join";
6304
+ readonly params: z.ZodObject<{
6305
+ id: z.ZodCoercedNumber<unknown>;
6306
+ }, z.core.$strip>;
6307
+ readonly body: z.ZodObject<{
6308
+ key: z.ZodOptional<z.ZodString>;
6309
+ }, z.core.$strip>;
6310
+ readonly response: z.ZodObject<{
6311
+ id: z.ZodNumber;
6312
+ title: z.ZodString;
6313
+ creator: z.ZodNullable<z.ZodObject<{
6314
+ id: z.ZodNumber;
6315
+ username: z.ZodString;
6316
+ avatar: z.ZodString;
6317
+ guest: z.ZodBoolean;
6318
+ }, z.core.$strip>>;
6319
+ visibility: z.ZodEnum<{
6320
+ open: "open";
6321
+ closed: "closed";
6322
+ }>;
6323
+ phase: z.ZodEnum<{
6324
+ done: "done";
6325
+ cancelled: "cancelled";
6326
+ signup: "signup";
6327
+ running: "running";
6328
+ }>;
6329
+ games: z.ZodArray<z.ZodString>;
6330
+ pick: z.ZodEnum<{
6331
+ fixed: "fixed";
6332
+ "random-once": "random-once";
6333
+ "random-each": "random-each";
6334
+ }>;
6335
+ game: z.ZodNullable<z.ZodString>;
6336
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6337
+ lives: z.ZodNumber;
6338
+ seeding: z.ZodEnum<{
6339
+ rank: "rank";
6340
+ random: "random";
6341
+ }>;
6342
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6343
+ kind: z.ZodLiteral<"scheduled">;
6344
+ at: z.ZodNumber;
6345
+ }, z.core.$strip>, z.ZodObject<{
6346
+ kind: z.ZodLiteral<"filled">;
6347
+ }, z.core.$strip>], "kind">;
6348
+ minPlayers: z.ZodNumber;
6349
+ maxPlayers: z.ZodNumber;
6350
+ readyMinutes: z.ZodNumber;
6351
+ entrants: z.ZodNumber;
6352
+ createdAt: z.ZodNumber;
6353
+ startedAt: z.ZodNullable<z.ZodNumber>;
6354
+ endedAt: z.ZodNullable<z.ZodNumber>;
6355
+ champion: z.ZodNullable<z.ZodObject<{
6356
+ id: z.ZodNumber;
6357
+ username: z.ZodString;
6358
+ avatar: z.ZodString;
6359
+ guest: z.ZodBoolean;
6360
+ }, z.core.$strip>>;
6361
+ me: z.ZodObject<{
6362
+ joined: z.ZodBoolean;
6363
+ invited: z.ZodBoolean;
6364
+ following: z.ZodBoolean;
6365
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6366
+ isCreator: z.ZodBoolean;
6367
+ stillIn: z.ZodBoolean;
6368
+ nextMatch: z.ZodNullable<z.ZodObject<{
6369
+ id: z.ZodString;
6370
+ opponent: z.ZodNullable<z.ZodObject<{
6371
+ id: z.ZodNumber;
6372
+ username: z.ZodString;
6373
+ avatar: z.ZodString;
6374
+ guest: z.ZodBoolean;
6375
+ }, z.core.$strip>>;
6376
+ game: z.ZodString;
6377
+ gameTitle: z.ZodString;
6378
+ deadlineAt: z.ZodNumber;
6379
+ started: z.ZodBoolean;
6380
+ }, z.core.$strip>>;
6381
+ }, z.core.$strip>;
6382
+ players: z.ZodArray<z.ZodObject<{
6383
+ user: z.ZodObject<{
6384
+ id: z.ZodNumber;
6385
+ username: z.ZodString;
6386
+ avatar: z.ZodString;
6387
+ guest: z.ZodBoolean;
6388
+ }, z.core.$strip>;
6389
+ seed: z.ZodNullable<z.ZodNumber>;
6390
+ wins: z.ZodNumber;
6391
+ losses: z.ZodNumber;
6392
+ out: z.ZodBoolean;
6393
+ }, z.core.$strip>>;
6394
+ matches: z.ZodArray<z.ZodObject<{
6395
+ id: z.ZodString;
6396
+ stage: z.ZodEnum<{
6397
+ winners: "winners";
6398
+ redemption: "redemption";
6399
+ final: "final";
6400
+ }>;
6401
+ level: z.ZodNumber;
6402
+ round: z.ZodNumber;
6403
+ slot: z.ZodNumber;
6404
+ a: z.ZodNullable<z.ZodNumber>;
6405
+ b: z.ZodNullable<z.ZodNumber>;
6406
+ status: z.ZodEnum<{
6407
+ ready: "ready";
6408
+ waiting: "waiting";
6409
+ done: "done";
6410
+ }>;
6411
+ winnerId: z.ZodNullable<z.ZodNumber>;
6412
+ decision: z.ZodNullable<z.ZodEnum<{
6413
+ forfeit: "forfeit";
6414
+ timeout: "timeout";
6415
+ withdrawn: "withdrawn";
6416
+ played: "played";
6417
+ bye: "bye";
6418
+ }>>;
6419
+ game: z.ZodNullable<z.ZodString>;
6420
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
6421
+ started: z.ZodBoolean;
6422
+ }, z.core.$strip>>;
6423
+ inviteUrl: z.ZodNullable<z.ZodString>;
6424
+ }, z.core.$strip>;
6425
+ readonly errors: {
6426
+ readonly 401: ErrorBodySchema;
6427
+ readonly 403: ErrorBodySchema;
6428
+ readonly 404: ErrorBodySchema;
6429
+ readonly 409: ErrorBodySchema;
6430
+ readonly 429: ErrorBodySchema;
6431
+ };
6432
+ readonly doc: {
6433
+ readonly summary: "Sign up (open tournaments, or closed ones I was invited to or have the link for)";
6434
+ readonly tags: readonly ["tournaments"];
6435
+ };
6436
+ }, {
6437
+ user: SessionUser;
6438
+ clientId: string;
6439
+ }, {}, import("@ayepi/core").EmptyObject>;
6440
+ leaveTournament: import("@ayepi/core").Endpoint<{
6441
+ readonly method: "POST";
6442
+ readonly path: "/tournaments/:id/leave";
6443
+ readonly params: z.ZodObject<{
6444
+ id: z.ZodCoercedNumber<unknown>;
6445
+ }, z.core.$strip>;
6446
+ readonly response: z.ZodObject<{
6447
+ id: z.ZodNumber;
6448
+ title: z.ZodString;
6449
+ creator: z.ZodNullable<z.ZodObject<{
6450
+ id: z.ZodNumber;
6451
+ username: z.ZodString;
6452
+ avatar: z.ZodString;
6453
+ guest: z.ZodBoolean;
6454
+ }, z.core.$strip>>;
6455
+ visibility: z.ZodEnum<{
6456
+ open: "open";
6457
+ closed: "closed";
6458
+ }>;
6459
+ phase: z.ZodEnum<{
6460
+ done: "done";
6461
+ cancelled: "cancelled";
6462
+ signup: "signup";
6463
+ running: "running";
6464
+ }>;
6465
+ games: z.ZodArray<z.ZodString>;
6466
+ pick: z.ZodEnum<{
6467
+ fixed: "fixed";
6468
+ "random-once": "random-once";
6469
+ "random-each": "random-each";
6470
+ }>;
6471
+ game: z.ZodNullable<z.ZodString>;
6472
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6473
+ lives: z.ZodNumber;
6474
+ seeding: z.ZodEnum<{
6475
+ rank: "rank";
6476
+ random: "random";
6477
+ }>;
6478
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6479
+ kind: z.ZodLiteral<"scheduled">;
6480
+ at: z.ZodNumber;
6481
+ }, z.core.$strip>, z.ZodObject<{
6482
+ kind: z.ZodLiteral<"filled">;
6483
+ }, z.core.$strip>], "kind">;
6484
+ minPlayers: z.ZodNumber;
6485
+ maxPlayers: z.ZodNumber;
6486
+ readyMinutes: z.ZodNumber;
6487
+ entrants: z.ZodNumber;
6488
+ createdAt: z.ZodNumber;
6489
+ startedAt: z.ZodNullable<z.ZodNumber>;
6490
+ endedAt: z.ZodNullable<z.ZodNumber>;
6491
+ champion: z.ZodNullable<z.ZodObject<{
6492
+ id: z.ZodNumber;
6493
+ username: z.ZodString;
6494
+ avatar: z.ZodString;
6495
+ guest: z.ZodBoolean;
6496
+ }, z.core.$strip>>;
6497
+ me: z.ZodObject<{
6498
+ joined: z.ZodBoolean;
6499
+ invited: z.ZodBoolean;
6500
+ following: z.ZodBoolean;
6501
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6502
+ isCreator: z.ZodBoolean;
6503
+ stillIn: z.ZodBoolean;
6504
+ nextMatch: z.ZodNullable<z.ZodObject<{
6505
+ id: z.ZodString;
6506
+ opponent: z.ZodNullable<z.ZodObject<{
6507
+ id: z.ZodNumber;
6508
+ username: z.ZodString;
6509
+ avatar: z.ZodString;
6510
+ guest: z.ZodBoolean;
6511
+ }, z.core.$strip>>;
6512
+ game: z.ZodString;
6513
+ gameTitle: z.ZodString;
6514
+ deadlineAt: z.ZodNumber;
6515
+ started: z.ZodBoolean;
6516
+ }, z.core.$strip>>;
6517
+ }, z.core.$strip>;
6518
+ players: z.ZodArray<z.ZodObject<{
6519
+ user: z.ZodObject<{
6520
+ id: z.ZodNumber;
6521
+ username: z.ZodString;
6522
+ avatar: z.ZodString;
6523
+ guest: z.ZodBoolean;
6524
+ }, z.core.$strip>;
6525
+ seed: z.ZodNullable<z.ZodNumber>;
6526
+ wins: z.ZodNumber;
6527
+ losses: z.ZodNumber;
6528
+ out: z.ZodBoolean;
6529
+ }, z.core.$strip>>;
6530
+ matches: z.ZodArray<z.ZodObject<{
6531
+ id: z.ZodString;
6532
+ stage: z.ZodEnum<{
6533
+ winners: "winners";
6534
+ redemption: "redemption";
6535
+ final: "final";
6536
+ }>;
6537
+ level: z.ZodNumber;
6538
+ round: z.ZodNumber;
6539
+ slot: z.ZodNumber;
6540
+ a: z.ZodNullable<z.ZodNumber>;
6541
+ b: z.ZodNullable<z.ZodNumber>;
6542
+ status: z.ZodEnum<{
6543
+ ready: "ready";
6544
+ waiting: "waiting";
6545
+ done: "done";
6546
+ }>;
6547
+ winnerId: z.ZodNullable<z.ZodNumber>;
6548
+ decision: z.ZodNullable<z.ZodEnum<{
6549
+ forfeit: "forfeit";
6550
+ timeout: "timeout";
6551
+ withdrawn: "withdrawn";
6552
+ played: "played";
6553
+ bye: "bye";
6554
+ }>>;
6555
+ game: z.ZodNullable<z.ZodString>;
6556
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
6557
+ started: z.ZodBoolean;
6558
+ }, z.core.$strip>>;
6559
+ inviteUrl: z.ZodNullable<z.ZodString>;
6560
+ }, z.core.$strip>;
6561
+ readonly errors: {
6562
+ readonly 401: ErrorBodySchema;
6563
+ readonly 403: ErrorBodySchema;
6564
+ readonly 404: ErrorBodySchema;
6565
+ readonly 409: ErrorBodySchema;
6566
+ };
6567
+ readonly doc: {
6568
+ readonly summary: "Drop out: before the start my place is freed; after it I forfeit what is left";
6569
+ readonly tags: readonly ["tournaments"];
6570
+ };
6571
+ }, {
6572
+ user: SessionUser;
6573
+ clientId: string;
6574
+ }, {}, import("@ayepi/core").EmptyObject>;
6575
+ launchTournamentMatch: import("@ayepi/core").Endpoint<{
6576
+ readonly method: "POST";
6577
+ readonly path: "/tournaments/:id/matches/:match/launch";
6578
+ readonly params: z.ZodObject<{
6579
+ id: z.ZodCoercedNumber<unknown>;
6580
+ match: z.ZodString;
6581
+ }, z.core.$strip>;
6582
+ readonly response: z.ZodObject<{
6583
+ launchToken: z.ZodString;
6584
+ url: z.ZodString;
6585
+ }, z.core.$strip>;
6586
+ readonly errors: {
6587
+ readonly 401: ErrorBodySchema;
6588
+ readonly 403: ErrorBodySchema;
6589
+ readonly 404: ErrorBodySchema;
6590
+ readonly 409: ErrorBodySchema;
6591
+ };
6592
+ readonly doc: {
6593
+ readonly summary: "A launch into my ready match: host for the better seed, guest for the other";
6594
+ readonly tags: readonly ["tournaments"];
6595
+ };
6596
+ }, {
6597
+ user: SessionUser;
6598
+ clientId: string;
6599
+ }, {}, import("@ayepi/core").EmptyObject>;
6600
+ createTournament: import("@ayepi/core").Endpoint<{
6601
+ readonly method: "POST";
6602
+ readonly path: "/tournaments";
6603
+ readonly body: z.ZodObject<{
6604
+ title: z.ZodOptional<z.ZodString>;
6605
+ games: z.ZodArray<z.ZodString>;
6606
+ pick: z.ZodDefault<z.ZodEnum<{
6607
+ fixed: "fixed";
6608
+ "random-once": "random-once";
6609
+ "random-each": "random-each";
6610
+ }>>;
6611
+ lives: z.ZodDefault<z.ZodNumber>;
6612
+ seeding: z.ZodDefault<z.ZodEnum<{
6613
+ rank: "rank";
6614
+ random: "random";
6615
+ }>>;
6616
+ visibility: z.ZodDefault<z.ZodEnum<{
6617
+ open: "open";
6618
+ closed: "closed";
6619
+ }>>;
6620
+ start: z.ZodDefault<z.ZodDiscriminatedUnion<[z.ZodObject<{
6621
+ kind: z.ZodLiteral<"scheduled">;
6622
+ at: z.ZodNumber;
6623
+ }, z.core.$strip>, z.ZodObject<{
6624
+ kind: z.ZodLiteral<"filled">;
6625
+ }, z.core.$strip>], "kind">>;
6626
+ minPlayers: z.ZodDefault<z.ZodNumber>;
6627
+ maxPlayers: z.ZodDefault<z.ZodNumber>;
6628
+ readyMinutes: z.ZodDefault<z.ZodNumber>;
6629
+ invite: z.ZodOptional<z.ZodArray<z.ZodNumber>>;
6630
+ }, z.core.$strip>;
6631
+ readonly response: z.ZodObject<{
6632
+ id: z.ZodNumber;
6633
+ title: z.ZodString;
6634
+ creator: z.ZodNullable<z.ZodObject<{
6635
+ id: z.ZodNumber;
6636
+ username: z.ZodString;
6637
+ avatar: z.ZodString;
6638
+ guest: z.ZodBoolean;
6639
+ }, z.core.$strip>>;
6640
+ visibility: z.ZodEnum<{
6641
+ open: "open";
6642
+ closed: "closed";
6643
+ }>;
6644
+ phase: z.ZodEnum<{
6645
+ done: "done";
6646
+ cancelled: "cancelled";
6647
+ signup: "signup";
6648
+ running: "running";
6649
+ }>;
6650
+ games: z.ZodArray<z.ZodString>;
6651
+ pick: z.ZodEnum<{
6652
+ fixed: "fixed";
6653
+ "random-once": "random-once";
6654
+ "random-each": "random-each";
6655
+ }>;
6656
+ game: z.ZodNullable<z.ZodString>;
6657
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6658
+ lives: z.ZodNumber;
6659
+ seeding: z.ZodEnum<{
6660
+ rank: "rank";
6661
+ random: "random";
6662
+ }>;
6663
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6664
+ kind: z.ZodLiteral<"scheduled">;
6665
+ at: z.ZodNumber;
6666
+ }, z.core.$strip>, z.ZodObject<{
6667
+ kind: z.ZodLiteral<"filled">;
6668
+ }, z.core.$strip>], "kind">;
6669
+ minPlayers: z.ZodNumber;
6670
+ maxPlayers: z.ZodNumber;
6671
+ readyMinutes: z.ZodNumber;
6672
+ entrants: z.ZodNumber;
6673
+ createdAt: z.ZodNumber;
6674
+ startedAt: z.ZodNullable<z.ZodNumber>;
6675
+ endedAt: z.ZodNullable<z.ZodNumber>;
6676
+ champion: z.ZodNullable<z.ZodObject<{
6677
+ id: z.ZodNumber;
6678
+ username: z.ZodString;
6679
+ avatar: z.ZodString;
6680
+ guest: z.ZodBoolean;
6681
+ }, z.core.$strip>>;
6682
+ me: z.ZodObject<{
6683
+ joined: z.ZodBoolean;
6684
+ invited: z.ZodBoolean;
6685
+ following: z.ZodBoolean;
6686
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6687
+ isCreator: z.ZodBoolean;
6688
+ stillIn: z.ZodBoolean;
6689
+ nextMatch: z.ZodNullable<z.ZodObject<{
6690
+ id: z.ZodString;
6691
+ opponent: z.ZodNullable<z.ZodObject<{
6692
+ id: z.ZodNumber;
6693
+ username: z.ZodString;
6694
+ avatar: z.ZodString;
6695
+ guest: z.ZodBoolean;
6696
+ }, z.core.$strip>>;
6697
+ game: z.ZodString;
6698
+ gameTitle: z.ZodString;
6699
+ deadlineAt: z.ZodNumber;
6700
+ started: z.ZodBoolean;
6701
+ }, z.core.$strip>>;
6702
+ }, z.core.$strip>;
6703
+ players: z.ZodArray<z.ZodObject<{
6704
+ user: z.ZodObject<{
6705
+ id: z.ZodNumber;
6706
+ username: z.ZodString;
6707
+ avatar: z.ZodString;
6708
+ guest: z.ZodBoolean;
6709
+ }, z.core.$strip>;
6710
+ seed: z.ZodNullable<z.ZodNumber>;
6711
+ wins: z.ZodNumber;
6712
+ losses: z.ZodNumber;
6713
+ out: z.ZodBoolean;
6714
+ }, z.core.$strip>>;
6715
+ matches: z.ZodArray<z.ZodObject<{
6716
+ id: z.ZodString;
6717
+ stage: z.ZodEnum<{
6718
+ winners: "winners";
6719
+ redemption: "redemption";
6720
+ final: "final";
6721
+ }>;
6722
+ level: z.ZodNumber;
6723
+ round: z.ZodNumber;
6724
+ slot: z.ZodNumber;
6725
+ a: z.ZodNullable<z.ZodNumber>;
6726
+ b: z.ZodNullable<z.ZodNumber>;
6727
+ status: z.ZodEnum<{
6728
+ ready: "ready";
6729
+ waiting: "waiting";
6730
+ done: "done";
6731
+ }>;
6732
+ winnerId: z.ZodNullable<z.ZodNumber>;
6733
+ decision: z.ZodNullable<z.ZodEnum<{
6734
+ forfeit: "forfeit";
6735
+ timeout: "timeout";
6736
+ withdrawn: "withdrawn";
6737
+ played: "played";
6738
+ bye: "bye";
6739
+ }>>;
6740
+ game: z.ZodNullable<z.ZodString>;
6741
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
6742
+ started: z.ZodBoolean;
6743
+ }, z.core.$strip>>;
6744
+ inviteUrl: z.ZodNullable<z.ZodString>;
6745
+ }, z.core.$strip>;
6746
+ readonly errors: {
6747
+ readonly 400: ErrorBodySchema;
6748
+ readonly 401: ErrorBodySchema;
6749
+ readonly 403: ErrorBodySchema;
6750
+ readonly 404: ErrorBodySchema;
6751
+ readonly 422: ErrorBodySchema;
6752
+ readonly 429: ErrorBodySchema;
6753
+ };
6754
+ readonly doc: {
6755
+ readonly summary: "Create a tournament (I am signed up to it); the title goes through the content filter";
6756
+ readonly tags: readonly ["tournaments"];
6757
+ };
6758
+ }, {
6759
+ user: SessionUser;
6760
+ clientId: string;
6761
+ }, {}, import("@ayepi/core").EmptyObject>;
6762
+ inviteToTournament: import("@ayepi/core").Endpoint<{
6763
+ readonly method: "POST";
6764
+ readonly path: "/tournaments/:id/invites";
6765
+ readonly params: z.ZodObject<{
6766
+ id: z.ZodCoercedNumber<unknown>;
6767
+ }, z.core.$strip>;
6768
+ readonly body: z.ZodObject<{
6769
+ userIds: z.ZodArray<z.ZodNumber>;
6770
+ }, z.core.$strip>;
6771
+ readonly response: z.ZodObject<{
6772
+ invited: z.ZodNumber;
6773
+ }, z.core.$strip>;
6774
+ readonly errors: {
6775
+ readonly 401: ErrorBodySchema;
6776
+ readonly 403: ErrorBodySchema;
6777
+ readonly 404: ErrorBodySchema;
6778
+ readonly 409: ErrorBodySchema;
6779
+ readonly 429: ErrorBodySchema;
6780
+ };
6781
+ readonly doc: {
6782
+ readonly summary: "Creator: invite friends (others are skipped without saying why)";
6783
+ readonly tags: readonly ["tournaments"];
6784
+ };
6785
+ }, {
6786
+ user: SessionUser;
6787
+ clientId: string;
6788
+ }, {}, import("@ayepi/core").EmptyObject>;
6789
+ followTournament: import("@ayepi/core").Endpoint<{
6790
+ readonly method: "PUT";
6791
+ readonly path: "/tournaments/:id/follow";
6792
+ readonly params: z.ZodObject<{
6793
+ id: z.ZodCoercedNumber<unknown>;
6794
+ }, z.core.$strip>;
6795
+ readonly body: z.ZodObject<{
6796
+ leadMinutes: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
6797
+ }, z.core.$strip>;
6798
+ readonly response: z.ZodObject<{
6799
+ id: z.ZodNumber;
6800
+ title: z.ZodString;
6801
+ creator: z.ZodNullable<z.ZodObject<{
6802
+ id: z.ZodNumber;
6803
+ username: z.ZodString;
6804
+ avatar: z.ZodString;
6805
+ guest: z.ZodBoolean;
6806
+ }, z.core.$strip>>;
6807
+ visibility: z.ZodEnum<{
6808
+ open: "open";
6809
+ closed: "closed";
6810
+ }>;
6811
+ phase: z.ZodEnum<{
6812
+ done: "done";
6813
+ cancelled: "cancelled";
6814
+ signup: "signup";
6815
+ running: "running";
6816
+ }>;
6817
+ games: z.ZodArray<z.ZodString>;
6818
+ pick: z.ZodEnum<{
6819
+ fixed: "fixed";
6820
+ "random-once": "random-once";
6821
+ "random-each": "random-each";
6822
+ }>;
6823
+ game: z.ZodNullable<z.ZodString>;
6824
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6825
+ lives: z.ZodNumber;
6826
+ seeding: z.ZodEnum<{
6827
+ rank: "rank";
6828
+ random: "random";
6829
+ }>;
6830
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6831
+ kind: z.ZodLiteral<"scheduled">;
6832
+ at: z.ZodNumber;
6833
+ }, z.core.$strip>, z.ZodObject<{
6834
+ kind: z.ZodLiteral<"filled">;
6835
+ }, z.core.$strip>], "kind">;
6836
+ minPlayers: z.ZodNumber;
6837
+ maxPlayers: z.ZodNumber;
6838
+ readyMinutes: z.ZodNumber;
6839
+ entrants: z.ZodNumber;
6840
+ createdAt: z.ZodNumber;
6841
+ startedAt: z.ZodNullable<z.ZodNumber>;
6842
+ endedAt: z.ZodNullable<z.ZodNumber>;
6843
+ champion: z.ZodNullable<z.ZodObject<{
6844
+ id: z.ZodNumber;
6845
+ username: z.ZodString;
6846
+ avatar: z.ZodString;
6847
+ guest: z.ZodBoolean;
6848
+ }, z.core.$strip>>;
6849
+ me: z.ZodObject<{
6850
+ joined: z.ZodBoolean;
6851
+ invited: z.ZodBoolean;
6852
+ following: z.ZodBoolean;
6853
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6854
+ isCreator: z.ZodBoolean;
6855
+ stillIn: z.ZodBoolean;
6856
+ nextMatch: z.ZodNullable<z.ZodObject<{
6857
+ id: z.ZodString;
6858
+ opponent: z.ZodNullable<z.ZodObject<{
6859
+ id: z.ZodNumber;
6860
+ username: z.ZodString;
6861
+ avatar: z.ZodString;
6862
+ guest: z.ZodBoolean;
6863
+ }, z.core.$strip>>;
6864
+ game: z.ZodString;
6865
+ gameTitle: z.ZodString;
6866
+ deadlineAt: z.ZodNumber;
6867
+ started: z.ZodBoolean;
6868
+ }, z.core.$strip>>;
6869
+ }, z.core.$strip>;
6870
+ }, z.core.$strip>;
6871
+ readonly errors: {
6872
+ readonly 401: ErrorBodySchema;
6873
+ readonly 403: ErrorBodySchema;
6874
+ readonly 404: ErrorBodySchema;
6875
+ };
6876
+ readonly doc: {
6877
+ readonly summary: "Follow a tournament (hear when it opens, starts and ends); leadMinutes: remind me that long before a scheduled start (absent: no reminder)";
6878
+ readonly tags: readonly ["tournaments"];
6879
+ };
6880
+ }, {
6881
+ user: SessionUser;
6882
+ clientId: string;
6883
+ }, {}, import("@ayepi/core").EmptyObject>;
6884
+ unfollowTournament: import("@ayepi/core").Endpoint<{
6885
+ readonly method: "DELETE";
6886
+ readonly path: "/tournaments/:id/follow";
6887
+ readonly params: z.ZodObject<{
6888
+ id: z.ZodCoercedNumber<unknown>;
6889
+ }, z.core.$strip>;
6890
+ readonly response: z.ZodObject<{
6891
+ ok: z.ZodLiteral<true>;
6892
+ }, z.core.$strip>;
6893
+ readonly errors: {
6894
+ readonly 401: ErrorBodySchema;
6895
+ readonly 403: ErrorBodySchema;
6896
+ readonly 404: ErrorBodySchema;
6897
+ };
6898
+ readonly doc: {
6899
+ readonly summary: "Stop following a tournament";
6900
+ readonly tags: readonly ["tournaments"];
6901
+ };
6902
+ }, {
6903
+ user: SessionUser;
6904
+ clientId: string;
6905
+ }, {}, import("@ayepi/core").EmptyObject>;
6906
+ startTournament: import("@ayepi/core").Endpoint<{
6907
+ readonly method: "POST";
6908
+ readonly path: "/tournaments/:id/start";
6909
+ readonly params: z.ZodObject<{
6910
+ id: z.ZodCoercedNumber<unknown>;
6911
+ }, z.core.$strip>;
6912
+ readonly response: z.ZodObject<{
6913
+ id: z.ZodNumber;
6914
+ title: z.ZodString;
6915
+ creator: z.ZodNullable<z.ZodObject<{
6916
+ id: z.ZodNumber;
6917
+ username: z.ZodString;
6918
+ avatar: z.ZodString;
6919
+ guest: z.ZodBoolean;
6920
+ }, z.core.$strip>>;
6921
+ visibility: z.ZodEnum<{
6922
+ open: "open";
6923
+ closed: "closed";
6924
+ }>;
6925
+ phase: z.ZodEnum<{
6926
+ done: "done";
6927
+ cancelled: "cancelled";
6928
+ signup: "signup";
6929
+ running: "running";
6930
+ }>;
6931
+ games: z.ZodArray<z.ZodString>;
6932
+ pick: z.ZodEnum<{
6933
+ fixed: "fixed";
6934
+ "random-once": "random-once";
6935
+ "random-each": "random-each";
6936
+ }>;
6937
+ game: z.ZodNullable<z.ZodString>;
6938
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
6939
+ lives: z.ZodNumber;
6940
+ seeding: z.ZodEnum<{
6941
+ rank: "rank";
6942
+ random: "random";
6943
+ }>;
6944
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
6945
+ kind: z.ZodLiteral<"scheduled">;
6946
+ at: z.ZodNumber;
6947
+ }, z.core.$strip>, z.ZodObject<{
6948
+ kind: z.ZodLiteral<"filled">;
6949
+ }, z.core.$strip>], "kind">;
6950
+ minPlayers: z.ZodNumber;
6951
+ maxPlayers: z.ZodNumber;
6952
+ readyMinutes: z.ZodNumber;
6953
+ entrants: z.ZodNumber;
6954
+ createdAt: z.ZodNumber;
6955
+ startedAt: z.ZodNullable<z.ZodNumber>;
6956
+ endedAt: z.ZodNullable<z.ZodNumber>;
6957
+ champion: z.ZodNullable<z.ZodObject<{
6958
+ id: z.ZodNumber;
6959
+ username: z.ZodString;
6960
+ avatar: z.ZodString;
6961
+ guest: z.ZodBoolean;
6962
+ }, z.core.$strip>>;
6963
+ me: z.ZodObject<{
6964
+ joined: z.ZodBoolean;
6965
+ invited: z.ZodBoolean;
6966
+ following: z.ZodBoolean;
6967
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
6968
+ isCreator: z.ZodBoolean;
6969
+ stillIn: z.ZodBoolean;
6970
+ nextMatch: z.ZodNullable<z.ZodObject<{
6971
+ id: z.ZodString;
6972
+ opponent: z.ZodNullable<z.ZodObject<{
6973
+ id: z.ZodNumber;
6974
+ username: z.ZodString;
6975
+ avatar: z.ZodString;
6976
+ guest: z.ZodBoolean;
6977
+ }, z.core.$strip>>;
6978
+ game: z.ZodString;
6979
+ gameTitle: z.ZodString;
6980
+ deadlineAt: z.ZodNumber;
6981
+ started: z.ZodBoolean;
6982
+ }, z.core.$strip>>;
6983
+ }, z.core.$strip>;
6984
+ players: z.ZodArray<z.ZodObject<{
6985
+ user: z.ZodObject<{
6986
+ id: z.ZodNumber;
6987
+ username: z.ZodString;
6988
+ avatar: z.ZodString;
6989
+ guest: z.ZodBoolean;
6990
+ }, z.core.$strip>;
6991
+ seed: z.ZodNullable<z.ZodNumber>;
6992
+ wins: z.ZodNumber;
6993
+ losses: z.ZodNumber;
6994
+ out: z.ZodBoolean;
6995
+ }, z.core.$strip>>;
6996
+ matches: z.ZodArray<z.ZodObject<{
6997
+ id: z.ZodString;
6998
+ stage: z.ZodEnum<{
6999
+ winners: "winners";
7000
+ redemption: "redemption";
7001
+ final: "final";
7002
+ }>;
7003
+ level: z.ZodNumber;
7004
+ round: z.ZodNumber;
7005
+ slot: z.ZodNumber;
7006
+ a: z.ZodNullable<z.ZodNumber>;
7007
+ b: z.ZodNullable<z.ZodNumber>;
7008
+ status: z.ZodEnum<{
7009
+ ready: "ready";
7010
+ waiting: "waiting";
7011
+ done: "done";
7012
+ }>;
7013
+ winnerId: z.ZodNullable<z.ZodNumber>;
7014
+ decision: z.ZodNullable<z.ZodEnum<{
7015
+ forfeit: "forfeit";
7016
+ timeout: "timeout";
7017
+ withdrawn: "withdrawn";
7018
+ played: "played";
7019
+ bye: "bye";
7020
+ }>>;
7021
+ game: z.ZodNullable<z.ZodString>;
7022
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
7023
+ started: z.ZodBoolean;
7024
+ }, z.core.$strip>>;
7025
+ inviteUrl: z.ZodNullable<z.ZodString>;
7026
+ }, z.core.$strip>;
7027
+ readonly errors: {
7028
+ readonly 401: ErrorBodySchema;
7029
+ readonly 403: ErrorBodySchema;
7030
+ readonly 404: ErrorBodySchema;
7031
+ readonly 409: ErrorBodySchema;
7032
+ };
7033
+ readonly doc: {
7034
+ readonly summary: "Creator: start now with whoever signed up (at least two)";
7035
+ readonly tags: readonly ["tournaments"];
7036
+ };
7037
+ }, {
7038
+ user: SessionUser;
7039
+ clientId: string;
7040
+ }, {}, import("@ayepi/core").EmptyObject>;
7041
+ cancelTournament: import("@ayepi/core").Endpoint<{
7042
+ readonly method: "DELETE";
7043
+ readonly path: "/tournaments/:id";
7044
+ readonly params: z.ZodObject<{
7045
+ id: z.ZodCoercedNumber<unknown>;
7046
+ }, z.core.$strip>;
7047
+ readonly response: z.ZodObject<{
7048
+ ok: z.ZodLiteral<true>;
7049
+ }, z.core.$strip>;
7050
+ readonly errors: {
7051
+ readonly 401: ErrorBodySchema;
7052
+ readonly 403: ErrorBodySchema;
7053
+ readonly 404: ErrorBodySchema;
7054
+ readonly 409: ErrorBodySchema;
7055
+ };
7056
+ readonly doc: {
7057
+ readonly summary: "Creator (or an admin): cancel a tournament that has not finished";
7058
+ readonly tags: readonly ["tournaments"];
7059
+ };
7060
+ }, {
7061
+ user: SessionUser;
7062
+ clientId: string;
7063
+ }, {}, import("@ayepi/core").EmptyObject>;
7064
+ listTournaments: import("@ayepi/core").Endpoint<{
7065
+ readonly method: "GET";
7066
+ readonly path: "/tournaments";
7067
+ readonly query: z.ZodObject<{
7068
+ game: z.ZodOptional<z.ZodUnion<readonly [z.ZodLiteral<"">, z.ZodString]>>;
7069
+ }, z.core.$strip>;
7070
+ readonly response: z.ZodObject<{
7071
+ tournaments: z.ZodArray<z.ZodObject<{
7072
+ id: z.ZodNumber;
7073
+ title: z.ZodString;
7074
+ creator: z.ZodNullable<z.ZodObject<{
7075
+ id: z.ZodNumber;
7076
+ username: z.ZodString;
7077
+ avatar: z.ZodString;
7078
+ guest: z.ZodBoolean;
7079
+ }, z.core.$strip>>;
7080
+ visibility: z.ZodEnum<{
7081
+ open: "open";
7082
+ closed: "closed";
7083
+ }>;
7084
+ phase: z.ZodEnum<{
7085
+ done: "done";
7086
+ cancelled: "cancelled";
7087
+ signup: "signup";
7088
+ running: "running";
7089
+ }>;
7090
+ games: z.ZodArray<z.ZodString>;
7091
+ pick: z.ZodEnum<{
7092
+ fixed: "fixed";
7093
+ "random-once": "random-once";
7094
+ "random-each": "random-each";
7095
+ }>;
7096
+ game: z.ZodNullable<z.ZodString>;
7097
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7098
+ lives: z.ZodNumber;
7099
+ seeding: z.ZodEnum<{
7100
+ rank: "rank";
7101
+ random: "random";
7102
+ }>;
7103
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7104
+ kind: z.ZodLiteral<"scheduled">;
7105
+ at: z.ZodNumber;
7106
+ }, z.core.$strip>, z.ZodObject<{
7107
+ kind: z.ZodLiteral<"filled">;
7108
+ }, z.core.$strip>], "kind">;
7109
+ minPlayers: z.ZodNumber;
7110
+ maxPlayers: z.ZodNumber;
7111
+ readyMinutes: z.ZodNumber;
7112
+ entrants: z.ZodNumber;
7113
+ createdAt: z.ZodNumber;
7114
+ startedAt: z.ZodNullable<z.ZodNumber>;
7115
+ endedAt: z.ZodNullable<z.ZodNumber>;
7116
+ champion: z.ZodNullable<z.ZodObject<{
7117
+ id: z.ZodNumber;
7118
+ username: z.ZodString;
7119
+ avatar: z.ZodString;
7120
+ guest: z.ZodBoolean;
7121
+ }, z.core.$strip>>;
7122
+ me: z.ZodObject<{
7123
+ joined: z.ZodBoolean;
7124
+ invited: z.ZodBoolean;
7125
+ following: z.ZodBoolean;
7126
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7127
+ isCreator: z.ZodBoolean;
7128
+ stillIn: z.ZodBoolean;
7129
+ nextMatch: z.ZodNullable<z.ZodObject<{
7130
+ id: z.ZodString;
7131
+ opponent: z.ZodNullable<z.ZodObject<{
7132
+ id: z.ZodNumber;
7133
+ username: z.ZodString;
7134
+ avatar: z.ZodString;
7135
+ guest: z.ZodBoolean;
7136
+ }, z.core.$strip>>;
7137
+ game: z.ZodString;
7138
+ gameTitle: z.ZodString;
7139
+ deadlineAt: z.ZodNumber;
7140
+ started: z.ZodBoolean;
7141
+ }, z.core.$strip>>;
7142
+ }, z.core.$strip>;
7143
+ }, z.core.$strip>>;
7144
+ }, z.core.$strip>;
7145
+ readonly doc: {
7146
+ readonly summary: "Open tournaments plus the ones I am in, invited to or follow, soonest first";
7147
+ readonly tags: readonly ["tournaments"];
7148
+ };
7149
+ }, {
7150
+ user: SessionUser | null;
7151
+ clientId: string;
7152
+ }, {}, import("@ayepi/core").EmptyObject>;
7153
+ getTournament: import("@ayepi/core").Endpoint<{
7154
+ readonly method: "GET";
7155
+ readonly path: "/tournaments/:id";
7156
+ readonly params: z.ZodObject<{
7157
+ id: z.ZodCoercedNumber<unknown>;
7158
+ }, z.core.$strip>;
7159
+ readonly query: z.ZodObject<{
7160
+ key: z.ZodOptional<z.ZodString>;
7161
+ }, z.core.$strip>;
7162
+ readonly response: z.ZodObject<{
7163
+ id: z.ZodNumber;
7164
+ title: z.ZodString;
7165
+ creator: z.ZodNullable<z.ZodObject<{
7166
+ id: z.ZodNumber;
7167
+ username: z.ZodString;
7168
+ avatar: z.ZodString;
7169
+ guest: z.ZodBoolean;
7170
+ }, z.core.$strip>>;
7171
+ visibility: z.ZodEnum<{
7172
+ open: "open";
7173
+ closed: "closed";
7174
+ }>;
7175
+ phase: z.ZodEnum<{
7176
+ done: "done";
7177
+ cancelled: "cancelled";
7178
+ signup: "signup";
7179
+ running: "running";
7180
+ }>;
7181
+ games: z.ZodArray<z.ZodString>;
7182
+ pick: z.ZodEnum<{
7183
+ fixed: "fixed";
7184
+ "random-once": "random-once";
7185
+ "random-each": "random-each";
7186
+ }>;
7187
+ game: z.ZodNullable<z.ZodString>;
7188
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7189
+ lives: z.ZodNumber;
7190
+ seeding: z.ZodEnum<{
7191
+ rank: "rank";
7192
+ random: "random";
7193
+ }>;
7194
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7195
+ kind: z.ZodLiteral<"scheduled">;
7196
+ at: z.ZodNumber;
7197
+ }, z.core.$strip>, z.ZodObject<{
7198
+ kind: z.ZodLiteral<"filled">;
7199
+ }, z.core.$strip>], "kind">;
7200
+ minPlayers: z.ZodNumber;
7201
+ maxPlayers: z.ZodNumber;
7202
+ readyMinutes: z.ZodNumber;
7203
+ entrants: z.ZodNumber;
7204
+ createdAt: z.ZodNumber;
7205
+ startedAt: z.ZodNullable<z.ZodNumber>;
7206
+ endedAt: z.ZodNullable<z.ZodNumber>;
7207
+ champion: z.ZodNullable<z.ZodObject<{
7208
+ id: z.ZodNumber;
7209
+ username: z.ZodString;
7210
+ avatar: z.ZodString;
7211
+ guest: z.ZodBoolean;
7212
+ }, z.core.$strip>>;
7213
+ me: z.ZodObject<{
7214
+ joined: z.ZodBoolean;
7215
+ invited: z.ZodBoolean;
7216
+ following: z.ZodBoolean;
7217
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7218
+ isCreator: z.ZodBoolean;
7219
+ stillIn: z.ZodBoolean;
7220
+ nextMatch: z.ZodNullable<z.ZodObject<{
7221
+ id: z.ZodString;
7222
+ opponent: z.ZodNullable<z.ZodObject<{
7223
+ id: z.ZodNumber;
7224
+ username: z.ZodString;
7225
+ avatar: z.ZodString;
7226
+ guest: z.ZodBoolean;
7227
+ }, z.core.$strip>>;
7228
+ game: z.ZodString;
7229
+ gameTitle: z.ZodString;
7230
+ deadlineAt: z.ZodNumber;
7231
+ started: z.ZodBoolean;
7232
+ }, z.core.$strip>>;
7233
+ }, z.core.$strip>;
7234
+ players: z.ZodArray<z.ZodObject<{
7235
+ user: z.ZodObject<{
7236
+ id: z.ZodNumber;
7237
+ username: z.ZodString;
7238
+ avatar: z.ZodString;
7239
+ guest: z.ZodBoolean;
7240
+ }, z.core.$strip>;
7241
+ seed: z.ZodNullable<z.ZodNumber>;
7242
+ wins: z.ZodNumber;
7243
+ losses: z.ZodNumber;
7244
+ out: z.ZodBoolean;
7245
+ }, z.core.$strip>>;
7246
+ matches: z.ZodArray<z.ZodObject<{
7247
+ id: z.ZodString;
7248
+ stage: z.ZodEnum<{
7249
+ winners: "winners";
7250
+ redemption: "redemption";
7251
+ final: "final";
7252
+ }>;
7253
+ level: z.ZodNumber;
7254
+ round: z.ZodNumber;
7255
+ slot: z.ZodNumber;
7256
+ a: z.ZodNullable<z.ZodNumber>;
7257
+ b: z.ZodNullable<z.ZodNumber>;
7258
+ status: z.ZodEnum<{
7259
+ ready: "ready";
7260
+ waiting: "waiting";
7261
+ done: "done";
7262
+ }>;
7263
+ winnerId: z.ZodNullable<z.ZodNumber>;
7264
+ decision: z.ZodNullable<z.ZodEnum<{
7265
+ forfeit: "forfeit";
7266
+ timeout: "timeout";
7267
+ withdrawn: "withdrawn";
7268
+ played: "played";
7269
+ bye: "bye";
7270
+ }>>;
7271
+ game: z.ZodNullable<z.ZodString>;
7272
+ deadlineAt: z.ZodNullable<z.ZodNumber>;
7273
+ started: z.ZodBoolean;
7274
+ }, z.core.$strip>>;
7275
+ inviteUrl: z.ZodNullable<z.ZodString>;
7276
+ }, z.core.$strip>;
7277
+ readonly errors: {
7278
+ readonly 404: ErrorBodySchema;
7279
+ };
7280
+ readonly doc: {
7281
+ readonly summary: "A tournament with its players and bracket (404 for a closed one not shared with me)";
7282
+ readonly tags: readonly ["tournaments"];
7283
+ };
7284
+ }, {
7285
+ user: SessionUser | null;
7286
+ clientId: string;
7287
+ }, {}, import("@ayepi/core").EmptyObject>;
7288
+ };
7289
+ //#endregion
7290
+ //#region src/api/tournaments/play-online.d.ts
7291
+ /** A public lobby or race waiting for players right now. */
7292
+ export declare const OpenLobbyEntry: z.ZodObject<{
7293
+ host: z.ZodObject<{
7294
+ id: z.ZodNumber;
7295
+ username: z.ZodString;
7296
+ avatar: z.ZodString;
7297
+ guest: z.ZodBoolean;
7298
+ }, z.core.$strip>;
7299
+ game: z.ZodString;
7300
+ gameTitle: z.ZodString;
7301
+ mode: z.ZodOptional<z.ZodString>;
7302
+ openSeats: z.ZodNumber;
7303
+ since: z.ZodNumber;
7304
+ }, z.core.$strip>;
7305
+ /** A public lobby or race waiting for players. */
7306
+ export type OpenLobbyEntry = z.infer<typeof OpenLobbyEntry>;
7307
+ /** The counts on the home card. */
7308
+ export declare const PlayOnlineCounts: z.ZodObject<{
7309
+ now: z.ZodNumber;
7310
+ invites: z.ZodNumber;
7311
+ mine: z.ZodNumber;
7312
+ upcoming: z.ZodNumber;
7313
+ }, z.core.$strip>;
7314
+ /** The counts on the home card. */
7315
+ export type PlayOnlineCounts = z.infer<typeof PlayOnlineCounts>;
7316
+ /** Everything playable online for the viewer. */
7317
+ export declare const PlayOnline: z.ZodObject<{
7318
+ counts: z.ZodObject<{
7319
+ now: z.ZodNumber;
7320
+ invites: z.ZodNumber;
7321
+ mine: z.ZodNumber;
7322
+ upcoming: z.ZodNumber;
7323
+ }, z.core.$strip>;
7324
+ lobbies: z.ZodArray<z.ZodObject<{
7325
+ host: z.ZodObject<{
7326
+ id: z.ZodNumber;
7327
+ username: z.ZodString;
7328
+ avatar: z.ZodString;
7329
+ guest: z.ZodBoolean;
7330
+ }, z.core.$strip>;
7331
+ game: z.ZodString;
7332
+ gameTitle: z.ZodString;
7333
+ mode: z.ZodOptional<z.ZodString>;
7334
+ openSeats: z.ZodNumber;
7335
+ since: z.ZodNumber;
7336
+ }, z.core.$strip>>;
7337
+ gameInvites: z.ZodArray<z.ZodObject<{
7338
+ id: z.ZodString;
7339
+ from: z.ZodObject<{
7340
+ id: z.ZodNumber;
7341
+ username: z.ZodString;
7342
+ avatar: z.ZodString;
7343
+ guest: z.ZodBoolean;
7344
+ }, z.core.$strip>;
7345
+ to: z.ZodObject<{
7346
+ id: z.ZodNumber;
7347
+ username: z.ZodString;
7348
+ avatar: z.ZodString;
7349
+ guest: z.ZodBoolean;
7350
+ }, z.core.$strip>;
7351
+ game: z.ZodString;
7352
+ gameTitle: z.ZodString;
7353
+ mode: z.ZodOptional<z.ZodString>;
7354
+ partyId: z.ZodString;
7355
+ expiresAt: z.ZodNumber;
7356
+ }, z.core.$strip>>;
7357
+ tournamentInvites: z.ZodArray<z.ZodObject<{
7358
+ id: z.ZodNumber;
7359
+ title: z.ZodString;
7360
+ creator: z.ZodNullable<z.ZodObject<{
7361
+ id: z.ZodNumber;
7362
+ username: z.ZodString;
7363
+ avatar: z.ZodString;
7364
+ guest: z.ZodBoolean;
7365
+ }, z.core.$strip>>;
7366
+ visibility: z.ZodEnum<{
7367
+ open: "open";
7368
+ closed: "closed";
7369
+ }>;
7370
+ phase: z.ZodEnum<{
7371
+ done: "done";
7372
+ cancelled: "cancelled";
7373
+ signup: "signup";
7374
+ running: "running";
7375
+ }>;
7376
+ games: z.ZodArray<z.ZodString>;
7377
+ pick: z.ZodEnum<{
7378
+ fixed: "fixed";
7379
+ "random-once": "random-once";
7380
+ "random-each": "random-each";
7381
+ }>;
7382
+ game: z.ZodNullable<z.ZodString>;
7383
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7384
+ lives: z.ZodNumber;
7385
+ seeding: z.ZodEnum<{
7386
+ rank: "rank";
7387
+ random: "random";
7388
+ }>;
7389
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7390
+ kind: z.ZodLiteral<"scheduled">;
7391
+ at: z.ZodNumber;
7392
+ }, z.core.$strip>, z.ZodObject<{
7393
+ kind: z.ZodLiteral<"filled">;
7394
+ }, z.core.$strip>], "kind">;
7395
+ minPlayers: z.ZodNumber;
7396
+ maxPlayers: z.ZodNumber;
7397
+ readyMinutes: z.ZodNumber;
7398
+ entrants: z.ZodNumber;
7399
+ createdAt: z.ZodNumber;
7400
+ startedAt: z.ZodNullable<z.ZodNumber>;
7401
+ endedAt: z.ZodNullable<z.ZodNumber>;
7402
+ champion: z.ZodNullable<z.ZodObject<{
7403
+ id: z.ZodNumber;
7404
+ username: z.ZodString;
7405
+ avatar: z.ZodString;
7406
+ guest: z.ZodBoolean;
7407
+ }, z.core.$strip>>;
7408
+ me: z.ZodObject<{
7409
+ joined: z.ZodBoolean;
7410
+ invited: z.ZodBoolean;
7411
+ following: z.ZodBoolean;
7412
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7413
+ isCreator: z.ZodBoolean;
7414
+ stillIn: z.ZodBoolean;
7415
+ nextMatch: z.ZodNullable<z.ZodObject<{
7416
+ id: z.ZodString;
7417
+ opponent: z.ZodNullable<z.ZodObject<{
7418
+ id: z.ZodNumber;
7419
+ username: z.ZodString;
7420
+ avatar: z.ZodString;
7421
+ guest: z.ZodBoolean;
7422
+ }, z.core.$strip>>;
7423
+ game: z.ZodString;
7424
+ gameTitle: z.ZodString;
7425
+ deadlineAt: z.ZodNumber;
7426
+ started: z.ZodBoolean;
7427
+ }, z.core.$strip>>;
7428
+ }, z.core.$strip>;
7429
+ }, z.core.$strip>>;
7430
+ mine: z.ZodArray<z.ZodObject<{
7431
+ id: z.ZodNumber;
7432
+ title: z.ZodString;
7433
+ creator: z.ZodNullable<z.ZodObject<{
7434
+ id: z.ZodNumber;
7435
+ username: z.ZodString;
7436
+ avatar: z.ZodString;
7437
+ guest: z.ZodBoolean;
7438
+ }, z.core.$strip>>;
7439
+ visibility: z.ZodEnum<{
7440
+ open: "open";
7441
+ closed: "closed";
7442
+ }>;
7443
+ phase: z.ZodEnum<{
7444
+ done: "done";
7445
+ cancelled: "cancelled";
7446
+ signup: "signup";
7447
+ running: "running";
7448
+ }>;
7449
+ games: z.ZodArray<z.ZodString>;
7450
+ pick: z.ZodEnum<{
7451
+ fixed: "fixed";
7452
+ "random-once": "random-once";
7453
+ "random-each": "random-each";
7454
+ }>;
7455
+ game: z.ZodNullable<z.ZodString>;
7456
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7457
+ lives: z.ZodNumber;
7458
+ seeding: z.ZodEnum<{
7459
+ rank: "rank";
7460
+ random: "random";
7461
+ }>;
7462
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7463
+ kind: z.ZodLiteral<"scheduled">;
7464
+ at: z.ZodNumber;
7465
+ }, z.core.$strip>, z.ZodObject<{
7466
+ kind: z.ZodLiteral<"filled">;
7467
+ }, z.core.$strip>], "kind">;
7468
+ minPlayers: z.ZodNumber;
7469
+ maxPlayers: z.ZodNumber;
7470
+ readyMinutes: z.ZodNumber;
7471
+ entrants: z.ZodNumber;
7472
+ createdAt: z.ZodNumber;
7473
+ startedAt: z.ZodNullable<z.ZodNumber>;
7474
+ endedAt: z.ZodNullable<z.ZodNumber>;
7475
+ champion: z.ZodNullable<z.ZodObject<{
7476
+ id: z.ZodNumber;
7477
+ username: z.ZodString;
7478
+ avatar: z.ZodString;
7479
+ guest: z.ZodBoolean;
7480
+ }, z.core.$strip>>;
7481
+ me: z.ZodObject<{
7482
+ joined: z.ZodBoolean;
7483
+ invited: z.ZodBoolean;
7484
+ following: z.ZodBoolean;
7485
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7486
+ isCreator: z.ZodBoolean;
7487
+ stillIn: z.ZodBoolean;
7488
+ nextMatch: z.ZodNullable<z.ZodObject<{
7489
+ id: z.ZodString;
7490
+ opponent: z.ZodNullable<z.ZodObject<{
7491
+ id: z.ZodNumber;
7492
+ username: z.ZodString;
7493
+ avatar: z.ZodString;
7494
+ guest: z.ZodBoolean;
7495
+ }, z.core.$strip>>;
7496
+ game: z.ZodString;
7497
+ gameTitle: z.ZodString;
7498
+ deadlineAt: z.ZodNumber;
7499
+ started: z.ZodBoolean;
7500
+ }, z.core.$strip>>;
7501
+ }, z.core.$strip>;
7502
+ }, z.core.$strip>>;
7503
+ upcoming: z.ZodArray<z.ZodObject<{
7504
+ id: z.ZodNumber;
7505
+ title: z.ZodString;
7506
+ creator: z.ZodNullable<z.ZodObject<{
7507
+ id: z.ZodNumber;
7508
+ username: z.ZodString;
7509
+ avatar: z.ZodString;
7510
+ guest: z.ZodBoolean;
7511
+ }, z.core.$strip>>;
7512
+ visibility: z.ZodEnum<{
7513
+ open: "open";
7514
+ closed: "closed";
7515
+ }>;
7516
+ phase: z.ZodEnum<{
7517
+ done: "done";
7518
+ cancelled: "cancelled";
7519
+ signup: "signup";
7520
+ running: "running";
7521
+ }>;
7522
+ games: z.ZodArray<z.ZodString>;
7523
+ pick: z.ZodEnum<{
7524
+ fixed: "fixed";
7525
+ "random-once": "random-once";
7526
+ "random-each": "random-each";
7527
+ }>;
7528
+ game: z.ZodNullable<z.ZodString>;
7529
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7530
+ lives: z.ZodNumber;
7531
+ seeding: z.ZodEnum<{
7532
+ rank: "rank";
7533
+ random: "random";
7534
+ }>;
7535
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7536
+ kind: z.ZodLiteral<"scheduled">;
7537
+ at: z.ZodNumber;
7538
+ }, z.core.$strip>, z.ZodObject<{
7539
+ kind: z.ZodLiteral<"filled">;
7540
+ }, z.core.$strip>], "kind">;
7541
+ minPlayers: z.ZodNumber;
7542
+ maxPlayers: z.ZodNumber;
7543
+ readyMinutes: z.ZodNumber;
7544
+ entrants: z.ZodNumber;
7545
+ createdAt: z.ZodNumber;
7546
+ startedAt: z.ZodNullable<z.ZodNumber>;
7547
+ endedAt: z.ZodNullable<z.ZodNumber>;
7548
+ champion: z.ZodNullable<z.ZodObject<{
7549
+ id: z.ZodNumber;
7550
+ username: z.ZodString;
7551
+ avatar: z.ZodString;
7552
+ guest: z.ZodBoolean;
7553
+ }, z.core.$strip>>;
7554
+ me: z.ZodObject<{
7555
+ joined: z.ZodBoolean;
7556
+ invited: z.ZodBoolean;
7557
+ following: z.ZodBoolean;
7558
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7559
+ isCreator: z.ZodBoolean;
7560
+ stillIn: z.ZodBoolean;
7561
+ nextMatch: z.ZodNullable<z.ZodObject<{
7562
+ id: z.ZodString;
7563
+ opponent: z.ZodNullable<z.ZodObject<{
7564
+ id: z.ZodNumber;
7565
+ username: z.ZodString;
7566
+ avatar: z.ZodString;
7567
+ guest: z.ZodBoolean;
7568
+ }, z.core.$strip>>;
7569
+ game: z.ZodString;
7570
+ gameTitle: z.ZodString;
7571
+ deadlineAt: z.ZodNumber;
7572
+ started: z.ZodBoolean;
7573
+ }, z.core.$strip>>;
7574
+ }, z.core.$strip>;
7575
+ }, z.core.$strip>>;
7576
+ }, z.core.$strip>;
7577
+ /** Everything playable online for the viewer. */
7578
+ export type PlayOnline = z.infer<typeof PlayOnline>;
7579
+ /** The play-online endpoint. Signed-out visitors get the open tournaments only. */
7580
+ export declare const playOnlineEndpoints: {
7581
+ getPlayOnline: import("@ayepi/core").Endpoint<{
7582
+ readonly method: "GET";
7583
+ readonly path: "/play-online";
7584
+ readonly response: z.ZodObject<{
7585
+ counts: z.ZodObject<{
7586
+ now: z.ZodNumber;
7587
+ invites: z.ZodNumber;
7588
+ mine: z.ZodNumber;
7589
+ upcoming: z.ZodNumber;
7590
+ }, z.core.$strip>;
7591
+ lobbies: z.ZodArray<z.ZodObject<{
7592
+ host: z.ZodObject<{
7593
+ id: z.ZodNumber;
7594
+ username: z.ZodString;
7595
+ avatar: z.ZodString;
7596
+ guest: z.ZodBoolean;
7597
+ }, z.core.$strip>;
7598
+ game: z.ZodString;
7599
+ gameTitle: z.ZodString;
7600
+ mode: z.ZodOptional<z.ZodString>;
7601
+ openSeats: z.ZodNumber;
7602
+ since: z.ZodNumber;
7603
+ }, z.core.$strip>>;
7604
+ gameInvites: z.ZodArray<z.ZodObject<{
7605
+ id: z.ZodString;
7606
+ from: z.ZodObject<{
7607
+ id: z.ZodNumber;
7608
+ username: z.ZodString;
7609
+ avatar: z.ZodString;
7610
+ guest: z.ZodBoolean;
7611
+ }, z.core.$strip>;
7612
+ to: z.ZodObject<{
7613
+ id: z.ZodNumber;
7614
+ username: z.ZodString;
7615
+ avatar: z.ZodString;
7616
+ guest: z.ZodBoolean;
7617
+ }, z.core.$strip>;
7618
+ game: z.ZodString;
7619
+ gameTitle: z.ZodString;
7620
+ mode: z.ZodOptional<z.ZodString>;
7621
+ partyId: z.ZodString;
7622
+ expiresAt: z.ZodNumber;
7623
+ }, z.core.$strip>>;
7624
+ tournamentInvites: z.ZodArray<z.ZodObject<{
7625
+ id: z.ZodNumber;
7626
+ title: z.ZodString;
7627
+ creator: z.ZodNullable<z.ZodObject<{
7628
+ id: z.ZodNumber;
7629
+ username: z.ZodString;
7630
+ avatar: z.ZodString;
7631
+ guest: z.ZodBoolean;
7632
+ }, z.core.$strip>>;
7633
+ visibility: z.ZodEnum<{
7634
+ open: "open";
7635
+ closed: "closed";
7636
+ }>;
7637
+ phase: z.ZodEnum<{
7638
+ done: "done";
7639
+ cancelled: "cancelled";
7640
+ signup: "signup";
7641
+ running: "running";
7642
+ }>;
7643
+ games: z.ZodArray<z.ZodString>;
7644
+ pick: z.ZodEnum<{
7645
+ fixed: "fixed";
7646
+ "random-once": "random-once";
7647
+ "random-each": "random-each";
7648
+ }>;
7649
+ game: z.ZodNullable<z.ZodString>;
7650
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7651
+ lives: z.ZodNumber;
7652
+ seeding: z.ZodEnum<{
7653
+ rank: "rank";
7654
+ random: "random";
7655
+ }>;
7656
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7657
+ kind: z.ZodLiteral<"scheduled">;
7658
+ at: z.ZodNumber;
7659
+ }, z.core.$strip>, z.ZodObject<{
7660
+ kind: z.ZodLiteral<"filled">;
7661
+ }, z.core.$strip>], "kind">;
7662
+ minPlayers: z.ZodNumber;
7663
+ maxPlayers: z.ZodNumber;
7664
+ readyMinutes: z.ZodNumber;
7665
+ entrants: z.ZodNumber;
7666
+ createdAt: z.ZodNumber;
7667
+ startedAt: z.ZodNullable<z.ZodNumber>;
7668
+ endedAt: z.ZodNullable<z.ZodNumber>;
7669
+ champion: z.ZodNullable<z.ZodObject<{
7670
+ id: z.ZodNumber;
7671
+ username: z.ZodString;
7672
+ avatar: z.ZodString;
7673
+ guest: z.ZodBoolean;
7674
+ }, z.core.$strip>>;
7675
+ me: z.ZodObject<{
7676
+ joined: z.ZodBoolean;
7677
+ invited: z.ZodBoolean;
7678
+ following: z.ZodBoolean;
7679
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7680
+ isCreator: z.ZodBoolean;
7681
+ stillIn: z.ZodBoolean;
7682
+ nextMatch: z.ZodNullable<z.ZodObject<{
7683
+ id: z.ZodString;
7684
+ opponent: z.ZodNullable<z.ZodObject<{
7685
+ id: z.ZodNumber;
7686
+ username: z.ZodString;
7687
+ avatar: z.ZodString;
7688
+ guest: z.ZodBoolean;
7689
+ }, z.core.$strip>>;
7690
+ game: z.ZodString;
7691
+ gameTitle: z.ZodString;
7692
+ deadlineAt: z.ZodNumber;
7693
+ started: z.ZodBoolean;
7694
+ }, z.core.$strip>>;
7695
+ }, z.core.$strip>;
7696
+ }, z.core.$strip>>;
7697
+ mine: z.ZodArray<z.ZodObject<{
7698
+ id: z.ZodNumber;
7699
+ title: z.ZodString;
7700
+ creator: z.ZodNullable<z.ZodObject<{
7701
+ id: z.ZodNumber;
7702
+ username: z.ZodString;
7703
+ avatar: z.ZodString;
7704
+ guest: z.ZodBoolean;
7705
+ }, z.core.$strip>>;
7706
+ visibility: z.ZodEnum<{
7707
+ open: "open";
7708
+ closed: "closed";
7709
+ }>;
7710
+ phase: z.ZodEnum<{
7711
+ done: "done";
7712
+ cancelled: "cancelled";
7713
+ signup: "signup";
7714
+ running: "running";
7715
+ }>;
7716
+ games: z.ZodArray<z.ZodString>;
7717
+ pick: z.ZodEnum<{
7718
+ fixed: "fixed";
7719
+ "random-once": "random-once";
7720
+ "random-each": "random-each";
7721
+ }>;
7722
+ game: z.ZodNullable<z.ZodString>;
7723
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7724
+ lives: z.ZodNumber;
7725
+ seeding: z.ZodEnum<{
7726
+ rank: "rank";
7727
+ random: "random";
7728
+ }>;
7729
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7730
+ kind: z.ZodLiteral<"scheduled">;
7731
+ at: z.ZodNumber;
7732
+ }, z.core.$strip>, z.ZodObject<{
7733
+ kind: z.ZodLiteral<"filled">;
7734
+ }, z.core.$strip>], "kind">;
7735
+ minPlayers: z.ZodNumber;
7736
+ maxPlayers: z.ZodNumber;
7737
+ readyMinutes: z.ZodNumber;
7738
+ entrants: z.ZodNumber;
7739
+ createdAt: z.ZodNumber;
7740
+ startedAt: z.ZodNullable<z.ZodNumber>;
7741
+ endedAt: z.ZodNullable<z.ZodNumber>;
7742
+ champion: z.ZodNullable<z.ZodObject<{
7743
+ id: z.ZodNumber;
7744
+ username: z.ZodString;
7745
+ avatar: z.ZodString;
7746
+ guest: z.ZodBoolean;
7747
+ }, z.core.$strip>>;
7748
+ me: z.ZodObject<{
7749
+ joined: z.ZodBoolean;
7750
+ invited: z.ZodBoolean;
7751
+ following: z.ZodBoolean;
7752
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7753
+ isCreator: z.ZodBoolean;
7754
+ stillIn: z.ZodBoolean;
7755
+ nextMatch: z.ZodNullable<z.ZodObject<{
7756
+ id: z.ZodString;
7757
+ opponent: z.ZodNullable<z.ZodObject<{
7758
+ id: z.ZodNumber;
7759
+ username: z.ZodString;
7760
+ avatar: z.ZodString;
7761
+ guest: z.ZodBoolean;
7762
+ }, z.core.$strip>>;
7763
+ game: z.ZodString;
7764
+ gameTitle: z.ZodString;
7765
+ deadlineAt: z.ZodNumber;
7766
+ started: z.ZodBoolean;
7767
+ }, z.core.$strip>>;
7768
+ }, z.core.$strip>;
7769
+ }, z.core.$strip>>;
7770
+ upcoming: z.ZodArray<z.ZodObject<{
7771
+ id: z.ZodNumber;
7772
+ title: z.ZodString;
7773
+ creator: z.ZodNullable<z.ZodObject<{
7774
+ id: z.ZodNumber;
7775
+ username: z.ZodString;
7776
+ avatar: z.ZodString;
7777
+ guest: z.ZodBoolean;
7778
+ }, z.core.$strip>>;
7779
+ visibility: z.ZodEnum<{
7780
+ open: "open";
7781
+ closed: "closed";
5467
7782
  }>;
5468
- chatLock: z.ZodBoolean;
5469
- mutedUntil: z.ZodNumber;
5470
- suspendedUntil: z.ZodNumber;
5471
- avatar: z.ZodString;
5472
- privacy: z.ZodEnum<{
5473
- friends: "friends";
5474
- nobody: "nobody";
7783
+ phase: z.ZodEnum<{
7784
+ done: "done";
7785
+ cancelled: "cancelled";
7786
+ signup: "signup";
7787
+ running: "running";
5475
7788
  }>;
5476
- dmPolicy: z.ZodEnum<{
5477
- friends: "friends";
5478
- nobody: "nobody";
7789
+ games: z.ZodArray<z.ZodString>;
7790
+ pick: z.ZodEnum<{
7791
+ fixed: "fixed";
7792
+ "random-once": "random-once";
7793
+ "random-each": "random-each";
5479
7794
  }>;
5480
- }, z.core.$strip>;
5481
- notify: z.ZodObject<{
5482
- dm: z.ZodBoolean;
5483
- friend_request: z.ZodBoolean;
5484
- friendOnlineAll: z.ZodBoolean;
5485
- friendOnline: z.ZodArray<z.ZodNumber>;
5486
- lobbyOpen: z.ZodArray<z.ZodString>;
5487
- }, z.core.$strip>;
5488
- pushSubs: z.ZodNumber;
5489
- }, z.core.$strip>;
5490
- readonly errors: {
5491
- readonly 401: ErrorBodySchema;
5492
- };
5493
- readonly doc: {
5494
- readonly summary: "Your social settings, notification preferences and push subscription count";
5495
- readonly tags: readonly ["social"];
5496
- };
5497
- }, {
5498
- user: SessionUser;
5499
- clientId: string;
5500
- }, {}, import("@ayepi/core").EmptyObject>;
5501
- getSocialConfig: import("@ayepi/core").Endpoint<{
5502
- readonly method: "GET";
5503
- readonly path: "/social/config";
5504
- readonly response: z.ZodObject<{
5505
- chatMode: z.ZodEnum<{
5506
- on: "on";
5507
- quick: "quick";
5508
- off: "off";
5509
- }>;
5510
- ai: z.ZodBoolean;
5511
- contactUrl: z.ZodString;
5512
- parentsUrl: z.ZodString;
5513
- vapidPublicKey: z.ZodString;
5514
- quickChat: z.ZodRecord<z.ZodString, z.ZodString>;
5515
- emotes: z.ZodArray<z.ZodString>;
5516
- limits: z.ZodObject<{
5517
- dmMaxChars: z.ZodNumber;
5518
- roomChatMaxChars: z.ZodNumber;
5519
- suggestionTitleMax: z.ZodNumber;
5520
- suggestionBodyMax: z.ZodNumber;
5521
- }, z.core.$strip>;
5522
- avatars: z.ZodArray<z.ZodString>;
5523
- test: z.ZodOptional<z.ZodLiteral<true>>;
5524
- }, z.core.$strip>;
5525
- readonly doc: {
5526
- readonly summary: "The site-wide social configuration";
5527
- readonly tags: readonly ["social"];
5528
- };
5529
- }, {
5530
- user: SessionUser | null;
5531
- clientId: string;
5532
- }, {}, import("@ayepi/core").EmptyObject>;
5533
- getOnlineCounts: import("@ayepi/core").Endpoint<{
5534
- readonly method: "GET";
5535
- readonly path: "/social/counts";
5536
- readonly response: z.ZodObject<{
5537
- online: z.ZodNumber;
5538
- byGame: z.ZodRecord<z.ZodString, z.ZodNumber>;
7795
+ game: z.ZodNullable<z.ZodString>;
7796
+ gameTitles: z.ZodRecord<z.ZodString, z.ZodString>;
7797
+ lives: z.ZodNumber;
7798
+ seeding: z.ZodEnum<{
7799
+ rank: "rank";
7800
+ random: "random";
7801
+ }>;
7802
+ start: z.ZodDiscriminatedUnion<[z.ZodObject<{
7803
+ kind: z.ZodLiteral<"scheduled">;
7804
+ at: z.ZodNumber;
7805
+ }, z.core.$strip>, z.ZodObject<{
7806
+ kind: z.ZodLiteral<"filled">;
7807
+ }, z.core.$strip>], "kind">;
7808
+ minPlayers: z.ZodNumber;
7809
+ maxPlayers: z.ZodNumber;
7810
+ readyMinutes: z.ZodNumber;
7811
+ entrants: z.ZodNumber;
7812
+ createdAt: z.ZodNumber;
7813
+ startedAt: z.ZodNullable<z.ZodNumber>;
7814
+ endedAt: z.ZodNullable<z.ZodNumber>;
7815
+ champion: z.ZodNullable<z.ZodObject<{
7816
+ id: z.ZodNumber;
7817
+ username: z.ZodString;
7818
+ avatar: z.ZodString;
7819
+ guest: z.ZodBoolean;
7820
+ }, z.core.$strip>>;
7821
+ me: z.ZodObject<{
7822
+ joined: z.ZodBoolean;
7823
+ invited: z.ZodBoolean;
7824
+ following: z.ZodBoolean;
7825
+ leadMinutes: z.ZodNullable<z.ZodNumber>;
7826
+ isCreator: z.ZodBoolean;
7827
+ stillIn: z.ZodBoolean;
7828
+ nextMatch: z.ZodNullable<z.ZodObject<{
7829
+ id: z.ZodString;
7830
+ opponent: z.ZodNullable<z.ZodObject<{
7831
+ id: z.ZodNumber;
7832
+ username: z.ZodString;
7833
+ avatar: z.ZodString;
7834
+ guest: z.ZodBoolean;
7835
+ }, z.core.$strip>>;
7836
+ game: z.ZodString;
7837
+ gameTitle: z.ZodString;
7838
+ deadlineAt: z.ZodNumber;
7839
+ started: z.ZodBoolean;
7840
+ }, z.core.$strip>>;
7841
+ }, z.core.$strip>;
7842
+ }, z.core.$strip>>;
5539
7843
  }, z.core.$strip>;
5540
- readonly errors: {
5541
- readonly 403: ErrorBodySchema;
5542
- };
5543
7844
  readonly doc: {
5544
- readonly summary: "Anonymous online counts, overall and per game";
5545
- readonly tags: readonly ["social"];
7845
+ readonly summary: "Lobbies to join now, invites, my tournaments and upcoming open ones (the home page card and modal)";
7846
+ readonly tags: readonly ["tournaments"];
5546
7847
  };
5547
7848
  }, {
5548
7849
  user: SessionUser | null;
@@ -5586,12 +7887,38 @@ export declare const versionEndpoints: {
5586
7887
  }, {}, import("@ayepi/core").EmptyObject>;
5587
7888
  };
5588
7889
  //#endregion
7890
+ //#region src/api/offline.d.ts
7891
+ /** The request header that carries a replayable call's operation key. */
7892
+ export declare const OFFLINE_OP_HEADER = "x-hub-op";
7893
+ /** An operation key: letters, digits and `_ . : -`, 1 to 100 characters. */
7894
+ export declare const OfflineOpKey: z.ZodString;
7895
+ /** How long the hub remembers an operation key's reply: 7 days. */
7896
+ export declare const OFFLINE_DEDUPE_TTL_MS: number;
7897
+ /** How an endpoint behaves offline: `replay` means it may be queued and sent later, deduplicated by its operation key. */
7898
+ export type OfflineMode = 'replay';
7899
+ /** The public endpoints that support offline replay, by name. */
7900
+ export declare const OFFLINE_REPLAY_ENDPOINTS: {
7901
+ readonly writeSave: "replay";
7902
+ readonly deleteSave: "replay";
7903
+ readonly updateGameStat: "replay";
7904
+ readonly setGameProfile: "replay";
7905
+ readonly submitScore: "replay";
7906
+ readonly completeDailyChallenge: "replay";
7907
+ readonly grantInventoryItems: "replay";
7908
+ readonly exchangeInventoryItems: "replay";
7909
+ readonly setGameFavorite: "replay";
7910
+ };
7911
+ /** The name of an endpoint that supports offline replay. */
7912
+ export type OfflineReplayEndpoint = keyof typeof OFFLINE_REPLAY_ENDPOINTS;
7913
+ /** Whether endpoint `name` supports offline replay. */
7914
+ export declare function isOfflineReplayEndpoint(name: string): name is OfflineReplayEndpoint;
7915
+ //#endregion
5589
7916
  //#region src/api/index.d.ts
5590
7917
  /**
5591
7918
  * Every public endpoint, by name. Typed as an intersection of the areas so the
5592
7919
  * published .d.ts refers to each area instead of repeating every endpoint.
5593
7920
  */
5594
- export type PublicEndpoints = typeof authEndpoints & typeof catalogEndpoints & typeof progressEndpoints & typeof leaderboardsEndpoints & typeof dailyEndpoints & typeof economyEndpoints & typeof analyticsEndpoints & typeof socialEndpoints & typeof messagesEndpoints & typeof notifyEndpoints & typeof reportsEndpoints & typeof mpEndpoints & typeof raceEndpoints & typeof versionEndpoints;
7921
+ export type PublicEndpoints = typeof authEndpoints & typeof catalogEndpoints & typeof progressEndpoints & typeof leaderboardsEndpoints & typeof dailyEndpoints & typeof economyEndpoints & typeof analyticsEndpoints & typeof socialEndpoints & typeof messagesEndpoints & typeof notifyEndpoints & typeof reportsEndpoints & typeof mpEndpoints & typeof raceEndpoints & typeof tournamentEndpoints & typeof playOnlineEndpoints & typeof versionEndpoints;
5595
7922
  /** Every public endpoint, by name. */
5596
7923
  export declare const publicEndpoints: PublicEndpoints;
5597
7924
  /**
@@ -5647,6 +7974,81 @@ export type EventData<E extends EventDef> = z.output<E['d']>;
5647
7974
  //#region src/realtime/events/multiplayer.d.ts
5648
7975
  /** The multiplayer events, by event name. */
5649
7976
  declare const multiplayerEvents: {
7977
+ tournament: EventDef<import("zod").ZodObject<{
7978
+ tournament: import("zod").ZodObject<{
7979
+ id: import("zod").ZodNumber;
7980
+ title: import("zod").ZodString;
7981
+ creator: import("zod").ZodNullable<import("zod").ZodObject<{
7982
+ id: import("zod").ZodNumber;
7983
+ username: import("zod").ZodString;
7984
+ avatar: import("zod").ZodString;
7985
+ guest: import("zod").ZodBoolean;
7986
+ }, import("zod/v4/core").$strip>>;
7987
+ visibility: import("zod").ZodEnum<{
7988
+ open: "open";
7989
+ closed: "closed";
7990
+ }>;
7991
+ phase: import("zod").ZodEnum<{
7992
+ done: "done";
7993
+ cancelled: "cancelled";
7994
+ signup: "signup";
7995
+ running: "running";
7996
+ }>;
7997
+ games: import("zod").ZodArray<import("zod").ZodString>;
7998
+ pick: import("zod").ZodEnum<{
7999
+ fixed: "fixed";
8000
+ "random-once": "random-once";
8001
+ "random-each": "random-each";
8002
+ }>;
8003
+ game: import("zod").ZodNullable<import("zod").ZodString>;
8004
+ gameTitles: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
8005
+ lives: import("zod").ZodNumber;
8006
+ seeding: import("zod").ZodEnum<{
8007
+ rank: "rank";
8008
+ random: "random";
8009
+ }>;
8010
+ start: import("zod").ZodDiscriminatedUnion<[import("zod").ZodObject<{
8011
+ kind: import("zod").ZodLiteral<"scheduled">;
8012
+ at: import("zod").ZodNumber;
8013
+ }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
8014
+ kind: import("zod").ZodLiteral<"filled">;
8015
+ }, import("zod/v4/core").$strip>], "kind">;
8016
+ minPlayers: import("zod").ZodNumber;
8017
+ maxPlayers: import("zod").ZodNumber;
8018
+ readyMinutes: import("zod").ZodNumber;
8019
+ entrants: import("zod").ZodNumber;
8020
+ createdAt: import("zod").ZodNumber;
8021
+ startedAt: import("zod").ZodNullable<import("zod").ZodNumber>;
8022
+ endedAt: import("zod").ZodNullable<import("zod").ZodNumber>;
8023
+ champion: import("zod").ZodNullable<import("zod").ZodObject<{
8024
+ id: import("zod").ZodNumber;
8025
+ username: import("zod").ZodString;
8026
+ avatar: import("zod").ZodString;
8027
+ guest: import("zod").ZodBoolean;
8028
+ }, import("zod/v4/core").$strip>>;
8029
+ me: import("zod").ZodObject<{
8030
+ joined: import("zod").ZodBoolean;
8031
+ invited: import("zod").ZodBoolean;
8032
+ following: import("zod").ZodBoolean;
8033
+ leadMinutes: import("zod").ZodNullable<import("zod").ZodNumber>;
8034
+ isCreator: import("zod").ZodBoolean;
8035
+ stillIn: import("zod").ZodBoolean;
8036
+ nextMatch: import("zod").ZodNullable<import("zod").ZodObject<{
8037
+ id: import("zod").ZodString;
8038
+ opponent: import("zod").ZodNullable<import("zod").ZodObject<{
8039
+ id: import("zod").ZodNumber;
8040
+ username: import("zod").ZodString;
8041
+ avatar: import("zod").ZodString;
8042
+ guest: import("zod").ZodBoolean;
8043
+ }, import("zod/v4/core").$strip>>;
8044
+ game: import("zod").ZodString;
8045
+ gameTitle: import("zod").ZodString;
8046
+ deadlineAt: import("zod").ZodNumber;
8047
+ started: import("zod").ZodBoolean;
8048
+ }, import("zod/v4/core").$strip>>;
8049
+ }, import("zod/v4/core").$strip>;
8050
+ }, import("zod/v4/core").$strip>;
8051
+ }, import("zod/v4/core").$strip>>;
5650
8052
  'race.start': EventDef<import("zod").ZodObject<{
5651
8053
  roomId: import("zod").ZodString;
5652
8054
  round: import("zod").ZodNumber;
@@ -5724,6 +8126,7 @@ declare const multiplayerEvents: {
5724
8126
  avatar: import("zod").ZodString;
5725
8127
  ready: import("zod").ZodBoolean;
5726
8128
  connected: import("zod").ZodBoolean;
8129
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
5727
8130
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
5728
8131
  }, import("zod/v4/core").$strip>>;
5729
8132
  spectators: import("zod").ZodNumber;
@@ -5734,10 +8137,10 @@ declare const multiplayerEvents: {
5734
8137
  }>;
5735
8138
  race: import("zod").ZodOptional<import("zod").ZodObject<{
5736
8139
  phase: import("zod").ZodEnum<{
5737
- done: "done";
5738
8140
  waiting: "waiting";
5739
8141
  countdown: "countdown";
5740
8142
  racing: "racing";
8143
+ done: "done";
5741
8144
  }>;
5742
8145
  round: import("zod").ZodNumber;
5743
8146
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -5749,11 +8152,11 @@ declare const multiplayerEvents: {
5749
8152
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
5750
8153
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
5751
8154
  state: import("zod").ZodEnum<{
8155
+ racing: "racing";
5752
8156
  finished: "finished";
5753
8157
  lost: "lost";
5754
8158
  forfeit: "forfeit";
5755
8159
  disconnected: "disconnected";
5756
- racing: "racing";
5757
8160
  }>;
5758
8161
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
5759
8162
  }, import("zod/v4/core").$strip>>;
@@ -5838,6 +8241,20 @@ declare const multiplayerEvents: {
5838
8241
  kicked: "kicked";
5839
8242
  }>;
5840
8243
  }, import("zod/v4/core").$strip>>;
8244
+ 'room.seat': EventDef<import("zod").ZodObject<{
8245
+ userId: import("zod").ZodNumber;
8246
+ status: import("zod").ZodEnum<{
8247
+ away: "away";
8248
+ back: "back";
8249
+ gone: "gone";
8250
+ }>;
8251
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
8252
+ reason: import("zod").ZodOptional<import("zod").ZodEnum<{
8253
+ left: "left";
8254
+ abandoned: "abandoned";
8255
+ kicked: "kicked";
8256
+ }>>;
8257
+ }, import("zod/v4/core").$strip>>;
5841
8258
  invite: EventDef<import("zod").ZodObject<{
5842
8259
  id: import("zod").ZodString;
5843
8260
  from: import("zod").ZodObject<{
@@ -5928,11 +8345,11 @@ declare const socialEvents: {
5928
8345
  friends: EventDef<z.ZodObject<{
5929
8346
  change: z.ZodEnum<{
5930
8347
  blocked: "blocked";
8348
+ request: "request";
5931
8349
  accepted: "accepted";
8350
+ removed: "removed";
5932
8351
  declined: "declined";
5933
8352
  cancelled: "cancelled";
5934
- removed: "removed";
5935
- request: "request";
5936
8353
  restored: "restored";
5937
8354
  }>;
5938
8355
  user: z.ZodObject<{
@@ -5992,9 +8409,10 @@ declare const socialEvents: {
5992
8409
  friend_request: "friend_request";
5993
8410
  friend_online: "friend_online";
5994
8411
  lobby_open: "lobby_open";
5995
- suggestion: "suggestion";
5996
8412
  invite: "invite";
8413
+ suggestion: "suggestion";
5997
8414
  renamed: "renamed";
8415
+ tournament: "tournament";
5998
8416
  }>;
5999
8417
  title: z.ZodString;
6000
8418
  body: z.ZodOptional<z.ZodString>;
@@ -6075,6 +8493,7 @@ declare const helloOps: {
6075
8493
  avatar: z.ZodString;
6076
8494
  ready: z.ZodBoolean;
6077
8495
  connected: z.ZodBoolean;
8496
+ graceEndsAt: z.ZodOptional<z.ZodNumber>;
6078
8497
  data: z.ZodOptional<z.ZodJSONSchema>;
6079
8498
  }, z.core.$strip>>;
6080
8499
  spectators: z.ZodNumber;
@@ -6085,10 +8504,10 @@ declare const helloOps: {
6085
8504
  }>;
6086
8505
  race: z.ZodOptional<z.ZodObject<{
6087
8506
  phase: z.ZodEnum<{
6088
- done: "done";
6089
8507
  waiting: "waiting";
6090
8508
  countdown: "countdown";
6091
8509
  racing: "racing";
8510
+ done: "done";
6092
8511
  }>;
6093
8512
  round: z.ZodNumber;
6094
8513
  params: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodBoolean, z.ZodString]>>;
@@ -6100,11 +8519,11 @@ declare const helloOps: {
6100
8519
  stats: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>, z.ZodBoolean, z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>]>>;
6101
8520
  progress: z.ZodOptional<z.ZodPipe<z.ZodNumber, z.ZodTransform<number, number>>>;
6102
8521
  state: z.ZodEnum<{
8522
+ racing: "racing";
6103
8523
  finished: "finished";
6104
8524
  lost: "lost";
6105
8525
  forfeit: "forfeit";
6106
8526
  disconnected: "disconnected";
6107
- racing: "racing";
6108
8527
  }>;
6109
8528
  ms: z.ZodOptional<z.ZodNumber>;
6110
8529
  }, z.core.$strip>>;
@@ -6278,6 +8697,7 @@ declare const multiplayerOps: {
6278
8697
  avatar: import("zod").ZodString;
6279
8698
  ready: import("zod").ZodBoolean;
6280
8699
  connected: import("zod").ZodBoolean;
8700
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
6281
8701
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
6282
8702
  }, import("zod/v4/core").$strip>>;
6283
8703
  spectators: import("zod").ZodNumber;
@@ -6288,10 +8708,10 @@ declare const multiplayerOps: {
6288
8708
  }>;
6289
8709
  race: import("zod").ZodOptional<import("zod").ZodObject<{
6290
8710
  phase: import("zod").ZodEnum<{
6291
- done: "done";
6292
8711
  waiting: "waiting";
6293
8712
  countdown: "countdown";
6294
8713
  racing: "racing";
8714
+ done: "done";
6295
8715
  }>;
6296
8716
  round: import("zod").ZodNumber;
6297
8717
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -6303,11 +8723,11 @@ declare const multiplayerOps: {
6303
8723
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
6304
8724
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
6305
8725
  state: import("zod").ZodEnum<{
8726
+ racing: "racing";
6306
8727
  finished: "finished";
6307
8728
  lost: "lost";
6308
8729
  forfeit: "forfeit";
6309
8730
  disconnected: "disconnected";
6310
- racing: "racing";
6311
8731
  }>;
6312
8732
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
6313
8733
  }, import("zod/v4/core").$strip>>;
@@ -6381,6 +8801,7 @@ declare const multiplayerOps: {
6381
8801
  avatar: import("zod").ZodString;
6382
8802
  ready: import("zod").ZodBoolean;
6383
8803
  connected: import("zod").ZodBoolean;
8804
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
6384
8805
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
6385
8806
  }, import("zod/v4/core").$strip>>;
6386
8807
  spectators: import("zod").ZodNumber;
@@ -6391,10 +8812,10 @@ declare const multiplayerOps: {
6391
8812
  }>;
6392
8813
  race: import("zod").ZodOptional<import("zod").ZodObject<{
6393
8814
  phase: import("zod").ZodEnum<{
6394
- done: "done";
6395
8815
  waiting: "waiting";
6396
8816
  countdown: "countdown";
6397
8817
  racing: "racing";
8818
+ done: "done";
6398
8819
  }>;
6399
8820
  round: import("zod").ZodNumber;
6400
8821
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -6406,11 +8827,11 @@ declare const multiplayerOps: {
6406
8827
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
6407
8828
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
6408
8829
  state: import("zod").ZodEnum<{
8830
+ racing: "racing";
6409
8831
  finished: "finished";
6410
8832
  lost: "lost";
6411
8833
  forfeit: "forfeit";
6412
8834
  disconnected: "disconnected";
6413
- racing: "racing";
6414
8835
  }>;
6415
8836
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
6416
8837
  }, import("zod/v4/core").$strip>>;
@@ -6482,6 +8903,7 @@ declare const multiplayerOps: {
6482
8903
  avatar: import("zod").ZodString;
6483
8904
  ready: import("zod").ZodBoolean;
6484
8905
  connected: import("zod").ZodBoolean;
8906
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
6485
8907
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
6486
8908
  }, import("zod/v4/core").$strip>>;
6487
8909
  spectators: import("zod").ZodNumber;
@@ -6492,10 +8914,10 @@ declare const multiplayerOps: {
6492
8914
  }>;
6493
8915
  race: import("zod").ZodOptional<import("zod").ZodObject<{
6494
8916
  phase: import("zod").ZodEnum<{
6495
- done: "done";
6496
8917
  waiting: "waiting";
6497
8918
  countdown: "countdown";
6498
8919
  racing: "racing";
8920
+ done: "done";
6499
8921
  }>;
6500
8922
  round: import("zod").ZodNumber;
6501
8923
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -6507,11 +8929,11 @@ declare const multiplayerOps: {
6507
8929
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
6508
8930
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
6509
8931
  state: import("zod").ZodEnum<{
8932
+ racing: "racing";
6510
8933
  finished: "finished";
6511
8934
  lost: "lost";
6512
8935
  forfeit: "forfeit";
6513
8936
  disconnected: "disconnected";
6514
- racing: "racing";
6515
8937
  }>;
6516
8938
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
6517
8939
  }, import("zod/v4/core").$strip>>;
@@ -6620,6 +9042,10 @@ declare const multiplayerOps: {
6620
9042
  host: "host";
6621
9043
  relay: "relay";
6622
9044
  }>>;
9045
+ hostMigration: import("zod").ZodOptional<import("zod").ZodEnum<{
9046
+ grace: "grace";
9047
+ drop: "drop";
9048
+ }>>;
6623
9049
  partyId: import("zod").ZodOptional<import("zod").ZodString>;
6624
9050
  }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
6625
9051
  room: import("zod").ZodObject<{
@@ -6645,6 +9071,7 @@ declare const multiplayerOps: {
6645
9071
  avatar: import("zod").ZodString;
6646
9072
  ready: import("zod").ZodBoolean;
6647
9073
  connected: import("zod").ZodBoolean;
9074
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
6648
9075
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
6649
9076
  }, import("zod/v4/core").$strip>>;
6650
9077
  spectators: import("zod").ZodNumber;
@@ -6655,10 +9082,10 @@ declare const multiplayerOps: {
6655
9082
  }>;
6656
9083
  race: import("zod").ZodOptional<import("zod").ZodObject<{
6657
9084
  phase: import("zod").ZodEnum<{
6658
- done: "done";
6659
9085
  waiting: "waiting";
6660
9086
  countdown: "countdown";
6661
9087
  racing: "racing";
9088
+ done: "done";
6662
9089
  }>;
6663
9090
  round: import("zod").ZodNumber;
6664
9091
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -6670,11 +9097,11 @@ declare const multiplayerOps: {
6670
9097
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
6671
9098
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
6672
9099
  state: import("zod").ZodEnum<{
9100
+ racing: "racing";
6673
9101
  finished: "finished";
6674
9102
  lost: "lost";
6675
9103
  forfeit: "forfeit";
6676
9104
  disconnected: "disconnected";
6677
- racing: "racing";
6678
9105
  }>;
6679
9106
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
6680
9107
  }, import("zod/v4/core").$strip>>;
@@ -6749,6 +9176,7 @@ declare const multiplayerOps: {
6749
9176
  avatar: import("zod").ZodString;
6750
9177
  ready: import("zod").ZodBoolean;
6751
9178
  connected: import("zod").ZodBoolean;
9179
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
6752
9180
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
6753
9181
  }, import("zod/v4/core").$strip>>;
6754
9182
  spectators: import("zod").ZodNumber;
@@ -6759,10 +9187,10 @@ declare const multiplayerOps: {
6759
9187
  }>;
6760
9188
  race: import("zod").ZodOptional<import("zod").ZodObject<{
6761
9189
  phase: import("zod").ZodEnum<{
6762
- done: "done";
6763
9190
  waiting: "waiting";
6764
9191
  countdown: "countdown";
6765
9192
  racing: "racing";
9193
+ done: "done";
6766
9194
  }>;
6767
9195
  round: import("zod").ZodNumber;
6768
9196
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -6774,11 +9202,11 @@ declare const multiplayerOps: {
6774
9202
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
6775
9203
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
6776
9204
  state: import("zod").ZodEnum<{
9205
+ racing: "racing";
6777
9206
  finished: "finished";
6778
9207
  lost: "lost";
6779
9208
  forfeit: "forfeit";
6780
9209
  disconnected: "disconnected";
6781
- racing: "racing";
6782
9210
  }>;
6783
9211
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
6784
9212
  }, import("zod/v4/core").$strip>>;
@@ -6831,6 +9259,117 @@ declare const multiplayerOps: {
6831
9259
  to: import("zod").ZodOptional<import("zod").ZodNumber>;
6832
9260
  }, import("zod/v4/core").$strip>>;
6833
9261
  }, import("zod/v4/core").$strip>>;
9262
+ 'room.reclaim': OpDef<import("zod").ZodObject<{
9263
+ game: import("zod").ZodString;
9264
+ }, import("zod/v4/core").$strip>, import("zod").ZodObject<{
9265
+ held: import("zod").ZodNullable<import("zod").ZodObject<{
9266
+ room: import("zod").ZodObject<{
9267
+ id: import("zod").ZodString;
9268
+ code: import("zod").ZodString;
9269
+ game: import("zod").ZodString;
9270
+ mode: import("zod").ZodOptional<import("zod").ZodString>;
9271
+ hostId: import("zod").ZodNumber;
9272
+ public: import("zod").ZodBoolean;
9273
+ phase: import("zod").ZodEnum<{
9274
+ ended: "ended";
9275
+ lobby: "lobby";
9276
+ playing: "playing";
9277
+ }>;
9278
+ maxPlayers: import("zod").ZodNumber;
9279
+ model: import("zod").ZodEnum<{
9280
+ host: "host";
9281
+ relay: "relay";
9282
+ }>;
9283
+ seats: import("zod").ZodArray<import("zod").ZodObject<{
9284
+ userId: import("zod").ZodNumber;
9285
+ name: import("zod").ZodString;
9286
+ avatar: import("zod").ZodString;
9287
+ ready: import("zod").ZodBoolean;
9288
+ connected: import("zod").ZodBoolean;
9289
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
9290
+ data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
9291
+ }, import("zod/v4/core").$strip>>;
9292
+ spectators: import("zod").ZodNumber;
9293
+ chatMode: import("zod").ZodEnum<{
9294
+ on: "on";
9295
+ quick: "quick";
9296
+ off: "off";
9297
+ }>;
9298
+ race: import("zod").ZodOptional<import("zod").ZodObject<{
9299
+ phase: import("zod").ZodEnum<{
9300
+ waiting: "waiting";
9301
+ countdown: "countdown";
9302
+ racing: "racing";
9303
+ done: "done";
9304
+ }>;
9305
+ round: import("zod").ZodNumber;
9306
+ params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
9307
+ minPlayers: import("zod").ZodNumber;
9308
+ players: import("zod").ZodArray<import("zod").ZodObject<{
9309
+ userId: import("zod").ZodNumber;
9310
+ name: import("zod").ZodString;
9311
+ avatar: import("zod").ZodString;
9312
+ stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
9313
+ progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
9314
+ state: import("zod").ZodEnum<{
9315
+ racing: "racing";
9316
+ finished: "finished";
9317
+ lost: "lost";
9318
+ forfeit: "forfeit";
9319
+ disconnected: "disconnected";
9320
+ }>;
9321
+ ms: import("zod").ZodOptional<import("zod").ZodNumber>;
9322
+ }, import("zod/v4/core").$strip>>;
9323
+ rematch: import("zod").ZodArray<import("zod").ZodNumber>;
9324
+ seed: import("zod").ZodOptional<import("zod").ZodNumber>;
9325
+ startAt: import("zod").ZodOptional<import("zod").ZodNumber>;
9326
+ result: import("zod").ZodOptional<import("zod").ZodObject<{
9327
+ game: import("zod").ZodString;
9328
+ params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
9329
+ outcome: import("zod").ZodEnum<{
9330
+ finished: "finished";
9331
+ lost: "lost";
9332
+ forfeit: "forfeit";
9333
+ disconnected: "disconnected";
9334
+ timeout: "timeout";
9335
+ }>;
9336
+ startedAt: import("zod").ZodNumber;
9337
+ endedAt: import("zod").ZodNumber;
9338
+ durationMs: import("zod").ZodNumber;
9339
+ id: import("zod").ZodNullable<import("zod").ZodNumber>;
9340
+ room: import("zod").ZodString;
9341
+ round: import("zod").ZodNumber;
9342
+ seed: import("zod").ZodNumber;
9343
+ winnerId: import("zod").ZodNullable<import("zod").ZodNumber>;
9344
+ players: import("zod").ZodArray<import("zod").ZodObject<{
9345
+ userId: import("zod").ZodNumber;
9346
+ name: import("zod").ZodString;
9347
+ avatar: import("zod").ZodString;
9348
+ stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
9349
+ progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
9350
+ place: import("zod").ZodNumber;
9351
+ result: import("zod").ZodEnum<{
9352
+ lost: "lost";
9353
+ forfeit: "forfeit";
9354
+ disconnected: "disconnected";
9355
+ timeout: "timeout";
9356
+ won: "won";
9357
+ beaten: "beaten";
9358
+ }>;
9359
+ ms: import("zod").ZodNumber;
9360
+ }, import("zod/v4/core").$strip>>;
9361
+ }, import("zod/v4/core").$strip>>;
9362
+ }, import("zod/v4/core").$strip>>;
9363
+ }, import("zod/v4/core").$strip>;
9364
+ state: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodJSONSchema>;
9365
+ history: import("zod").ZodArray<import("zod").ZodObject<{
9366
+ from: import("zod").ZodNumber;
9367
+ data: import("zod").ZodJSONSchema;
9368
+ seq: import("zod").ZodNumber;
9369
+ to: import("zod").ZodOptional<import("zod").ZodNumber>;
9370
+ }, import("zod/v4/core").$strip>>;
9371
+ }, import("zod/v4/core").$strip>>;
9372
+ }, import("zod/v4/core").$strip>>;
6834
9373
  'room.leave': OpDef<import("zod").ZodObject<{}, import("zod/v4/core").$strip>, import("zod").ZodObject<{}, import("zod/v4/core").$strip>>;
6835
9374
  'room.ready': OpDef<import("zod").ZodObject<{
6836
9375
  ready: import("zod").ZodBoolean;
@@ -6892,6 +9431,7 @@ declare const multiplayerOps: {
6892
9431
  avatar: import("zod").ZodString;
6893
9432
  ready: import("zod").ZodBoolean;
6894
9433
  connected: import("zod").ZodBoolean;
9434
+ graceEndsAt: import("zod").ZodOptional<import("zod").ZodNumber>;
6895
9435
  data: import("zod").ZodOptional<import("zod").ZodJSONSchema>;
6896
9436
  }, import("zod/v4/core").$strip>>;
6897
9437
  spectators: import("zod").ZodNumber;
@@ -6902,10 +9442,10 @@ declare const multiplayerOps: {
6902
9442
  }>;
6903
9443
  race: import("zod").ZodOptional<import("zod").ZodObject<{
6904
9444
  phase: import("zod").ZodEnum<{
6905
- done: "done";
6906
9445
  waiting: "waiting";
6907
9446
  countdown: "countdown";
6908
9447
  racing: "racing";
9448
+ done: "done";
6909
9449
  }>;
6910
9450
  round: import("zod").ZodNumber;
6911
9451
  params: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodNumber, import("zod").ZodBoolean, import("zod").ZodString]>>;
@@ -6917,11 +9457,11 @@ declare const multiplayerOps: {
6917
9457
  stats: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodUnion<readonly [import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>, import("zod").ZodBoolean, import("zod").ZodPipe<import("zod").ZodString, import("zod").ZodTransform<string, string>>]>>;
6918
9458
  progress: import("zod").ZodOptional<import("zod").ZodPipe<import("zod").ZodNumber, import("zod").ZodTransform<number, number>>>;
6919
9459
  state: import("zod").ZodEnum<{
9460
+ racing: "racing";
6920
9461
  finished: "finished";
6921
9462
  lost: "lost";
6922
9463
  forfeit: "forfeit";
6923
9464
  disconnected: "disconnected";
6924
- racing: "racing";
6925
9465
  }>;
6926
9466
  ms: import("zod").ZodOptional<import("zod").ZodNumber>;
6927
9467
  }, import("zod/v4/core").$strip>>;
@@ -7216,6 +9756,7 @@ export declare const StaticGame: z.ZodObject<{
7216
9756
  x: z.ZodOptional<z.ZodNumber>;
7217
9757
  y: z.ZodOptional<z.ZodNumber>;
7218
9758
  }, z.core.$strict>]>>;
9759
+ labels: z.ZodOptional<z.ZodArray<z.ZodString>>;
7219
9760
  dailyChallenges: z.ZodOptional<z.ZodBoolean>;
7220
9761
  leaderboards: z.ZodOptional<z.ZodArray<z.ZodObject<{
7221
9762
  key: z.ZodString;
@@ -7226,8 +9767,8 @@ export declare const StaticGame: z.ZodObject<{
7226
9767
  }>>;
7227
9768
  showZeros: z.ZodOptional<z.ZodBoolean>;
7228
9769
  source: z.ZodDefault<z.ZodEnum<{
7229
- server: "server";
7230
9770
  client: "client";
9771
+ server: "server";
7231
9772
  }>>;
7232
9773
  }, z.core.$strict>>>;
7233
9774
  controls: z.ZodOptional<z.ZodObject<{
@@ -7304,6 +9845,7 @@ export declare const StaticGame: z.ZodObject<{
7304
9845
  join: z.ZodDefault<z.ZodBoolean>;
7305
9846
  spectate: z.ZodDefault<z.ZodBoolean>;
7306
9847
  quickMatch: z.ZodDefault<z.ZodBoolean>;
9848
+ tournaments: z.ZodDefault<z.ZodBoolean>;
7307
9849
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
7308
9850
  key: z.ZodString;
7309
9851
  title: z.ZodOptional<z.ZodString>;
@@ -7319,6 +9861,7 @@ export declare const StaticGame: z.ZodObject<{
7319
9861
  join?: boolean | undefined;
7320
9862
  spectate?: boolean | undefined;
7321
9863
  quickMatch?: boolean | undefined;
9864
+ tournaments?: boolean | undefined;
7322
9865
  modes?: {
7323
9866
  key: string;
7324
9867
  title?: string | undefined;
@@ -7348,6 +9891,7 @@ export declare const ProcessGame: z.ZodObject<{
7348
9891
  x: z.ZodOptional<z.ZodNumber>;
7349
9892
  y: z.ZodOptional<z.ZodNumber>;
7350
9893
  }, z.core.$strict>]>>;
9894
+ labels: z.ZodOptional<z.ZodArray<z.ZodString>>;
7351
9895
  dailyChallenges: z.ZodOptional<z.ZodBoolean>;
7352
9896
  leaderboards: z.ZodOptional<z.ZodArray<z.ZodObject<{
7353
9897
  key: z.ZodString;
@@ -7358,8 +9902,8 @@ export declare const ProcessGame: z.ZodObject<{
7358
9902
  }>>;
7359
9903
  showZeros: z.ZodOptional<z.ZodBoolean>;
7360
9904
  source: z.ZodDefault<z.ZodEnum<{
7361
- server: "server";
7362
9905
  client: "client";
9906
+ server: "server";
7363
9907
  }>>;
7364
9908
  }, z.core.$strict>>>;
7365
9909
  controls: z.ZodOptional<z.ZodObject<{
@@ -7437,6 +9981,7 @@ export declare const ProcessGame: z.ZodObject<{
7437
9981
  join: z.ZodDefault<z.ZodBoolean>;
7438
9982
  spectate: z.ZodDefault<z.ZodBoolean>;
7439
9983
  quickMatch: z.ZodDefault<z.ZodBoolean>;
9984
+ tournaments: z.ZodDefault<z.ZodBoolean>;
7440
9985
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
7441
9986
  key: z.ZodString;
7442
9987
  title: z.ZodOptional<z.ZodString>;
@@ -7452,6 +9997,7 @@ export declare const ProcessGame: z.ZodObject<{
7452
9997
  join?: boolean | undefined;
7453
9998
  spectate?: boolean | undefined;
7454
9999
  quickMatch?: boolean | undefined;
10000
+ tournaments?: boolean | undefined;
7455
10001
  modes?: {
7456
10002
  key: string;
7457
10003
  title?: string | undefined;
@@ -7481,6 +10027,7 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7481
10027
  x: z.ZodOptional<z.ZodNumber>;
7482
10028
  y: z.ZodOptional<z.ZodNumber>;
7483
10029
  }, z.core.$strict>]>>;
10030
+ labels: z.ZodOptional<z.ZodArray<z.ZodString>>;
7484
10031
  dailyChallenges: z.ZodOptional<z.ZodBoolean>;
7485
10032
  leaderboards: z.ZodOptional<z.ZodArray<z.ZodObject<{
7486
10033
  key: z.ZodString;
@@ -7491,8 +10038,8 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7491
10038
  }>>;
7492
10039
  showZeros: z.ZodOptional<z.ZodBoolean>;
7493
10040
  source: z.ZodDefault<z.ZodEnum<{
7494
- server: "server";
7495
10041
  client: "client";
10042
+ server: "server";
7496
10043
  }>>;
7497
10044
  }, z.core.$strict>>>;
7498
10045
  controls: z.ZodOptional<z.ZodObject<{
@@ -7569,6 +10116,7 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7569
10116
  join: z.ZodDefault<z.ZodBoolean>;
7570
10117
  spectate: z.ZodDefault<z.ZodBoolean>;
7571
10118
  quickMatch: z.ZodDefault<z.ZodBoolean>;
10119
+ tournaments: z.ZodDefault<z.ZodBoolean>;
7572
10120
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
7573
10121
  key: z.ZodString;
7574
10122
  title: z.ZodOptional<z.ZodString>;
@@ -7584,6 +10132,7 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7584
10132
  join?: boolean | undefined;
7585
10133
  spectate?: boolean | undefined;
7586
10134
  quickMatch?: boolean | undefined;
10135
+ tournaments?: boolean | undefined;
7587
10136
  modes?: {
7588
10137
  key: string;
7589
10138
  title?: string | undefined;
@@ -7611,6 +10160,7 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7611
10160
  x: z.ZodOptional<z.ZodNumber>;
7612
10161
  y: z.ZodOptional<z.ZodNumber>;
7613
10162
  }, z.core.$strict>]>>;
10163
+ labels: z.ZodOptional<z.ZodArray<z.ZodString>>;
7614
10164
  dailyChallenges: z.ZodOptional<z.ZodBoolean>;
7615
10165
  leaderboards: z.ZodOptional<z.ZodArray<z.ZodObject<{
7616
10166
  key: z.ZodString;
@@ -7621,8 +10171,8 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7621
10171
  }>>;
7622
10172
  showZeros: z.ZodOptional<z.ZodBoolean>;
7623
10173
  source: z.ZodDefault<z.ZodEnum<{
7624
- server: "server";
7625
10174
  client: "client";
10175
+ server: "server";
7626
10176
  }>>;
7627
10177
  }, z.core.$strict>>>;
7628
10178
  controls: z.ZodOptional<z.ZodObject<{
@@ -7700,6 +10250,7 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7700
10250
  join: z.ZodDefault<z.ZodBoolean>;
7701
10251
  spectate: z.ZodDefault<z.ZodBoolean>;
7702
10252
  quickMatch: z.ZodDefault<z.ZodBoolean>;
10253
+ tournaments: z.ZodDefault<z.ZodBoolean>;
7703
10254
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
7704
10255
  key: z.ZodString;
7705
10256
  title: z.ZodOptional<z.ZodString>;
@@ -7715,6 +10266,7 @@ export declare const GameManifest: z.ZodDiscriminatedUnion<[z.ZodObject<{
7715
10266
  join?: boolean | undefined;
7716
10267
  spectate?: boolean | undefined;
7717
10268
  quickMatch?: boolean | undefined;
10269
+ tournaments?: boolean | undefined;
7718
10270
  modes?: {
7719
10271
  key: string;
7720
10272
  title?: string | undefined;
@@ -7754,6 +10306,7 @@ export declare const GamePackageJson: z.ZodObject<{
7754
10306
  x: z.ZodOptional<z.ZodNumber>;
7755
10307
  y: z.ZodOptional<z.ZodNumber>;
7756
10308
  }, z.core.$strict>]>>;
10309
+ labels: z.ZodOptional<z.ZodArray<z.ZodString>>;
7757
10310
  dailyChallenges: z.ZodOptional<z.ZodBoolean>;
7758
10311
  leaderboards: z.ZodOptional<z.ZodArray<z.ZodObject<{
7759
10312
  key: z.ZodString;
@@ -7764,8 +10317,8 @@ export declare const GamePackageJson: z.ZodObject<{
7764
10317
  }>>;
7765
10318
  showZeros: z.ZodOptional<z.ZodBoolean>;
7766
10319
  source: z.ZodDefault<z.ZodEnum<{
7767
- server: "server";
7768
10320
  client: "client";
10321
+ server: "server";
7769
10322
  }>>;
7770
10323
  }, z.core.$strict>>>;
7771
10324
  controls: z.ZodOptional<z.ZodObject<{
@@ -7842,6 +10395,7 @@ export declare const GamePackageJson: z.ZodObject<{
7842
10395
  join: z.ZodDefault<z.ZodBoolean>;
7843
10396
  spectate: z.ZodDefault<z.ZodBoolean>;
7844
10397
  quickMatch: z.ZodDefault<z.ZodBoolean>;
10398
+ tournaments: z.ZodDefault<z.ZodBoolean>;
7845
10399
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
7846
10400
  key: z.ZodString;
7847
10401
  title: z.ZodOptional<z.ZodString>;
@@ -7857,6 +10411,7 @@ export declare const GamePackageJson: z.ZodObject<{
7857
10411
  join?: boolean | undefined;
7858
10412
  spectate?: boolean | undefined;
7859
10413
  quickMatch?: boolean | undefined;
10414
+ tournaments?: boolean | undefined;
7860
10415
  modes?: {
7861
10416
  key: string;
7862
10417
  title?: string | undefined;
@@ -7884,6 +10439,7 @@ export declare const GamePackageJson: z.ZodObject<{
7884
10439
  x: z.ZodOptional<z.ZodNumber>;
7885
10440
  y: z.ZodOptional<z.ZodNumber>;
7886
10441
  }, z.core.$strict>]>>;
10442
+ labels: z.ZodOptional<z.ZodArray<z.ZodString>>;
7887
10443
  dailyChallenges: z.ZodOptional<z.ZodBoolean>;
7888
10444
  leaderboards: z.ZodOptional<z.ZodArray<z.ZodObject<{
7889
10445
  key: z.ZodString;
@@ -7894,8 +10450,8 @@ export declare const GamePackageJson: z.ZodObject<{
7894
10450
  }>>;
7895
10451
  showZeros: z.ZodOptional<z.ZodBoolean>;
7896
10452
  source: z.ZodDefault<z.ZodEnum<{
7897
- server: "server";
7898
10453
  client: "client";
10454
+ server: "server";
7899
10455
  }>>;
7900
10456
  }, z.core.$strict>>>;
7901
10457
  controls: z.ZodOptional<z.ZodObject<{
@@ -7973,6 +10529,7 @@ export declare const GamePackageJson: z.ZodObject<{
7973
10529
  join: z.ZodDefault<z.ZodBoolean>;
7974
10530
  spectate: z.ZodDefault<z.ZodBoolean>;
7975
10531
  quickMatch: z.ZodDefault<z.ZodBoolean>;
10532
+ tournaments: z.ZodDefault<z.ZodBoolean>;
7976
10533
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
7977
10534
  key: z.ZodString;
7978
10535
  title: z.ZodOptional<z.ZodString>;
@@ -7988,6 +10545,7 @@ export declare const GamePackageJson: z.ZodObject<{
7988
10545
  join?: boolean | undefined;
7989
10546
  spectate?: boolean | undefined;
7990
10547
  quickMatch?: boolean | undefined;
10548
+ tournaments?: boolean | undefined;
7991
10549
  modes?: {
7992
10550
  key: string;
7993
10551
  title?: string | undefined;
@@ -8043,6 +10601,66 @@ export declare const HubInject: z.ZodObject<{
8043
10601
  /** The injected `window.__HUB__` config. */
8044
10602
  export type HubInject = z.infer<typeof HubInject>;
8045
10603
  //#endregion
10604
+ //#region src/manifest/labels.d.ts
10605
+ /** The vocabulary, by group. */
10606
+ export declare const GAME_LABEL_GROUPS: {
10607
+ /** What kind of game. */
10608
+ readonly genre: readonly ["cards", "board", "puzzle", "arcade", "platformer", "real-time-strategy", "physics", "typing", "word", "sports", "racing"];
10609
+ /** How it looks. */
10610
+ readonly form: readonly ["2d", "3d"];
10611
+ /** Where it plays: `phone` (touch controls), `controller` (gamepad support), `desktop` (keyboard or mouse only). */
10612
+ readonly platform: readonly ["phone", "controller", "desktop"];
10613
+ /** How many play. */
10614
+ readonly play: readonly ["multiplayer", "single-player"];
10615
+ };
10616
+ /** A label group's key. */
10617
+ export type GameLabelGroup = keyof typeof GAME_LABEL_GROUPS;
10618
+ /** The groups in display order. */
10619
+ export declare const GAME_LABEL_GROUP_ORDER: readonly GameLabelGroup[];
10620
+ /** Every label, in display order (group by group). */
10621
+ export declare const GAME_LABELS: readonly ["cards", "board", "puzzle", "arcade", "platformer", "real-time-strategy", "physics", "typing", "word", "sports", "racing", "2d", "3d", "phone", "controller", "desktop", "multiplayer", "single-player"];
10622
+ /** One known label. */
10623
+ export declare const GameLabel: z.ZodEnum<{
10624
+ racing: "racing";
10625
+ typing: "typing";
10626
+ multiplayer: "multiplayer";
10627
+ board: "board";
10628
+ cards: "cards";
10629
+ puzzle: "puzzle";
10630
+ arcade: "arcade";
10631
+ platformer: "platformer";
10632
+ "real-time-strategy": "real-time-strategy";
10633
+ physics: "physics";
10634
+ word: "word";
10635
+ sports: "sports";
10636
+ "2d": "2d";
10637
+ "3d": "3d";
10638
+ phone: "phone";
10639
+ controller: "controller";
10640
+ desktop: "desktop";
10641
+ "single-player": "single-player";
10642
+ }>;
10643
+ /** One known label. */
10644
+ export type GameLabel = z.infer<typeof GameLabel>;
10645
+ /** Each label's display name. */
10646
+ export declare const GAME_LABEL_TITLES: Readonly<Record<GameLabel, string>>;
10647
+ /** Each group's display name. */
10648
+ export declare const GAME_LABEL_GROUP_TITLES: Readonly<Record<GameLabelGroup, string>>;
10649
+ /** Whether `text` is a known label. */
10650
+ export declare function isGameLabel(text: string): text is GameLabel;
10651
+ /** The group a label belongs to. */
10652
+ export declare function groupOfLabel(label: GameLabel): GameLabelGroup;
10653
+ /**
10654
+ * `game.labels` as written: short strings. Unknown ones parse (they are a
10655
+ * warning, see {@link splitGameLabels}).
10656
+ */
10657
+ export declare const GameLabels: z.ZodArray<z.ZodString>;
10658
+ /** Known labels (trimmed, lower-cased, de-duplicated, in vocabulary order) and the unknown ones as written. */
10659
+ export declare function splitGameLabels(written: readonly string[]): {
10660
+ readonly labels: GameLabel[];
10661
+ readonly unknown: string[];
10662
+ };
10663
+ //#endregion
8046
10664
  //#region src/manifest/leaderboards.d.ts
8047
10665
  /** One declared leaderboard. */
8048
10666
  export declare const LeaderboardDecl: z.ZodObject<{
@@ -8054,8 +10672,8 @@ export declare const LeaderboardDecl: z.ZodObject<{
8054
10672
  }>>;
8055
10673
  showZeros: z.ZodOptional<z.ZodBoolean>;
8056
10674
  source: z.ZodDefault<z.ZodEnum<{
8057
- server: "server";
8058
10675
  client: "client";
10676
+ server: "server";
8059
10677
  }>>;
8060
10678
  }, z.core.$strict>;
8061
10679
  /** `game.leaderboards`: unique keys. */
@@ -8068,8 +10686,8 @@ export declare const GameLeaderboardDecls: z.ZodArray<z.ZodObject<{
8068
10686
  }>>;
8069
10687
  showZeros: z.ZodOptional<z.ZodBoolean>;
8070
10688
  source: z.ZodDefault<z.ZodEnum<{
8071
- server: "server";
8072
10689
  client: "client";
10690
+ server: "server";
8073
10691
  }>>;
8074
10692
  }, z.core.$strict>>;
8075
10693
  //#endregion
@@ -8107,6 +10725,7 @@ export declare const GameMultiplayer: z.ZodObject<{
8107
10725
  join: z.ZodDefault<z.ZodBoolean>;
8108
10726
  spectate: z.ZodDefault<z.ZodBoolean>;
8109
10727
  quickMatch: z.ZodDefault<z.ZodBoolean>;
10728
+ tournaments: z.ZodDefault<z.ZodBoolean>;
8110
10729
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
8111
10730
  key: z.ZodString;
8112
10731
  title: z.ZodOptional<z.ZodString>;
@@ -8129,6 +10748,7 @@ export declare const StaticGameMultiplayer: z.ZodObject<{
8129
10748
  join: z.ZodDefault<z.ZodBoolean>;
8130
10749
  spectate: z.ZodDefault<z.ZodBoolean>;
8131
10750
  quickMatch: z.ZodDefault<z.ZodBoolean>;
10751
+ tournaments: z.ZodDefault<z.ZodBoolean>;
8132
10752
  modes: z.ZodDefault<z.ZodArray<z.ZodObject<{
8133
10753
  key: z.ZodString;
8134
10754
  title: z.ZodOptional<z.ZodString>;
@@ -8335,6 +10955,30 @@ export declare const MANIFEST_LIMITS: {
8335
10955
  /** Largest `game.race.minMs`, in ms (10 minutes). */
8336
10956
  readonly raceMinMsMax: 600000;
8337
10957
  };
10958
+ /** What a tournament may be (batch-2026-10 R15). The server enforces each one. */
10959
+ export declare const TOURNAMENT_LIMITS: {
10960
+ /** Longest title, in characters. */
10961
+ readonly titleMax: 48;
10962
+ /** Fewest players. */
10963
+ readonly playersMin: 2;
10964
+ /** Most players. */
10965
+ readonly playersMax: 64;
10966
+ /** Most games in the set a tournament picks from. */
10967
+ readonly gamesMax: 8;
10968
+ /** Lives per player: 1 single, 2 double, 3 triple elimination. */
10969
+ readonly livesMax: 3;
10970
+ /** The default and the longest window to join a ready match before forfeiting, in minutes. */
10971
+ readonly readyMinutesDefault: 10;
10972
+ readonly readyMinutesMax: 60;
10973
+ /** The longest "remind me before it starts", in minutes (one day). */
10974
+ readonly leadMinutesMax: 1440;
10975
+ /** The default reminder for players who signed up for a scheduled tournament, in minutes. */
10976
+ readonly leadMinutesDefault: 10;
10977
+ /** The furthest ahead a tournament may be scheduled, in days. */
10978
+ readonly scheduleDaysMax: 30;
10979
+ /** Most friends invited in one call. */
10980
+ readonly invitesMax: 50;
10981
+ };
8338
10982
  //#endregion
8339
10983
  //#region src/logic/daily.d.ts
8340
10984
  /**