pitchapi 0.1.1
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/LICENSE +21 -0
- package/README.md +123 -0
- package/dist/index.cjs +397 -0
- package/dist/index.d.cts +2021 -0
- package/dist/index.d.ts +2021 -0
- package/dist/index.js +360 -0
- package/package.json +59 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,2021 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was auto-generated by openapi-typescript.
|
|
3
|
+
* Do not make direct changes to the file.
|
|
4
|
+
*/
|
|
5
|
+
interface paths {
|
|
6
|
+
"/date/{date}": {
|
|
7
|
+
parameters: {
|
|
8
|
+
query?: never;
|
|
9
|
+
header?: never;
|
|
10
|
+
path?: never;
|
|
11
|
+
cookie?: never;
|
|
12
|
+
};
|
|
13
|
+
/** All matches on a given day */
|
|
14
|
+
get: operations["getMatchesByDate"];
|
|
15
|
+
put?: never;
|
|
16
|
+
post?: never;
|
|
17
|
+
delete?: never;
|
|
18
|
+
options?: never;
|
|
19
|
+
head?: never;
|
|
20
|
+
patch?: never;
|
|
21
|
+
trace?: never;
|
|
22
|
+
};
|
|
23
|
+
"/matches/{id}": {
|
|
24
|
+
parameters: {
|
|
25
|
+
query?: never;
|
|
26
|
+
header?: never;
|
|
27
|
+
path?: never;
|
|
28
|
+
cookie?: never;
|
|
29
|
+
};
|
|
30
|
+
/** Match summary */
|
|
31
|
+
get: operations["getMatch"];
|
|
32
|
+
put?: never;
|
|
33
|
+
post?: never;
|
|
34
|
+
delete?: never;
|
|
35
|
+
options?: never;
|
|
36
|
+
head?: never;
|
|
37
|
+
patch?: never;
|
|
38
|
+
trace?: never;
|
|
39
|
+
};
|
|
40
|
+
"/matches/{id}/shots": {
|
|
41
|
+
parameters: {
|
|
42
|
+
query?: never;
|
|
43
|
+
header?: never;
|
|
44
|
+
path?: never;
|
|
45
|
+
cookie?: never;
|
|
46
|
+
};
|
|
47
|
+
/** Every shot with pitch coordinates and xG */
|
|
48
|
+
get: operations["getMatchShots"];
|
|
49
|
+
put?: never;
|
|
50
|
+
post?: never;
|
|
51
|
+
delete?: never;
|
|
52
|
+
options?: never;
|
|
53
|
+
head?: never;
|
|
54
|
+
patch?: never;
|
|
55
|
+
trace?: never;
|
|
56
|
+
};
|
|
57
|
+
"/matches/{id}/shots/{sid}": {
|
|
58
|
+
parameters: {
|
|
59
|
+
query?: never;
|
|
60
|
+
header?: never;
|
|
61
|
+
path?: never;
|
|
62
|
+
cookie?: never;
|
|
63
|
+
};
|
|
64
|
+
/** A single shot */
|
|
65
|
+
get: operations["getShot"];
|
|
66
|
+
put?: never;
|
|
67
|
+
post?: never;
|
|
68
|
+
delete?: never;
|
|
69
|
+
options?: never;
|
|
70
|
+
head?: never;
|
|
71
|
+
patch?: never;
|
|
72
|
+
trace?: never;
|
|
73
|
+
};
|
|
74
|
+
"/matches/{id}/events": {
|
|
75
|
+
parameters: {
|
|
76
|
+
query?: never;
|
|
77
|
+
header?: never;
|
|
78
|
+
path?: never;
|
|
79
|
+
cookie?: never;
|
|
80
|
+
};
|
|
81
|
+
/** Match events (goals, cards, subs, ...) */
|
|
82
|
+
get: operations["getMatchEvents"];
|
|
83
|
+
put?: never;
|
|
84
|
+
post?: never;
|
|
85
|
+
delete?: never;
|
|
86
|
+
options?: never;
|
|
87
|
+
head?: never;
|
|
88
|
+
patch?: never;
|
|
89
|
+
trace?: never;
|
|
90
|
+
};
|
|
91
|
+
"/matches/{id}/lineups": {
|
|
92
|
+
parameters: {
|
|
93
|
+
query?: never;
|
|
94
|
+
header?: never;
|
|
95
|
+
path?: never;
|
|
96
|
+
cookie?: never;
|
|
97
|
+
};
|
|
98
|
+
/** Starting lineups and substitutes */
|
|
99
|
+
get: operations["getMatchLineups"];
|
|
100
|
+
put?: never;
|
|
101
|
+
post?: never;
|
|
102
|
+
delete?: never;
|
|
103
|
+
options?: never;
|
|
104
|
+
head?: never;
|
|
105
|
+
patch?: never;
|
|
106
|
+
trace?: never;
|
|
107
|
+
};
|
|
108
|
+
"/matches/{id}/momentum": {
|
|
109
|
+
parameters: {
|
|
110
|
+
query?: never;
|
|
111
|
+
header?: never;
|
|
112
|
+
path?: never;
|
|
113
|
+
cookie?: never;
|
|
114
|
+
};
|
|
115
|
+
/** Possession-momentum timeline */
|
|
116
|
+
get: operations["getMatchMomentum"];
|
|
117
|
+
put?: never;
|
|
118
|
+
post?: never;
|
|
119
|
+
delete?: never;
|
|
120
|
+
options?: never;
|
|
121
|
+
head?: never;
|
|
122
|
+
patch?: never;
|
|
123
|
+
trace?: never;
|
|
124
|
+
};
|
|
125
|
+
"/matches/{id}/stats": {
|
|
126
|
+
parameters: {
|
|
127
|
+
query?: never;
|
|
128
|
+
header?: never;
|
|
129
|
+
path?: never;
|
|
130
|
+
cookie?: never;
|
|
131
|
+
};
|
|
132
|
+
/** Team-level match statistics */
|
|
133
|
+
get: operations["getMatchStats"];
|
|
134
|
+
put?: never;
|
|
135
|
+
post?: never;
|
|
136
|
+
delete?: never;
|
|
137
|
+
options?: never;
|
|
138
|
+
head?: never;
|
|
139
|
+
patch?: never;
|
|
140
|
+
trace?: never;
|
|
141
|
+
};
|
|
142
|
+
"/matches/{id}/players": {
|
|
143
|
+
parameters: {
|
|
144
|
+
query?: never;
|
|
145
|
+
header?: never;
|
|
146
|
+
path?: never;
|
|
147
|
+
cookie?: never;
|
|
148
|
+
};
|
|
149
|
+
/**
|
|
150
|
+
* Per-player match stats
|
|
151
|
+
* @description Stat groups share one shape across leagues. Leagues served without a player rating carry none; for the few competitions where match statistics are unavailable (Latvia's Virsliga, Venezuela's Primera División) the lines are derived from the match events and stats the events cannot reproduce (chances created, final-third passes) are omitted rather than zero.
|
|
152
|
+
*/
|
|
153
|
+
get: operations["getMatchPlayers"];
|
|
154
|
+
put?: never;
|
|
155
|
+
post?: never;
|
|
156
|
+
delete?: never;
|
|
157
|
+
options?: never;
|
|
158
|
+
head?: never;
|
|
159
|
+
patch?: never;
|
|
160
|
+
trace?: never;
|
|
161
|
+
};
|
|
162
|
+
"/matches/{id}/players/halves": {
|
|
163
|
+
parameters: {
|
|
164
|
+
query?: never;
|
|
165
|
+
header?: never;
|
|
166
|
+
path?: never;
|
|
167
|
+
cookie?: never;
|
|
168
|
+
};
|
|
169
|
+
/**
|
|
170
|
+
* Per-player stats for each half
|
|
171
|
+
* @description Every player's stat line for the first and the second half. Each half's `stats` has the shape of `/matches/{id}/players`, though not every stat is available per half (the rating is match-level only). A player lists only the halves they took part in. Extra time belongs to neither half, and the halves need not add up exactly to `/matches/{id}/players`. Returns `404 HALVES_UNAVAILABLE` for a match we hold without per-half player stats.
|
|
172
|
+
*/
|
|
173
|
+
get: operations["getMatchPlayerHalves"];
|
|
174
|
+
put?: never;
|
|
175
|
+
post?: never;
|
|
176
|
+
delete?: never;
|
|
177
|
+
options?: never;
|
|
178
|
+
head?: never;
|
|
179
|
+
patch?: never;
|
|
180
|
+
trace?: never;
|
|
181
|
+
};
|
|
182
|
+
"/matches/{id}/players/{pid}": {
|
|
183
|
+
parameters: {
|
|
184
|
+
query?: never;
|
|
185
|
+
header?: never;
|
|
186
|
+
path?: never;
|
|
187
|
+
cookie?: never;
|
|
188
|
+
};
|
|
189
|
+
/** Individual player detail */
|
|
190
|
+
get: operations["getMatchPlayer"];
|
|
191
|
+
put?: never;
|
|
192
|
+
post?: never;
|
|
193
|
+
delete?: never;
|
|
194
|
+
options?: never;
|
|
195
|
+
head?: never;
|
|
196
|
+
patch?: never;
|
|
197
|
+
trace?: never;
|
|
198
|
+
};
|
|
199
|
+
"/matches/{id}/players/{pid}/halves": {
|
|
200
|
+
parameters: {
|
|
201
|
+
query?: never;
|
|
202
|
+
header?: never;
|
|
203
|
+
path?: never;
|
|
204
|
+
cookie?: never;
|
|
205
|
+
};
|
|
206
|
+
/**
|
|
207
|
+
* One player's stats for each half
|
|
208
|
+
* @description The halves of one player, in the shape of an entry of `/matches/{id}/players/halves`. `RESOURCE_NOT_FOUND` for a player who took no part in a match that has halves; `HALVES_UNAVAILABLE` for a match that has none.
|
|
209
|
+
*/
|
|
210
|
+
get: operations["getMatchPlayerHalf"];
|
|
211
|
+
put?: never;
|
|
212
|
+
post?: never;
|
|
213
|
+
delete?: never;
|
|
214
|
+
options?: never;
|
|
215
|
+
head?: never;
|
|
216
|
+
patch?: never;
|
|
217
|
+
trace?: never;
|
|
218
|
+
};
|
|
219
|
+
"/matches/{id}/players/{pid}/shots": {
|
|
220
|
+
parameters: {
|
|
221
|
+
query?: never;
|
|
222
|
+
header?: never;
|
|
223
|
+
path?: never;
|
|
224
|
+
cookie?: never;
|
|
225
|
+
};
|
|
226
|
+
/** A single player's shots */
|
|
227
|
+
get: operations["getMatchPlayerShots"];
|
|
228
|
+
put?: never;
|
|
229
|
+
post?: never;
|
|
230
|
+
delete?: never;
|
|
231
|
+
options?: never;
|
|
232
|
+
head?: never;
|
|
233
|
+
patch?: never;
|
|
234
|
+
trace?: never;
|
|
235
|
+
};
|
|
236
|
+
"/matches/{id}/h2h": {
|
|
237
|
+
parameters: {
|
|
238
|
+
query?: never;
|
|
239
|
+
header?: never;
|
|
240
|
+
path?: never;
|
|
241
|
+
cookie?: never;
|
|
242
|
+
};
|
|
243
|
+
/** Head-to-head history */
|
|
244
|
+
get: operations["getMatchH2H"];
|
|
245
|
+
put?: never;
|
|
246
|
+
post?: never;
|
|
247
|
+
delete?: never;
|
|
248
|
+
options?: never;
|
|
249
|
+
head?: never;
|
|
250
|
+
patch?: never;
|
|
251
|
+
trace?: never;
|
|
252
|
+
};
|
|
253
|
+
"/matches/{id}/advanced": {
|
|
254
|
+
parameters: {
|
|
255
|
+
query?: never;
|
|
256
|
+
header?: never;
|
|
257
|
+
path?: never;
|
|
258
|
+
cookie?: never;
|
|
259
|
+
};
|
|
260
|
+
/**
|
|
261
|
+
* Advanced team analytics (PPDA, field tilt, xG timeline)
|
|
262
|
+
* @description Returns `404 ANALYTICS_UNAVAILABLE` for a match whose analytics have not been computed.
|
|
263
|
+
*/
|
|
264
|
+
get: operations["getMatchAdvanced"];
|
|
265
|
+
put?: never;
|
|
266
|
+
post?: never;
|
|
267
|
+
delete?: never;
|
|
268
|
+
options?: never;
|
|
269
|
+
head?: never;
|
|
270
|
+
patch?: never;
|
|
271
|
+
trace?: never;
|
|
272
|
+
};
|
|
273
|
+
"/matches/{id}/advanced/network": {
|
|
274
|
+
parameters: {
|
|
275
|
+
query?: never;
|
|
276
|
+
header?: never;
|
|
277
|
+
path?: never;
|
|
278
|
+
cookie?: never;
|
|
279
|
+
};
|
|
280
|
+
/** Pass networks */
|
|
281
|
+
get: operations["getMatchAdvancedNetwork"];
|
|
282
|
+
put?: never;
|
|
283
|
+
post?: never;
|
|
284
|
+
delete?: never;
|
|
285
|
+
options?: never;
|
|
286
|
+
head?: never;
|
|
287
|
+
patch?: never;
|
|
288
|
+
trace?: never;
|
|
289
|
+
};
|
|
290
|
+
"/matches/{id}/advanced/players": {
|
|
291
|
+
parameters: {
|
|
292
|
+
query?: never;
|
|
293
|
+
header?: never;
|
|
294
|
+
path?: never;
|
|
295
|
+
cookie?: never;
|
|
296
|
+
};
|
|
297
|
+
/** Player-level advanced rollups */
|
|
298
|
+
get: operations["getMatchAdvancedPlayers"];
|
|
299
|
+
put?: never;
|
|
300
|
+
post?: never;
|
|
301
|
+
delete?: never;
|
|
302
|
+
options?: never;
|
|
303
|
+
head?: never;
|
|
304
|
+
patch?: never;
|
|
305
|
+
trace?: never;
|
|
306
|
+
};
|
|
307
|
+
"/matches/{id}/advanced/players/{pid}": {
|
|
308
|
+
parameters: {
|
|
309
|
+
query?: never;
|
|
310
|
+
header?: never;
|
|
311
|
+
path?: never;
|
|
312
|
+
cookie?: never;
|
|
313
|
+
};
|
|
314
|
+
/** One player's advanced rollup */
|
|
315
|
+
get: operations["getMatchAdvancedPlayer"];
|
|
316
|
+
put?: never;
|
|
317
|
+
post?: never;
|
|
318
|
+
delete?: never;
|
|
319
|
+
options?: never;
|
|
320
|
+
head?: never;
|
|
321
|
+
patch?: never;
|
|
322
|
+
trace?: never;
|
|
323
|
+
};
|
|
324
|
+
"/matches/{id}/heatmaps": {
|
|
325
|
+
parameters: {
|
|
326
|
+
query?: never;
|
|
327
|
+
header?: never;
|
|
328
|
+
path?: never;
|
|
329
|
+
cookie?: never;
|
|
330
|
+
};
|
|
331
|
+
/** Binned activity grids per team and player */
|
|
332
|
+
get: operations["getMatchHeatmaps"];
|
|
333
|
+
put?: never;
|
|
334
|
+
post?: never;
|
|
335
|
+
delete?: never;
|
|
336
|
+
options?: never;
|
|
337
|
+
head?: never;
|
|
338
|
+
patch?: never;
|
|
339
|
+
trace?: never;
|
|
340
|
+
};
|
|
341
|
+
"/leagues": {
|
|
342
|
+
parameters: {
|
|
343
|
+
query?: never;
|
|
344
|
+
header?: never;
|
|
345
|
+
path?: never;
|
|
346
|
+
cookie?: never;
|
|
347
|
+
};
|
|
348
|
+
/** All leagues */
|
|
349
|
+
get: operations["listLeagues"];
|
|
350
|
+
put?: never;
|
|
351
|
+
post?: never;
|
|
352
|
+
delete?: never;
|
|
353
|
+
options?: never;
|
|
354
|
+
head?: never;
|
|
355
|
+
patch?: never;
|
|
356
|
+
trace?: never;
|
|
357
|
+
};
|
|
358
|
+
"/leagues/{id}": {
|
|
359
|
+
parameters: {
|
|
360
|
+
query?: never;
|
|
361
|
+
header?: never;
|
|
362
|
+
path?: never;
|
|
363
|
+
cookie?: never;
|
|
364
|
+
};
|
|
365
|
+
/** League detail */
|
|
366
|
+
get: operations["getLeague"];
|
|
367
|
+
put?: never;
|
|
368
|
+
post?: never;
|
|
369
|
+
delete?: never;
|
|
370
|
+
options?: never;
|
|
371
|
+
head?: never;
|
|
372
|
+
patch?: never;
|
|
373
|
+
trace?: never;
|
|
374
|
+
};
|
|
375
|
+
"/leagues/{id}/matches": {
|
|
376
|
+
parameters: {
|
|
377
|
+
query?: never;
|
|
378
|
+
header?: never;
|
|
379
|
+
path?: never;
|
|
380
|
+
cookie?: never;
|
|
381
|
+
};
|
|
382
|
+
/** Matches in a league season */
|
|
383
|
+
get: operations["getLeagueMatches"];
|
|
384
|
+
put?: never;
|
|
385
|
+
post?: never;
|
|
386
|
+
delete?: never;
|
|
387
|
+
options?: never;
|
|
388
|
+
head?: never;
|
|
389
|
+
patch?: never;
|
|
390
|
+
trace?: never;
|
|
391
|
+
};
|
|
392
|
+
"/teams/{id}": {
|
|
393
|
+
parameters: {
|
|
394
|
+
query?: never;
|
|
395
|
+
header?: never;
|
|
396
|
+
path?: never;
|
|
397
|
+
cookie?: never;
|
|
398
|
+
};
|
|
399
|
+
/** Team profile */
|
|
400
|
+
get: operations["getTeam"];
|
|
401
|
+
put?: never;
|
|
402
|
+
post?: never;
|
|
403
|
+
delete?: never;
|
|
404
|
+
options?: never;
|
|
405
|
+
head?: never;
|
|
406
|
+
patch?: never;
|
|
407
|
+
trace?: never;
|
|
408
|
+
};
|
|
409
|
+
"/players/{id}": {
|
|
410
|
+
parameters: {
|
|
411
|
+
query?: never;
|
|
412
|
+
header?: never;
|
|
413
|
+
path?: never;
|
|
414
|
+
cookie?: never;
|
|
415
|
+
};
|
|
416
|
+
/** Player profile */
|
|
417
|
+
get: operations["getPlayer"];
|
|
418
|
+
put?: never;
|
|
419
|
+
post?: never;
|
|
420
|
+
delete?: never;
|
|
421
|
+
options?: never;
|
|
422
|
+
head?: never;
|
|
423
|
+
patch?: never;
|
|
424
|
+
trace?: never;
|
|
425
|
+
};
|
|
426
|
+
}
|
|
427
|
+
interface components {
|
|
428
|
+
schemas: {
|
|
429
|
+
ErrorEnvelope: {
|
|
430
|
+
error: {
|
|
431
|
+
/** @enum {string} */
|
|
432
|
+
code: "INVALID_PARAMETER" | "UNAUTHORIZED" | "SUBSCRIPTION_SUSPENDED" | "PLAN_UPGRADE_REQUIRED" | "RESOURCE_NOT_FOUND" | "ANALYTICS_UNAVAILABLE" | "HALVES_UNAVAILABLE" | "RATE_LIMIT_EXCEEDED" | "INTERNAL_SERVER_ERROR";
|
|
433
|
+
message: string;
|
|
434
|
+
};
|
|
435
|
+
};
|
|
436
|
+
LeagueRef: {
|
|
437
|
+
id: string;
|
|
438
|
+
name: string;
|
|
439
|
+
image_url?: string | null;
|
|
440
|
+
};
|
|
441
|
+
TeamRef: {
|
|
442
|
+
id: string;
|
|
443
|
+
name: string;
|
|
444
|
+
image_url?: string | null;
|
|
445
|
+
};
|
|
446
|
+
TeamNameRef: {
|
|
447
|
+
id: string;
|
|
448
|
+
name: string;
|
|
449
|
+
};
|
|
450
|
+
PlayerRef: {
|
|
451
|
+
id: string;
|
|
452
|
+
name: string;
|
|
453
|
+
position_id?: number | null;
|
|
454
|
+
image_url?: string | null;
|
|
455
|
+
};
|
|
456
|
+
AdvancedPlayerRef: {
|
|
457
|
+
id: string;
|
|
458
|
+
name: string;
|
|
459
|
+
shirt_number?: number | null;
|
|
460
|
+
};
|
|
461
|
+
CoachRef: {
|
|
462
|
+
name: string;
|
|
463
|
+
};
|
|
464
|
+
Match: {
|
|
465
|
+
id: string;
|
|
466
|
+
league: components["schemas"]["LeagueRef"];
|
|
467
|
+
/** @description Season of this match */
|
|
468
|
+
season?: string | null;
|
|
469
|
+
home_team: components["schemas"]["TeamRef"];
|
|
470
|
+
away_team: components["schemas"]["TeamRef"];
|
|
471
|
+
date?: string | null;
|
|
472
|
+
/** Format: date-time */
|
|
473
|
+
time_utc?: string | null;
|
|
474
|
+
status?: string | null;
|
|
475
|
+
score_home?: number | null;
|
|
476
|
+
score_away?: number | null;
|
|
477
|
+
round_name?: string | null;
|
|
478
|
+
has_playoff: boolean;
|
|
479
|
+
referee?: string | null;
|
|
480
|
+
stadium?: string | null;
|
|
481
|
+
};
|
|
482
|
+
MatchSummary: {
|
|
483
|
+
id: string;
|
|
484
|
+
league: components["schemas"]["LeagueRef"];
|
|
485
|
+
home_team: components["schemas"]["TeamRef"];
|
|
486
|
+
away_team: components["schemas"]["TeamRef"];
|
|
487
|
+
/** Format: date-time */
|
|
488
|
+
time_utc?: string | null;
|
|
489
|
+
status?: string | null;
|
|
490
|
+
score_home?: number | null;
|
|
491
|
+
score_away?: number | null;
|
|
492
|
+
};
|
|
493
|
+
DateMatches: {
|
|
494
|
+
/** Format: date */
|
|
495
|
+
date: string;
|
|
496
|
+
matches: components["schemas"]["MatchSummary"][];
|
|
497
|
+
};
|
|
498
|
+
Shot: {
|
|
499
|
+
id: string;
|
|
500
|
+
player: components["schemas"]["PlayerRef"];
|
|
501
|
+
team_id: string;
|
|
502
|
+
x: number;
|
|
503
|
+
y: number;
|
|
504
|
+
expected_goals: number;
|
|
505
|
+
expected_goals_on_target?: number | null;
|
|
506
|
+
is_on_target: boolean;
|
|
507
|
+
goal_crossed_y?: number | null;
|
|
508
|
+
goal_crossed_z?: number | null;
|
|
509
|
+
is_inside_box: boolean;
|
|
510
|
+
shot_type: string;
|
|
511
|
+
situation: string;
|
|
512
|
+
minute: number;
|
|
513
|
+
event_type: string;
|
|
514
|
+
is_blocked?: boolean;
|
|
515
|
+
blocked_x?: number | null;
|
|
516
|
+
blocked_y?: number | null;
|
|
517
|
+
is_own_goal?: boolean;
|
|
518
|
+
is_saved_off_line?: boolean;
|
|
519
|
+
minute_added?: number | null;
|
|
520
|
+
keeper?: components["schemas"]["PlayerRef"] | null;
|
|
521
|
+
};
|
|
522
|
+
ShotPeriod: {
|
|
523
|
+
period: string;
|
|
524
|
+
shots: components["schemas"]["Shot"][];
|
|
525
|
+
};
|
|
526
|
+
Shots: {
|
|
527
|
+
match_id: string;
|
|
528
|
+
periods: components["schemas"]["ShotPeriod"][];
|
|
529
|
+
};
|
|
530
|
+
PlayerShots: {
|
|
531
|
+
player: components["schemas"]["PlayerRef"];
|
|
532
|
+
shots: components["schemas"]["Shot"][];
|
|
533
|
+
};
|
|
534
|
+
Event: {
|
|
535
|
+
event_type: string;
|
|
536
|
+
minute: number;
|
|
537
|
+
minute_added: number;
|
|
538
|
+
period: string;
|
|
539
|
+
team_id?: string;
|
|
540
|
+
player?: components["schemas"]["PlayerRef"];
|
|
541
|
+
sub_in_player?: components["schemas"]["PlayerRef"];
|
|
542
|
+
score_home?: number | null;
|
|
543
|
+
score_away?: number | null;
|
|
544
|
+
is_own_goal: boolean;
|
|
545
|
+
is_penalty: boolean;
|
|
546
|
+
};
|
|
547
|
+
Events: {
|
|
548
|
+
match_id: string;
|
|
549
|
+
events: components["schemas"]["Event"][];
|
|
550
|
+
};
|
|
551
|
+
LineupPlayer: {
|
|
552
|
+
player_id: string;
|
|
553
|
+
name: string;
|
|
554
|
+
shirt_number: string;
|
|
555
|
+
position_id: number;
|
|
556
|
+
is_captain: boolean;
|
|
557
|
+
pitch_x: number;
|
|
558
|
+
pitch_y: number;
|
|
559
|
+
};
|
|
560
|
+
LineupSide: {
|
|
561
|
+
formation: string;
|
|
562
|
+
/** @description False while this is the pre-match predicted lineup, true once the real one is published. Branch on this before trusting an upcoming fixture's XI. */
|
|
563
|
+
confirmed: boolean;
|
|
564
|
+
/**
|
|
565
|
+
* @description The source's own label for a prediction, e.g. `lastStarting11`. Omitted entirely for a confirmed lineup.
|
|
566
|
+
* @example lastStarting11
|
|
567
|
+
*/
|
|
568
|
+
lineup_type?: string;
|
|
569
|
+
coach?: components["schemas"]["CoachRef"];
|
|
570
|
+
starters: components["schemas"]["LineupPlayer"][];
|
|
571
|
+
subs: components["schemas"]["LineupPlayer"][];
|
|
572
|
+
};
|
|
573
|
+
Lineups: {
|
|
574
|
+
match_id: string;
|
|
575
|
+
home_team: components["schemas"]["TeamRef"];
|
|
576
|
+
away_team: components["schemas"]["TeamRef"];
|
|
577
|
+
home: components["schemas"]["LineupSide"];
|
|
578
|
+
away: components["schemas"]["LineupSide"];
|
|
579
|
+
};
|
|
580
|
+
MomentumPoint: {
|
|
581
|
+
minute: number;
|
|
582
|
+
value: number;
|
|
583
|
+
};
|
|
584
|
+
/** @description The momentum timeline. Matches from the 33 leagues served without one have none: points is an empty array. */
|
|
585
|
+
Momentum: {
|
|
586
|
+
match_id: string;
|
|
587
|
+
points: components["schemas"]["MomentumPoint"][];
|
|
588
|
+
};
|
|
589
|
+
MatchStatItem: {
|
|
590
|
+
title: string;
|
|
591
|
+
key: string;
|
|
592
|
+
home: string;
|
|
593
|
+
away: string;
|
|
594
|
+
format_type: string;
|
|
595
|
+
};
|
|
596
|
+
MatchStatGroup: {
|
|
597
|
+
group_name: string;
|
|
598
|
+
items: components["schemas"]["MatchStatItem"][];
|
|
599
|
+
};
|
|
600
|
+
MatchStatPeriod: {
|
|
601
|
+
period: string;
|
|
602
|
+
groups: components["schemas"]["MatchStatGroup"][];
|
|
603
|
+
};
|
|
604
|
+
MatchStats: {
|
|
605
|
+
match_id: string;
|
|
606
|
+
home_team: components["schemas"]["TeamRef"];
|
|
607
|
+
away_team: components["schemas"]["TeamRef"];
|
|
608
|
+
periods: components["schemas"]["MatchStatPeriod"][];
|
|
609
|
+
};
|
|
610
|
+
PlayerMatchStats: {
|
|
611
|
+
player: components["schemas"]["PlayerRef"];
|
|
612
|
+
team_id: string;
|
|
613
|
+
/** @description Raw stat line; shape varies by position. */
|
|
614
|
+
stats: {
|
|
615
|
+
[key: string]: unknown;
|
|
616
|
+
};
|
|
617
|
+
};
|
|
618
|
+
PlayerDetail: {
|
|
619
|
+
player: components["schemas"]["PlayerRef"];
|
|
620
|
+
team_id: string;
|
|
621
|
+
position_id?: number | null;
|
|
622
|
+
stats: {
|
|
623
|
+
[key: string]: unknown;
|
|
624
|
+
};
|
|
625
|
+
};
|
|
626
|
+
PlayerHalfStats: {
|
|
627
|
+
/** @enum {string} */
|
|
628
|
+
period: "FirstHalf" | "SecondHalf";
|
|
629
|
+
/** @description The half's stat line, grouped as in PlayerMatchStats. */
|
|
630
|
+
stats: {
|
|
631
|
+
[key: string]: unknown;
|
|
632
|
+
}[];
|
|
633
|
+
};
|
|
634
|
+
PlayerHalves: {
|
|
635
|
+
player: components["schemas"]["PlayerRef"];
|
|
636
|
+
team_id: string;
|
|
637
|
+
/** @description Only the halves the player took part in, first half first. */
|
|
638
|
+
periods: components["schemas"]["PlayerHalfStats"][];
|
|
639
|
+
};
|
|
640
|
+
MatchPlayerHalves: {
|
|
641
|
+
match_id: string;
|
|
642
|
+
players: components["schemas"]["PlayerHalves"][];
|
|
643
|
+
};
|
|
644
|
+
PlayerHalfDetail: {
|
|
645
|
+
match_id: string;
|
|
646
|
+
player: components["schemas"]["PlayerRef"];
|
|
647
|
+
team_id: string;
|
|
648
|
+
periods: components["schemas"]["PlayerHalfStats"][];
|
|
649
|
+
};
|
|
650
|
+
H2HMatch: {
|
|
651
|
+
/** Format: date-time */
|
|
652
|
+
time_utc?: string | null;
|
|
653
|
+
home: components["schemas"]["TeamRef"];
|
|
654
|
+
away: components["schemas"]["TeamRef"];
|
|
655
|
+
score_home?: number | null;
|
|
656
|
+
score_away?: number | null;
|
|
657
|
+
finished: boolean;
|
|
658
|
+
};
|
|
659
|
+
H2H: {
|
|
660
|
+
match_id: string;
|
|
661
|
+
home_team: components["schemas"]["TeamRef"];
|
|
662
|
+
away_team: components["schemas"]["TeamRef"];
|
|
663
|
+
home_wins: number;
|
|
664
|
+
draws: number;
|
|
665
|
+
away_wins: number;
|
|
666
|
+
total_matches: number;
|
|
667
|
+
recent_matches: components["schemas"]["H2HMatch"][];
|
|
668
|
+
};
|
|
669
|
+
League: {
|
|
670
|
+
id: string;
|
|
671
|
+
name: string;
|
|
672
|
+
country_code: string;
|
|
673
|
+
season: string;
|
|
674
|
+
image_url?: string;
|
|
675
|
+
};
|
|
676
|
+
LeagueSummary: {
|
|
677
|
+
id: string;
|
|
678
|
+
name: string;
|
|
679
|
+
country_code: string;
|
|
680
|
+
image_url?: string | null;
|
|
681
|
+
seasons: string[];
|
|
682
|
+
is_free: boolean;
|
|
683
|
+
};
|
|
684
|
+
LeagueSeasonRef: {
|
|
685
|
+
id: string;
|
|
686
|
+
name: string;
|
|
687
|
+
season: string;
|
|
688
|
+
image_url?: string;
|
|
689
|
+
};
|
|
690
|
+
LeagueMatchSummary: {
|
|
691
|
+
id: string;
|
|
692
|
+
date?: string | null;
|
|
693
|
+
/** Format: date-time */
|
|
694
|
+
time_utc?: string | null;
|
|
695
|
+
status?: string | null;
|
|
696
|
+
home_team: components["schemas"]["TeamRef"];
|
|
697
|
+
away_team: components["schemas"]["TeamRef"];
|
|
698
|
+
score_home?: number | null;
|
|
699
|
+
score_away?: number | null;
|
|
700
|
+
};
|
|
701
|
+
LeagueMatches: {
|
|
702
|
+
league: components["schemas"]["LeagueSeasonRef"];
|
|
703
|
+
matches: components["schemas"]["LeagueMatchSummary"][];
|
|
704
|
+
};
|
|
705
|
+
Team: {
|
|
706
|
+
id: string;
|
|
707
|
+
name: string;
|
|
708
|
+
image_url?: string;
|
|
709
|
+
};
|
|
710
|
+
PlayerProfile: {
|
|
711
|
+
id: string;
|
|
712
|
+
name: string;
|
|
713
|
+
short_name?: string;
|
|
714
|
+
shirt_number?: string;
|
|
715
|
+
position_id?: number | null;
|
|
716
|
+
country_code?: string;
|
|
717
|
+
image_url?: string;
|
|
718
|
+
};
|
|
719
|
+
/** @description Null as a whole object when no model ran; members omitted when their model did not run. */
|
|
720
|
+
PossessionValue: {
|
|
721
|
+
xt_total?: number | null;
|
|
722
|
+
vaep_total?: number | null;
|
|
723
|
+
vaep_offensive?: number | null;
|
|
724
|
+
vaep_defensive?: number | null;
|
|
725
|
+
pv_total?: number | null;
|
|
726
|
+
pv_offensive?: number | null;
|
|
727
|
+
pv_defensive?: number | null;
|
|
728
|
+
};
|
|
729
|
+
/** @description `passes` already includes `crosses`; never sum the two. */
|
|
730
|
+
PassingStats: {
|
|
731
|
+
passes?: number;
|
|
732
|
+
pass_accuracy?: number | null;
|
|
733
|
+
progressive_passes?: number;
|
|
734
|
+
progressive_pass_distance?: number;
|
|
735
|
+
passes_into_box?: number;
|
|
736
|
+
key_passes?: number;
|
|
737
|
+
assists?: number;
|
|
738
|
+
through_balls?: number;
|
|
739
|
+
crosses?: number;
|
|
740
|
+
switches?: number;
|
|
741
|
+
};
|
|
742
|
+
CarryingStats: {
|
|
743
|
+
carries?: number;
|
|
744
|
+
carry_distance?: number;
|
|
745
|
+
progressive_carries?: number;
|
|
746
|
+
progressive_carry_distance?: number;
|
|
747
|
+
carries_into_final_third?: number;
|
|
748
|
+
carries_into_box?: number;
|
|
749
|
+
take_ons?: number;
|
|
750
|
+
take_ons_won?: number;
|
|
751
|
+
miscontrols?: number;
|
|
752
|
+
dispossessed?: number;
|
|
753
|
+
};
|
|
754
|
+
TeamSCABreakdown: {
|
|
755
|
+
pass_live?: number;
|
|
756
|
+
pass_dead?: number;
|
|
757
|
+
take_on?: number;
|
|
758
|
+
shot?: number;
|
|
759
|
+
foul_drawn?: number;
|
|
760
|
+
defensive?: number;
|
|
761
|
+
};
|
|
762
|
+
/** @description `chances_created` equals `passing.key_passes`; never sum them. */
|
|
763
|
+
TeamCreation: {
|
|
764
|
+
sca?: number;
|
|
765
|
+
gca?: number;
|
|
766
|
+
chances_created?: number;
|
|
767
|
+
second_assists?: number;
|
|
768
|
+
sca_breakdown?: components["schemas"]["TeamSCABreakdown"];
|
|
769
|
+
xag?: number | null;
|
|
770
|
+
};
|
|
771
|
+
PlayerSCABreakdown: {
|
|
772
|
+
pass_live?: number;
|
|
773
|
+
pass_dead?: number;
|
|
774
|
+
take_on?: number;
|
|
775
|
+
shot?: number;
|
|
776
|
+
defensive?: number;
|
|
777
|
+
};
|
|
778
|
+
PlayerCreation: {
|
|
779
|
+
sca?: number;
|
|
780
|
+
gca?: number;
|
|
781
|
+
chances_created?: number;
|
|
782
|
+
second_assists?: number;
|
|
783
|
+
sca_breakdown?: components["schemas"]["PlayerSCABreakdown"];
|
|
784
|
+
/** @description xG of shots this player's passes created (not xA). */
|
|
785
|
+
xag?: number | null;
|
|
786
|
+
xg_chain?: number | null;
|
|
787
|
+
/** @description Always <= xg_chain. */
|
|
788
|
+
xg_buildup?: number | null;
|
|
789
|
+
};
|
|
790
|
+
PlayerDefending: {
|
|
791
|
+
tackles?: number;
|
|
792
|
+
interceptions?: number;
|
|
793
|
+
blocks?: number;
|
|
794
|
+
clearances?: number;
|
|
795
|
+
duels_won?: number;
|
|
796
|
+
aerials?: number;
|
|
797
|
+
aerials_won?: number;
|
|
798
|
+
};
|
|
799
|
+
/** @description Flattens PlayerDefending plus team-only pressing/transition measures. */
|
|
800
|
+
TeamDefending: {
|
|
801
|
+
tackles?: number;
|
|
802
|
+
interceptions?: number;
|
|
803
|
+
blocks?: number;
|
|
804
|
+
clearances?: number;
|
|
805
|
+
duels_won?: number;
|
|
806
|
+
aerials?: number;
|
|
807
|
+
aerials_won?: number;
|
|
808
|
+
ppda?: number | null;
|
|
809
|
+
opponent_passes?: number;
|
|
810
|
+
defensive_actions?: number;
|
|
811
|
+
challenges?: number;
|
|
812
|
+
avg_defensive_action_x?: number | null;
|
|
813
|
+
high_turnovers?: number;
|
|
814
|
+
counterpress_regains_5s?: number;
|
|
815
|
+
ball_recovery_time?: number | null;
|
|
816
|
+
};
|
|
817
|
+
TerritoryStats: {
|
|
818
|
+
possession_pct?: number | null;
|
|
819
|
+
field_tilt?: number | null;
|
|
820
|
+
final_third_entries?: number;
|
|
821
|
+
box_entries?: number;
|
|
822
|
+
avg_action_x?: number | null;
|
|
823
|
+
};
|
|
824
|
+
TempoStats: {
|
|
825
|
+
passes_per_sequence?: number | null;
|
|
826
|
+
sequence_time?: number | null;
|
|
827
|
+
direct_speed?: number | null;
|
|
828
|
+
buildup_attacks?: number;
|
|
829
|
+
direct_attacks?: number;
|
|
830
|
+
};
|
|
831
|
+
/** @description Present only for the two starting keepers. */
|
|
832
|
+
Goalkeeping: {
|
|
833
|
+
claims?: number;
|
|
834
|
+
claims_won?: number;
|
|
835
|
+
claim_rate?: number | null;
|
|
836
|
+
sweeper_actions?: number;
|
|
837
|
+
distributions?: number;
|
|
838
|
+
launches?: number;
|
|
839
|
+
launch_pct?: number | null;
|
|
840
|
+
avg_pass_length?: number | null;
|
|
841
|
+
distribution_accuracy?: number | null;
|
|
842
|
+
};
|
|
843
|
+
AdvancedTeamStat: {
|
|
844
|
+
team: components["schemas"]["TeamNameRef"];
|
|
845
|
+
actions: number;
|
|
846
|
+
possession_value?: components["schemas"]["PossessionValue"] | null;
|
|
847
|
+
passing?: components["schemas"]["PassingStats"];
|
|
848
|
+
carrying?: components["schemas"]["CarryingStats"];
|
|
849
|
+
creation?: components["schemas"]["TeamCreation"];
|
|
850
|
+
defending?: components["schemas"]["TeamDefending"];
|
|
851
|
+
territory?: components["schemas"]["TerritoryStats"];
|
|
852
|
+
tempo?: components["schemas"]["TempoStats"];
|
|
853
|
+
};
|
|
854
|
+
AdvancedTeams: {
|
|
855
|
+
match_id: string;
|
|
856
|
+
teams: components["schemas"]["AdvancedTeamStat"][];
|
|
857
|
+
};
|
|
858
|
+
AdvancedPlayerStat: {
|
|
859
|
+
player: components["schemas"]["AdvancedPlayerRef"];
|
|
860
|
+
team_id: string;
|
|
861
|
+
minutes_played?: number | null;
|
|
862
|
+
actions: number;
|
|
863
|
+
possession_value?: components["schemas"]["PossessionValue"] | null;
|
|
864
|
+
passing?: components["schemas"]["PassingStats"];
|
|
865
|
+
carrying?: components["schemas"]["CarryingStats"];
|
|
866
|
+
creation?: components["schemas"]["PlayerCreation"];
|
|
867
|
+
defending?: components["schemas"]["PlayerDefending"];
|
|
868
|
+
goalkeeping?: components["schemas"]["Goalkeeping"] | null;
|
|
869
|
+
};
|
|
870
|
+
AdvancedPlayers: {
|
|
871
|
+
match_id: string;
|
|
872
|
+
/** @description Ordering used; falls back to "actions" when VAEP did not run. */
|
|
873
|
+
sorted_by: string;
|
|
874
|
+
players: components["schemas"]["AdvancedPlayerStat"][];
|
|
875
|
+
};
|
|
876
|
+
NetworkWindow: {
|
|
877
|
+
kind: string;
|
|
878
|
+
/** @description Null when the network covers the full match. */
|
|
879
|
+
until_seconds?: number | null;
|
|
880
|
+
};
|
|
881
|
+
PassNetworkNode: {
|
|
882
|
+
player: components["schemas"]["AdvancedPlayerRef"];
|
|
883
|
+
/** @description Mean location the player passed FROM. */
|
|
884
|
+
avg_x?: number | null;
|
|
885
|
+
avg_y?: number | null;
|
|
886
|
+
passes: number;
|
|
887
|
+
passes_received: number;
|
|
888
|
+
degree?: number | null;
|
|
889
|
+
strength?: number | null;
|
|
890
|
+
betweenness?: number | null;
|
|
891
|
+
clustering?: number | null;
|
|
892
|
+
};
|
|
893
|
+
PassNetworkEdge: {
|
|
894
|
+
from: components["schemas"]["AdvancedPlayerRef"];
|
|
895
|
+
to: components["schemas"]["AdvancedPlayerRef"];
|
|
896
|
+
passes: number;
|
|
897
|
+
};
|
|
898
|
+
PassNetwork: {
|
|
899
|
+
team: components["schemas"]["TeamNameRef"];
|
|
900
|
+
window: components["schemas"]["NetworkWindow"];
|
|
901
|
+
/** @description Null when the graph had no edges. */
|
|
902
|
+
centralization?: number | null;
|
|
903
|
+
nodes: components["schemas"]["PassNetworkNode"][];
|
|
904
|
+
edges: components["schemas"]["PassNetworkEdge"][];
|
|
905
|
+
};
|
|
906
|
+
AdvancedNetworks: {
|
|
907
|
+
match_id: string;
|
|
908
|
+
networks: components["schemas"]["PassNetwork"][];
|
|
909
|
+
};
|
|
910
|
+
/** @description The frame the cells are counted in. Without it the cells are unreadable: cell_x 0 is not "the left end of the pitch", it is the acting team's own goal line, in both halves. */
|
|
911
|
+
HeatmapGrid: {
|
|
912
|
+
/** @description Cells from goal line to goal line. Always 16. */
|
|
913
|
+
length: number;
|
|
914
|
+
/** @description Cells from touchline to touchline. Always 12. */
|
|
915
|
+
width: number;
|
|
916
|
+
/**
|
|
917
|
+
* @description The orientation actually served, echoed so a response is self-describing whether or not the request named one. In `acting_ltr`, cell_x 0 is the acting team's own goal line and 15 the opponent's, for both teams and in both halves — the same direction normalisation the shot coordinates use. In `home_ltr` the away side's cells are already turned onto the shared pitch.
|
|
918
|
+
* @enum {string}
|
|
919
|
+
*/
|
|
920
|
+
frame: "acting_ltr" | "home_ltr";
|
|
921
|
+
/** @description Cell length in metres on the 105 x 68 pitch. */
|
|
922
|
+
cell_length_m: number;
|
|
923
|
+
/** @description Cell width in metres. */
|
|
924
|
+
cell_width_m: number;
|
|
925
|
+
};
|
|
926
|
+
/** @description Sparse [cell_x, cell_y, actions] triples. A cell with no activity is absent rather than zero, which is most of the 192 — expand to a dense grid client-side if you need one. Empty array, never null. */
|
|
927
|
+
HeatmapCells: number[][];
|
|
928
|
+
TeamHeatmap: {
|
|
929
|
+
team: components["schemas"]["TeamNameRef"];
|
|
930
|
+
/**
|
|
931
|
+
* @description Cells are in this team's own attacking frame either way; the side is what lets you mirror one of them to draw both on a single pitch.
|
|
932
|
+
* @enum {string}
|
|
933
|
+
*/
|
|
934
|
+
side: "home" | "away";
|
|
935
|
+
actions: number;
|
|
936
|
+
cells: components["schemas"]["HeatmapCells"];
|
|
937
|
+
};
|
|
938
|
+
PlayerHeatmap: {
|
|
939
|
+
player: components["schemas"]["AdvancedPlayerRef"];
|
|
940
|
+
team: components["schemas"]["TeamNameRef"];
|
|
941
|
+
/**
|
|
942
|
+
* @description The player's team's side, repeated so a caller iterating players alone can orient them.
|
|
943
|
+
* @enum {string}
|
|
944
|
+
*/
|
|
945
|
+
side: "home" | "away";
|
|
946
|
+
/** @description A raw count for the match, not per-90. A substitute's grid is thinner than a starter's for reasons that are about minutes rather than involvement. */
|
|
947
|
+
actions: number;
|
|
948
|
+
cells: components["schemas"]["HeatmapCells"];
|
|
949
|
+
};
|
|
950
|
+
/** @description Binned activity for one match: each team's own grid plus one grid per player who touched the ball. Match level only — there is no season or cross-match aggregate behind this. */
|
|
951
|
+
MatchHeatmaps: {
|
|
952
|
+
match_id: string;
|
|
953
|
+
grid: components["schemas"]["HeatmapGrid"];
|
|
954
|
+
/** @description Both teams, home first. */
|
|
955
|
+
teams: components["schemas"]["TeamHeatmap"][];
|
|
956
|
+
/** @description Ordered by involvement, busiest first. */
|
|
957
|
+
players: components["schemas"]["PlayerHeatmap"][];
|
|
958
|
+
};
|
|
959
|
+
};
|
|
960
|
+
responses: {
|
|
961
|
+
/** @description A malformed ID, date, or season (`INVALID_PARAMETER`). */
|
|
962
|
+
InvalidParameter: {
|
|
963
|
+
headers: {
|
|
964
|
+
[name: string]: unknown;
|
|
965
|
+
};
|
|
966
|
+
content: {
|
|
967
|
+
"application/json": components["schemas"]["ErrorEnvelope"];
|
|
968
|
+
};
|
|
969
|
+
};
|
|
970
|
+
/** @description Missing, malformed, or revoked key (`UNAUTHORIZED`), or a suspended subscription (`SUBSCRIPTION_SUSPENDED`). */
|
|
971
|
+
Unauthorized: {
|
|
972
|
+
headers: {
|
|
973
|
+
[name: string]: unknown;
|
|
974
|
+
};
|
|
975
|
+
content: {
|
|
976
|
+
"application/json": components["schemas"]["ErrorEnvelope"];
|
|
977
|
+
};
|
|
978
|
+
};
|
|
979
|
+
/** @description The resource's league is not on the free tier (`PLAN_UPGRADE_REQUIRED`). */
|
|
980
|
+
PlanUpgradeRequired: {
|
|
981
|
+
headers: {
|
|
982
|
+
[name: string]: unknown;
|
|
983
|
+
};
|
|
984
|
+
content: {
|
|
985
|
+
"application/json": components["schemas"]["ErrorEnvelope"];
|
|
986
|
+
};
|
|
987
|
+
};
|
|
988
|
+
/** @description Resource does not exist (`RESOURCE_NOT_FOUND`), analytics not yet computed (`ANALYTICS_UNAVAILABLE`), or no per-half player stats for the match (`HALVES_UNAVAILABLE`). */
|
|
989
|
+
NotFound: {
|
|
990
|
+
headers: {
|
|
991
|
+
[name: string]: unknown;
|
|
992
|
+
};
|
|
993
|
+
content: {
|
|
994
|
+
"application/json": components["schemas"]["ErrorEnvelope"];
|
|
995
|
+
};
|
|
996
|
+
};
|
|
997
|
+
/** @description Per-user fair-use ceiling exceeded (`RATE_LIMIT_EXCEEDED`). */
|
|
998
|
+
RateLimited: {
|
|
999
|
+
headers: {
|
|
1000
|
+
/** @description Seconds to wait before retrying. */
|
|
1001
|
+
"Retry-After"?: number;
|
|
1002
|
+
[name: string]: unknown;
|
|
1003
|
+
};
|
|
1004
|
+
content: {
|
|
1005
|
+
"application/json": components["schemas"]["ErrorEnvelope"];
|
|
1006
|
+
};
|
|
1007
|
+
};
|
|
1008
|
+
};
|
|
1009
|
+
parameters: {
|
|
1010
|
+
MatchId: string;
|
|
1011
|
+
ShotId: string;
|
|
1012
|
+
PlayerId: string;
|
|
1013
|
+
PlayerProfileId: string;
|
|
1014
|
+
LeagueId: string;
|
|
1015
|
+
TeamId: string;
|
|
1016
|
+
/** @description Calendar day in `YYYY-MM-DD`. */
|
|
1017
|
+
Date: string;
|
|
1018
|
+
/** @description Which fixtures to return. `played` covers matches that have kicked off, `upcoming` future fixtures (a kickoff `time_utc` and a `status`, but no score yet), and `all` both. Omitting the parameter is the same as `played`; sending it empty is rejected. */
|
|
1019
|
+
MatchStatus: "played" | "upcoming" | "all";
|
|
1020
|
+
};
|
|
1021
|
+
requestBodies: never;
|
|
1022
|
+
headers: never;
|
|
1023
|
+
pathItems: never;
|
|
1024
|
+
}
|
|
1025
|
+
interface operations {
|
|
1026
|
+
getMatchesByDate: {
|
|
1027
|
+
parameters: {
|
|
1028
|
+
query?: {
|
|
1029
|
+
/** @description Which fixtures to return. `played` covers matches that have kicked off, `upcoming` future fixtures (a kickoff `time_utc` and a `status`, but no score yet), and `all` both. Omitting the parameter is the same as `played`; sending it empty is rejected. */
|
|
1030
|
+
status?: components["parameters"]["MatchStatus"];
|
|
1031
|
+
};
|
|
1032
|
+
header?: never;
|
|
1033
|
+
path: {
|
|
1034
|
+
/** @description Calendar day in `YYYY-MM-DD`. */
|
|
1035
|
+
date: components["parameters"]["Date"];
|
|
1036
|
+
};
|
|
1037
|
+
cookie?: never;
|
|
1038
|
+
};
|
|
1039
|
+
requestBody?: never;
|
|
1040
|
+
responses: {
|
|
1041
|
+
/** @description Matches for the day */
|
|
1042
|
+
200: {
|
|
1043
|
+
headers: {
|
|
1044
|
+
[name: string]: unknown;
|
|
1045
|
+
};
|
|
1046
|
+
content: {
|
|
1047
|
+
"application/json": {
|
|
1048
|
+
data?: components["schemas"]["DateMatches"];
|
|
1049
|
+
};
|
|
1050
|
+
};
|
|
1051
|
+
};
|
|
1052
|
+
400: components["responses"]["InvalidParameter"];
|
|
1053
|
+
401: components["responses"]["Unauthorized"];
|
|
1054
|
+
429: components["responses"]["RateLimited"];
|
|
1055
|
+
};
|
|
1056
|
+
};
|
|
1057
|
+
getMatch: {
|
|
1058
|
+
parameters: {
|
|
1059
|
+
query?: never;
|
|
1060
|
+
header?: never;
|
|
1061
|
+
path: {
|
|
1062
|
+
id: components["parameters"]["MatchId"];
|
|
1063
|
+
};
|
|
1064
|
+
cookie?: never;
|
|
1065
|
+
};
|
|
1066
|
+
requestBody?: never;
|
|
1067
|
+
responses: {
|
|
1068
|
+
/** @description Match summary */
|
|
1069
|
+
200: {
|
|
1070
|
+
headers: {
|
|
1071
|
+
[name: string]: unknown;
|
|
1072
|
+
};
|
|
1073
|
+
content: {
|
|
1074
|
+
"application/json": {
|
|
1075
|
+
data?: components["schemas"]["Match"];
|
|
1076
|
+
};
|
|
1077
|
+
};
|
|
1078
|
+
};
|
|
1079
|
+
400: components["responses"]["InvalidParameter"];
|
|
1080
|
+
401: components["responses"]["Unauthorized"];
|
|
1081
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1082
|
+
404: components["responses"]["NotFound"];
|
|
1083
|
+
429: components["responses"]["RateLimited"];
|
|
1084
|
+
};
|
|
1085
|
+
};
|
|
1086
|
+
getMatchShots: {
|
|
1087
|
+
parameters: {
|
|
1088
|
+
query?: never;
|
|
1089
|
+
header?: never;
|
|
1090
|
+
path: {
|
|
1091
|
+
id: components["parameters"]["MatchId"];
|
|
1092
|
+
};
|
|
1093
|
+
cookie?: never;
|
|
1094
|
+
};
|
|
1095
|
+
requestBody?: never;
|
|
1096
|
+
responses: {
|
|
1097
|
+
/** @description Shots grouped by period */
|
|
1098
|
+
200: {
|
|
1099
|
+
headers: {
|
|
1100
|
+
[name: string]: unknown;
|
|
1101
|
+
};
|
|
1102
|
+
content: {
|
|
1103
|
+
"application/json": {
|
|
1104
|
+
data?: components["schemas"]["Shots"];
|
|
1105
|
+
};
|
|
1106
|
+
};
|
|
1107
|
+
};
|
|
1108
|
+
400: components["responses"]["InvalidParameter"];
|
|
1109
|
+
401: components["responses"]["Unauthorized"];
|
|
1110
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1111
|
+
429: components["responses"]["RateLimited"];
|
|
1112
|
+
};
|
|
1113
|
+
};
|
|
1114
|
+
getShot: {
|
|
1115
|
+
parameters: {
|
|
1116
|
+
query?: never;
|
|
1117
|
+
header?: never;
|
|
1118
|
+
path: {
|
|
1119
|
+
id: components["parameters"]["MatchId"];
|
|
1120
|
+
sid: components["parameters"]["ShotId"];
|
|
1121
|
+
};
|
|
1122
|
+
cookie?: never;
|
|
1123
|
+
};
|
|
1124
|
+
requestBody?: never;
|
|
1125
|
+
responses: {
|
|
1126
|
+
/** @description Shot detail */
|
|
1127
|
+
200: {
|
|
1128
|
+
headers: {
|
|
1129
|
+
[name: string]: unknown;
|
|
1130
|
+
};
|
|
1131
|
+
content: {
|
|
1132
|
+
"application/json": {
|
|
1133
|
+
data?: components["schemas"]["Shot"];
|
|
1134
|
+
};
|
|
1135
|
+
};
|
|
1136
|
+
};
|
|
1137
|
+
400: components["responses"]["InvalidParameter"];
|
|
1138
|
+
401: components["responses"]["Unauthorized"];
|
|
1139
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1140
|
+
404: components["responses"]["NotFound"];
|
|
1141
|
+
429: components["responses"]["RateLimited"];
|
|
1142
|
+
};
|
|
1143
|
+
};
|
|
1144
|
+
getMatchEvents: {
|
|
1145
|
+
parameters: {
|
|
1146
|
+
query?: never;
|
|
1147
|
+
header?: never;
|
|
1148
|
+
path: {
|
|
1149
|
+
id: components["parameters"]["MatchId"];
|
|
1150
|
+
};
|
|
1151
|
+
cookie?: never;
|
|
1152
|
+
};
|
|
1153
|
+
requestBody?: never;
|
|
1154
|
+
responses: {
|
|
1155
|
+
/** @description Events */
|
|
1156
|
+
200: {
|
|
1157
|
+
headers: {
|
|
1158
|
+
[name: string]: unknown;
|
|
1159
|
+
};
|
|
1160
|
+
content: {
|
|
1161
|
+
"application/json": {
|
|
1162
|
+
data?: components["schemas"]["Events"];
|
|
1163
|
+
};
|
|
1164
|
+
};
|
|
1165
|
+
};
|
|
1166
|
+
401: components["responses"]["Unauthorized"];
|
|
1167
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1168
|
+
429: components["responses"]["RateLimited"];
|
|
1169
|
+
};
|
|
1170
|
+
};
|
|
1171
|
+
getMatchLineups: {
|
|
1172
|
+
parameters: {
|
|
1173
|
+
query?: never;
|
|
1174
|
+
header?: never;
|
|
1175
|
+
path: {
|
|
1176
|
+
id: components["parameters"]["MatchId"];
|
|
1177
|
+
};
|
|
1178
|
+
cookie?: never;
|
|
1179
|
+
};
|
|
1180
|
+
requestBody?: never;
|
|
1181
|
+
responses: {
|
|
1182
|
+
/** @description Lineups */
|
|
1183
|
+
200: {
|
|
1184
|
+
headers: {
|
|
1185
|
+
[name: string]: unknown;
|
|
1186
|
+
};
|
|
1187
|
+
content: {
|
|
1188
|
+
"application/json": {
|
|
1189
|
+
data?: components["schemas"]["Lineups"];
|
|
1190
|
+
};
|
|
1191
|
+
};
|
|
1192
|
+
};
|
|
1193
|
+
401: components["responses"]["Unauthorized"];
|
|
1194
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1195
|
+
404: components["responses"]["NotFound"];
|
|
1196
|
+
429: components["responses"]["RateLimited"];
|
|
1197
|
+
};
|
|
1198
|
+
};
|
|
1199
|
+
getMatchMomentum: {
|
|
1200
|
+
parameters: {
|
|
1201
|
+
query?: never;
|
|
1202
|
+
header?: never;
|
|
1203
|
+
path: {
|
|
1204
|
+
id: components["parameters"]["MatchId"];
|
|
1205
|
+
};
|
|
1206
|
+
cookie?: never;
|
|
1207
|
+
};
|
|
1208
|
+
requestBody?: never;
|
|
1209
|
+
responses: {
|
|
1210
|
+
/** @description Momentum */
|
|
1211
|
+
200: {
|
|
1212
|
+
headers: {
|
|
1213
|
+
[name: string]: unknown;
|
|
1214
|
+
};
|
|
1215
|
+
content: {
|
|
1216
|
+
"application/json": {
|
|
1217
|
+
data?: components["schemas"]["Momentum"];
|
|
1218
|
+
};
|
|
1219
|
+
};
|
|
1220
|
+
};
|
|
1221
|
+
401: components["responses"]["Unauthorized"];
|
|
1222
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1223
|
+
429: components["responses"]["RateLimited"];
|
|
1224
|
+
};
|
|
1225
|
+
};
|
|
1226
|
+
getMatchStats: {
|
|
1227
|
+
parameters: {
|
|
1228
|
+
query?: never;
|
|
1229
|
+
header?: never;
|
|
1230
|
+
path: {
|
|
1231
|
+
id: components["parameters"]["MatchId"];
|
|
1232
|
+
};
|
|
1233
|
+
cookie?: never;
|
|
1234
|
+
};
|
|
1235
|
+
requestBody?: never;
|
|
1236
|
+
responses: {
|
|
1237
|
+
/** @description Team stats */
|
|
1238
|
+
200: {
|
|
1239
|
+
headers: {
|
|
1240
|
+
[name: string]: unknown;
|
|
1241
|
+
};
|
|
1242
|
+
content: {
|
|
1243
|
+
"application/json": {
|
|
1244
|
+
data?: components["schemas"]["MatchStats"];
|
|
1245
|
+
};
|
|
1246
|
+
};
|
|
1247
|
+
};
|
|
1248
|
+
401: components["responses"]["Unauthorized"];
|
|
1249
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1250
|
+
404: components["responses"]["NotFound"];
|
|
1251
|
+
429: components["responses"]["RateLimited"];
|
|
1252
|
+
};
|
|
1253
|
+
};
|
|
1254
|
+
getMatchPlayers: {
|
|
1255
|
+
parameters: {
|
|
1256
|
+
query?: never;
|
|
1257
|
+
header?: never;
|
|
1258
|
+
path: {
|
|
1259
|
+
id: components["parameters"]["MatchId"];
|
|
1260
|
+
};
|
|
1261
|
+
cookie?: never;
|
|
1262
|
+
};
|
|
1263
|
+
requestBody?: never;
|
|
1264
|
+
responses: {
|
|
1265
|
+
/** @description Player stat lines */
|
|
1266
|
+
200: {
|
|
1267
|
+
headers: {
|
|
1268
|
+
[name: string]: unknown;
|
|
1269
|
+
};
|
|
1270
|
+
content: {
|
|
1271
|
+
"application/json": {
|
|
1272
|
+
data?: components["schemas"]["PlayerMatchStats"][];
|
|
1273
|
+
};
|
|
1274
|
+
};
|
|
1275
|
+
};
|
|
1276
|
+
401: components["responses"]["Unauthorized"];
|
|
1277
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1278
|
+
429: components["responses"]["RateLimited"];
|
|
1279
|
+
};
|
|
1280
|
+
};
|
|
1281
|
+
getMatchPlayerHalves: {
|
|
1282
|
+
parameters: {
|
|
1283
|
+
query?: never;
|
|
1284
|
+
header?: never;
|
|
1285
|
+
path: {
|
|
1286
|
+
id: components["parameters"]["MatchId"];
|
|
1287
|
+
};
|
|
1288
|
+
cookie?: never;
|
|
1289
|
+
};
|
|
1290
|
+
requestBody?: never;
|
|
1291
|
+
responses: {
|
|
1292
|
+
/** @description Player halves */
|
|
1293
|
+
200: {
|
|
1294
|
+
headers: {
|
|
1295
|
+
[name: string]: unknown;
|
|
1296
|
+
};
|
|
1297
|
+
content: {
|
|
1298
|
+
"application/json": {
|
|
1299
|
+
data?: components["schemas"]["MatchPlayerHalves"];
|
|
1300
|
+
};
|
|
1301
|
+
};
|
|
1302
|
+
};
|
|
1303
|
+
401: components["responses"]["Unauthorized"];
|
|
1304
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1305
|
+
404: components["responses"]["NotFound"];
|
|
1306
|
+
429: components["responses"]["RateLimited"];
|
|
1307
|
+
};
|
|
1308
|
+
};
|
|
1309
|
+
getMatchPlayer: {
|
|
1310
|
+
parameters: {
|
|
1311
|
+
query?: never;
|
|
1312
|
+
header?: never;
|
|
1313
|
+
path: {
|
|
1314
|
+
id: components["parameters"]["MatchId"];
|
|
1315
|
+
pid: components["parameters"]["PlayerId"];
|
|
1316
|
+
};
|
|
1317
|
+
cookie?: never;
|
|
1318
|
+
};
|
|
1319
|
+
requestBody?: never;
|
|
1320
|
+
responses: {
|
|
1321
|
+
/** @description Player detail */
|
|
1322
|
+
200: {
|
|
1323
|
+
headers: {
|
|
1324
|
+
[name: string]: unknown;
|
|
1325
|
+
};
|
|
1326
|
+
content: {
|
|
1327
|
+
"application/json": {
|
|
1328
|
+
data?: components["schemas"]["PlayerDetail"];
|
|
1329
|
+
};
|
|
1330
|
+
};
|
|
1331
|
+
};
|
|
1332
|
+
401: components["responses"]["Unauthorized"];
|
|
1333
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1334
|
+
404: components["responses"]["NotFound"];
|
|
1335
|
+
429: components["responses"]["RateLimited"];
|
|
1336
|
+
};
|
|
1337
|
+
};
|
|
1338
|
+
getMatchPlayerHalf: {
|
|
1339
|
+
parameters: {
|
|
1340
|
+
query?: never;
|
|
1341
|
+
header?: never;
|
|
1342
|
+
path: {
|
|
1343
|
+
id: components["parameters"]["MatchId"];
|
|
1344
|
+
pid: components["parameters"]["PlayerId"];
|
|
1345
|
+
};
|
|
1346
|
+
cookie?: never;
|
|
1347
|
+
};
|
|
1348
|
+
requestBody?: never;
|
|
1349
|
+
responses: {
|
|
1350
|
+
/** @description Player halves */
|
|
1351
|
+
200: {
|
|
1352
|
+
headers: {
|
|
1353
|
+
[name: string]: unknown;
|
|
1354
|
+
};
|
|
1355
|
+
content: {
|
|
1356
|
+
"application/json": {
|
|
1357
|
+
data?: components["schemas"]["PlayerHalfDetail"];
|
|
1358
|
+
};
|
|
1359
|
+
};
|
|
1360
|
+
};
|
|
1361
|
+
401: components["responses"]["Unauthorized"];
|
|
1362
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1363
|
+
404: components["responses"]["NotFound"];
|
|
1364
|
+
429: components["responses"]["RateLimited"];
|
|
1365
|
+
};
|
|
1366
|
+
};
|
|
1367
|
+
getMatchPlayerShots: {
|
|
1368
|
+
parameters: {
|
|
1369
|
+
query?: never;
|
|
1370
|
+
header?: never;
|
|
1371
|
+
path: {
|
|
1372
|
+
id: components["parameters"]["MatchId"];
|
|
1373
|
+
pid: components["parameters"]["PlayerId"];
|
|
1374
|
+
};
|
|
1375
|
+
cookie?: never;
|
|
1376
|
+
};
|
|
1377
|
+
requestBody?: never;
|
|
1378
|
+
responses: {
|
|
1379
|
+
/** @description Player shots */
|
|
1380
|
+
200: {
|
|
1381
|
+
headers: {
|
|
1382
|
+
[name: string]: unknown;
|
|
1383
|
+
};
|
|
1384
|
+
content: {
|
|
1385
|
+
"application/json": {
|
|
1386
|
+
data?: components["schemas"]["PlayerShots"];
|
|
1387
|
+
};
|
|
1388
|
+
};
|
|
1389
|
+
};
|
|
1390
|
+
401: components["responses"]["Unauthorized"];
|
|
1391
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1392
|
+
429: components["responses"]["RateLimited"];
|
|
1393
|
+
};
|
|
1394
|
+
};
|
|
1395
|
+
getMatchH2H: {
|
|
1396
|
+
parameters: {
|
|
1397
|
+
query?: never;
|
|
1398
|
+
header?: never;
|
|
1399
|
+
path: {
|
|
1400
|
+
id: components["parameters"]["MatchId"];
|
|
1401
|
+
};
|
|
1402
|
+
cookie?: never;
|
|
1403
|
+
};
|
|
1404
|
+
requestBody?: never;
|
|
1405
|
+
responses: {
|
|
1406
|
+
/** @description Head-to-head */
|
|
1407
|
+
200: {
|
|
1408
|
+
headers: {
|
|
1409
|
+
[name: string]: unknown;
|
|
1410
|
+
};
|
|
1411
|
+
content: {
|
|
1412
|
+
"application/json": {
|
|
1413
|
+
data?: components["schemas"]["H2H"];
|
|
1414
|
+
};
|
|
1415
|
+
};
|
|
1416
|
+
};
|
|
1417
|
+
401: components["responses"]["Unauthorized"];
|
|
1418
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1419
|
+
404: components["responses"]["NotFound"];
|
|
1420
|
+
429: components["responses"]["RateLimited"];
|
|
1421
|
+
};
|
|
1422
|
+
};
|
|
1423
|
+
getMatchAdvanced: {
|
|
1424
|
+
parameters: {
|
|
1425
|
+
query?: never;
|
|
1426
|
+
header?: never;
|
|
1427
|
+
path: {
|
|
1428
|
+
id: components["parameters"]["MatchId"];
|
|
1429
|
+
};
|
|
1430
|
+
cookie?: never;
|
|
1431
|
+
};
|
|
1432
|
+
requestBody?: never;
|
|
1433
|
+
responses: {
|
|
1434
|
+
/** @description Advanced team rollups */
|
|
1435
|
+
200: {
|
|
1436
|
+
headers: {
|
|
1437
|
+
[name: string]: unknown;
|
|
1438
|
+
};
|
|
1439
|
+
content: {
|
|
1440
|
+
"application/json": {
|
|
1441
|
+
data?: components["schemas"]["AdvancedTeams"];
|
|
1442
|
+
};
|
|
1443
|
+
};
|
|
1444
|
+
};
|
|
1445
|
+
401: components["responses"]["Unauthorized"];
|
|
1446
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1447
|
+
404: components["responses"]["NotFound"];
|
|
1448
|
+
429: components["responses"]["RateLimited"];
|
|
1449
|
+
};
|
|
1450
|
+
};
|
|
1451
|
+
getMatchAdvancedNetwork: {
|
|
1452
|
+
parameters: {
|
|
1453
|
+
query?: never;
|
|
1454
|
+
header?: never;
|
|
1455
|
+
path: {
|
|
1456
|
+
id: components["parameters"]["MatchId"];
|
|
1457
|
+
};
|
|
1458
|
+
cookie?: never;
|
|
1459
|
+
};
|
|
1460
|
+
requestBody?: never;
|
|
1461
|
+
responses: {
|
|
1462
|
+
/** @description Pass networks */
|
|
1463
|
+
200: {
|
|
1464
|
+
headers: {
|
|
1465
|
+
[name: string]: unknown;
|
|
1466
|
+
};
|
|
1467
|
+
content: {
|
|
1468
|
+
"application/json": {
|
|
1469
|
+
data?: components["schemas"]["AdvancedNetworks"];
|
|
1470
|
+
};
|
|
1471
|
+
};
|
|
1472
|
+
};
|
|
1473
|
+
401: components["responses"]["Unauthorized"];
|
|
1474
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1475
|
+
404: components["responses"]["NotFound"];
|
|
1476
|
+
429: components["responses"]["RateLimited"];
|
|
1477
|
+
};
|
|
1478
|
+
};
|
|
1479
|
+
getMatchAdvancedPlayers: {
|
|
1480
|
+
parameters: {
|
|
1481
|
+
query?: never;
|
|
1482
|
+
header?: never;
|
|
1483
|
+
path: {
|
|
1484
|
+
id: components["parameters"]["MatchId"];
|
|
1485
|
+
};
|
|
1486
|
+
cookie?: never;
|
|
1487
|
+
};
|
|
1488
|
+
requestBody?: never;
|
|
1489
|
+
responses: {
|
|
1490
|
+
/** @description Advanced player rollups */
|
|
1491
|
+
200: {
|
|
1492
|
+
headers: {
|
|
1493
|
+
[name: string]: unknown;
|
|
1494
|
+
};
|
|
1495
|
+
content: {
|
|
1496
|
+
"application/json": {
|
|
1497
|
+
data?: components["schemas"]["AdvancedPlayers"];
|
|
1498
|
+
};
|
|
1499
|
+
};
|
|
1500
|
+
};
|
|
1501
|
+
401: components["responses"]["Unauthorized"];
|
|
1502
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1503
|
+
404: components["responses"]["NotFound"];
|
|
1504
|
+
429: components["responses"]["RateLimited"];
|
|
1505
|
+
};
|
|
1506
|
+
};
|
|
1507
|
+
getMatchAdvancedPlayer: {
|
|
1508
|
+
parameters: {
|
|
1509
|
+
query?: never;
|
|
1510
|
+
header?: never;
|
|
1511
|
+
path: {
|
|
1512
|
+
id: components["parameters"]["MatchId"];
|
|
1513
|
+
pid: components["parameters"]["PlayerId"];
|
|
1514
|
+
};
|
|
1515
|
+
cookie?: never;
|
|
1516
|
+
};
|
|
1517
|
+
requestBody?: never;
|
|
1518
|
+
responses: {
|
|
1519
|
+
/** @description Advanced player rollup */
|
|
1520
|
+
200: {
|
|
1521
|
+
headers: {
|
|
1522
|
+
[name: string]: unknown;
|
|
1523
|
+
};
|
|
1524
|
+
content: {
|
|
1525
|
+
"application/json": {
|
|
1526
|
+
data?: components["schemas"]["AdvancedPlayerStat"];
|
|
1527
|
+
};
|
|
1528
|
+
};
|
|
1529
|
+
};
|
|
1530
|
+
401: components["responses"]["Unauthorized"];
|
|
1531
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1532
|
+
404: components["responses"]["NotFound"];
|
|
1533
|
+
429: components["responses"]["RateLimited"];
|
|
1534
|
+
};
|
|
1535
|
+
};
|
|
1536
|
+
getMatchHeatmaps: {
|
|
1537
|
+
parameters: {
|
|
1538
|
+
query?: {
|
|
1539
|
+
/** @description Orientation to serve the cells in. `acting_ltr` (the default) gives every team its own attacking frame, which is what makes a player comparable across home and away fixtures. `home_ltr` puts both teams on one pitch — the home side attacking cell_x 15, the away side 0 — which is what a match view needs. The server applies the turn, so there is nothing to mirror client-side. */
|
|
1540
|
+
frame?: "acting_ltr" | "home_ltr";
|
|
1541
|
+
};
|
|
1542
|
+
header?: never;
|
|
1543
|
+
path: {
|
|
1544
|
+
id: components["parameters"]["MatchId"];
|
|
1545
|
+
};
|
|
1546
|
+
cookie?: never;
|
|
1547
|
+
};
|
|
1548
|
+
requestBody?: never;
|
|
1549
|
+
responses: {
|
|
1550
|
+
/** @description Heatmaps */
|
|
1551
|
+
200: {
|
|
1552
|
+
headers: {
|
|
1553
|
+
[name: string]: unknown;
|
|
1554
|
+
};
|
|
1555
|
+
content: {
|
|
1556
|
+
"application/json": {
|
|
1557
|
+
data?: components["schemas"]["MatchHeatmaps"];
|
|
1558
|
+
};
|
|
1559
|
+
};
|
|
1560
|
+
};
|
|
1561
|
+
401: components["responses"]["Unauthorized"];
|
|
1562
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1563
|
+
404: components["responses"]["NotFound"];
|
|
1564
|
+
429: components["responses"]["RateLimited"];
|
|
1565
|
+
};
|
|
1566
|
+
};
|
|
1567
|
+
listLeagues: {
|
|
1568
|
+
parameters: {
|
|
1569
|
+
query?: never;
|
|
1570
|
+
header?: never;
|
|
1571
|
+
path?: never;
|
|
1572
|
+
cookie?: never;
|
|
1573
|
+
};
|
|
1574
|
+
requestBody?: never;
|
|
1575
|
+
responses: {
|
|
1576
|
+
/** @description League list */
|
|
1577
|
+
200: {
|
|
1578
|
+
headers: {
|
|
1579
|
+
[name: string]: unknown;
|
|
1580
|
+
};
|
|
1581
|
+
content: {
|
|
1582
|
+
"application/json": {
|
|
1583
|
+
data?: {
|
|
1584
|
+
leagues: components["schemas"]["LeagueSummary"][];
|
|
1585
|
+
};
|
|
1586
|
+
};
|
|
1587
|
+
};
|
|
1588
|
+
};
|
|
1589
|
+
401: components["responses"]["Unauthorized"];
|
|
1590
|
+
429: components["responses"]["RateLimited"];
|
|
1591
|
+
};
|
|
1592
|
+
};
|
|
1593
|
+
getLeague: {
|
|
1594
|
+
parameters: {
|
|
1595
|
+
query?: never;
|
|
1596
|
+
header?: never;
|
|
1597
|
+
path: {
|
|
1598
|
+
id: components["parameters"]["LeagueId"];
|
|
1599
|
+
};
|
|
1600
|
+
cookie?: never;
|
|
1601
|
+
};
|
|
1602
|
+
requestBody?: never;
|
|
1603
|
+
responses: {
|
|
1604
|
+
/** @description League detail */
|
|
1605
|
+
200: {
|
|
1606
|
+
headers: {
|
|
1607
|
+
[name: string]: unknown;
|
|
1608
|
+
};
|
|
1609
|
+
content: {
|
|
1610
|
+
"application/json": {
|
|
1611
|
+
data?: components["schemas"]["League"];
|
|
1612
|
+
};
|
|
1613
|
+
};
|
|
1614
|
+
};
|
|
1615
|
+
400: components["responses"]["InvalidParameter"];
|
|
1616
|
+
401: components["responses"]["Unauthorized"];
|
|
1617
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1618
|
+
404: components["responses"]["NotFound"];
|
|
1619
|
+
429: components["responses"]["RateLimited"];
|
|
1620
|
+
};
|
|
1621
|
+
};
|
|
1622
|
+
getLeagueMatches: {
|
|
1623
|
+
parameters: {
|
|
1624
|
+
query?: {
|
|
1625
|
+
/** @description Season selector — `2025/2026` for a fall-spring league, `2026` for a calendar-year one. Omitted, the latest season with data is used. */
|
|
1626
|
+
season?: string;
|
|
1627
|
+
/** @description Which fixtures to return. `played` covers matches that have kicked off, `upcoming` future fixtures (a kickoff `time_utc` and a `status`, but no score yet), and `all` both. Omitting the parameter is the same as `played`; sending it empty is rejected. */
|
|
1628
|
+
status?: components["parameters"]["MatchStatus"];
|
|
1629
|
+
};
|
|
1630
|
+
header?: never;
|
|
1631
|
+
path: {
|
|
1632
|
+
id: components["parameters"]["LeagueId"];
|
|
1633
|
+
};
|
|
1634
|
+
cookie?: never;
|
|
1635
|
+
};
|
|
1636
|
+
requestBody?: never;
|
|
1637
|
+
responses: {
|
|
1638
|
+
/** @description League matches */
|
|
1639
|
+
200: {
|
|
1640
|
+
headers: {
|
|
1641
|
+
[name: string]: unknown;
|
|
1642
|
+
};
|
|
1643
|
+
content: {
|
|
1644
|
+
"application/json": {
|
|
1645
|
+
data?: components["schemas"]["LeagueMatches"];
|
|
1646
|
+
};
|
|
1647
|
+
};
|
|
1648
|
+
};
|
|
1649
|
+
400: components["responses"]["InvalidParameter"];
|
|
1650
|
+
401: components["responses"]["Unauthorized"];
|
|
1651
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1652
|
+
429: components["responses"]["RateLimited"];
|
|
1653
|
+
};
|
|
1654
|
+
};
|
|
1655
|
+
getTeam: {
|
|
1656
|
+
parameters: {
|
|
1657
|
+
query?: never;
|
|
1658
|
+
header?: never;
|
|
1659
|
+
path: {
|
|
1660
|
+
id: components["parameters"]["TeamId"];
|
|
1661
|
+
};
|
|
1662
|
+
cookie?: never;
|
|
1663
|
+
};
|
|
1664
|
+
requestBody?: never;
|
|
1665
|
+
responses: {
|
|
1666
|
+
/** @description Team profile */
|
|
1667
|
+
200: {
|
|
1668
|
+
headers: {
|
|
1669
|
+
[name: string]: unknown;
|
|
1670
|
+
};
|
|
1671
|
+
content: {
|
|
1672
|
+
"application/json": {
|
|
1673
|
+
data?: components["schemas"]["Team"];
|
|
1674
|
+
};
|
|
1675
|
+
};
|
|
1676
|
+
};
|
|
1677
|
+
400: components["responses"]["InvalidParameter"];
|
|
1678
|
+
401: components["responses"]["Unauthorized"];
|
|
1679
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1680
|
+
404: components["responses"]["NotFound"];
|
|
1681
|
+
429: components["responses"]["RateLimited"];
|
|
1682
|
+
};
|
|
1683
|
+
};
|
|
1684
|
+
getPlayer: {
|
|
1685
|
+
parameters: {
|
|
1686
|
+
query?: never;
|
|
1687
|
+
header?: never;
|
|
1688
|
+
path: {
|
|
1689
|
+
id: components["parameters"]["PlayerProfileId"];
|
|
1690
|
+
};
|
|
1691
|
+
cookie?: never;
|
|
1692
|
+
};
|
|
1693
|
+
requestBody?: never;
|
|
1694
|
+
responses: {
|
|
1695
|
+
/** @description Player profile */
|
|
1696
|
+
200: {
|
|
1697
|
+
headers: {
|
|
1698
|
+
[name: string]: unknown;
|
|
1699
|
+
};
|
|
1700
|
+
content: {
|
|
1701
|
+
"application/json": {
|
|
1702
|
+
data?: components["schemas"]["PlayerProfile"];
|
|
1703
|
+
};
|
|
1704
|
+
};
|
|
1705
|
+
};
|
|
1706
|
+
400: components["responses"]["InvalidParameter"];
|
|
1707
|
+
401: components["responses"]["Unauthorized"];
|
|
1708
|
+
403: components["responses"]["PlanUpgradeRequired"];
|
|
1709
|
+
404: components["responses"]["NotFound"];
|
|
1710
|
+
429: components["responses"]["RateLimited"];
|
|
1711
|
+
};
|
|
1712
|
+
};
|
|
1713
|
+
}
|
|
1714
|
+
|
|
1715
|
+
type FetchLike = (input: string, init?: RequestInit) => Promise<Response>;
|
|
1716
|
+
interface TransportOptions {
|
|
1717
|
+
apiKey: string;
|
|
1718
|
+
baseUrl: string;
|
|
1719
|
+
timeoutMs: number;
|
|
1720
|
+
maxRetries: number;
|
|
1721
|
+
fetch: FetchLike;
|
|
1722
|
+
sleep?: (ms: number) => Promise<void>;
|
|
1723
|
+
}
|
|
1724
|
+
type Query = Record<string, string | undefined>;
|
|
1725
|
+
declare class Transport {
|
|
1726
|
+
private readonly opts;
|
|
1727
|
+
private readonly headers;
|
|
1728
|
+
private readonly sleep;
|
|
1729
|
+
constructor(opts: TransportOptions);
|
|
1730
|
+
get<T>(path: string, query?: Query, signal?: AbortSignal): Promise<T>;
|
|
1731
|
+
private fetchOnce;
|
|
1732
|
+
}
|
|
1733
|
+
|
|
1734
|
+
/**
|
|
1735
|
+
* The PitchAPI client and its resource namespaces.
|
|
1736
|
+
*
|
|
1737
|
+
* import { PitchAPI } from "pitchapi";
|
|
1738
|
+
* const client = new PitchAPI({ apiKey: "pk_live_..." });
|
|
1739
|
+
* const match = await client.matches.get("m_4DP2fy");
|
|
1740
|
+
*
|
|
1741
|
+
* Every method returns the `data` object of its endpoint, typed from the
|
|
1742
|
+
* OpenAPI spec, so the reference at pitchapi.dev is the field-level reference
|
|
1743
|
+
* for the SDK too.
|
|
1744
|
+
*/
|
|
1745
|
+
|
|
1746
|
+
/** The `data` payload of an operation's 200 response. */
|
|
1747
|
+
type Data<Op extends keyof operations> = NonNullable<operations[Op]["responses"][200]["content"]["application/json"]["data"]>;
|
|
1748
|
+
type LeaguesList = Data<"listLeagues">;
|
|
1749
|
+
/**
|
|
1750
|
+
* Which fixtures a match listing returns: `played` (the API's default) only
|
|
1751
|
+
* matches that have kicked off, `upcoming` only future fixtures, `all` both.
|
|
1752
|
+
*/
|
|
1753
|
+
type MatchStatus = "played" | "upcoming" | "all";
|
|
1754
|
+
/**
|
|
1755
|
+
* Heatmap orientation. `acting_ltr` (default) gives every team its own
|
|
1756
|
+
* attacking frame; `home_ltr` puts both teams on one pitch. The server applies
|
|
1757
|
+
* the turn, so there is nothing to mirror client-side.
|
|
1758
|
+
*/
|
|
1759
|
+
type HeatmapFrame = "acting_ltr" | "home_ltr";
|
|
1760
|
+
/** Per-call options accepted by every method. */
|
|
1761
|
+
interface RequestOptions {
|
|
1762
|
+
/** Abort the request (and any pending retry) from the caller's side. */
|
|
1763
|
+
signal?: AbortSignal;
|
|
1764
|
+
}
|
|
1765
|
+
interface PitchAPIOptions {
|
|
1766
|
+
/**
|
|
1767
|
+
* A `pk_live_` / `pk_test_` key. Falls back to the `PITCHAPI_API_KEY`
|
|
1768
|
+
* environment variable. Keep it server-side, never in browser code.
|
|
1769
|
+
*/
|
|
1770
|
+
apiKey?: string;
|
|
1771
|
+
/** Override the API host (testing, proxies). Falls back to `PITCHAPI_BASE_URL`. */
|
|
1772
|
+
baseUrl?: string;
|
|
1773
|
+
/** Per-attempt timeout in milliseconds. Default 30000. */
|
|
1774
|
+
timeoutMs?: number;
|
|
1775
|
+
/** Replays on 429/5xx and network errors. `0` disables retries. Default 2. */
|
|
1776
|
+
maxRetries?: number;
|
|
1777
|
+
/** A custom `fetch` implementation. Defaults to the global one. */
|
|
1778
|
+
fetch?: FetchLike;
|
|
1779
|
+
}
|
|
1780
|
+
declare abstract class Resource {
|
|
1781
|
+
protected readonly t: Transport;
|
|
1782
|
+
constructor(t: Transport);
|
|
1783
|
+
protected request<T>(path: string, opts: RequestOptions | undefined, query?: Query): Promise<T>;
|
|
1784
|
+
}
|
|
1785
|
+
/** `/date` — the per-day match index. */
|
|
1786
|
+
declare class DateResource extends Resource {
|
|
1787
|
+
/**
|
|
1788
|
+
* Every match on a day. `date` is a `YYYY-MM-DD` string or a `Date`, which
|
|
1789
|
+
* is read in UTC. An upcoming fixture carries a kickoff `time_utc` and a
|
|
1790
|
+
* `status` but no score yet.
|
|
1791
|
+
*/
|
|
1792
|
+
get(date: string | Date, opts?: {
|
|
1793
|
+
status?: MatchStatus;
|
|
1794
|
+
} & RequestOptions): Promise<Data<"getMatchesByDate">>;
|
|
1795
|
+
}
|
|
1796
|
+
/** `/matches` and all of its sub-routes. */
|
|
1797
|
+
declare class MatchesResource extends Resource {
|
|
1798
|
+
/** Match summary — league, teams, score, referee, stadium. */
|
|
1799
|
+
get(matchId: string, opts?: RequestOptions): Promise<Data<"getMatch">>;
|
|
1800
|
+
/** Every shot, grouped by period, with pitch coordinates and xG. */
|
|
1801
|
+
shots(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchShots">>;
|
|
1802
|
+
/** A single shot by its opaque ID. */
|
|
1803
|
+
shot(matchId: string, shotId: string, opts?: RequestOptions): Promise<Data<"getShot">>;
|
|
1804
|
+
/** Match events (goals, cards, subs, ...). */
|
|
1805
|
+
events(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchEvents">>;
|
|
1806
|
+
/** Starting lineups and substitutes. Before kickoff the XI may be predicted. */
|
|
1807
|
+
lineups(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchLineups">>;
|
|
1808
|
+
/** Possession-momentum timeline. */
|
|
1809
|
+
momentum(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchMomentum">>;
|
|
1810
|
+
/** Team-level match statistics. */
|
|
1811
|
+
stats(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchStats">>;
|
|
1812
|
+
/** Per-player match stat lines. */
|
|
1813
|
+
players(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchPlayers">>;
|
|
1814
|
+
/** One player's match stat line. */
|
|
1815
|
+
player(matchId: string, playerId: string, opts?: RequestOptions): Promise<Data<"getMatchPlayer">>;
|
|
1816
|
+
/**
|
|
1817
|
+
* Every player's stat line for the first and the second half. Throws
|
|
1818
|
+
* `NotFoundError` (code `HALVES_UNAVAILABLE`) for a match without them.
|
|
1819
|
+
*/
|
|
1820
|
+
playersHalves(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchPlayerHalves">>;
|
|
1821
|
+
/** One player's stat line for each half they played. */
|
|
1822
|
+
playerHalves(matchId: string, playerId: string, opts?: RequestOptions): Promise<Data<"getMatchPlayerHalf">>;
|
|
1823
|
+
/** A single player's shots in the match. */
|
|
1824
|
+
playerShots(matchId: string, playerId: string, opts?: RequestOptions): Promise<Data<"getMatchPlayerShots">>;
|
|
1825
|
+
/** Head-to-head history for the two sides. */
|
|
1826
|
+
h2h(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchH2H">>;
|
|
1827
|
+
/**
|
|
1828
|
+
* Team advanced rollups (PPDA, field tilt, xG timeline). Throws
|
|
1829
|
+
* `NotFoundError` (code `ANALYTICS_UNAVAILABLE`) for a match not yet rated.
|
|
1830
|
+
*/
|
|
1831
|
+
advanced(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchAdvanced">>;
|
|
1832
|
+
/** Pass networks for both sides. */
|
|
1833
|
+
advancedNetwork(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchAdvancedNetwork">>;
|
|
1834
|
+
/** Player-level advanced rollups. */
|
|
1835
|
+
advancedPlayers(matchId: string, opts?: RequestOptions): Promise<Data<"getMatchAdvancedPlayers">>;
|
|
1836
|
+
/** One player's advanced rollup. */
|
|
1837
|
+
advancedPlayer(matchId: string, playerId: string, opts?: RequestOptions): Promise<Data<"getMatchAdvancedPlayer">>;
|
|
1838
|
+
/**
|
|
1839
|
+
* Binned activity for both teams and every player who touched the ball.
|
|
1840
|
+
* Cells are sparse `[cell_x, cell_y, actions]` triples on a 16x12 grid.
|
|
1841
|
+
*/
|
|
1842
|
+
heatmaps(matchId: string, opts?: {
|
|
1843
|
+
frame?: HeatmapFrame;
|
|
1844
|
+
} & RequestOptions): Promise<Data<"getMatchHeatmaps">>;
|
|
1845
|
+
}
|
|
1846
|
+
/** `/leagues`. */
|
|
1847
|
+
declare class LeaguesResource extends Resource {
|
|
1848
|
+
/** All leagues, each with its accepted seasons and coverage. */
|
|
1849
|
+
list(opts?: RequestOptions): Promise<LeaguesList>;
|
|
1850
|
+
/** League detail. */
|
|
1851
|
+
get(leagueId: string, opts?: RequestOptions): Promise<Data<"getLeague">>;
|
|
1852
|
+
/**
|
|
1853
|
+
* Matches in a league. `season` is `"2025/2026"` for a fall-spring league
|
|
1854
|
+
* and `"2026"` for a calendar-year one; omitted, the latest season with
|
|
1855
|
+
* data. The season is resolved before `status` applies, so `upcoming` on a
|
|
1856
|
+
* finished season is an empty list.
|
|
1857
|
+
*/
|
|
1858
|
+
matches(leagueId: string, opts?: {
|
|
1859
|
+
season?: string;
|
|
1860
|
+
status?: MatchStatus;
|
|
1861
|
+
} & RequestOptions): Promise<Data<"getLeagueMatches">>;
|
|
1862
|
+
}
|
|
1863
|
+
/** `/teams`. */
|
|
1864
|
+
declare class TeamsResource extends Resource {
|
|
1865
|
+
/** Team profile. */
|
|
1866
|
+
get(teamId: string, opts?: RequestOptions): Promise<Data<"getTeam">>;
|
|
1867
|
+
}
|
|
1868
|
+
/** `/players` — the standalone profile. Per-match stats live under `matches`. */
|
|
1869
|
+
declare class PlayersResource extends Resource {
|
|
1870
|
+
/** Player profile. */
|
|
1871
|
+
get(playerId: string, opts?: RequestOptions): Promise<Data<"getPlayer">>;
|
|
1872
|
+
}
|
|
1873
|
+
declare class PitchAPI {
|
|
1874
|
+
readonly date: DateResource;
|
|
1875
|
+
readonly matches: MatchesResource;
|
|
1876
|
+
readonly leagues: LeaguesResource;
|
|
1877
|
+
readonly teams: TeamsResource;
|
|
1878
|
+
readonly players: PlayersResource;
|
|
1879
|
+
constructor(options?: PitchAPIOptions);
|
|
1880
|
+
}
|
|
1881
|
+
|
|
1882
|
+
/**
|
|
1883
|
+
* Error hierarchy for the PitchAPI SDK.
|
|
1884
|
+
*
|
|
1885
|
+
* Every error the API returns carries a stable `error.code` string in its
|
|
1886
|
+
* envelope. Errors are mapped from that code first and the HTTP status second,
|
|
1887
|
+
* so callers can branch on a semantic type rather than parsing status numbers.
|
|
1888
|
+
*/
|
|
1889
|
+
type ErrorCode = "INVALID_PARAMETER" | "UNAUTHORIZED" | "SUBSCRIPTION_SUSPENDED" | "PLAN_UPGRADE_REQUIRED" | "RESOURCE_NOT_FOUND" | "ANALYTICS_UNAVAILABLE" | "HALVES_UNAVAILABLE" | "RATE_LIMIT_EXCEEDED" | "INTERNAL_SERVER_ERROR";
|
|
1890
|
+
interface PitchAPIErrorOptions {
|
|
1891
|
+
/** The stable `error.code`, when the failure came from the API envelope. */
|
|
1892
|
+
code?: string | undefined;
|
|
1893
|
+
/** The HTTP status, when there was a response. */
|
|
1894
|
+
status?: number | undefined;
|
|
1895
|
+
/** The `X-Request-ID` echoed by the API — quote it in support threads. */
|
|
1896
|
+
requestId?: string | undefined;
|
|
1897
|
+
cause?: unknown;
|
|
1898
|
+
}
|
|
1899
|
+
/** Base class for every error thrown by the SDK. */
|
|
1900
|
+
declare class PitchAPIError extends Error {
|
|
1901
|
+
readonly code: string | undefined;
|
|
1902
|
+
readonly status: number | undefined;
|
|
1903
|
+
readonly requestId: string | undefined;
|
|
1904
|
+
constructor(message: string, options?: PitchAPIErrorOptions);
|
|
1905
|
+
}
|
|
1906
|
+
/** The request never produced a response (network error, timeout, DNS). */
|
|
1907
|
+
declare class APIConnectionError extends PitchAPIError {
|
|
1908
|
+
}
|
|
1909
|
+
/** 400 INVALID_PARAMETER — a malformed ID, date, or season. */
|
|
1910
|
+
declare class InvalidParameterError extends PitchAPIError {
|
|
1911
|
+
}
|
|
1912
|
+
/** 401 UNAUTHORIZED — the API key is missing, malformed, or revoked. */
|
|
1913
|
+
declare class AuthError extends PitchAPIError {
|
|
1914
|
+
}
|
|
1915
|
+
/** 403 SUBSCRIPTION_SUSPENDED — the account's subscription is not active. */
|
|
1916
|
+
declare class SubscriptionSuspendedError extends PitchAPIError {
|
|
1917
|
+
}
|
|
1918
|
+
/** 403 PLAN_UPGRADE_REQUIRED — the resource's league is not on the account's plan. */
|
|
1919
|
+
declare class PlanUpgradeRequiredError extends PitchAPIError {
|
|
1920
|
+
}
|
|
1921
|
+
/**
|
|
1922
|
+
* 404 — the resource does not exist, or its analytics or halves are unavailable.
|
|
1923
|
+
*
|
|
1924
|
+
* `code` distinguishes `RESOURCE_NOT_FOUND` from `ANALYTICS_UNAVAILABLE` and
|
|
1925
|
+
* `HALVES_UNAVAILABLE`.
|
|
1926
|
+
*/
|
|
1927
|
+
declare class NotFoundError extends PitchAPIError {
|
|
1928
|
+
}
|
|
1929
|
+
/**
|
|
1930
|
+
* 429 RATE_LIMIT_EXCEEDED — the per-user fair-use ceiling was hit.
|
|
1931
|
+
*
|
|
1932
|
+
* `retryAfter` is the number of seconds the API asked the client to wait, from
|
|
1933
|
+
* the `Retry-After` header; `undefined` if the header was absent. Retries are
|
|
1934
|
+
* automatic, so this means the client already backed off and tried again.
|
|
1935
|
+
*/
|
|
1936
|
+
declare class RateLimitError extends PitchAPIError {
|
|
1937
|
+
readonly retryAfter: number | undefined;
|
|
1938
|
+
constructor(message: string, options?: PitchAPIErrorOptions & {
|
|
1939
|
+
retryAfter?: number | undefined;
|
|
1940
|
+
});
|
|
1941
|
+
}
|
|
1942
|
+
/** 5xx — the API failed to serve the request. */
|
|
1943
|
+
declare class ServerError extends PitchAPIError {
|
|
1944
|
+
}
|
|
1945
|
+
|
|
1946
|
+
/**
|
|
1947
|
+
* The package version. `package.json` is the other place it is written; the
|
|
1948
|
+
* release workflow and `test/version.test.ts` refuse a build where the two
|
|
1949
|
+
* disagree, and this is what the client reports as its `User-Agent`.
|
|
1950
|
+
*/
|
|
1951
|
+
declare const VERSION = "0.1.1";
|
|
1952
|
+
|
|
1953
|
+
type S = components["schemas"];
|
|
1954
|
+
type ErrorEnvelope = S["ErrorEnvelope"];
|
|
1955
|
+
type LeagueRef = S["LeagueRef"];
|
|
1956
|
+
type TeamRef = S["TeamRef"];
|
|
1957
|
+
type TeamNameRef = S["TeamNameRef"];
|
|
1958
|
+
type PlayerRef = S["PlayerRef"];
|
|
1959
|
+
type AdvancedPlayerRef = S["AdvancedPlayerRef"];
|
|
1960
|
+
type CoachRef = S["CoachRef"];
|
|
1961
|
+
type Match = S["Match"];
|
|
1962
|
+
type MatchSummary = S["MatchSummary"];
|
|
1963
|
+
type DateMatches = S["DateMatches"];
|
|
1964
|
+
type Shot = S["Shot"];
|
|
1965
|
+
type ShotPeriod = S["ShotPeriod"];
|
|
1966
|
+
type Shots = S["Shots"];
|
|
1967
|
+
type PlayerShots = S["PlayerShots"];
|
|
1968
|
+
type Event = S["Event"];
|
|
1969
|
+
type Events = S["Events"];
|
|
1970
|
+
type LineupPlayer = S["LineupPlayer"];
|
|
1971
|
+
type LineupSide = S["LineupSide"];
|
|
1972
|
+
type Lineups = S["Lineups"];
|
|
1973
|
+
type MomentumPoint = S["MomentumPoint"];
|
|
1974
|
+
type Momentum = S["Momentum"];
|
|
1975
|
+
type MatchStatItem = S["MatchStatItem"];
|
|
1976
|
+
type MatchStatGroup = S["MatchStatGroup"];
|
|
1977
|
+
type MatchStatPeriod = S["MatchStatPeriod"];
|
|
1978
|
+
type MatchStats = S["MatchStats"];
|
|
1979
|
+
type PlayerMatchStats = S["PlayerMatchStats"];
|
|
1980
|
+
type PlayerDetail = S["PlayerDetail"];
|
|
1981
|
+
type PlayerHalfStats = S["PlayerHalfStats"];
|
|
1982
|
+
type PlayerHalves = S["PlayerHalves"];
|
|
1983
|
+
type MatchPlayerHalves = S["MatchPlayerHalves"];
|
|
1984
|
+
type PlayerHalfDetail = S["PlayerHalfDetail"];
|
|
1985
|
+
type H2HMatch = S["H2HMatch"];
|
|
1986
|
+
type H2H = S["H2H"];
|
|
1987
|
+
type League = S["League"];
|
|
1988
|
+
type LeagueSummary = S["LeagueSummary"];
|
|
1989
|
+
type LeagueSeasonRef = S["LeagueSeasonRef"];
|
|
1990
|
+
type LeagueMatchSummary = S["LeagueMatchSummary"];
|
|
1991
|
+
type LeagueMatches = S["LeagueMatches"];
|
|
1992
|
+
type Team = S["Team"];
|
|
1993
|
+
type PlayerProfile = S["PlayerProfile"];
|
|
1994
|
+
type PossessionValue = S["PossessionValue"];
|
|
1995
|
+
type PassingStats = S["PassingStats"];
|
|
1996
|
+
type CarryingStats = S["CarryingStats"];
|
|
1997
|
+
type TeamSCABreakdown = S["TeamSCABreakdown"];
|
|
1998
|
+
type TeamCreation = S["TeamCreation"];
|
|
1999
|
+
type PlayerSCABreakdown = S["PlayerSCABreakdown"];
|
|
2000
|
+
type PlayerCreation = S["PlayerCreation"];
|
|
2001
|
+
type PlayerDefending = S["PlayerDefending"];
|
|
2002
|
+
type TeamDefending = S["TeamDefending"];
|
|
2003
|
+
type TerritoryStats = S["TerritoryStats"];
|
|
2004
|
+
type TempoStats = S["TempoStats"];
|
|
2005
|
+
type Goalkeeping = S["Goalkeeping"];
|
|
2006
|
+
type AdvancedTeamStat = S["AdvancedTeamStat"];
|
|
2007
|
+
type AdvancedTeams = S["AdvancedTeams"];
|
|
2008
|
+
type AdvancedPlayerStat = S["AdvancedPlayerStat"];
|
|
2009
|
+
type AdvancedPlayers = S["AdvancedPlayers"];
|
|
2010
|
+
type NetworkWindow = S["NetworkWindow"];
|
|
2011
|
+
type PassNetworkNode = S["PassNetworkNode"];
|
|
2012
|
+
type PassNetworkEdge = S["PassNetworkEdge"];
|
|
2013
|
+
type PassNetwork = S["PassNetwork"];
|
|
2014
|
+
type AdvancedNetworks = S["AdvancedNetworks"];
|
|
2015
|
+
type HeatmapGrid = S["HeatmapGrid"];
|
|
2016
|
+
type HeatmapCells = S["HeatmapCells"];
|
|
2017
|
+
type TeamHeatmap = S["TeamHeatmap"];
|
|
2018
|
+
type PlayerHeatmap = S["PlayerHeatmap"];
|
|
2019
|
+
type MatchHeatmaps = S["MatchHeatmaps"];
|
|
2020
|
+
|
|
2021
|
+
export { APIConnectionError, type AdvancedNetworks, type AdvancedPlayerRef, type AdvancedPlayerStat, type AdvancedPlayers, type AdvancedTeamStat, type AdvancedTeams, AuthError, type CarryingStats, type CoachRef, type DateMatches, type ErrorCode, type ErrorEnvelope, type Event, type Events, type FetchLike, type Goalkeeping, type H2H, type H2HMatch, type HeatmapCells, type HeatmapFrame, type HeatmapGrid, InvalidParameterError, type League, type LeagueMatchSummary, type LeagueMatches, type LeagueRef, type LeagueSeasonRef, type LeagueSummary, type LeaguesList, type LineupPlayer, type LineupSide, type Lineups, type Match, type MatchHeatmaps, type MatchPlayerHalves, type MatchStatGroup, type MatchStatItem, type MatchStatPeriod, type MatchStats, type MatchStatus, type MatchSummary, type Momentum, type MomentumPoint, type NetworkWindow, NotFoundError, type PassNetwork, type PassNetworkEdge, type PassNetworkNode, type PassingStats, PitchAPI, PitchAPIError, type PitchAPIErrorOptions, type PitchAPIOptions, PlanUpgradeRequiredError, type PlayerCreation, type PlayerDefending, type PlayerDetail, type PlayerHalfDetail, type PlayerHalfStats, type PlayerHalves, type PlayerHeatmap, type PlayerMatchStats, type PlayerProfile, type PlayerRef, type PlayerSCABreakdown, type PlayerShots, type PossessionValue, RateLimitError, type RequestOptions, ServerError, type Shot, type ShotPeriod, type Shots, SubscriptionSuspendedError, type Team, type TeamCreation, type TeamDefending, type TeamHeatmap, type TeamNameRef, type TeamRef, type TeamSCABreakdown, type TempoStats, type TerritoryStats, VERSION, type components, type operations, type paths };
|