@bp1222/stats-api 0.0.1 → 0.0.2

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.
Files changed (43) hide show
  1. package/Makefile +3 -2
  2. package/openapitools.json +16 -13
  3. package/package.json +8 -2
  4. package/spec/components/schemas/game.yaml +2 -6
  5. package/spec/components/schemas/gameTeam.yaml +1 -9
  6. package/spec/components/schemas/leagueRecord.yaml +15 -0
  7. package/spec/components/schemas/record.yaml +1 -16
  8. package/spec/components/schemas/schedule.yaml +1 -1
  9. package/spec/components/schemas/schemas.yaml +2 -0
  10. package/src/.openapi-generator/FILES +14 -16
  11. package/src/.openapi-generator/VERSION +1 -1
  12. package/src/apis/MlbApi.ts +112 -13
  13. package/src/models/MLBGame.ts +1 -15
  14. package/src/models/MLBGameTeam.ts +10 -10
  15. package/src/models/{MLBTeamRecord1.ts → MLBLeagueRecord.ts} +14 -15
  16. package/src/models/MLBRecord.ts +9 -9
  17. package/src/models/MLBSchedule.ts +9 -9
  18. package/src/models/{MLBScheduleDay.ts → MLBScheduleDays.ts} +23 -23
  19. package/src/models/MLBSeasons.ts +9 -9
  20. package/src/models/MLBStandingsList.ts +9 -9
  21. package/src/models/MLBTeams.ts +9 -9
  22. package/src/models/index.ts +14 -16
  23. package/spec/components/parameters/query/eventTypes.yaml +0 -5
  24. package/spec/components/parameters/query/gamePks.yaml +0 -5
  25. package/spec/components/parameters/query/gameTypes.yaml +0 -5
  26. package/spec/components/parameters/query/opponentId.yaml +0 -5
  27. package/spec/components/parameters/query/scheduleType.yaml +0 -5
  28. package/spec/components/parameters/query/venueIds.yaml +0 -5
  29. package/src/models/Division.ts +0 -164
  30. package/src/models/Game.ts +0 -385
  31. package/src/models/GameContent.ts +0 -60
  32. package/src/models/GameTeam.ts +0 -117
  33. package/src/models/GameTeams.ts +0 -77
  34. package/src/models/League.ts +0 -190
  35. package/src/models/MLBGameContent.ts +0 -60
  36. package/src/models/MLBTeamRecord.ts +0 -76
  37. package/src/models/Record.ts +0 -337
  38. package/src/models/Schedule.ts +0 -105
  39. package/src/models/Season.ts +0 -226
  40. package/src/models/Sport.ts +0 -110
  41. package/src/models/Standings.ts +0 -130
  42. package/src/models/Team.ts +0 -248
  43. package/src/models/Venue.ts +0 -95
@@ -1,248 +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.0.1
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 { League } from './League';
17
- import {
18
- LeagueFromJSON,
19
- LeagueFromJSONTyped,
20
- LeagueToJSON,
21
- } from './League';
22
- import type { Sport } from './Sport';
23
- import {
24
- SportFromJSON,
25
- SportFromJSONTyped,
26
- SportToJSON,
27
- } from './Sport';
28
- import type { Venue } from './Venue';
29
- import {
30
- VenueFromJSON,
31
- VenueFromJSONTyped,
32
- VenueToJSON,
33
- } from './Venue';
34
- import type { Division } from './Division';
35
- import {
36
- DivisionFromJSON,
37
- DivisionFromJSONTyped,
38
- DivisionToJSON,
39
- } from './Division';
40
-
41
- /**
42
- * Team
43
- *
44
- * @export
45
- * @interface Team
46
- */
47
- export interface Team {
48
- /**
49
- *
50
- * @type {number}
51
- * @memberof Team
52
- */
53
- id: number;
54
- /**
55
- *
56
- * @type {string}
57
- * @memberof Team
58
- */
59
- name: string;
60
- /**
61
- *
62
- * @type {string}
63
- * @memberof Team
64
- */
65
- link?: string;
66
- /**
67
- *
68
- * @type {string}
69
- * @memberof Team
70
- */
71
- allStarStatus?: string;
72
- /**
73
- *
74
- * @type {number}
75
- * @memberof Team
76
- */
77
- season?: number;
78
- /**
79
- *
80
- * @type {Venue}
81
- * @memberof Team
82
- */
83
- venue?: Venue;
84
- /**
85
- *
86
- * @type {Venue}
87
- * @memberof Team
88
- */
89
- springVenue?: Venue;
90
- /**
91
- *
92
- * @type {string}
93
- * @memberof Team
94
- */
95
- teamCode?: string;
96
- /**
97
- *
98
- * @type {string}
99
- * @memberof Team
100
- */
101
- fileCode?: string;
102
- /**
103
- *
104
- * @type {string}
105
- * @memberof Team
106
- */
107
- abbreviation?: string;
108
- /**
109
- *
110
- * @type {string}
111
- * @memberof Team
112
- */
113
- teamName?: string;
114
- /**
115
- *
116
- * @type {string}
117
- * @memberof Team
118
- */
119
- locationName?: string;
120
- /**
121
- *
122
- * @type {string}
123
- * @memberof Team
124
- */
125
- firstYearOfPlay?: string;
126
- /**
127
- *
128
- * @type {League}
129
- * @memberof Team
130
- */
131
- league?: League;
132
- /**
133
- *
134
- * @type {League}
135
- * @memberof Team
136
- */
137
- springLeague?: League;
138
- /**
139
- *
140
- * @type {Division}
141
- * @memberof Team
142
- */
143
- division?: Division;
144
- /**
145
- *
146
- * @type {Sport}
147
- * @memberof Team
148
- */
149
- sport?: Sport;
150
- /**
151
- *
152
- * @type {string}
153
- * @memberof Team
154
- */
155
- shortName?: string;
156
- /**
157
- *
158
- * @type {string}
159
- * @memberof Team
160
- */
161
- franchiseName?: string;
162
- /**
163
- *
164
- * @type {string}
165
- * @memberof Team
166
- */
167
- clubName?: string;
168
- /**
169
- *
170
- * @type {boolean}
171
- * @memberof Team
172
- */
173
- active?: boolean;
174
- }
175
-
176
- /**
177
- * Check if a given object implements the Team interface.
178
- */
179
- export function instanceOfTeam(value: object): value is Team {
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 TeamFromJSON(json: any): Team {
186
- return TeamFromJSONTyped(json, false);
187
- }
188
-
189
- export function TeamFromJSONTyped(json: any, ignoreDiscriminator: boolean): Team {
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 : VenueFromJSON(json['venue']),
201
- 'springVenue': json['springVenue'] == null ? undefined : VenueFromJSON(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 : LeagueFromJSON(json['league']),
209
- 'springLeague': json['springLeague'] == null ? undefined : LeagueFromJSON(json['springLeague']),
210
- 'division': json['division'] == null ? undefined : DivisionFromJSON(json['division']),
211
- 'sport': json['sport'] == null ? undefined : SportFromJSON(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 TeamToJSON(value?: Team | 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': VenueToJSON(value['venue']),
231
- 'springVenue': VenueToJSON(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': LeagueToJSON(value['league']),
239
- 'springLeague': LeagueToJSON(value['springLeague']),
240
- 'division': DivisionToJSON(value['division']),
241
- 'sport': SportToJSON(value['sport']),
242
- 'shortName': value['shortName'],
243
- 'franchiseName': value['franchiseName'],
244
- 'clubName': value['clubName'],
245
- 'active': value['active'],
246
- };
247
- }
248
-
@@ -1,95 +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.0.1
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 Venue
21
- */
22
- export interface Venue {
23
- /**
24
- *
25
- * @type {number}
26
- * @memberof Venue
27
- */
28
- id: number;
29
- /**
30
- *
31
- * @type {string}
32
- * @memberof Venue
33
- */
34
- name: string;
35
- /**
36
- *
37
- * @type {string}
38
- * @memberof Venue
39
- */
40
- link?: string;
41
- /**
42
- *
43
- * @type {boolean}
44
- * @memberof Venue
45
- */
46
- active?: boolean;
47
- /**
48
- *
49
- * @type {string}
50
- * @memberof Venue
51
- */
52
- season?: string;
53
- }
54
-
55
- /**
56
- * Check if a given object implements the Venue interface.
57
- */
58
- export function instanceOfVenue(value: object): value is Venue {
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 VenueFromJSON(json: any): Venue {
65
- return VenueFromJSONTyped(json, false);
66
- }
67
-
68
- export function VenueFromJSONTyped(json: any, ignoreDiscriminator: boolean): Venue {
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 VenueToJSON(value?: Venue | 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
-