@rotesblatt/hex-tractor-data-api 2.2.0 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -4,7 +4,7 @@ exports.api = exports.schemas = void 0;
|
|
|
4
4
|
exports.createApiClient = createApiClient;
|
|
5
5
|
const core_1 = require("@zodios/core");
|
|
6
6
|
const zod_1 = require("zod");
|
|
7
|
-
const
|
|
7
|
+
const LeagueMiniseries = zod_1.z
|
|
8
8
|
.object({
|
|
9
9
|
losses: zod_1.z.number().int(),
|
|
10
10
|
progress: zod_1.z.string(),
|
|
@@ -12,7 +12,7 @@ const league_v4_MiniSeriesDTO = zod_1.z
|
|
|
12
12
|
wins: zod_1.z.number().int(),
|
|
13
13
|
})
|
|
14
14
|
.passthrough();
|
|
15
|
-
const
|
|
15
|
+
const LeagueEntry = zod_1.z
|
|
16
16
|
.object({
|
|
17
17
|
leagueId: zod_1.z.string().optional(),
|
|
18
18
|
puuid: zod_1.z.string(),
|
|
@@ -26,43 +26,43 @@ const league_v4_LeagueEntryDTO = zod_1.z
|
|
|
26
26
|
veteran: zod_1.z.boolean(),
|
|
27
27
|
freshBlood: zod_1.z.boolean(),
|
|
28
28
|
inactive: zod_1.z.boolean(),
|
|
29
|
-
miniSeries:
|
|
29
|
+
miniSeries: LeagueMiniseries.optional(),
|
|
30
30
|
summonerId: zod_1.z.string().optional(),
|
|
31
31
|
})
|
|
32
32
|
.passthrough();
|
|
33
|
-
const
|
|
33
|
+
const SpectatorBannedChampions = zod_1.z
|
|
34
34
|
.object({
|
|
35
35
|
pickTurn: zod_1.z.number().int(),
|
|
36
36
|
championId: zod_1.z.number().int(),
|
|
37
37
|
teamId: zod_1.z.number().int(),
|
|
38
38
|
})
|
|
39
39
|
.passthrough();
|
|
40
|
-
const
|
|
40
|
+
const SpectatorObserver = zod_1.z
|
|
41
41
|
.object({ encryptionKey: zod_1.z.string() })
|
|
42
42
|
.passthrough();
|
|
43
|
-
const
|
|
43
|
+
const SpectatorPerks = zod_1.z
|
|
44
44
|
.object({
|
|
45
45
|
perkIds: zod_1.z.array(zod_1.z.number().int()),
|
|
46
46
|
perkStyle: zod_1.z.number().int(),
|
|
47
47
|
perkSubStyle: zod_1.z.number().int(),
|
|
48
48
|
})
|
|
49
49
|
.passthrough();
|
|
50
|
-
const
|
|
51
|
-
const
|
|
50
|
+
const SpectatorGameCustomizationObject = zod_1.z.object({ category: zod_1.z.string(), content: zod_1.z.string() }).passthrough();
|
|
51
|
+
const SpectatorCurrentGameParticipant = zod_1.z
|
|
52
52
|
.object({
|
|
53
53
|
championId: zod_1.z.number().int(),
|
|
54
|
-
perks:
|
|
54
|
+
perks: SpectatorPerks.optional(),
|
|
55
55
|
profileIconId: zod_1.z.number().int(),
|
|
56
56
|
bot: zod_1.z.boolean(),
|
|
57
57
|
teamId: zod_1.z.number().int(),
|
|
58
58
|
puuid: zod_1.z.string().nullish(),
|
|
59
59
|
spell1Id: zod_1.z.number().int(),
|
|
60
60
|
spell2Id: zod_1.z.number().int(),
|
|
61
|
-
gameCustomizationObjects: zod_1.z.array(
|
|
61
|
+
gameCustomizationObjects: zod_1.z.array(SpectatorGameCustomizationObject),
|
|
62
62
|
riotId: zod_1.z.string().optional(),
|
|
63
63
|
})
|
|
64
64
|
.passthrough();
|
|
65
|
-
const
|
|
65
|
+
const SpectatorCurrentGameInfo = zod_1.z
|
|
66
66
|
.object({
|
|
67
67
|
gameId: zod_1.z.number().int(),
|
|
68
68
|
gameType: zod_1.z.string(),
|
|
@@ -71,10 +71,10 @@ const spectator_v5_CurrentGameInfo = zod_1.z
|
|
|
71
71
|
gameLength: zod_1.z.number().int(),
|
|
72
72
|
platformId: zod_1.z.string(),
|
|
73
73
|
gameMode: zod_1.z.string(),
|
|
74
|
-
bannedChampions: zod_1.z.array(
|
|
74
|
+
bannedChampions: zod_1.z.array(SpectatorBannedChampions),
|
|
75
75
|
gameQueueConfigId: zod_1.z.number().int().optional(),
|
|
76
|
-
observers:
|
|
77
|
-
participants: zod_1.z.array(
|
|
76
|
+
observers: SpectatorObserver,
|
|
77
|
+
participants: zod_1.z.array(SpectatorCurrentGameParticipant),
|
|
78
78
|
})
|
|
79
79
|
.passthrough();
|
|
80
80
|
const AccountInfo = zod_1.z
|
|
@@ -90,8 +90,8 @@ const AccountInfo = zod_1.z
|
|
|
90
90
|
lastUpdated: zod_1.z.string(),
|
|
91
91
|
})
|
|
92
92
|
.passthrough(),
|
|
93
|
-
leagueEntries: zod_1.z.array(
|
|
94
|
-
currentGame:
|
|
93
|
+
leagueEntries: zod_1.z.array(LeagueEntry),
|
|
94
|
+
currentGame: SpectatorCurrentGameInfo.optional(),
|
|
95
95
|
})
|
|
96
96
|
.passthrough();
|
|
97
97
|
const validationError = zod_1.z
|
|
@@ -111,11 +111,11 @@ const validationError = zod_1.z
|
|
|
111
111
|
.passthrough();
|
|
112
112
|
const simpleError = zod_1.z.object({ message: zod_1.z.string() }).passthrough();
|
|
113
113
|
const simpleInternalError = zod_1.z.object({ message: zod_1.z.string() }).passthrough();
|
|
114
|
-
const
|
|
114
|
+
const LeagueItem = zod_1.z
|
|
115
115
|
.object({
|
|
116
116
|
freshBlood: zod_1.z.boolean(),
|
|
117
117
|
wins: zod_1.z.number().int(),
|
|
118
|
-
miniSeries:
|
|
118
|
+
miniSeries: LeagueMiniseries.optional(),
|
|
119
119
|
inactive: zod_1.z.boolean(),
|
|
120
120
|
veteran: zod_1.z.boolean(),
|
|
121
121
|
hotStreak: zod_1.z.boolean(),
|
|
@@ -133,17 +133,17 @@ const LeagueDetails = zod_1.z
|
|
|
133
133
|
division: zod_1.z.string(),
|
|
134
134
|
name: zod_1.z.string().optional(),
|
|
135
135
|
lastUpdated: zod_1.z.string(),
|
|
136
|
-
entries: zod_1.z.array(
|
|
136
|
+
entries: zod_1.z.array(LeagueItem),
|
|
137
137
|
})
|
|
138
138
|
.passthrough();
|
|
139
|
-
const
|
|
139
|
+
const MatchMetadata = zod_1.z
|
|
140
140
|
.object({
|
|
141
141
|
dataVersion: zod_1.z.string(),
|
|
142
142
|
matchId: zod_1.z.string(),
|
|
143
143
|
participants: zod_1.z.array(zod_1.z.string()),
|
|
144
144
|
})
|
|
145
145
|
.passthrough();
|
|
146
|
-
const
|
|
146
|
+
const MatchChallenges = zod_1.z
|
|
147
147
|
.object({
|
|
148
148
|
"12AssistStreakCount": zod_1.z.number().int(),
|
|
149
149
|
baronBuffGoldAdvantageOverThreshold: zod_1.z.number().int(),
|
|
@@ -295,7 +295,7 @@ const match_v5_ChallengesDto = zod_1.z
|
|
|
295
295
|
})
|
|
296
296
|
.partial()
|
|
297
297
|
.passthrough();
|
|
298
|
-
const
|
|
298
|
+
const MatchMissions = zod_1.z
|
|
299
299
|
.object({
|
|
300
300
|
playerScore0: zod_1.z.number(),
|
|
301
301
|
playerScore1: zod_1.z.number(),
|
|
@@ -312,14 +312,14 @@ const match_v5_MissionsDto = zod_1.z
|
|
|
312
312
|
})
|
|
313
313
|
.partial()
|
|
314
314
|
.passthrough();
|
|
315
|
-
const
|
|
315
|
+
const MatchPerkStats = zod_1.z
|
|
316
316
|
.object({
|
|
317
317
|
defense: zod_1.z.number().int(),
|
|
318
318
|
flex: zod_1.z.number().int(),
|
|
319
319
|
offense: zod_1.z.number().int(),
|
|
320
320
|
})
|
|
321
321
|
.passthrough();
|
|
322
|
-
const
|
|
322
|
+
const MatchPerkStyleSelection = zod_1.z
|
|
323
323
|
.object({
|
|
324
324
|
perk: zod_1.z.number().int(),
|
|
325
325
|
var1: zod_1.z.number().int(),
|
|
@@ -327,20 +327,17 @@ const match_v5_PerkStyleSelectionDto = zod_1.z
|
|
|
327
327
|
var3: zod_1.z.number().int(),
|
|
328
328
|
})
|
|
329
329
|
.passthrough();
|
|
330
|
-
const
|
|
330
|
+
const MatchPerkStyle = zod_1.z
|
|
331
331
|
.object({
|
|
332
332
|
description: zod_1.z.string(),
|
|
333
|
-
selections: zod_1.z.array(
|
|
333
|
+
selections: zod_1.z.array(MatchPerkStyleSelection),
|
|
334
334
|
style: zod_1.z.number().int(),
|
|
335
335
|
})
|
|
336
336
|
.passthrough();
|
|
337
|
-
const
|
|
338
|
-
.object({
|
|
339
|
-
statPerks: match_v5_PerkStatsDto,
|
|
340
|
-
styles: zod_1.z.array(match_v5_PerkStyleDto),
|
|
341
|
-
})
|
|
337
|
+
const MatchPerks = zod_1.z
|
|
338
|
+
.object({ statPerks: MatchPerkStats, styles: zod_1.z.array(MatchPerkStyle) })
|
|
342
339
|
.passthrough();
|
|
343
|
-
const
|
|
340
|
+
const MatchParticipant = zod_1.z
|
|
344
341
|
.object({
|
|
345
342
|
allInPings: zod_1.z.number().int().optional(),
|
|
346
343
|
assistMePings: zod_1.z.number().int().optional(),
|
|
@@ -354,7 +351,7 @@ const match_v5_ParticipantDto = zod_1.z
|
|
|
354
351
|
commandPings: zod_1.z.number().int().optional(),
|
|
355
352
|
championTransform: zod_1.z.number().int(),
|
|
356
353
|
consumablesPurchased: zod_1.z.number().int(),
|
|
357
|
-
challenges:
|
|
354
|
+
challenges: MatchChallenges.optional(),
|
|
358
355
|
damageDealtToBuildings: zod_1.z.number().int().optional(),
|
|
359
356
|
damageDealtToObjectives: zod_1.z.number().int(),
|
|
360
357
|
damageDealtToTurrets: zod_1.z.number().int(),
|
|
@@ -398,7 +395,7 @@ const match_v5_ParticipantDto = zod_1.z
|
|
|
398
395
|
magicDamageDealt: zod_1.z.number().int(),
|
|
399
396
|
magicDamageDealtToChampions: zod_1.z.number().int(),
|
|
400
397
|
magicDamageTaken: zod_1.z.number().int(),
|
|
401
|
-
missions:
|
|
398
|
+
missions: MatchMissions.optional(),
|
|
402
399
|
neutralMinionsKilled: zod_1.z.number().int(),
|
|
403
400
|
needVisionPings: zod_1.z.number().int().optional(),
|
|
404
401
|
nexusKills: zod_1.z.number().int(),
|
|
@@ -421,7 +418,7 @@ const match_v5_ParticipantDto = zod_1.z
|
|
|
421
418
|
playerScore10: zod_1.z.number().optional(),
|
|
422
419
|
playerScore11: zod_1.z.number().optional(),
|
|
423
420
|
pentaKills: zod_1.z.number().int(),
|
|
424
|
-
perks:
|
|
421
|
+
perks: MatchPerks,
|
|
425
422
|
physicalDamageDealt: zod_1.z.number().int(),
|
|
426
423
|
physicalDamageDealtToChampions: zod_1.z.number().int(),
|
|
427
424
|
physicalDamageTaken: zod_1.z.number().int(),
|
|
@@ -492,46 +489,147 @@ const match_v5_ParticipantDto = zod_1.z
|
|
|
492
489
|
championSkinId: zod_1.z.number().int().optional(),
|
|
493
490
|
})
|
|
494
491
|
.passthrough();
|
|
495
|
-
const
|
|
492
|
+
const QueueId = zod_1.z.union([
|
|
493
|
+
zod_1.z.literal(0),
|
|
494
|
+
zod_1.z.literal(2),
|
|
495
|
+
zod_1.z.literal(4),
|
|
496
|
+
zod_1.z.literal(6),
|
|
497
|
+
zod_1.z.literal(7),
|
|
498
|
+
zod_1.z.literal(8),
|
|
499
|
+
zod_1.z.literal(9),
|
|
500
|
+
zod_1.z.literal(14),
|
|
501
|
+
zod_1.z.literal(16),
|
|
502
|
+
zod_1.z.literal(17),
|
|
503
|
+
zod_1.z.literal(25),
|
|
504
|
+
zod_1.z.literal(31),
|
|
505
|
+
zod_1.z.literal(32),
|
|
506
|
+
zod_1.z.literal(33),
|
|
507
|
+
zod_1.z.literal(41),
|
|
508
|
+
zod_1.z.literal(42),
|
|
509
|
+
zod_1.z.literal(52),
|
|
510
|
+
zod_1.z.literal(61),
|
|
511
|
+
zod_1.z.literal(65),
|
|
512
|
+
zod_1.z.literal(67),
|
|
513
|
+
zod_1.z.literal(70),
|
|
514
|
+
zod_1.z.literal(72),
|
|
515
|
+
zod_1.z.literal(73),
|
|
516
|
+
zod_1.z.literal(75),
|
|
517
|
+
zod_1.z.literal(76),
|
|
518
|
+
zod_1.z.literal(78),
|
|
519
|
+
zod_1.z.literal(83),
|
|
520
|
+
zod_1.z.literal(91),
|
|
521
|
+
zod_1.z.literal(92),
|
|
522
|
+
zod_1.z.literal(93),
|
|
523
|
+
zod_1.z.literal(96),
|
|
524
|
+
zod_1.z.literal(98),
|
|
525
|
+
zod_1.z.literal(100),
|
|
526
|
+
zod_1.z.literal(300),
|
|
527
|
+
zod_1.z.literal(310),
|
|
528
|
+
zod_1.z.literal(313),
|
|
529
|
+
zod_1.z.literal(315),
|
|
530
|
+
zod_1.z.literal(317),
|
|
531
|
+
zod_1.z.literal(318),
|
|
532
|
+
zod_1.z.literal(325),
|
|
533
|
+
zod_1.z.literal(400),
|
|
534
|
+
zod_1.z.literal(410),
|
|
535
|
+
zod_1.z.literal(420),
|
|
536
|
+
zod_1.z.literal(430),
|
|
537
|
+
zod_1.z.literal(440),
|
|
538
|
+
zod_1.z.literal(450),
|
|
539
|
+
zod_1.z.literal(460),
|
|
540
|
+
zod_1.z.literal(470),
|
|
541
|
+
zod_1.z.literal(480),
|
|
542
|
+
zod_1.z.literal(490),
|
|
543
|
+
zod_1.z.literal(600),
|
|
544
|
+
zod_1.z.literal(610),
|
|
545
|
+
zod_1.z.literal(700),
|
|
546
|
+
zod_1.z.literal(720),
|
|
547
|
+
zod_1.z.literal(800),
|
|
548
|
+
zod_1.z.literal(810),
|
|
549
|
+
zod_1.z.literal(820),
|
|
550
|
+
zod_1.z.literal(830),
|
|
551
|
+
zod_1.z.literal(840),
|
|
552
|
+
zod_1.z.literal(850),
|
|
553
|
+
zod_1.z.literal(870),
|
|
554
|
+
zod_1.z.literal(880),
|
|
555
|
+
zod_1.z.literal(890),
|
|
556
|
+
zod_1.z.literal(900),
|
|
557
|
+
zod_1.z.literal(910),
|
|
558
|
+
zod_1.z.literal(920),
|
|
559
|
+
zod_1.z.literal(940),
|
|
560
|
+
zod_1.z.literal(950),
|
|
561
|
+
zod_1.z.literal(960),
|
|
562
|
+
zod_1.z.literal(980),
|
|
563
|
+
zod_1.z.literal(990),
|
|
564
|
+
zod_1.z.literal(1000),
|
|
565
|
+
zod_1.z.literal(1010),
|
|
566
|
+
zod_1.z.literal(1020),
|
|
567
|
+
zod_1.z.literal(1030),
|
|
568
|
+
zod_1.z.literal(1040),
|
|
569
|
+
zod_1.z.literal(1050),
|
|
570
|
+
zod_1.z.literal(1060),
|
|
571
|
+
zod_1.z.literal(1070),
|
|
572
|
+
zod_1.z.literal(1090),
|
|
573
|
+
zod_1.z.literal(1100),
|
|
574
|
+
zod_1.z.literal(1110),
|
|
575
|
+
zod_1.z.literal(1111),
|
|
576
|
+
zod_1.z.literal(1200),
|
|
577
|
+
zod_1.z.literal(1210),
|
|
578
|
+
zod_1.z.literal(1300),
|
|
579
|
+
zod_1.z.literal(1400),
|
|
580
|
+
zod_1.z.literal(1700),
|
|
581
|
+
zod_1.z.literal(1710),
|
|
582
|
+
zod_1.z.literal(1810),
|
|
583
|
+
zod_1.z.literal(1820),
|
|
584
|
+
zod_1.z.literal(1830),
|
|
585
|
+
zod_1.z.literal(1840),
|
|
586
|
+
zod_1.z.literal(1900),
|
|
587
|
+
zod_1.z.literal(2000),
|
|
588
|
+
zod_1.z.literal(2010),
|
|
589
|
+
zod_1.z.literal(2020),
|
|
590
|
+
zod_1.z.literal(2300),
|
|
591
|
+
zod_1.z.literal(2400),
|
|
592
|
+
]);
|
|
593
|
+
const MatchBan = zod_1.z
|
|
496
594
|
.object({ championId: zod_1.z.number().int(), pickTurn: zod_1.z.number().int() })
|
|
497
595
|
.passthrough();
|
|
498
|
-
const
|
|
596
|
+
const MatchObjective = zod_1.z
|
|
499
597
|
.object({ first: zod_1.z.boolean(), kills: zod_1.z.number().int() })
|
|
500
598
|
.passthrough();
|
|
501
|
-
const
|
|
599
|
+
const MatchObjectives = zod_1.z
|
|
502
600
|
.object({
|
|
503
|
-
baron:
|
|
504
|
-
champion:
|
|
505
|
-
dragon:
|
|
506
|
-
horde:
|
|
507
|
-
inhibitor:
|
|
508
|
-
riftHerald:
|
|
509
|
-
tower:
|
|
510
|
-
atakhan:
|
|
601
|
+
baron: MatchObjective,
|
|
602
|
+
champion: MatchObjective,
|
|
603
|
+
dragon: MatchObjective,
|
|
604
|
+
horde: MatchObjective.optional(),
|
|
605
|
+
inhibitor: MatchObjective,
|
|
606
|
+
riftHerald: MatchObjective,
|
|
607
|
+
tower: MatchObjective,
|
|
608
|
+
atakhan: MatchObjective.optional(),
|
|
511
609
|
})
|
|
512
610
|
.passthrough();
|
|
513
|
-
const
|
|
611
|
+
const MatchFeat = zod_1.z
|
|
514
612
|
.object({ featState: zod_1.z.number().int() })
|
|
515
613
|
.partial()
|
|
516
614
|
.passthrough();
|
|
517
|
-
const
|
|
615
|
+
const MatchFeats = zod_1.z
|
|
518
616
|
.object({
|
|
519
|
-
EPIC_MONSTER_KILL:
|
|
520
|
-
FIRST_BLOOD:
|
|
521
|
-
FIRST_TURRET:
|
|
617
|
+
EPIC_MONSTER_KILL: MatchFeat,
|
|
618
|
+
FIRST_BLOOD: MatchFeat,
|
|
619
|
+
FIRST_TURRET: MatchFeat,
|
|
522
620
|
})
|
|
523
621
|
.partial()
|
|
524
622
|
.passthrough();
|
|
525
|
-
const
|
|
623
|
+
const MatchTeam = zod_1.z
|
|
526
624
|
.object({
|
|
527
|
-
bans: zod_1.z.array(
|
|
528
|
-
objectives:
|
|
625
|
+
bans: zod_1.z.array(MatchBan),
|
|
626
|
+
objectives: MatchObjectives,
|
|
529
627
|
teamId: zod_1.z.number().int(),
|
|
530
628
|
win: zod_1.z.boolean(),
|
|
531
|
-
feats:
|
|
629
|
+
feats: MatchFeats.optional(),
|
|
532
630
|
})
|
|
533
631
|
.passthrough();
|
|
534
|
-
const
|
|
632
|
+
const MatchInfo = zod_1.z
|
|
535
633
|
.object({
|
|
536
634
|
endOfGameResult: zod_1.z.string().optional(),
|
|
537
635
|
gameCreation: zod_1.z.number().int(),
|
|
@@ -544,58 +642,91 @@ const match_v5_InfoDto = zod_1.z
|
|
|
544
642
|
gameType: zod_1.z.string(),
|
|
545
643
|
gameVersion: zod_1.z.string(),
|
|
546
644
|
mapId: zod_1.z.number().int(),
|
|
547
|
-
participants: zod_1.z.array(
|
|
645
|
+
participants: zod_1.z.array(MatchParticipant),
|
|
548
646
|
platformId: zod_1.z.string(),
|
|
549
|
-
queueId:
|
|
550
|
-
teams: zod_1.z.array(
|
|
647
|
+
queueId: QueueId,
|
|
648
|
+
teams: zod_1.z.array(MatchTeam),
|
|
551
649
|
tournamentCode: zod_1.z.string().optional(),
|
|
552
650
|
gameModeMutators: zod_1.z.array(zod_1.z.string()).optional(),
|
|
553
651
|
})
|
|
554
652
|
.passthrough();
|
|
555
|
-
const
|
|
556
|
-
.object({ metadata:
|
|
557
|
-
.passthrough();
|
|
558
|
-
const league_v4_LeagueListDTO = zod_1.z
|
|
559
|
-
.object({
|
|
560
|
-
leagueId: zod_1.z.string().optional(),
|
|
561
|
-
entries: zod_1.z.array(league_v4_LeagueItemDTO),
|
|
562
|
-
tier: zod_1.z.string(),
|
|
563
|
-
name: zod_1.z.string().optional(),
|
|
564
|
-
queue: zod_1.z.string(),
|
|
565
|
-
})
|
|
653
|
+
const Match = zod_1.z
|
|
654
|
+
.object({ metadata: MatchMetadata, info: MatchInfo })
|
|
566
655
|
.passthrough();
|
|
656
|
+
const Region = zod_1.z.enum([
|
|
657
|
+
"br1",
|
|
658
|
+
"euw1",
|
|
659
|
+
"na1",
|
|
660
|
+
"eun1",
|
|
661
|
+
"kr",
|
|
662
|
+
"jp1",
|
|
663
|
+
"la1",
|
|
664
|
+
"la2",
|
|
665
|
+
"oc1",
|
|
666
|
+
"tr1",
|
|
667
|
+
"ru",
|
|
668
|
+
"ph2",
|
|
669
|
+
"sg2",
|
|
670
|
+
"th2",
|
|
671
|
+
"tw2",
|
|
672
|
+
"vn2",
|
|
673
|
+
]);
|
|
674
|
+
const Platform = zod_1.z.enum(["europe", "americas", "asia", "sea"]);
|
|
675
|
+
const RankedQueue = zod_1.z.enum([
|
|
676
|
+
"RANKED_SOLO_5x5",
|
|
677
|
+
"RANKED_FLEX_SR",
|
|
678
|
+
"RANKED_FLEX_TT",
|
|
679
|
+
]);
|
|
680
|
+
const RankedTier = zod_1.z.enum([
|
|
681
|
+
"IRON",
|
|
682
|
+
"BRONZE",
|
|
683
|
+
"SILVER",
|
|
684
|
+
"GOLD",
|
|
685
|
+
"PLATINUM",
|
|
686
|
+
"EMERALD",
|
|
687
|
+
"DIAMOND",
|
|
688
|
+
"MASTER",
|
|
689
|
+
"GRANDMASTER",
|
|
690
|
+
"CHALLENGER",
|
|
691
|
+
]);
|
|
692
|
+
const RankedDivision = zod_1.z.enum(["I", "II", "III", "IV"]);
|
|
567
693
|
exports.schemas = {
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
694
|
+
LeagueMiniseries,
|
|
695
|
+
LeagueEntry,
|
|
696
|
+
SpectatorBannedChampions,
|
|
697
|
+
SpectatorObserver,
|
|
698
|
+
SpectatorPerks,
|
|
699
|
+
SpectatorGameCustomizationObject,
|
|
700
|
+
SpectatorCurrentGameParticipant,
|
|
701
|
+
SpectatorCurrentGameInfo,
|
|
576
702
|
AccountInfo,
|
|
577
703
|
validationError,
|
|
578
704
|
simpleError,
|
|
579
705
|
simpleInternalError,
|
|
580
|
-
|
|
706
|
+
LeagueItem,
|
|
581
707
|
LeagueDetails,
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
708
|
+
MatchMetadata,
|
|
709
|
+
MatchChallenges,
|
|
710
|
+
MatchMissions,
|
|
711
|
+
MatchPerkStats,
|
|
712
|
+
MatchPerkStyleSelection,
|
|
713
|
+
MatchPerkStyle,
|
|
714
|
+
MatchPerks,
|
|
715
|
+
MatchParticipant,
|
|
716
|
+
QueueId,
|
|
717
|
+
MatchBan,
|
|
718
|
+
MatchObjective,
|
|
719
|
+
MatchObjectives,
|
|
720
|
+
MatchFeat,
|
|
721
|
+
MatchFeats,
|
|
722
|
+
MatchTeam,
|
|
723
|
+
MatchInfo,
|
|
724
|
+
Match,
|
|
725
|
+
Region,
|
|
726
|
+
Platform,
|
|
727
|
+
RankedQueue,
|
|
728
|
+
RankedTier,
|
|
729
|
+
RankedDivision,
|
|
599
730
|
};
|
|
600
731
|
const endpoints = (0, core_1.makeApi)([
|
|
601
732
|
{
|
|
@@ -608,7 +739,24 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
608
739
|
{
|
|
609
740
|
name: "region",
|
|
610
741
|
type: "Path",
|
|
611
|
-
schema: zod_1.z.
|
|
742
|
+
schema: zod_1.z.enum([
|
|
743
|
+
"br1",
|
|
744
|
+
"euw1",
|
|
745
|
+
"na1",
|
|
746
|
+
"eun1",
|
|
747
|
+
"kr",
|
|
748
|
+
"jp1",
|
|
749
|
+
"la1",
|
|
750
|
+
"la2",
|
|
751
|
+
"oc1",
|
|
752
|
+
"tr1",
|
|
753
|
+
"ru",
|
|
754
|
+
"ph2",
|
|
755
|
+
"sg2",
|
|
756
|
+
"th2",
|
|
757
|
+
"tw2",
|
|
758
|
+
"vn2",
|
|
759
|
+
]),
|
|
612
760
|
},
|
|
613
761
|
{
|
|
614
762
|
name: "puuid",
|
|
@@ -645,7 +793,24 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
645
793
|
{
|
|
646
794
|
name: "region",
|
|
647
795
|
type: "Path",
|
|
648
|
-
schema: zod_1.z.
|
|
796
|
+
schema: zod_1.z.enum([
|
|
797
|
+
"br1",
|
|
798
|
+
"euw1",
|
|
799
|
+
"na1",
|
|
800
|
+
"eun1",
|
|
801
|
+
"kr",
|
|
802
|
+
"jp1",
|
|
803
|
+
"la1",
|
|
804
|
+
"la2",
|
|
805
|
+
"oc1",
|
|
806
|
+
"tr1",
|
|
807
|
+
"ru",
|
|
808
|
+
"ph2",
|
|
809
|
+
"sg2",
|
|
810
|
+
"th2",
|
|
811
|
+
"tw2",
|
|
812
|
+
"vn2",
|
|
813
|
+
]),
|
|
649
814
|
},
|
|
650
815
|
{
|
|
651
816
|
name: "summonerName",
|
|
@@ -687,22 +852,50 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
687
852
|
{
|
|
688
853
|
name: "region",
|
|
689
854
|
type: "Path",
|
|
690
|
-
schema: zod_1.z.
|
|
855
|
+
schema: zod_1.z.enum([
|
|
856
|
+
"br1",
|
|
857
|
+
"euw1",
|
|
858
|
+
"na1",
|
|
859
|
+
"eun1",
|
|
860
|
+
"kr",
|
|
861
|
+
"jp1",
|
|
862
|
+
"la1",
|
|
863
|
+
"la2",
|
|
864
|
+
"oc1",
|
|
865
|
+
"tr1",
|
|
866
|
+
"ru",
|
|
867
|
+
"ph2",
|
|
868
|
+
"sg2",
|
|
869
|
+
"th2",
|
|
870
|
+
"tw2",
|
|
871
|
+
"vn2",
|
|
872
|
+
]),
|
|
691
873
|
},
|
|
692
874
|
{
|
|
693
875
|
name: "queue",
|
|
694
876
|
type: "Path",
|
|
695
|
-
schema: zod_1.z.
|
|
877
|
+
schema: zod_1.z.enum(["RANKED_SOLO_5x5", "RANKED_FLEX_SR", "RANKED_FLEX_TT"]),
|
|
696
878
|
},
|
|
697
879
|
{
|
|
698
880
|
name: "tier",
|
|
699
881
|
type: "Path",
|
|
700
|
-
schema: zod_1.z.
|
|
882
|
+
schema: zod_1.z.enum([
|
|
883
|
+
"IRON",
|
|
884
|
+
"BRONZE",
|
|
885
|
+
"SILVER",
|
|
886
|
+
"GOLD",
|
|
887
|
+
"PLATINUM",
|
|
888
|
+
"EMERALD",
|
|
889
|
+
"DIAMOND",
|
|
890
|
+
"MASTER",
|
|
891
|
+
"GRANDMASTER",
|
|
892
|
+
"CHALLENGER",
|
|
893
|
+
]),
|
|
701
894
|
},
|
|
702
895
|
{
|
|
703
896
|
name: "division",
|
|
704
897
|
type: "Path",
|
|
705
|
-
schema: zod_1.z.
|
|
898
|
+
schema: zod_1.z.enum(["I", "II", "III", "IV"]),
|
|
706
899
|
},
|
|
707
900
|
{
|
|
708
901
|
name: "count",
|
|
@@ -734,7 +927,7 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
734
927
|
{
|
|
735
928
|
name: "region",
|
|
736
929
|
type: "Path",
|
|
737
|
-
schema: zod_1.z.
|
|
930
|
+
schema: zod_1.z.enum(["europe", "americas", "asia", "sea"]),
|
|
738
931
|
},
|
|
739
932
|
{
|
|
740
933
|
name: "puuid",
|
|
@@ -754,10 +947,112 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
754
947
|
{
|
|
755
948
|
name: "queueId",
|
|
756
949
|
type: "Query",
|
|
757
|
-
schema: zod_1.z
|
|
950
|
+
schema: zod_1.z
|
|
951
|
+
.union([
|
|
952
|
+
zod_1.z.literal(0),
|
|
953
|
+
zod_1.z.literal(2),
|
|
954
|
+
zod_1.z.literal(4),
|
|
955
|
+
zod_1.z.literal(6),
|
|
956
|
+
zod_1.z.literal(7),
|
|
957
|
+
zod_1.z.literal(8),
|
|
958
|
+
zod_1.z.literal(9),
|
|
959
|
+
zod_1.z.literal(14),
|
|
960
|
+
zod_1.z.literal(16),
|
|
961
|
+
zod_1.z.literal(17),
|
|
962
|
+
zod_1.z.literal(25),
|
|
963
|
+
zod_1.z.literal(31),
|
|
964
|
+
zod_1.z.literal(32),
|
|
965
|
+
zod_1.z.literal(33),
|
|
966
|
+
zod_1.z.literal(41),
|
|
967
|
+
zod_1.z.literal(42),
|
|
968
|
+
zod_1.z.literal(52),
|
|
969
|
+
zod_1.z.literal(61),
|
|
970
|
+
zod_1.z.literal(65),
|
|
971
|
+
zod_1.z.literal(67),
|
|
972
|
+
zod_1.z.literal(70),
|
|
973
|
+
zod_1.z.literal(72),
|
|
974
|
+
zod_1.z.literal(73),
|
|
975
|
+
zod_1.z.literal(75),
|
|
976
|
+
zod_1.z.literal(76),
|
|
977
|
+
zod_1.z.literal(78),
|
|
978
|
+
zod_1.z.literal(83),
|
|
979
|
+
zod_1.z.literal(91),
|
|
980
|
+
zod_1.z.literal(92),
|
|
981
|
+
zod_1.z.literal(93),
|
|
982
|
+
zod_1.z.literal(96),
|
|
983
|
+
zod_1.z.literal(98),
|
|
984
|
+
zod_1.z.literal(100),
|
|
985
|
+
zod_1.z.literal(300),
|
|
986
|
+
zod_1.z.literal(310),
|
|
987
|
+
zod_1.z.literal(313),
|
|
988
|
+
zod_1.z.literal(315),
|
|
989
|
+
zod_1.z.literal(317),
|
|
990
|
+
zod_1.z.literal(318),
|
|
991
|
+
zod_1.z.literal(325),
|
|
992
|
+
zod_1.z.literal(400),
|
|
993
|
+
zod_1.z.literal(410),
|
|
994
|
+
zod_1.z.literal(420),
|
|
995
|
+
zod_1.z.literal(430),
|
|
996
|
+
zod_1.z.literal(440),
|
|
997
|
+
zod_1.z.literal(450),
|
|
998
|
+
zod_1.z.literal(460),
|
|
999
|
+
zod_1.z.literal(470),
|
|
1000
|
+
zod_1.z.literal(480),
|
|
1001
|
+
zod_1.z.literal(490),
|
|
1002
|
+
zod_1.z.literal(600),
|
|
1003
|
+
zod_1.z.literal(610),
|
|
1004
|
+
zod_1.z.literal(700),
|
|
1005
|
+
zod_1.z.literal(720),
|
|
1006
|
+
zod_1.z.literal(800),
|
|
1007
|
+
zod_1.z.literal(810),
|
|
1008
|
+
zod_1.z.literal(820),
|
|
1009
|
+
zod_1.z.literal(830),
|
|
1010
|
+
zod_1.z.literal(840),
|
|
1011
|
+
zod_1.z.literal(850),
|
|
1012
|
+
zod_1.z.literal(870),
|
|
1013
|
+
zod_1.z.literal(880),
|
|
1014
|
+
zod_1.z.literal(890),
|
|
1015
|
+
zod_1.z.literal(900),
|
|
1016
|
+
zod_1.z.literal(910),
|
|
1017
|
+
zod_1.z.literal(920),
|
|
1018
|
+
zod_1.z.literal(940),
|
|
1019
|
+
zod_1.z.literal(950),
|
|
1020
|
+
zod_1.z.literal(960),
|
|
1021
|
+
zod_1.z.literal(980),
|
|
1022
|
+
zod_1.z.literal(990),
|
|
1023
|
+
zod_1.z.literal(1000),
|
|
1024
|
+
zod_1.z.literal(1010),
|
|
1025
|
+
zod_1.z.literal(1020),
|
|
1026
|
+
zod_1.z.literal(1030),
|
|
1027
|
+
zod_1.z.literal(1040),
|
|
1028
|
+
zod_1.z.literal(1050),
|
|
1029
|
+
zod_1.z.literal(1060),
|
|
1030
|
+
zod_1.z.literal(1070),
|
|
1031
|
+
zod_1.z.literal(1090),
|
|
1032
|
+
zod_1.z.literal(1100),
|
|
1033
|
+
zod_1.z.literal(1110),
|
|
1034
|
+
zod_1.z.literal(1111),
|
|
1035
|
+
zod_1.z.literal(1200),
|
|
1036
|
+
zod_1.z.literal(1210),
|
|
1037
|
+
zod_1.z.literal(1300),
|
|
1038
|
+
zod_1.z.literal(1400),
|
|
1039
|
+
zod_1.z.literal(1700),
|
|
1040
|
+
zod_1.z.literal(1710),
|
|
1041
|
+
zod_1.z.literal(1810),
|
|
1042
|
+
zod_1.z.literal(1820),
|
|
1043
|
+
zod_1.z.literal(1830),
|
|
1044
|
+
zod_1.z.literal(1840),
|
|
1045
|
+
zod_1.z.literal(1900),
|
|
1046
|
+
zod_1.z.literal(2000),
|
|
1047
|
+
zod_1.z.literal(2010),
|
|
1048
|
+
zod_1.z.literal(2020),
|
|
1049
|
+
zod_1.z.literal(2300),
|
|
1050
|
+
zod_1.z.literal(2400),
|
|
1051
|
+
])
|
|
1052
|
+
.optional(),
|
|
758
1053
|
},
|
|
759
1054
|
],
|
|
760
|
-
response: zod_1.z.array(
|
|
1055
|
+
response: zod_1.z.array(Match),
|
|
761
1056
|
errors: [
|
|
762
1057
|
{
|
|
763
1058
|
status: 400,
|
|
@@ -786,7 +1081,7 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
786
1081
|
{
|
|
787
1082
|
name: "region",
|
|
788
1083
|
type: "Path",
|
|
789
|
-
schema: zod_1.z.
|
|
1084
|
+
schema: zod_1.z.enum(["europe", "americas", "asia", "sea"]),
|
|
790
1085
|
},
|
|
791
1086
|
{
|
|
792
1087
|
name: "puuid",
|
|
@@ -833,7 +1128,7 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
833
1128
|
{
|
|
834
1129
|
name: "region",
|
|
835
1130
|
type: "Path",
|
|
836
|
-
schema: zod_1.z.
|
|
1131
|
+
schema: zod_1.z.enum(["europe", "americas", "asia", "sea"]),
|
|
837
1132
|
},
|
|
838
1133
|
{
|
|
839
1134
|
name: "matchId",
|
|
@@ -841,7 +1136,7 @@ const endpoints = (0, core_1.makeApi)([
|
|
|
841
1136
|
schema: zod_1.z.string(),
|
|
842
1137
|
},
|
|
843
1138
|
],
|
|
844
|
-
response:
|
|
1139
|
+
response: Match,
|
|
845
1140
|
errors: [
|
|
846
1141
|
{
|
|
847
1142
|
status: 400,
|