@bp1222/stats-api 0.1.4 → 0.1.6

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,226 +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.4
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
- /**
17
- * Season
18
- *
19
- * @export
20
- * @interface MLBSeason
21
- */
22
- export interface MLBSeason {
23
- /**
24
- *
25
- * @type {string}
26
- * @memberof MLBSeason
27
- */
28
- seasonId: string;
29
- /**
30
- *
31
- * @type {boolean}
32
- * @memberof MLBSeason
33
- */
34
- hasWildcard?: boolean;
35
- /**
36
- *
37
- * @type {string}
38
- * @memberof MLBSeason
39
- */
40
- preSeasonStartDate?: string;
41
- /**
42
- *
43
- * @type {string}
44
- * @memberof MLBSeason
45
- */
46
- preSeasonEndDate?: string;
47
- /**
48
- *
49
- * @type {string}
50
- * @memberof MLBSeason
51
- */
52
- seasonStartDate: string;
53
- /**
54
- *
55
- * @type {string}
56
- * @memberof MLBSeason
57
- */
58
- seasonEndDate: string;
59
- /**
60
- *
61
- * @type {string}
62
- * @memberof MLBSeason
63
- */
64
- springStartDate?: string;
65
- /**
66
- *
67
- * @type {string}
68
- * @memberof MLBSeason
69
- */
70
- springEndDate?: string;
71
- /**
72
- *
73
- * @type {string}
74
- * @memberof MLBSeason
75
- */
76
- regularSeasonStartDate: string;
77
- /**
78
- *
79
- * @type {string}
80
- * @memberof MLBSeason
81
- */
82
- lastDate1stHalf?: string;
83
- /**
84
- *
85
- * @type {string}
86
- * @memberof MLBSeason
87
- */
88
- allStartDate?: string;
89
- /**
90
- *
91
- * @type {string}
92
- * @memberof MLBSeason
93
- */
94
- firstDate2ndHalf?: string;
95
- /**
96
- *
97
- * @type {string}
98
- * @memberof MLBSeason
99
- */
100
- regularSeasonEndDate: string;
101
- /**
102
- *
103
- * @type {string}
104
- * @memberof MLBSeason
105
- */
106
- postSeasonStartDate?: string;
107
- /**
108
- *
109
- * @type {string}
110
- * @memberof MLBSeason
111
- */
112
- postSeasonEndDate?: string;
113
- /**
114
- *
115
- * @type {string}
116
- * @memberof MLBSeason
117
- */
118
- offSeasonStartDate?: string;
119
- /**
120
- *
121
- * @type {string}
122
- * @memberof MLBSeason
123
- */
124
- offSeasonEndDate?: string;
125
- /**
126
- *
127
- * @type {string}
128
- * @memberof MLBSeason
129
- */
130
- seasonLevelGamedayType?: string;
131
- /**
132
- *
133
- * @type {string}
134
- * @memberof MLBSeason
135
- */
136
- gameLevelGamedayType?: string;
137
- /**
138
- *
139
- * @type {number}
140
- * @memberof MLBSeason
141
- */
142
- qualifierPlateAppearances?: number;
143
- /**
144
- *
145
- * @type {number}
146
- * @memberof MLBSeason
147
- */
148
- qualifierOutsPitched?: number;
149
- }
150
-
151
- /**
152
- * Check if a given object implements the MLBSeason interface.
153
- */
154
- export function instanceOfMLBSeason(value: object): value is MLBSeason {
155
- if (!('seasonId' in value) || value['seasonId'] === undefined) return false;
156
- if (!('seasonStartDate' in value) || value['seasonStartDate'] === undefined) return false;
157
- if (!('seasonEndDate' in value) || value['seasonEndDate'] === undefined) return false;
158
- if (!('regularSeasonStartDate' in value) || value['regularSeasonStartDate'] === undefined) return false;
159
- if (!('regularSeasonEndDate' in value) || value['regularSeasonEndDate'] === undefined) return false;
160
- return true;
161
- }
162
-
163
- export function MLBSeasonFromJSON(json: any): MLBSeason {
164
- return MLBSeasonFromJSONTyped(json, false);
165
- }
166
-
167
- export function MLBSeasonFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBSeason {
168
- if (json == null) {
169
- return json;
170
- }
171
- return {
172
-
173
- 'seasonId': json['seasonId'],
174
- 'hasWildcard': json['hasWildcard'] == null ? undefined : json['hasWildcard'],
175
- 'preSeasonStartDate': json['preSeasonStartDate'] == null ? undefined : json['preSeasonStartDate'],
176
- 'preSeasonEndDate': json['preSeasonEndDate'] == null ? undefined : json['preSeasonEndDate'],
177
- 'seasonStartDate': json['seasonStartDate'],
178
- 'seasonEndDate': json['seasonEndDate'],
179
- 'springStartDate': json['springStartDate'] == null ? undefined : json['springStartDate'],
180
- 'springEndDate': json['springEndDate'] == null ? undefined : json['springEndDate'],
181
- 'regularSeasonStartDate': json['regularSeasonStartDate'],
182
- 'lastDate1stHalf': json['lastDate1stHalf'] == null ? undefined : json['lastDate1stHalf'],
183
- 'allStartDate': json['allStartDate'] == null ? undefined : json['allStartDate'],
184
- 'firstDate2ndHalf': json['firstDate2ndHalf'] == null ? undefined : json['firstDate2ndHalf'],
185
- 'regularSeasonEndDate': json['regularSeasonEndDate'],
186
- 'postSeasonStartDate': json['postSeasonStartDate'] == null ? undefined : json['postSeasonStartDate'],
187
- 'postSeasonEndDate': json['postSeasonEndDate'] == null ? undefined : json['postSeasonEndDate'],
188
- 'offSeasonStartDate': json['offSeasonStartDate'] == null ? undefined : json['offSeasonStartDate'],
189
- 'offSeasonEndDate': json['offSeasonEndDate'] == null ? undefined : json['offSeasonEndDate'],
190
- 'seasonLevelGamedayType': json['seasonLevelGamedayType'] == null ? undefined : json['seasonLevelGamedayType'],
191
- 'gameLevelGamedayType': json['gameLevelGamedayType'] == null ? undefined : json['gameLevelGamedayType'],
192
- 'qualifierPlateAppearances': json['qualifierPlateAppearances'] == null ? undefined : json['qualifierPlateAppearances'],
193
- 'qualifierOutsPitched': json['qualifierOutsPitched'] == null ? undefined : json['qualifierOutsPitched'],
194
- };
195
- }
196
-
197
- export function MLBSeasonToJSON(value?: MLBSeason | null): any {
198
- if (value == null) {
199
- return value;
200
- }
201
- return {
202
-
203
- 'seasonId': value['seasonId'],
204
- 'hasWildcard': value['hasWildcard'],
205
- 'preSeasonStartDate': value['preSeasonStartDate'],
206
- 'preSeasonEndDate': value['preSeasonEndDate'],
207
- 'seasonStartDate': value['seasonStartDate'],
208
- 'seasonEndDate': value['seasonEndDate'],
209
- 'springStartDate': value['springStartDate'],
210
- 'springEndDate': value['springEndDate'],
211
- 'regularSeasonStartDate': value['regularSeasonStartDate'],
212
- 'lastDate1stHalf': value['lastDate1stHalf'],
213
- 'allStartDate': value['allStartDate'],
214
- 'firstDate2ndHalf': value['firstDate2ndHalf'],
215
- 'regularSeasonEndDate': value['regularSeasonEndDate'],
216
- 'postSeasonStartDate': value['postSeasonStartDate'],
217
- 'postSeasonEndDate': value['postSeasonEndDate'],
218
- 'offSeasonStartDate': value['offSeasonStartDate'],
219
- 'offSeasonEndDate': value['offSeasonEndDate'],
220
- 'seasonLevelGamedayType': value['seasonLevelGamedayType'],
221
- 'gameLevelGamedayType': value['gameLevelGamedayType'],
222
- 'qualifierPlateAppearances': value['qualifierPlateAppearances'],
223
- 'qualifierOutsPitched': value['qualifierOutsPitched'],
224
- };
225
- }
226
-
@@ -1,67 +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.4
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 { MLBSeason } from './MLBSeason';
17
- import {
18
- MLBSeasonFromJSON,
19
- MLBSeasonFromJSONTyped,
20
- MLBSeasonToJSON,
21
- } from './MLBSeason';
22
-
23
- /**
24
- *
25
- * @export
26
- * @interface MLBSeasons
27
- */
28
- export interface MLBSeasons {
29
- /**
30
- *
31
- * @type {Array<MLBSeason>}
32
- * @memberof MLBSeasons
33
- */
34
- seasons?: Array<MLBSeason>;
35
- }
36
-
37
- /**
38
- * Check if a given object implements the MLBSeasons interface.
39
- */
40
- export function instanceOfMLBSeasons(value: object): value is MLBSeasons {
41
- return true;
42
- }
43
-
44
- export function MLBSeasonsFromJSON(json: any): MLBSeasons {
45
- return MLBSeasonsFromJSONTyped(json, false);
46
- }
47
-
48
- export function MLBSeasonsFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBSeasons {
49
- if (json == null) {
50
- return json;
51
- }
52
- return {
53
-
54
- 'seasons': json['seasons'] == null ? undefined : ((json['seasons'] as Array<any>).map(MLBSeasonFromJSON)),
55
- };
56
- }
57
-
58
- export function MLBSeasonsToJSON(value?: MLBSeasons | null): any {
59
- if (value == null) {
60
- return value;
61
- }
62
- return {
63
-
64
- 'seasons': value['seasons'] == null ? undefined : ((value['seasons'] as Array<any>).map(MLBSeasonToJSON)),
65
- };
66
- }
67
-
@@ -1,110 +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.4
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
- /**
17
- * Sport
18
- *
19
- * @export
20
- * @interface MLBSport
21
- */
22
- export interface MLBSport {
23
- /**
24
- *
25
- * @type {number}
26
- * @memberof MLBSport
27
- */
28
- id: number;
29
- /**
30
- *
31
- * @type {string}
32
- * @memberof MLBSport
33
- */
34
- code?: string;
35
- /**
36
- *
37
- * @type {string}
38
- * @memberof MLBSport
39
- */
40
- link?: string;
41
- /**
42
- *
43
- * @type {string}
44
- * @memberof MLBSport
45
- */
46
- name?: string;
47
- /**
48
- *
49
- * @type {string}
50
- * @memberof MLBSport
51
- */
52
- abbreviation?: string;
53
- /**
54
- *
55
- * @type {number}
56
- * @memberof MLBSport
57
- */
58
- sortOrder?: number;
59
- /**
60
- *
61
- * @type {boolean}
62
- * @memberof MLBSport
63
- */
64
- activeStatus?: boolean;
65
- }
66
-
67
- /**
68
- * Check if a given object implements the MLBSport interface.
69
- */
70
- export function instanceOfMLBSport(value: object): value is MLBSport {
71
- if (!('id' in value) || value['id'] === undefined) return false;
72
- return true;
73
- }
74
-
75
- export function MLBSportFromJSON(json: any): MLBSport {
76
- return MLBSportFromJSONTyped(json, false);
77
- }
78
-
79
- export function MLBSportFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBSport {
80
- if (json == null) {
81
- return json;
82
- }
83
- return {
84
-
85
- 'id': json['id'],
86
- 'code': json['code'] == null ? undefined : json['code'],
87
- 'link': json['link'] == null ? undefined : json['link'],
88
- 'name': json['name'] == null ? undefined : json['name'],
89
- 'abbreviation': json['abbreviation'] == null ? undefined : json['abbreviation'],
90
- 'sortOrder': json['sortOrder'] == null ? undefined : json['sortOrder'],
91
- 'activeStatus': json['activeStatus'] == null ? undefined : json['activeStatus'],
92
- };
93
- }
94
-
95
- export function MLBSportToJSON(value?: MLBSport | null): any {
96
- if (value == null) {
97
- return value;
98
- }
99
- return {
100
-
101
- 'id': value['id'],
102
- 'code': value['code'],
103
- 'link': value['link'],
104
- 'name': value['name'],
105
- 'abbreviation': value['abbreviation'],
106
- 'sortOrder': value['sortOrder'],
107
- 'activeStatus': value['activeStatus'],
108
- };
109
- }
110
-
@@ -1,130 +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.4
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 { MLBRecord } from './MLBRecord';
17
- import {
18
- MLBRecordFromJSON,
19
- MLBRecordFromJSONTyped,
20
- MLBRecordToJSON,
21
- } from './MLBRecord';
22
- import type { MLBDivision } from './MLBDivision';
23
- import {
24
- MLBDivisionFromJSON,
25
- MLBDivisionFromJSONTyped,
26
- MLBDivisionToJSON,
27
- } from './MLBDivision';
28
- import type { MLBLeague } from './MLBLeague';
29
- import {
30
- MLBLeagueFromJSON,
31
- MLBLeagueFromJSONTyped,
32
- MLBLeagueToJSON,
33
- } from './MLBLeague';
34
- import type { MLBSport } from './MLBSport';
35
- import {
36
- MLBSportFromJSON,
37
- MLBSportFromJSONTyped,
38
- MLBSportToJSON,
39
- } from './MLBSport';
40
-
41
- /**
42
- * Standings
43
- *
44
- * @export
45
- * @interface MLBStandings
46
- */
47
- export interface MLBStandings {
48
- /**
49
- *
50
- * @type {string}
51
- * @memberof MLBStandings
52
- */
53
- standingsType?: string;
54
- /**
55
- *
56
- * @type {MLBLeague}
57
- * @memberof MLBStandings
58
- */
59
- league: MLBLeague;
60
- /**
61
- *
62
- * @type {MLBDivision}
63
- * @memberof MLBStandings
64
- */
65
- division: MLBDivision;
66
- /**
67
- *
68
- * @type {MLBSport}
69
- * @memberof MLBStandings
70
- */
71
- sport: MLBSport;
72
- /**
73
- *
74
- * @type {string}
75
- * @memberof MLBStandings
76
- */
77
- lastUpdated?: string;
78
- /**
79
- *
80
- * @type {Array<MLBRecord>}
81
- * @memberof MLBStandings
82
- */
83
- teamRecords: Array<MLBRecord>;
84
- }
85
-
86
- /**
87
- * Check if a given object implements the MLBStandings interface.
88
- */
89
- export function instanceOfMLBStandings(value: object): value is MLBStandings {
90
- if (!('league' in value) || value['league'] === undefined) return false;
91
- if (!('division' in value) || value['division'] === undefined) return false;
92
- if (!('sport' in value) || value['sport'] === undefined) return false;
93
- if (!('teamRecords' in value) || value['teamRecords'] === undefined) return false;
94
- return true;
95
- }
96
-
97
- export function MLBStandingsFromJSON(json: any): MLBStandings {
98
- return MLBStandingsFromJSONTyped(json, false);
99
- }
100
-
101
- export function MLBStandingsFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBStandings {
102
- if (json == null) {
103
- return json;
104
- }
105
- return {
106
-
107
- 'standingsType': json['standingsType'] == null ? undefined : json['standingsType'],
108
- 'league': MLBLeagueFromJSON(json['league']),
109
- 'division': MLBDivisionFromJSON(json['division']),
110
- 'sport': MLBSportFromJSON(json['sport']),
111
- 'lastUpdated': json['lastUpdated'] == null ? undefined : json['lastUpdated'],
112
- 'teamRecords': ((json['teamRecords'] as Array<any>).map(MLBRecordFromJSON)),
113
- };
114
- }
115
-
116
- export function MLBStandingsToJSON(value?: MLBStandings | null): any {
117
- if (value == null) {
118
- return value;
119
- }
120
- return {
121
-
122
- 'standingsType': value['standingsType'],
123
- 'league': MLBLeagueToJSON(value['league']),
124
- 'division': MLBDivisionToJSON(value['division']),
125
- 'sport': MLBSportToJSON(value['sport']),
126
- 'lastUpdated': value['lastUpdated'],
127
- 'teamRecords': ((value['teamRecords'] as Array<any>).map(MLBRecordToJSON)),
128
- };
129
- }
130
-
@@ -1,67 +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.4
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 { MLBStandings } from './MLBStandings';
17
- import {
18
- MLBStandingsFromJSON,
19
- MLBStandingsFromJSONTyped,
20
- MLBStandingsToJSON,
21
- } from './MLBStandings';
22
-
23
- /**
24
- *
25
- * @export
26
- * @interface MLBStandingsList
27
- */
28
- export interface MLBStandingsList {
29
- /**
30
- *
31
- * @type {Array<MLBStandings>}
32
- * @memberof MLBStandingsList
33
- */
34
- records?: Array<MLBStandings>;
35
- }
36
-
37
- /**
38
- * Check if a given object implements the MLBStandingsList interface.
39
- */
40
- export function instanceOfMLBStandingsList(value: object): value is MLBStandingsList {
41
- return true;
42
- }
43
-
44
- export function MLBStandingsListFromJSON(json: any): MLBStandingsList {
45
- return MLBStandingsListFromJSONTyped(json, false);
46
- }
47
-
48
- export function MLBStandingsListFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBStandingsList {
49
- if (json == null) {
50
- return json;
51
- }
52
- return {
53
-
54
- 'records': json['records'] == null ? undefined : ((json['records'] as Array<any>).map(MLBStandingsFromJSON)),
55
- };
56
- }
57
-
58
- export function MLBStandingsListToJSON(value?: MLBStandingsList | null): any {
59
- if (value == null) {
60
- return value;
61
- }
62
- return {
63
-
64
- 'records': value['records'] == null ? undefined : ((value['records'] as Array<any>).map(MLBStandingsToJSON)),
65
- };
66
- }
67
-
@@ -1,74 +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.4
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
- /**
17
- *
18
- * @export
19
- * @interface MLBStreak
20
- */
21
- export interface MLBStreak {
22
- /**
23
- * Streak Type:
24
- * * Losing Streak
25
- * * Winning Streak
26
- *
27
- * @type {string}
28
- * @memberof MLBStreak
29
- */
30
- streakType?: MLBStreakStreakTypeEnum;
31
- }
32
-
33
-
34
- /**
35
- * @export
36
- */
37
- export const MLBStreakStreakTypeEnum = {
38
- Losing: 'losses',
39
- Winning: 'wins'
40
- } as const;
41
- export type MLBStreakStreakTypeEnum = typeof MLBStreakStreakTypeEnum[keyof typeof MLBStreakStreakTypeEnum];
42
-
43
-
44
- /**
45
- * Check if a given object implements the MLBStreak interface.
46
- */
47
- export function instanceOfMLBStreak(value: object): value is MLBStreak {
48
- return true;
49
- }
50
-
51
- export function MLBStreakFromJSON(json: any): MLBStreak {
52
- return MLBStreakFromJSONTyped(json, false);
53
- }
54
-
55
- export function MLBStreakFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBStreak {
56
- if (json == null) {
57
- return json;
58
- }
59
- return {
60
-
61
- 'streakType': json['streakType'] == null ? undefined : json['streakType'],
62
- };
63
- }
64
-
65
- export function MLBStreakToJSON(value?: MLBStreak | null): any {
66
- if (value == null) {
67
- return value;
68
- }
69
- return {
70
-
71
- 'streakType': value['streakType'],
72
- };
73
- }
74
-