@bp1222/stats-api 0.1.3 → 0.1.5

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.
@@ -0,0 +1,248 @@
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 { MLBDivision } from './MLBDivision';
17
+ import {
18
+ MLBDivisionFromJSON,
19
+ MLBDivisionFromJSONTyped,
20
+ MLBDivisionToJSON,
21
+ } from './MLBDivision';
22
+ import type { MLBVenue } from './MLBVenue';
23
+ import {
24
+ MLBVenueFromJSON,
25
+ MLBVenueFromJSONTyped,
26
+ MLBVenueToJSON,
27
+ } from './MLBVenue';
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
+ * Team
43
+ *
44
+ * @export
45
+ * @interface MLBTeam
46
+ */
47
+ export interface MLBTeam {
48
+ /**
49
+ *
50
+ * @type {number}
51
+ * @memberof MLBTeam
52
+ */
53
+ id: number;
54
+ /**
55
+ *
56
+ * @type {string}
57
+ * @memberof MLBTeam
58
+ */
59
+ name: string;
60
+ /**
61
+ *
62
+ * @type {string}
63
+ * @memberof MLBTeam
64
+ */
65
+ link?: string;
66
+ /**
67
+ *
68
+ * @type {string}
69
+ * @memberof MLBTeam
70
+ */
71
+ allStarStatus?: string;
72
+ /**
73
+ *
74
+ * @type {number}
75
+ * @memberof MLBTeam
76
+ */
77
+ season?: number;
78
+ /**
79
+ *
80
+ * @type {MLBVenue}
81
+ * @memberof MLBTeam
82
+ */
83
+ venue?: MLBVenue;
84
+ /**
85
+ *
86
+ * @type {MLBVenue}
87
+ * @memberof MLBTeam
88
+ */
89
+ springVenue?: MLBVenue;
90
+ /**
91
+ *
92
+ * @type {string}
93
+ * @memberof MLBTeam
94
+ */
95
+ teamCode?: string;
96
+ /**
97
+ *
98
+ * @type {string}
99
+ * @memberof MLBTeam
100
+ */
101
+ fileCode?: string;
102
+ /**
103
+ *
104
+ * @type {string}
105
+ * @memberof MLBTeam
106
+ */
107
+ abbreviation?: string;
108
+ /**
109
+ *
110
+ * @type {string}
111
+ * @memberof MLBTeam
112
+ */
113
+ teamName?: string;
114
+ /**
115
+ *
116
+ * @type {string}
117
+ * @memberof MLBTeam
118
+ */
119
+ locationName?: string;
120
+ /**
121
+ *
122
+ * @type {string}
123
+ * @memberof MLBTeam
124
+ */
125
+ firstYearOfPlay?: string;
126
+ /**
127
+ *
128
+ * @type {MLBLeague}
129
+ * @memberof MLBTeam
130
+ */
131
+ league?: MLBLeague;
132
+ /**
133
+ *
134
+ * @type {MLBLeague}
135
+ * @memberof MLBTeam
136
+ */
137
+ springLeague?: MLBLeague;
138
+ /**
139
+ *
140
+ * @type {MLBDivision}
141
+ * @memberof MLBTeam
142
+ */
143
+ division?: MLBDivision;
144
+ /**
145
+ *
146
+ * @type {MLBSport}
147
+ * @memberof MLBTeam
148
+ */
149
+ sport?: MLBSport;
150
+ /**
151
+ *
152
+ * @type {string}
153
+ * @memberof MLBTeam
154
+ */
155
+ shortName?: string;
156
+ /**
157
+ *
158
+ * @type {string}
159
+ * @memberof MLBTeam
160
+ */
161
+ franchiseName?: string;
162
+ /**
163
+ *
164
+ * @type {string}
165
+ * @memberof MLBTeam
166
+ */
167
+ clubName?: string;
168
+ /**
169
+ *
170
+ * @type {boolean}
171
+ * @memberof MLBTeam
172
+ */
173
+ active?: boolean;
174
+ }
175
+
176
+ /**
177
+ * Check if a given object implements the MLBTeam interface.
178
+ */
179
+ export function instanceOfMLBTeam(value: object): value is MLBTeam {
180
+ if (!('id' in value) || value['id'] === undefined) return false;
181
+ if (!('name' in value) || value['name'] === undefined) return false;
182
+ return true;
183
+ }
184
+
185
+ export function MLBTeamFromJSON(json: any): MLBTeam {
186
+ return MLBTeamFromJSONTyped(json, false);
187
+ }
188
+
189
+ export function MLBTeamFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBTeam {
190
+ if (json == null) {
191
+ return json;
192
+ }
193
+ return {
194
+
195
+ 'id': json['id'],
196
+ 'name': json['name'],
197
+ 'link': json['link'] == null ? undefined : json['link'],
198
+ 'allStarStatus': json['allStarStatus'] == null ? undefined : json['allStarStatus'],
199
+ 'season': json['season'] == null ? undefined : json['season'],
200
+ 'venue': json['venue'] == null ? undefined : MLBVenueFromJSON(json['venue']),
201
+ 'springVenue': json['springVenue'] == null ? undefined : MLBVenueFromJSON(json['springVenue']),
202
+ 'teamCode': json['teamCode'] == null ? undefined : json['teamCode'],
203
+ 'fileCode': json['fileCode'] == null ? undefined : json['fileCode'],
204
+ 'abbreviation': json['abbreviation'] == null ? undefined : json['abbreviation'],
205
+ 'teamName': json['teamName'] == null ? undefined : json['teamName'],
206
+ 'locationName': json['locationName'] == null ? undefined : json['locationName'],
207
+ 'firstYearOfPlay': json['firstYearOfPlay'] == null ? undefined : json['firstYearOfPlay'],
208
+ 'league': json['league'] == null ? undefined : MLBLeagueFromJSON(json['league']),
209
+ 'springLeague': json['springLeague'] == null ? undefined : MLBLeagueFromJSON(json['springLeague']),
210
+ 'division': json['division'] == null ? undefined : MLBDivisionFromJSON(json['division']),
211
+ 'sport': json['sport'] == null ? undefined : MLBSportFromJSON(json['sport']),
212
+ 'shortName': json['shortName'] == null ? undefined : json['shortName'],
213
+ 'franchiseName': json['franchiseName'] == null ? undefined : json['franchiseName'],
214
+ 'clubName': json['clubName'] == null ? undefined : json['clubName'],
215
+ 'active': json['active'] == null ? undefined : json['active'],
216
+ };
217
+ }
218
+
219
+ export function MLBTeamToJSON(value?: MLBTeam | null): any {
220
+ if (value == null) {
221
+ return value;
222
+ }
223
+ return {
224
+
225
+ 'id': value['id'],
226
+ 'name': value['name'],
227
+ 'link': value['link'],
228
+ 'allStarStatus': value['allStarStatus'],
229
+ 'season': value['season'],
230
+ 'venue': MLBVenueToJSON(value['venue']),
231
+ 'springVenue': MLBVenueToJSON(value['springVenue']),
232
+ 'teamCode': value['teamCode'],
233
+ 'fileCode': value['fileCode'],
234
+ 'abbreviation': value['abbreviation'],
235
+ 'teamName': value['teamName'],
236
+ 'locationName': value['locationName'],
237
+ 'firstYearOfPlay': value['firstYearOfPlay'],
238
+ 'league': MLBLeagueToJSON(value['league']),
239
+ 'springLeague': MLBLeagueToJSON(value['springLeague']),
240
+ 'division': MLBDivisionToJSON(value['division']),
241
+ 'sport': MLBSportToJSON(value['sport']),
242
+ 'shortName': value['shortName'],
243
+ 'franchiseName': value['franchiseName'],
244
+ 'clubName': value['clubName'],
245
+ 'active': value['active'],
246
+ };
247
+ }
248
+
@@ -0,0 +1,67 @@
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 { MLBTeam } from './MLBTeam';
17
+ import {
18
+ MLBTeamFromJSON,
19
+ MLBTeamFromJSONTyped,
20
+ MLBTeamToJSON,
21
+ } from './MLBTeam';
22
+
23
+ /**
24
+ *
25
+ * @export
26
+ * @interface MLBTeams
27
+ */
28
+ export interface MLBTeams {
29
+ /**
30
+ *
31
+ * @type {Array<MLBTeam>}
32
+ * @memberof MLBTeams
33
+ */
34
+ teams?: Array<MLBTeam>;
35
+ }
36
+
37
+ /**
38
+ * Check if a given object implements the MLBTeams interface.
39
+ */
40
+ export function instanceOfMLBTeams(value: object): value is MLBTeams {
41
+ return true;
42
+ }
43
+
44
+ export function MLBTeamsFromJSON(json: any): MLBTeams {
45
+ return MLBTeamsFromJSONTyped(json, false);
46
+ }
47
+
48
+ export function MLBTeamsFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBTeams {
49
+ if (json == null) {
50
+ return json;
51
+ }
52
+ return {
53
+
54
+ 'teams': json['teams'] == null ? undefined : ((json['teams'] as Array<any>).map(MLBTeamFromJSON)),
55
+ };
56
+ }
57
+
58
+ export function MLBTeamsToJSON(value?: MLBTeams | null): any {
59
+ if (value == null) {
60
+ return value;
61
+ }
62
+ return {
63
+
64
+ 'teams': value['teams'] == null ? undefined : ((value['teams'] as Array<any>).map(MLBTeamToJSON)),
65
+ };
66
+ }
67
+
@@ -0,0 +1,95 @@
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
+ /**
17
+ * Venue
18
+ *
19
+ * @export
20
+ * @interface MLBVenue
21
+ */
22
+ export interface MLBVenue {
23
+ /**
24
+ *
25
+ * @type {number}
26
+ * @memberof MLBVenue
27
+ */
28
+ id: number;
29
+ /**
30
+ *
31
+ * @type {string}
32
+ * @memberof MLBVenue
33
+ */
34
+ name: string;
35
+ /**
36
+ *
37
+ * @type {string}
38
+ * @memberof MLBVenue
39
+ */
40
+ link?: string;
41
+ /**
42
+ *
43
+ * @type {boolean}
44
+ * @memberof MLBVenue
45
+ */
46
+ active?: boolean;
47
+ /**
48
+ *
49
+ * @type {string}
50
+ * @memberof MLBVenue
51
+ */
52
+ season?: string;
53
+ }
54
+
55
+ /**
56
+ * Check if a given object implements the MLBVenue interface.
57
+ */
58
+ export function instanceOfMLBVenue(value: object): value is MLBVenue {
59
+ if (!('id' in value) || value['id'] === undefined) return false;
60
+ if (!('name' in value) || value['name'] === undefined) return false;
61
+ return true;
62
+ }
63
+
64
+ export function MLBVenueFromJSON(json: any): MLBVenue {
65
+ return MLBVenueFromJSONTyped(json, false);
66
+ }
67
+
68
+ export function MLBVenueFromJSONTyped(json: any, ignoreDiscriminator: boolean): MLBVenue {
69
+ if (json == null) {
70
+ return json;
71
+ }
72
+ return {
73
+
74
+ 'id': json['id'],
75
+ 'name': json['name'],
76
+ 'link': json['link'] == null ? undefined : json['link'],
77
+ 'active': json['active'] == null ? undefined : json['active'],
78
+ 'season': json['season'] == null ? undefined : json['season'],
79
+ };
80
+ }
81
+
82
+ export function MLBVenueToJSON(value?: MLBVenue | null): any {
83
+ if (value == null) {
84
+ return value;
85
+ }
86
+ return {
87
+
88
+ 'id': value['id'],
89
+ 'name': value['name'],
90
+ 'link': value['link'],
91
+ 'active': value['active'],
92
+ 'season': value['season'],
93
+ };
94
+ }
95
+
@@ -0,0 +1,22 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ export * from './MLBDivision';
4
+ export * from './MLBGame';
5
+ export * from './MLBGameStatus';
6
+ export * from './MLBGameTeam';
7
+ export * from './MLBGameTeams';
8
+ export * from './MLBLeague';
9
+ export * from './MLBLeagueDates';
10
+ export * from './MLBLeagueRecord';
11
+ export * from './MLBRecord';
12
+ export * from './MLBSchedule';
13
+ export * from './MLBScheduleDay';
14
+ export * from './MLBSeason';
15
+ export * from './MLBSeasons';
16
+ export * from './MLBSport';
17
+ export * from './MLBStandings';
18
+ export * from './MLBStandingsList';
19
+ export * from './MLBStreak';
20
+ export * from './MLBTeam';
21
+ export * from './MLBTeams';
22
+ export * from './MLBVenue';