@bp1222/stats-api 0.1.5 → 0.1.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,337 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * MLB StatAPI
5
- * An spec API to consume the MLB Stat API
6
- *
7
- * The version of the OpenAPI document: 0.1.5
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
- import { mapValues } from '../runtime';
16
- import type { MLBStreak } from './MLBStreak';
17
- import {
18
- MLBStreakFromJSON,
19
- MLBStreakFromJSONTyped,
20
- MLBStreakToJSON,
21
- } from './MLBStreak';
22
- import type { MLBTeam } from './MLBTeam';
23
- import {
24
- MLBTeamFromJSON,
25
- MLBTeamFromJSONTyped,
26
- MLBTeamToJSON,
27
- } from './MLBTeam';
28
- import type { MLBLeagueRecord } from './MLBLeagueRecord';
29
- import {
30
- MLBLeagueRecordFromJSON,
31
- MLBLeagueRecordFromJSONTyped,
32
- MLBLeagueRecordToJSON,
33
- } from './MLBLeagueRecord';
34
-
35
- /**
36
- * Record
37
- *
38
- * @export
39
- * @interface MLBRecord
40
- */
41
- export interface MLBRecord {
42
- /**
43
- *
44
- * @type {MLBTeam}
45
- * @memberof MLBRecord
46
- */
47
- team: MLBTeam;
48
- /**
49
- *
50
- * @type {string}
51
- * @memberof MLBRecord
52
- */
53
- season: string;
54
- /**
55
- *
56
- * @type {MLBStreak}
57
- * @memberof MLBRecord
58
- */
59
- streak: MLBStreak;
60
- /**
61
- *
62
- * @type {string}
63
- * @memberof MLBRecord
64
- */
65
- divisionRank: string;
66
- /**
67
- *
68
- * @type {string}
69
- * @memberof MLBRecord
70
- */
71
- leagueRank: string;
72
- /**
73
- *
74
- * @type {string}
75
- * @memberof MLBRecord
76
- */
77
- sportRank?: string;
78
- /**
79
- *
80
- * @type {number}
81
- * @memberof MLBRecord
82
- */
83
- gamesPlayed?: number;
84
- /**
85
- *
86
- * @type {string}
87
- * @memberof MLBRecord
88
- */
89
- gamesBack: string;
90
- /**
91
- *
92
- * @type {string}
93
- * @memberof MLBRecord
94
- */
95
- wildCardGamesBack?: string;
96
- /**
97
- *
98
- * @type {string}
99
- * @memberof MLBRecord
100
- */
101
- leagueGamesBack?: string;
102
- /**
103
- *
104
- * @type {string}
105
- * @memberof MLBRecord
106
- */
107
- sportGamesBack?: string;
108
- /**
109
- *
110
- * @type {string}
111
- * @memberof MLBRecord
112
- */
113
- divisionGamesBack?: string;
114
- /**
115
- *
116
- * @type {string}
117
- * @memberof MLBRecord
118
- */
119
- conferenceGamesBack?: string;
120
- /**
121
- *
122
- * @type {MLBLeagueRecord}
123
- * @memberof MLBRecord
124
- */
125
- leagueRecord: MLBLeagueRecord;
126
- /**
127
- *
128
- * @type {string}
129
- * @memberof MLBRecord
130
- */
131
- lastUpdated?: string;
132
- /**
133
- *
134
- * @type {number}
135
- * @memberof MLBRecord
136
- */
137
- runsAllowed?: number;
138
- /**
139
- *
140
- * @type {number}
141
- * @memberof MLBRecord
142
- */
143
- runsScored?: number;
144
- /**
145
- *
146
- * @type {boolean}
147
- * @memberof MLBRecord
148
- */
149
- divisionChamp?: boolean;
150
- /**
151
- *
152
- * @type {boolean}
153
- * @memberof MLBRecord
154
- */
155
- divisionLeader?: boolean;
156
- /**
157
- *
158
- * @type {boolean}
159
- * @memberof MLBRecord
160
- */
161
- hasWildcard?: boolean;
162
- /**
163
- *
164
- * @type {boolean}
165
- * @memberof MLBRecord
166
- */
167
- clinched?: boolean;
168
- /**
169
- *
170
- * @type {string}
171
- * @memberof MLBRecord
172
- */
173
- eliminationNumber?: string;
174
- /**
175
- *
176
- * @type {string}
177
- * @memberof MLBRecord
178
- */
179
- eliminationNumberSport?: string;
180
- /**
181
- *
182
- * @type {string}
183
- * @memberof MLBRecord
184
- */
185
- eliminationNumberLeague?: string;
186
- /**
187
- *
188
- * @type {string}
189
- * @memberof MLBRecord
190
- */
191
- eliminationNumberDivision?: string;
192
- /**
193
- *
194
- * @type {string}
195
- * @memberof MLBRecord
196
- */
197
- eliminationNumberConference?: string;
198
- /**
199
- *
200
- * @type {string}
201
- * @memberof MLBRecord
202
- */
203
- wildCardEliminationNumber?: string;
204
- /**
205
- *
206
- * @type {string}
207
- * @memberof MLBRecord
208
- */
209
- magicNumber?: string;
210
- /**
211
- *
212
- * @type {number}
213
- * @memberof MLBRecord
214
- */
215
- wins: number;
216
- /**
217
- *
218
- * @type {number}
219
- * @memberof MLBRecord
220
- */
221
- losses: number;
222
- /**
223
- *
224
- * @type {number}
225
- * @memberof MLBRecord
226
- */
227
- runDifferential?: number;
228
- /**
229
- *
230
- * @type {string}
231
- * @memberof MLBRecord
232
- */
233
- winningPercentage?: string;
234
- }
235
-
236
- /**
237
- * Check if a given object implements the MLBRecord interface.
238
- */
239
- export function instanceOfMLBRecord(value: object): value is MLBRecord {
240
- if (!('team' in value) || value['team'] === undefined) return false;
241
- if (!('season' in value) || value['season'] === undefined) return false;
242
- if (!('streak' in value) || value['streak'] === undefined) return false;
243
- if (!('divisionRank' in value) || value['divisionRank'] === undefined) return false;
244
- if (!('leagueRank' in value) || value['leagueRank'] === undefined) return false;
245
- if (!('gamesBack' in value) || value['gamesBack'] === undefined) return false;
246
- if (!('leagueRecord' in value) || value['leagueRecord'] === undefined) return false;
247
- if (!('wins' in value) || value['wins'] === undefined) return false;
248
- if (!('losses' in value) || value['losses'] === undefined) return false;
249
- return true;
250
- }
251
-
252
- export function MLBRecordFromJSON(json: any): MLBRecord {
253
- return MLBRecordFromJSONTyped(json, false);
254
- }
255
-
256
- export function MLBRecordFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBRecord {
257
- if (json == null) {
258
- return json;
259
- }
260
- return {
261
-
262
- 'team': MLBTeamFromJSON(json['team']),
263
- 'season': json['season'],
264
- 'streak': MLBStreakFromJSON(json['streak']),
265
- 'divisionRank': json['divisionRank'],
266
- 'leagueRank': json['leagueRank'],
267
- 'sportRank': json['sportRank'] == null ? undefined : json['sportRank'],
268
- 'gamesPlayed': json['gamesPlayed'] == null ? undefined : json['gamesPlayed'],
269
- 'gamesBack': json['gamesBack'],
270
- 'wildCardGamesBack': json['wildCardGamesBack'] == null ? undefined : json['wildCardGamesBack'],
271
- 'leagueGamesBack': json['leagueGamesBack'] == null ? undefined : json['leagueGamesBack'],
272
- 'sportGamesBack': json['sportGamesBack'] == null ? undefined : json['sportGamesBack'],
273
- 'divisionGamesBack': json['divisionGamesBack'] == null ? undefined : json['divisionGamesBack'],
274
- 'conferenceGamesBack': json['conferenceGamesBack'] == null ? undefined : json['conferenceGamesBack'],
275
- 'leagueRecord': MLBLeagueRecordFromJSON(json['leagueRecord']),
276
- 'lastUpdated': json['lastUpdated'] == null ? undefined : json['lastUpdated'],
277
- 'runsAllowed': json['runsAllowed'] == null ? undefined : json['runsAllowed'],
278
- 'runsScored': json['runsScored'] == null ? undefined : json['runsScored'],
279
- 'divisionChamp': json['divisionChamp'] == null ? undefined : json['divisionChamp'],
280
- 'divisionLeader': json['divisionLeader'] == null ? undefined : json['divisionLeader'],
281
- 'hasWildcard': json['hasWildcard'] == null ? undefined : json['hasWildcard'],
282
- 'clinched': json['clinched'] == null ? undefined : json['clinched'],
283
- 'eliminationNumber': json['eliminationNumber'] == null ? undefined : json['eliminationNumber'],
284
- 'eliminationNumberSport': json['eliminationNumberSport'] == null ? undefined : json['eliminationNumberSport'],
285
- 'eliminationNumberLeague': json['eliminationNumberLeague'] == null ? undefined : json['eliminationNumberLeague'],
286
- 'eliminationNumberDivision': json['eliminationNumberDivision'] == null ? undefined : json['eliminationNumberDivision'],
287
- 'eliminationNumberConference': json['eliminationNumberConference'] == null ? undefined : json['eliminationNumberConference'],
288
- 'wildCardEliminationNumber': json['wildCardEliminationNumber'] == null ? undefined : json['wildCardEliminationNumber'],
289
- 'magicNumber': json['magicNumber'] == null ? undefined : json['magicNumber'],
290
- 'wins': json['wins'],
291
- 'losses': json['losses'],
292
- 'runDifferential': json['runDifferential'] == null ? undefined : json['runDifferential'],
293
- 'winningPercentage': json['winningPercentage'] == null ? undefined : json['winningPercentage'],
294
- };
295
- }
296
-
297
- export function MLBRecordToJSON(value?: MLBRecord | null): any {
298
- if (value == null) {
299
- return value;
300
- }
301
- return {
302
-
303
- 'team': MLBTeamToJSON(value['team']),
304
- 'season': value['season'],
305
- 'streak': MLBStreakToJSON(value['streak']),
306
- 'divisionRank': value['divisionRank'],
307
- 'leagueRank': value['leagueRank'],
308
- 'sportRank': value['sportRank'],
309
- 'gamesPlayed': value['gamesPlayed'],
310
- 'gamesBack': value['gamesBack'],
311
- 'wildCardGamesBack': value['wildCardGamesBack'],
312
- 'leagueGamesBack': value['leagueGamesBack'],
313
- 'sportGamesBack': value['sportGamesBack'],
314
- 'divisionGamesBack': value['divisionGamesBack'],
315
- 'conferenceGamesBack': value['conferenceGamesBack'],
316
- 'leagueRecord': MLBLeagueRecordToJSON(value['leagueRecord']),
317
- 'lastUpdated': value['lastUpdated'],
318
- 'runsAllowed': value['runsAllowed'],
319
- 'runsScored': value['runsScored'],
320
- 'divisionChamp': value['divisionChamp'],
321
- 'divisionLeader': value['divisionLeader'],
322
- 'hasWildcard': value['hasWildcard'],
323
- 'clinched': value['clinched'],
324
- 'eliminationNumber': value['eliminationNumber'],
325
- 'eliminationNumberSport': value['eliminationNumberSport'],
326
- 'eliminationNumberLeague': value['eliminationNumberLeague'],
327
- 'eliminationNumberDivision': value['eliminationNumberDivision'],
328
- 'eliminationNumberConference': value['eliminationNumberConference'],
329
- 'wildCardEliminationNumber': value['wildCardEliminationNumber'],
330
- 'magicNumber': value['magicNumber'],
331
- 'wins': value['wins'],
332
- 'losses': value['losses'],
333
- 'runDifferential': value['runDifferential'],
334
- 'winningPercentage': value['winningPercentage'],
335
- };
336
- }
337
-
@@ -1,105 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * MLB StatAPI
5
- * An spec API to consume the MLB Stat API
6
- *
7
- * The version of the OpenAPI document: 0.1.5
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
- import { mapValues } from '../runtime';
16
- import type { MLBScheduleDay } from './MLBScheduleDay';
17
- import {
18
- MLBScheduleDayFromJSON,
19
- MLBScheduleDayFromJSONTyped,
20
- MLBScheduleDayToJSON,
21
- } from './MLBScheduleDay';
22
-
23
- /**
24
- * Schedule
25
- *
26
- * @export
27
- * @interface MLBSchedule
28
- */
29
- export interface MLBSchedule {
30
- /**
31
- *
32
- * @type {number}
33
- * @memberof MLBSchedule
34
- */
35
- totalItems: number;
36
- /**
37
- *
38
- * @type {number}
39
- * @memberof MLBSchedule
40
- */
41
- totalEvents: number;
42
- /**
43
- *
44
- * @type {number}
45
- * @memberof MLBSchedule
46
- */
47
- totalGames: number;
48
- /**
49
- *
50
- * @type {number}
51
- * @memberof MLBSchedule
52
- */
53
- totalGamesInProgress: number;
54
- /**
55
- *
56
- * @type {Array<MLBScheduleDay>}
57
- * @memberof MLBSchedule
58
- */
59
- dates: Array<MLBScheduleDay>;
60
- }
61
-
62
- /**
63
- * Check if a given object implements the MLBSchedule interface.
64
- */
65
- export function instanceOfMLBSchedule(value: object): value is MLBSchedule {
66
- if (!('totalItems' in value) || value['totalItems'] === undefined) return false;
67
- if (!('totalEvents' in value) || value['totalEvents'] === undefined) return false;
68
- if (!('totalGames' in value) || value['totalGames'] === undefined) return false;
69
- if (!('totalGamesInProgress' in value) || value['totalGamesInProgress'] === undefined) return false;
70
- if (!('dates' in value) || value['dates'] === undefined) return false;
71
- return true;
72
- }
73
-
74
- export function MLBScheduleFromJSON(json: any): MLBSchedule {
75
- return MLBScheduleFromJSONTyped(json, false);
76
- }
77
-
78
- export function MLBScheduleFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBSchedule {
79
- if (json == null) {
80
- return json;
81
- }
82
- return {
83
-
84
- 'totalItems': json['totalItems'],
85
- 'totalEvents': json['totalEvents'],
86
- 'totalGames': json['totalGames'],
87
- 'totalGamesInProgress': json['totalGamesInProgress'],
88
- 'dates': ((json['dates'] as Array<any>).map(MLBScheduleDayFromJSON)),
89
- };
90
- }
91
-
92
- export function MLBScheduleToJSON(value?: MLBSchedule | null): any {
93
- if (value == null) {
94
- return value;
95
- }
96
- return {
97
-
98
- 'totalItems': value['totalItems'],
99
- 'totalEvents': value['totalEvents'],
100
- 'totalGames': value['totalGames'],
101
- 'totalGamesInProgress': value['totalGamesInProgress'],
102
- 'dates': ((value['dates'] as Array<any>).map(MLBScheduleDayToJSON)),
103
- };
104
- }
105
-
@@ -1,108 +0,0 @@
1
- /* tslint:disable */
2
- /* eslint-disable */
3
- /**
4
- * MLB StatAPI
5
- * An spec API to consume the MLB Stat API
6
- *
7
- * The version of the OpenAPI document: 0.1.5
8
- *
9
- *
10
- * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
- * https://openapi-generator.tech
12
- * Do not edit the class manually.
13
- */
14
-
15
- import { mapValues } from '../runtime';
16
- import type { MLBGame } from './MLBGame';
17
- import {
18
- MLBGameFromJSON,
19
- MLBGameFromJSONTyped,
20
- MLBGameToJSON,
21
- } from './MLBGame';
22
-
23
- /**
24
- *
25
- * @export
26
- * @interface MLBScheduleDay
27
- */
28
- export interface MLBScheduleDay {
29
- /**
30
- *
31
- * @type {string}
32
- * @memberof MLBScheduleDay
33
- */
34
- date?: string;
35
- /**
36
- *
37
- * @type {number}
38
- * @memberof MLBScheduleDay
39
- */
40
- totalItems?: number;
41
- /**
42
- *
43
- * @type {number}
44
- * @memberof MLBScheduleDay
45
- */
46
- totalEvents?: number;
47
- /**
48
- *
49
- * @type {number}
50
- * @memberof MLBScheduleDay
51
- */
52
- totalGames?: number;
53
- /**
54
- *
55
- * @type {number}
56
- * @memberof MLBScheduleDay
57
- */
58
- totalGamesInProgress?: number;
59
- /**
60
- *
61
- * @type {Array<MLBGame>}
62
- * @memberof MLBScheduleDay
63
- */
64
- games: Array<MLBGame>;
65
- }
66
-
67
- /**
68
- * Check if a given object implements the MLBScheduleDay interface.
69
- */
70
- export function instanceOfMLBScheduleDay(value: object): value is MLBScheduleDay {
71
- if (!('games' in value) || value['games'] === undefined) return false;
72
- return true;
73
- }
74
-
75
- export function MLBScheduleDayFromJSON(json: any): MLBScheduleDay {
76
- return MLBScheduleDayFromJSONTyped(json, false);
77
- }
78
-
79
- export function MLBScheduleDayFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBScheduleDay {
80
- if (json == null) {
81
- return json;
82
- }
83
- return {
84
-
85
- 'date': json['date'] == null ? undefined : json['date'],
86
- 'totalItems': json['totalItems'] == null ? undefined : json['totalItems'],
87
- 'totalEvents': json['totalEvents'] == null ? undefined : json['totalEvents'],
88
- 'totalGames': json['totalGames'] == null ? undefined : json['totalGames'],
89
- 'totalGamesInProgress': json['totalGamesInProgress'] == null ? undefined : json['totalGamesInProgress'],
90
- 'games': ((json['games'] as Array<any>).map(MLBGameFromJSON)),
91
- };
92
- }
93
-
94
- export function MLBScheduleDayToJSON(value?: MLBScheduleDay | null): any {
95
- if (value == null) {
96
- return value;
97
- }
98
- return {
99
-
100
- 'date': value['date'],
101
- 'totalItems': value['totalItems'],
102
- 'totalEvents': value['totalEvents'],
103
- 'totalGames': value['totalGames'],
104
- 'totalGamesInProgress': value['totalGamesInProgress'],
105
- 'games': ((value['games'] as Array<any>).map(MLBGameToJSON)),
106
- };
107
- }
108
-