@my-swu/simulator-client 0.1.6 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (111) hide show
  1. package/README.md +29 -0
  2. package/dist/client.js +6 -1
  3. package/dist/connection/url.d.ts +2 -0
  4. package/dist/connection/url.js +4 -0
  5. package/dist/generated/index.d.ts +4 -0
  6. package/dist/generated/schemas.d.ts +1 -1
  7. package/dist/generated/schemas.js +1405 -23
  8. package/dist/generated/types/admin-match-debug-bundle.d.ts +1 -1
  9. package/dist/generated/types/admin-match-list-response.d.ts +1 -1
  10. package/dist/generated/types/admin-match-replay-response.d.ts +1 -1
  11. package/dist/generated/types/common.d.ts +445 -0
  12. package/dist/generated/types/create-limited-event-request.d.ts +1 -1
  13. package/dist/generated/types/format-event-response.d.ts +1 -1
  14. package/dist/generated/types/game-event.d.ts +1 -1
  15. package/dist/generated/types/game-state.d.ts +1 -1
  16. package/dist/generated/types/get-match-response.d.ts +1 -1
  17. package/dist/generated/types/leave-limited-event-request.d.ts +1 -0
  18. package/dist/generated/types/leave-limited-event-request.js +2 -0
  19. package/dist/generated/types/limited-event-server-message.d.ts +1 -0
  20. package/dist/generated/types/limited-event-server-message.js +2 -0
  21. package/dist/generated/types/list-active-ai-matches-response.d.ts +1 -1
  22. package/dist/generated/types/lobby-access-response.d.ts +1 -1
  23. package/dist/generated/types/lobby-chat-response.d.ts +1 -1
  24. package/dist/generated/types/lobby-response.d.ts +1 -1
  25. package/dist/generated/types/lobby-server-message.d.ts +1 -1
  26. package/dist/generated/types/match-access-recovery-response.d.ts +1 -1
  27. package/dist/generated/types/match-access-response.d.ts +1 -1
  28. package/dist/generated/types/match-history-replay-response.d.ts +1 -1
  29. package/dist/generated/types/match-recovery-response.d.ts +1 -1
  30. package/dist/generated/types/match-spectator-access-response.d.ts +1 -1
  31. package/dist/generated/types/rematch-match-response.d.ts +1 -1
  32. package/dist/generated/types/restore-history-response.d.ts +1 -1
  33. package/dist/generated/types/restore-match-save-response.d.ts +1 -1
  34. package/dist/generated/types/server-message.d.ts +1 -1
  35. package/dist/generated/types/shared-match-history-replay-response.d.ts +1 -1
  36. package/dist/generated/types/submit-ai-game-feedback-request.d.ts +1 -0
  37. package/dist/generated/types/submit-ai-game-feedback-request.js +2 -0
  38. package/dist/generated/types/submit-ai-game-feedback-response.d.ts +1 -0
  39. package/dist/generated/types/submit-ai-game-feedback-response.js +2 -0
  40. package/dist/generated/types/submit-match-deck-response.d.ts +1 -1
  41. package/dist/generated/types/tournament-room-access-response.d.ts +1 -1
  42. package/dist/generated/types/tournament-room-server-message.d.ts +1 -1
  43. package/dist/generated/types/undo-match-response.d.ts +1 -1
  44. package/dist/generated/types/update-lobby-settings-request.d.ts +1 -1
  45. package/dist/generated/version.d.ts +1 -1
  46. package/dist/generated/version.js +1 -1
  47. package/dist/http/request.d.ts +2 -0
  48. package/dist/http/request.js +9 -1
  49. package/dist/i18n/card-print-catalog.d.ts +9 -0
  50. package/dist/i18n/card-print-catalog.js +260 -0
  51. package/dist/i18n/catalog.d.ts +8 -0
  52. package/dist/i18n/catalog.js +195 -0
  53. package/dist/i18n/diagnostics.d.ts +6 -0
  54. package/dist/i18n/diagnostics.js +19 -0
  55. package/dist/i18n/fallback.d.ts +3 -0
  56. package/dist/i18n/fallback.js +40 -0
  57. package/dist/i18n/format.d.ts +8 -0
  58. package/dist/i18n/format.js +29 -0
  59. package/dist/i18n/generated/message-types.d.ts +91 -0
  60. package/dist/i18n/generated/message-types.js +3 -0
  61. package/dist/i18n/icu.d.ts +12 -0
  62. package/dist/i18n/icu.js +75 -0
  63. package/dist/i18n/index.d.ts +9 -0
  64. package/dist/i18n/index.js +5 -0
  65. package/dist/i18n/locale.d.ts +9 -0
  66. package/dist/i18n/locale.js +19 -0
  67. package/dist/i18n/types.d.ts +151 -0
  68. package/dist/i18n/types.js +1 -0
  69. package/dist/index.d.ts +4 -3
  70. package/dist/internal/authenticated-socket-session.d.ts +2 -0
  71. package/dist/internal/authenticated-socket-session.js +3 -1
  72. package/dist/local/client.js +7 -2
  73. package/dist/local/server/http-router.js +18 -0
  74. package/dist/resources/admin.d.ts +8 -0
  75. package/dist/resources/admin.js +2 -0
  76. package/dist/resources/limited-event-session.d.ts +10 -0
  77. package/dist/resources/limited-event-session.js +35 -0
  78. package/dist/resources/limited-event-types.d.ts +34 -1
  79. package/dist/resources/limited-events.d.ts +8 -1
  80. package/dist/resources/limited-events.js +18 -1
  81. package/dist/resources/lobbies.d.ts +1 -1
  82. package/dist/resources/lobbies.js +1 -1
  83. package/dist/resources/lobby-types.d.ts +15 -2
  84. package/dist/resources/match-history.d.ts +8 -1
  85. package/dist/resources/match-history.js +10 -0
  86. package/dist/resources/tournament-rooms.d.ts +1 -1
  87. package/dist/resources/tournament-rooms.js +1 -1
  88. package/dist/validators.d.ts +5 -1
  89. package/i18n/cards/de.json +121 -0
  90. package/i18n/cards/en.json +121 -0
  91. package/i18n/cards/es.json +121 -0
  92. package/i18n/cards/fr.json +121 -0
  93. package/i18n/cards/it.json +121 -0
  94. package/i18n/cards/manifest.json +2715 -0
  95. package/i18n/de.json +11 -0
  96. package/i18n/en.json +11 -0
  97. package/i18n/es.json +11 -0
  98. package/i18n/fr.json +11 -0
  99. package/i18n/it.json +11 -0
  100. package/i18n/messages.schema.json +28 -0
  101. package/package.json +12 -2
  102. package/schema/common.schema.json +1092 -1
  103. package/schema/create-limited-event-request.schema.json +11 -0
  104. package/schema/game-event.schema.json +76 -0
  105. package/schema/leave-limited-event-request.schema.json +15 -0
  106. package/schema/limited-event-server-message.schema.json +63 -0
  107. package/schema/manifest.json +5 -1
  108. package/schema/route-manifest.json +54 -0
  109. package/schema/submit-ai-game-feedback-request.schema.json +36 -0
  110. package/schema/submit-ai-game-feedback-response.schema.json +19 -0
  111. package/schema/update-lobby-settings-request.schema.json +67 -0
@@ -29,6 +29,16 @@ export type AbilityTarget = ({
29
29
  } | {
30
30
  seat: Seat;
31
31
  type: "leader";
32
+ } | {
33
+ /**
34
+ * Zero-based position in that player's leader list.
35
+ */
36
+ leaderIndex: number;
37
+ /**
38
+ * Player who owns the leader slot.
39
+ */
40
+ seat: Seat;
41
+ type: "leaderByIndex";
32
42
  } | {
33
43
  seat: Seat;
34
44
  type: "base";
@@ -64,6 +74,12 @@ export type AbilityWindow = (("AfterPlayOrDeploy" | "WhenActionPhaseStarts" | "W
64
74
  } | "WhenYouReadyCardsDuringRegroup" | "WhenFriendlyUnitAttacksAndDefeats" | "WhenFriendlyUnitDefeatedWhileAttacking" | "WhenYouPlayEvent" | "WhenYouPlayAUnit" | "WhenYouPlayOrCreateAUnit" | "WhenFriendlyUnitEntersPlay" | "WhenYouPlayAnotherUnit" | "WhenYouPlayAnUpgrade" | "WhenYouCollectABounty" | "WhenYouDiscardFromDeck");
65
75
  export type ActionAbilitySource = ({
66
76
  type: "leader";
77
+ } | {
78
+ /**
79
+ * Non-primary leader slots start at one; slot zero uses legacy `Leader`.
80
+ */
81
+ leaderIndex: number;
82
+ type: "leaderByIndex";
67
83
  } | {
68
84
  actionIndex: number;
69
85
  type: "leaderUnit";
@@ -82,8 +98,13 @@ export type ActionAbilitySource = ({
82
98
  export interface ActionAbilityView {
83
99
  creditTokenCounts: number[];
84
100
  label: string;
101
+ modeChoice?: (ModeChoiceView | null);
85
102
  source: ActionAbilitySource;
86
103
  targetGroups: TargetSelectionGroup[];
104
+ /**
105
+ * Exact public Action or Epic Action declaration when migrated.
106
+ */
107
+ text?: (EffectTextRefsView | null);
87
108
  }
88
109
  /**
89
110
  * Admission scope that blocked creation of an AI-backed match.
@@ -231,6 +252,12 @@ export interface ActiveEffectView {
231
252
  inactive?: boolean;
232
253
  source?: (EffectSourceView | null);
233
254
  targets: EffectTargetView[];
255
+ /**
256
+ * Reviewed card-text and shared-message provenance when this public row
257
+ * was created by a resolving instruction. Absence means this registry
258
+ * does not retain a display declaration, never that text was inferred.
259
+ */
260
+ text?: (EffectTextRefsView | null);
234
261
  }
235
262
  export interface AddLobbyAiPlayerRequest {
236
263
  /**
@@ -274,6 +301,10 @@ export interface AdminMatchReplayResponse {
274
301
  * Compact durable match data safe for an administrator list view.
275
302
  */
276
303
  export interface AdminMatchSummary {
304
+ /**
305
+ * Feedback collected for individual completed AI games in this match.
306
+ */
307
+ aiFeedback: AiGameFeedback[];
277
308
  completedAtMs?: (number | null);
278
309
  createdAtMs: number;
279
310
  format: MatchFormat;
@@ -374,6 +405,19 @@ export type AiDecisionSearchMode = ("mcts" | "setupEvaluator" | "fastPath");
374
405
  * adjusted without changing the SDK surface.
375
406
  */
376
407
  export type AiDifficulty = ("easy" | "medium" | "hard" | "unfair");
408
+ /**
409
+ * One immutable player assessment of an AI opponent for a completed game.
410
+ */
411
+ export interface AiGameFeedback {
412
+ comments?: (string | null);
413
+ gameNumber: number;
414
+ rating: AiGameFeedbackRating;
415
+ submittedAtMs: number;
416
+ }
417
+ /**
418
+ * Rating submitted by a player after completing one Solo-versus-AI game.
419
+ */
420
+ export type AiGameFeedbackRating = ("poorly" | "okay" | "good");
377
421
  /**
378
422
  * Explicit AI seat configuration.
379
423
  */
@@ -587,6 +631,20 @@ export interface CardReferenceMatchView {
587
631
  cardType: CardType;
588
632
  title: string;
589
633
  }
634
+ export interface CardTextRef {
635
+ /**
636
+ * Canonical card identity that owns this reviewed printed slot.
637
+ */
638
+ cardId: number;
639
+ /**
640
+ * Full semantic-contract fingerprint pinning this reference to reviewed text.
641
+ */
642
+ contractFingerprint: string;
643
+ /**
644
+ * Durable reviewed slot identifier within the canonical card contract.
645
+ */
646
+ slot: string;
647
+ }
590
648
  /**
591
649
  * Canonical card families from production card data.
592
650
  */
@@ -684,6 +742,10 @@ export interface CreateLimitedEventRequest {
684
742
  * Set code used for booster generation.
685
743
  */
686
744
  setCode: string;
745
+ /**
746
+ * Optional lobby-owned pick and deck-construction schedule.
747
+ */
748
+ timerSettings?: (LimitedLobbyTimerSettings | null);
687
749
  }
688
750
  export interface CreateLobbyRequest {
689
751
  config: LobbyConfig;
@@ -1054,6 +1116,10 @@ export interface DelayedEffectOrderOptionView {
1054
1116
  label: string;
1055
1117
  occurrenceSequence: number;
1056
1118
  sourceCardId?: (number | null);
1119
+ /**
1120
+ * Reviewed text retained by the delayed follow-up when it was created.
1121
+ */
1122
+ text?: (EffectTextRefsView | null);
1057
1123
  }
1058
1124
  /**
1059
1125
  * Public trigger point for a delayed effect.
@@ -1086,6 +1152,10 @@ export interface DelayedEffectView {
1086
1152
  id: string;
1087
1153
  source?: (EffectSourceView | null);
1088
1154
  targets: EffectTargetView[];
1155
+ /**
1156
+ * Reviewed card-text and shared-message provenance for this public row.
1157
+ */
1158
+ text?: (EffectTextRefsView | null);
1089
1159
  timing: DelayedEffectTimingView;
1090
1160
  }
1091
1161
  export interface DistributionAssignment {
@@ -1114,6 +1184,24 @@ export interface DistributionTargetView {
1114
1184
  target: AbilityTarget;
1115
1185
  }
1116
1186
  export type DistributionTokenKindView = ("experience" | "shield" | "advantage");
1187
+ /**
1188
+ * Draft pick schedule. Vectors are ordered by remaining choices: leader
1189
+ * values cover 2 through 8, pack values cover 2 through 14.
1190
+ */
1191
+ export interface DraftLobbyTimerSettings {
1192
+ /**
1193
+ * Leader-pick duration in seconds for 2 through 8 leaders remaining.
1194
+ */
1195
+ leaderPickSeconds: number[];
1196
+ /**
1197
+ * Pack-pick duration in seconds for 2 through 14 cards remaining.
1198
+ */
1199
+ packPickSeconds: number[];
1200
+ /**
1201
+ * Review duration between booster packs in seconds.
1202
+ */
1203
+ reviewSeconds: number;
1204
+ }
1117
1205
  /**
1118
1206
  * One configured booster round for a chaos draft.
1119
1207
  */
@@ -1157,36 +1245,46 @@ export type EffectResolutionDraftStepView = ({
1157
1245
  purpose: TargetGroupPurpose;
1158
1246
  selected: AbilityTarget[];
1159
1247
  stepId: string;
1248
+ text?: (EffectTextRefsView | null);
1160
1249
  } | {
1161
1250
  editable: boolean;
1162
1251
  kind: "amount";
1163
1252
  label: string;
1164
1253
  selected: number;
1165
1254
  stepId: string;
1255
+ text?: (EffectTextRefsView | null);
1166
1256
  } | {
1167
1257
  editable: boolean;
1168
1258
  kind: "modes";
1169
1259
  label: string;
1260
+ /**
1261
+ * Exact reviewed Mode wrappers for every selected executable option.
1262
+ */
1263
+ modeTextReferences?: (CardTextRef | null)[];
1170
1264
  selected: number[];
1171
1265
  stepId: string;
1266
+ text?: (EffectTextRefsView | null);
1172
1267
  } | {
1173
1268
  editable: boolean;
1174
1269
  kind: "cards";
1175
1270
  label: string;
1176
1271
  selected: number[];
1177
1272
  stepId: string;
1273
+ text?: (EffectTextRefsView | null);
1178
1274
  } | {
1179
1275
  editable: boolean;
1180
1276
  kind: "name";
1181
1277
  label: string;
1182
1278
  selected: string;
1183
1279
  stepId: string;
1280
+ text?: (EffectTextRefsView | null);
1184
1281
  } | {
1185
1282
  editable: boolean;
1186
1283
  kind: "aspect";
1187
1284
  label: string;
1188
1285
  selected: string;
1189
1286
  stepId: string;
1287
+ text?: (EffectTextRefsView | null);
1190
1288
  } | {
1191
1289
  attackerId: number;
1192
1290
  editable: boolean;
@@ -1194,12 +1292,14 @@ export type EffectResolutionDraftStepView = ({
1194
1292
  label: string;
1195
1293
  stepId: string;
1196
1294
  target: AttackTarget;
1295
+ text?: (EffectTextRefsView | null);
1197
1296
  } | {
1198
1297
  editable: boolean;
1199
1298
  kind: "distribution";
1200
1299
  label: string;
1201
1300
  selected: DistributionAssignment[];
1202
1301
  stepId: string;
1302
+ text?: (EffectTextRefsView | null);
1203
1303
  });
1204
1304
  /**
1205
1305
  * Engine-owned answers collected for one uncommitted semantic effect.
@@ -1213,6 +1313,10 @@ export interface EffectResolutionDraftView {
1213
1313
  * Printed label of originating effect, retained for descendants.
1214
1314
  */
1215
1315
  originLabel: string;
1316
+ /**
1317
+ * Exact reviewed text owner for the originating command.
1318
+ */
1319
+ originText?: (EffectTextRefsView | null);
1216
1320
  sourceCardId: number;
1217
1321
  steps: EffectResolutionDraftStepView[];
1218
1322
  }
@@ -1260,6 +1364,10 @@ export type EffectTargetView = ({
1260
1364
  } | {
1261
1365
  seat: Seat;
1262
1366
  type: "leader";
1367
+ } | {
1368
+ leaderIndex: number;
1369
+ seat: Seat;
1370
+ type: "leaderByIndex";
1263
1371
  } | {
1264
1372
  seat: Seat;
1265
1373
  type: "base";
@@ -1270,6 +1378,32 @@ export type EffectTargetView = ({
1270
1378
  cardId: number;
1271
1379
  type: "card";
1272
1380
  });
1381
+ /**
1382
+ * Locale-neutral reviewed text that owns visible effect work.
1383
+ *
1384
+ * Clients resolve these catalog references in their selected locale. Empty
1385
+ * fields mean runtime work came from an unmigrated declaration; they never
1386
+ * authorize reconstructing English from a label. Explicit system messages
1387
+ * remain present in `shared_messages` instead of being mistaken for absence.
1388
+ */
1389
+ export interface EffectTextRefsView {
1390
+ /**
1391
+ * Printed ability that created this resolution.
1392
+ */
1393
+ ability?: (CardTextRef | null);
1394
+ /**
1395
+ * Nested printed effects enclosing this visible work, outermost first.
1396
+ */
1397
+ effects?: CardTextRef[];
1398
+ /**
1399
+ * Printed mode selected before the current continuation, if any.
1400
+ */
1401
+ selectedMode?: (CardTextRef | null);
1402
+ /**
1403
+ * Finite SDK messages explicitly declared for this outcome.
1404
+ */
1405
+ sharedMessages?: SimulatorMessage[];
1406
+ }
1273
1407
  export interface ErrorPayload {
1274
1408
  code: string;
1275
1409
  message: string;
@@ -1283,6 +1417,35 @@ export interface ErrorPayload {
1283
1417
  */
1284
1418
  retryAtMs?: (number | null);
1285
1419
  }
1420
+ /**
1421
+ * Reviewed printed ownership for inputs accepted by one event-play command.
1422
+ *
1423
+ * Target groups retain their native ownership/order. Mode references stay
1424
+ * position-aligned with submitted mode indexes, including legacy `None`
1425
+ * entries, so sparse bindings never shift a selected option's identity.
1426
+ */
1427
+ export interface EventPlayInputProvenance {
1428
+ /**
1429
+ * One explicit Mode reference per submitted mode index, in command order.
1430
+ */
1431
+ modeTextReferences?: (CardTextRef | null)[];
1432
+ /**
1433
+ * One compact ownership record per submitted target or capture pair, in
1434
+ * command order.
1435
+ *
1436
+ * This intentionally excludes target candidates and the selected target
1437
+ * itself. Event history needs printed ownership, while candidate lists can
1438
+ * reveal hidden resources and live board information.
1439
+ */
1440
+ targetInputs?: EventPlayTargetInputProvenance[];
1441
+ }
1442
+ /**
1443
+ * Printed ownership for one submitted event target.
1444
+ */
1445
+ export interface EventPlayTargetInputProvenance {
1446
+ purpose: TargetGroupPurpose;
1447
+ textReferences?: CardTextRef[];
1448
+ }
1286
1449
  export interface ExploitOptionsView {
1287
1450
  candidateUnitIds: number[];
1288
1451
  max: number;
@@ -1693,8 +1856,21 @@ export type GameEvent = ("setupCompleted" | {
1693
1856
  } | {
1694
1857
  eventPlayed: {
1695
1858
  cardId: number;
1859
+ /**
1860
+ * Exact reviewed owners for inputs supplied while playing this event.
1861
+ *
1862
+ * This is emitted only for migrated declarations. It captures the
1863
+ * play command before later event clauses can replace the active
1864
+ * prompt, which lets draft/history consumers retain the source input
1865
+ * rather than borrowing a descendant's text.
1866
+ */
1867
+ inputProvenance?: (EventPlayInputProvenance | null);
1696
1868
  playedWithSmuggle: boolean;
1697
1869
  seat: Seat;
1870
+ /**
1871
+ * Exact printed event declaration exposed when this public event was played.
1872
+ */
1873
+ text?: (EffectTextRefsView | null);
1698
1874
  };
1699
1875
  } | {
1700
1876
  upgradePlayed: {
@@ -1786,6 +1962,17 @@ export type GameEvent = ("setupCompleted" | {
1786
1962
  cardIds: number[];
1787
1963
  seat: Seat;
1788
1964
  };
1965
+ } | {
1966
+ cardsChosenFromDiscard: {
1967
+ /**
1968
+ * Printed card identities in command order; duplicates represent distinct copies.
1969
+ */
1970
+ cardIds: number[];
1971
+ /**
1972
+ * Player who made the selection, which may differ from the discard-pile owner.
1973
+ */
1974
+ seat: Seat;
1975
+ };
1789
1976
  } | {
1790
1977
  namedCardChosen: {
1791
1978
  name: string;
@@ -1825,6 +2012,10 @@ export type GameEvent = ("setupCompleted" | {
1825
2012
  source: ActionAbilitySource;
1826
2013
  sourceCardId?: (number | null);
1827
2014
  targets?: AbilityTarget[];
2015
+ /**
2016
+ * Exact public Action or Epic Action declaration that was used.
2017
+ */
2018
+ text?: (EffectTextRefsView | null);
1828
2019
  };
1829
2020
  } | {
1830
2021
  triggeredAbilityResolved: {
@@ -1832,6 +2023,10 @@ export type GameEvent = ("setupCompleted" | {
1832
2023
  seat: Seat;
1833
2024
  sourceCardId: number;
1834
2025
  sourceUnitId?: (number | null);
2026
+ /**
2027
+ * Exact public trigger declaration and currently resolved effect.
2028
+ */
2029
+ text?: (EffectTextRefsView | null);
1835
2030
  window: AbilityWindow;
1836
2031
  };
1837
2032
  } | {
@@ -2359,7 +2554,12 @@ export interface KickLobbySpectatorRequest {
2359
2554
  export interface LeaderActionView {
2360
2555
  creditTokenCounts: number[];
2361
2556
  label: string;
2557
+ modeChoice?: (ModeChoiceView | null);
2362
2558
  targetGroups: TargetSelectionGroup[];
2559
+ /**
2560
+ * Reviewed declaration text for a migrated leader action.
2561
+ */
2562
+ text?: (EffectTextRefsView | null);
2363
2563
  }
2364
2564
  export interface LeaderDeployActionView {
2365
2565
  /**
@@ -2434,6 +2634,15 @@ export interface LeaderStateView {
2434
2634
  flipped: boolean;
2435
2635
  unitId?: (number | null);
2436
2636
  }
2637
+ /**
2638
+ * Explicit departure from one direct Limited Event seat.
2639
+ */
2640
+ export interface LeaveLimitedEventRequest {
2641
+ /**
2642
+ * Seat token returned by create or join.
2643
+ */
2644
+ seatToken: string;
2645
+ }
2437
2646
  export interface LeaveLobbyRequest {
2438
2647
  playerToken: string;
2439
2648
  }
@@ -2658,6 +2867,21 @@ export interface LimitedEventSeatView {
2658
2867
  */
2659
2868
  seatIndex: number;
2660
2869
  }
2870
+ /**
2871
+ * Server messages emitted by direct Limited Event sockets.
2872
+ */
2873
+ export type LimitedEventServerMessage = ({
2874
+ payload: LimitedEventSnapshot;
2875
+ type: "snapshot";
2876
+ } | {
2877
+ payload: {
2878
+ nonce?: (string | null);
2879
+ };
2880
+ type: "pong";
2881
+ } | {
2882
+ payload: ErrorPayload;
2883
+ type: "error";
2884
+ });
2661
2885
  /**
2662
2886
  * Public snapshot of one limited event.
2663
2887
  */
@@ -2756,6 +2980,23 @@ export interface LimitedEventViewerView {
2756
2980
  */
2757
2981
  seatIndex: number;
2758
2982
  }
2983
+ /**
2984
+ * Limited-event timing controls owned by a lobby host.
2985
+ */
2986
+ export interface LimitedLobbyTimerSettings {
2987
+ /**
2988
+ * Deck construction duration in seconds.
2989
+ */
2990
+ deckBuildingSeconds: number;
2991
+ /**
2992
+ * Enables informational deck construction deadline displays.
2993
+ */
2994
+ deckBuildingTimerEnabled: boolean;
2995
+ /**
2996
+ * Draft-only pick and review schedule. Sealed lobbies omit it.
2997
+ */
2998
+ draft?: (DraftLobbyTimerSettings | null);
2999
+ }
2759
3000
  /**
2760
3001
  * One generated pack card plus collation metadata.
2761
3002
  */
@@ -2902,6 +3143,19 @@ export interface LobbyDeckSetPreview {
2902
3143
  */
2903
3144
  leader?: (number | null);
2904
3145
  }
3146
+ /**
3147
+ * Per-game clock values shared by constructed and Limited lobbies.
3148
+ */
3149
+ export interface LobbyGameTimerSettings {
3150
+ /**
3151
+ * Seconds of reserve time granted to each player.
3152
+ */
3153
+ reserveSeconds: number;
3154
+ /**
3155
+ * Seconds allocated to each normal turn before reserve is used.
3156
+ */
3157
+ turnSeconds: number;
3158
+ }
2905
3159
  export interface LobbyKickedPayload {
2906
3160
  /**
2907
3161
  * Player or spectator identity removed from this lobby.
@@ -3106,6 +3360,11 @@ export interface LobbySnapshot {
3106
3360
  requiredPlayerCount: number;
3107
3361
  spectators?: LobbySpectatorView[];
3108
3362
  status: LobbyStatus;
3363
+ /**
3364
+ * Host-selected timer schedule for this lobby. Missing values identify
3365
+ * records created before configurable timers were introduced.
3366
+ */
3367
+ timerSettings?: (LobbyTimerSettings | null);
3109
3368
  visibility: LobbyVisibility;
3110
3369
  }
3111
3370
  export interface LobbySpectatorView {
@@ -3140,6 +3399,19 @@ export type LobbyStatus = ("waiting" | "started" | "closed");
3140
3399
  export interface LobbySyncRequest {
3141
3400
  playerToken: string;
3142
3401
  }
3402
+ /**
3403
+ * Host-selected timing rules for a lobby and its started event or match.
3404
+ */
3405
+ export interface LobbyTimerSettings {
3406
+ /**
3407
+ * Per-turn and reserve-bank settings for the final game.
3408
+ */
3409
+ game: LobbyGameTimerSettings;
3410
+ /**
3411
+ * Limited-only draft and deck-construction settings.
3412
+ */
3413
+ limited?: (LimitedLobbyTimerSettings | null);
3414
+ }
3143
3415
  export type LobbyVisibility = ("private" | "public");
3144
3416
  export interface LobbyWelcomePayload {
3145
3417
  lobbyId: string;
@@ -3727,6 +3999,10 @@ export interface PendingAbilityAspectChoiceView {
3727
3999
  */
3728
4000
  promptProvenance?: (PromptProvenanceView | null);
3729
4001
  sourceCardId: number;
4002
+ /**
4003
+ * Reviewed printed text owning this chooser payload.
4004
+ */
4005
+ text?: (EffectTextRefsView | null);
3730
4006
  }
3731
4007
  export interface PendingAbilityAttackChoiceView {
3732
4008
  abilityId: number;
@@ -3755,6 +4031,10 @@ export interface PendingAbilityAttackChoiceView {
3755
4031
  */
3756
4032
  revealedCardIds?: number[];
3757
4033
  sourceCardId: number;
4034
+ /**
4035
+ * Reviewed printed text owning this chooser payload.
4036
+ */
4037
+ text?: (EffectTextRefsView | null);
3758
4038
  }
3759
4039
  export interface PendingAbilityCardChoiceView {
3760
4040
  abilityId: number;
@@ -3788,6 +4068,10 @@ export interface PendingAbilityCardChoiceView {
3788
4068
  revealMode: HiddenCardChoiceMode;
3789
4069
  searchedCards: CardInstanceView[];
3790
4070
  sourceCardId: number;
4071
+ /**
4072
+ * Reviewed printed text owning this private chooser payload.
4073
+ */
4074
+ text?: (EffectTextRefsView | null);
3791
4075
  }
3792
4076
  /**
3793
4077
  * Coarse family of one pending ability: [`PendingAbilityKind`]'s variant
@@ -3821,11 +4105,22 @@ export interface PendingAbilityModeChoiceView {
3821
4105
  max: number;
3822
4106
  min: number;
3823
4107
  optionLabels: string[];
4108
+ /**
4109
+ * Reviewed printed text for each matching mode option.
4110
+ *
4111
+ * Index aligns with `option_labels`; `None` denotes an engine/system
4112
+ * option rather than inferred prose.
4113
+ */
4114
+ optionTextReferences?: (CardTextRef | null)[];
3824
4115
  /**
3825
4116
  * Parent/stage identity and interaction policy inherited from resolution.
3826
4117
  */
3827
4118
  promptProvenance?: (PromptProvenanceView | null);
3828
4119
  sourceCardId: number;
4120
+ /**
4121
+ * Reviewed printed text owning this chooser payload.
4122
+ */
4123
+ text?: (EffectTextRefsView | null);
3829
4124
  }
3830
4125
  export interface PendingAbilityNameChoiceView {
3831
4126
  abilityId: number;
@@ -3840,6 +4135,10 @@ export interface PendingAbilityNameChoiceView {
3840
4135
  */
3841
4136
  promptProvenance?: (PromptProvenanceView | null);
3842
4137
  sourceCardId: number;
4138
+ /**
4139
+ * Reviewed printed text owning this chooser payload.
4140
+ */
4141
+ text?: (EffectTextRefsView | null);
3843
4142
  }
3844
4143
  /**
3845
4144
  * One queued ability shown while a player-order choice is pending.
@@ -3852,6 +4151,11 @@ export interface PendingAbilityOrderAbilityView {
3852
4151
  id: number;
3853
4152
  label: string;
3854
4153
  sourceCardId: number;
4154
+ /**
4155
+ * Reviewed text retained by the queued ability when its producer made it
4156
+ * public. The order prompt does not infer ownership from source cards.
4157
+ */
4158
+ text?: (EffectTextRefsView | null);
3855
4159
  }
3856
4160
  /**
3857
4161
  * Payload for [`PromptState::ChooseTriggeredAbilityPlayerOrder`].
@@ -3917,6 +4221,10 @@ export interface PendingAbilityView {
3917
4221
  * Groups retain ordering, bounds, and structural purpose together.
3918
4222
  */
3919
4223
  targetPlan: TargetSelectionPlanView;
4224
+ /**
4225
+ * Reviewed printed ability, selected mode, and current effect ownership.
4226
+ */
4227
+ text?: (EffectTextRefsView | null);
3920
4228
  /**
3921
4229
  * Trigger window this ability was collected in.
3922
4230
  *
@@ -3987,6 +4295,10 @@ export interface PendingDistributionView {
3987
4295
  */
3988
4296
  promptProvenance?: (PromptProvenanceView | null);
3989
4297
  sourceCardId: number;
4298
+ /**
4299
+ * Reviewed printed text owning this chooser payload.
4300
+ */
4301
+ text?: (EffectTextRefsView | null);
3990
4302
  title: string;
3991
4303
  validTargets: DistributionTargetView[];
3992
4304
  }
@@ -4070,9 +4382,14 @@ export type PlayerPresenceStatus = ("joined" | "disconnected" | "reconnected" |
4070
4382
  */
4071
4383
  export interface PlaygroundActionAbilityView {
4072
4384
  label: string;
4385
+ modeChoice?: (ModeChoiceView | null);
4073
4386
  seat: Seat;
4074
4387
  source: ActionAbilitySource;
4075
4388
  targetGroups: TargetSelectionGroup[];
4389
+ /**
4390
+ * Exact public Action or Epic Action declaration when migrated.
4391
+ */
4392
+ text?: (EffectTextRefsView | null);
4076
4393
  }
4077
4394
  /**
4078
4395
  * One in-play card whose Playground-editable state may be set exactly.
@@ -4887,6 +5204,65 @@ export interface SimulatorAvailabilityResponse {
4887
5204
  */
4888
5205
  maintenance: MaintenanceStatus;
4889
5206
  }
5207
+ /**
5208
+ * Typed engine-origin simulator copy with a stable SDK message id.
5209
+ */
5210
+ export type SimulatorMessage = ({
5211
+ kind: "abilityUnavailable";
5212
+ } | {
5213
+ kind: "action.exhaust";
5214
+ } | {
5215
+ count: number;
5216
+ kind: "amount.resources";
5217
+ } | {
5218
+ kind: "choice.none";
5219
+ } | {
5220
+ kind: "chooseTarget";
5221
+ } | {
5222
+ kind: "chooseTargets";
5223
+ max: number;
5224
+ min: number;
5225
+ } | {
5226
+ kind: "controls.cancel";
5227
+ } | {
5228
+ kind: "controls.confirm";
5229
+ } | {
5230
+ kind: "controls.decline";
5231
+ } | {
5232
+ kind: "controls.done";
5233
+ } | {
5234
+ kind: "duration.phase";
5235
+ } | {
5236
+ count: number;
5237
+ kind: "duration.rounds";
5238
+ } | {
5239
+ keyword: string;
5240
+ kind: "keyword.name";
5241
+ } | {
5242
+ kind: "keyword.overwhelm";
5243
+ } | {
5244
+ kind: "keyword.raid";
5245
+ } | {
5246
+ kind: "keyword.sentinel";
5247
+ } | {
5248
+ kind: "legacyText";
5249
+ text: string;
5250
+ } | {
5251
+ kind: "targetPurpose.attachUpgrade";
5252
+ } | {
5253
+ kind: "targetPurpose.chooseTarget";
5254
+ } | {
5255
+ amount: number;
5256
+ kind: "targetPurpose.dealDamage";
5257
+ } | {
5258
+ amount: number;
5259
+ kind: "targetPurpose.giveShield";
5260
+ } | {
5261
+ amount: number;
5262
+ kind: "targetPurpose.heal";
5263
+ } | {
5264
+ kind: "timing.onceEachRound";
5265
+ });
4890
5266
  /**
4891
5267
  * One cursor-paginated admin report list page.
4892
5268
  */
@@ -5006,6 +5382,28 @@ export interface StartLobbyRequest {
5006
5382
  export interface StartTournamentEventRequest {
5007
5383
  playerToken: string;
5008
5384
  }
5385
+ /**
5386
+ * Participant-authorized feedback for one completed Solo-versus-AI game.
5387
+ */
5388
+ export interface SubmitAiGameFeedbackRequest {
5389
+ comments?: (string | null);
5390
+ gameNumber: number;
5391
+ /**
5392
+ * @minItems 1
5393
+ */
5394
+ identities: [HistoryIdentityInput, ...(HistoryIdentityInput)[]];
5395
+ rating: AiGameFeedbackRating;
5396
+ }
5397
+ /**
5398
+ * Result of an idempotent AI-game-feedback submission.
5399
+ */
5400
+ export interface SubmitAiGameFeedbackResponse {
5401
+ /**
5402
+ * `false` means this game had already received feedback.
5403
+ */
5404
+ created: boolean;
5405
+ feedback: AiGameFeedback;
5406
+ }
5009
5407
  export interface SubmitLobbyLimitedDeckRequest {
5010
5408
  deck: DeckInput;
5011
5409
  deckId?: (string | null);
@@ -5185,6 +5583,13 @@ export interface TargetSelectionGroup {
5185
5583
  * effect requests targets but has no classifiable structural meaning.
5186
5584
  */
5187
5585
  purpose?: (TargetGroupPurpose | null);
5586
+ /**
5587
+ * Reviewed printed text that produced this exact group.
5588
+ *
5589
+ * References are locale-neutral and preserve nested printed-effect
5590
+ * ownership without placing card prose in public match state.
5591
+ */
5592
+ textReferences?: CardTextRef[];
5188
5593
  validTargets: AbilityTarget[];
5189
5594
  }
5190
5595
  /**
@@ -5254,6 +5659,10 @@ export interface TournamentRoomPlayerView {
5254
5659
  deck?: (LobbyDeckPreview | null);
5255
5660
  deckReady: boolean;
5256
5661
  host: boolean;
5662
+ /**
5663
+ * Whether server automation permanently controls this participant.
5664
+ */
5665
+ isAi?: boolean;
5257
5666
  joinedAtMs: number;
5258
5667
  name: string;
5259
5668
  playerId: string;
@@ -5563,13 +5972,49 @@ export interface UpdateLobbySettingsRequest {
5563
5972
  * Replacement BO1/BO3 length for one-deck Duel lobbies.
5564
5973
  */
5565
5974
  bestOfMatches?: (number | null);
5975
+ /**
5976
+ * Clears the deterministic match seed, restoring random matches.
5977
+ */
5978
+ clearMatchSeed?: boolean;
5979
+ /**
5980
+ * Clears the deterministic Limited pool seed, restoring random pools.
5981
+ */
5982
+ clearPackSeed?: boolean;
5983
+ /**
5984
+ * Replacement Chaos Draft booster sequence.
5985
+ */
5986
+ draftRounds?: (DraftRoundConfig[] | null);
5566
5987
  gameTimerEnabled?: (boolean | null);
5567
5988
  /**
5568
5989
  * Replacement constructed format for one-deck Duel lobbies.
5569
5990
  */
5570
5991
  matchFormat?: (ConstructedFormat | null);
5992
+ /**
5993
+ * Replacement deterministic match seed.
5994
+ */
5995
+ matchSeed?: (string | null);
5996
+ /**
5997
+ * Replacement deterministic Limited pool seed.
5998
+ */
5999
+ packSeed?: (string | null);
6000
+ /**
6001
+ * Enables or disables draft pick auto-selection countdowns.
6002
+ */
6003
+ pickTimerEnabled?: (boolean | null);
5571
6004
  playerCount?: (number | null);
5572
6005
  playerToken: string;
6006
+ /**
6007
+ * Replacement Sealed booster count.
6008
+ */
6009
+ sealedPackCount?: (number | null);
6010
+ /**
6011
+ * Replacement Limited set code for sealed and normal Draft lobbies.
6012
+ */
6013
+ setCode?: (string | null);
6014
+ /**
6015
+ * Replaces timer durations for the final match and Limited event.
6016
+ */
6017
+ timerSettings?: (LobbyTimerSettings | null);
5573
6018
  /**
5574
6019
  * Replacement legality profile for Trilogy lobbies.
5575
6020
  */