@jugarhoy/api 1.1.11 → 1.1.13
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/apis/PositionsApi.ts +235 -0
- package/apis/RecurringGamesApi.ts +279 -0
- package/apis/SportEventsApi.ts +133 -0
- package/apis/TeamFeedApi.ts +386 -0
- package/apis/TeamsApi.ts +578 -0
- package/apis/VotingApi.ts +404 -0
- package/apis/index.ts +6 -0
- package/models/ApiAppTeamsTeamIdEventsGet200Response.ts +73 -0
- package/models/ApiAppTeamsTeamIdEventsGet200ResponseEventsInner.ts +97 -0
- package/models/ApiAppTeamsTeamIdEventsPostRequest.ts +139 -0
- package/models/ApiAppTeamsTeamIdFeedFeedItemIdPatchRequest.ts +81 -0
- package/models/ApiAppTeamsTeamIdFeedFeedItemIdReactionsPatchRequest.ts +66 -0
- package/models/ApiAppTeamsTeamIdFeedSummaryGet200Response.ts +81 -0
- package/models/ApiAppVotingHasVotedPlaySearchIdGet200Response.ts +65 -0
- package/models/AssignPositionsRequest.ts +92 -0
- package/models/AssignPositionsRequestPositionsInner.ts +130 -0
- package/models/AutoAssignPositionsRequest.ts +93 -0
- package/models/CreateRecurringGameRequest.ts +130 -0
- package/models/CreateTeamFeedRequest.ts +82 -0
- package/models/CreateTeamRequest.ts +134 -0
- package/models/FeedMediaType.ts +56 -0
- package/models/GroupedPositionsResponse.ts +83 -0
- package/models/GroupedPositionsResponseHome.ts +83 -0
- package/models/JoinTeamRequest.ts +66 -0
- package/models/MatchVote.ts +134 -0
- package/models/PlaySearchPosition.ts +153 -0
- package/models/PlayerRatingResponse.ts +111 -0
- package/models/PositionResponse.ts +157 -0
- package/models/PositionStatus.ts +53 -0
- package/models/PositionTeam.ts +53 -0
- package/models/RecurringGame.ts +164 -0
- package/models/RecurringGameResponse.ts +155 -0
- package/models/SportEventData.ts +113 -0
- package/models/SportEventType.ts +77 -0
- package/models/SubmitRatingsRequest.ts +92 -0
- package/models/SubmitRatingsRequestRatingsInner.ts +99 -0
- package/models/Team.ts +186 -0
- package/models/TeamFeedItem.ts +188 -0
- package/models/TeamFeedItemResponse.ts +168 -0
- package/models/TeamFeedListResponse.ts +89 -0
- package/models/TeamFeedMedia.ts +101 -0
- package/models/TeamMember.ts +121 -0
- package/models/TeamMemberResponse.ts +123 -0
- package/models/TeamMemberRole.ts +54 -0
- package/models/TeamResponse.ts +194 -0
- package/models/TeamType.ts +53 -0
- package/models/UpdateMemberRoleRequest.ts +76 -0
- package/models/UpdateRecurringGameRequest.ts +124 -0
- package/models/UpdateTeamRequest.ts +105 -0
- package/models/VotingStatsResponse.ts +93 -0
- package/models/VotingStatusResponse.ts +82 -0
- package/models/index.ts +44 -0
- package/package.json +1 -1
|
@@ -0,0 +1,404 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Jugar Hoy - API
|
|
5
|
+
* API documentation for Jugar Hoy application
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.5.0
|
|
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
|
+
|
|
16
|
+
import * as runtime from '../runtime';
|
|
17
|
+
import type {
|
|
18
|
+
ApiAppVotingHasVotedPlaySearchIdGet200Response,
|
|
19
|
+
PlayerRatingResponse,
|
|
20
|
+
SubmitRatingsRequest,
|
|
21
|
+
VotingStatsResponse,
|
|
22
|
+
VotingStatusResponse,
|
|
23
|
+
} from '../models/index';
|
|
24
|
+
import {
|
|
25
|
+
ApiAppVotingHasVotedPlaySearchIdGet200ResponseFromJSON,
|
|
26
|
+
ApiAppVotingHasVotedPlaySearchIdGet200ResponseToJSON,
|
|
27
|
+
PlayerRatingResponseFromJSON,
|
|
28
|
+
PlayerRatingResponseToJSON,
|
|
29
|
+
SubmitRatingsRequestFromJSON,
|
|
30
|
+
SubmitRatingsRequestToJSON,
|
|
31
|
+
VotingStatsResponseFromJSON,
|
|
32
|
+
VotingStatsResponseToJSON,
|
|
33
|
+
VotingStatusResponseFromJSON,
|
|
34
|
+
VotingStatusResponseToJSON,
|
|
35
|
+
} from '../models/index';
|
|
36
|
+
|
|
37
|
+
export interface ApiAppVotingHasVotedPlaySearchIdGetRequest {
|
|
38
|
+
playSearchId: string;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface ApiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGetRequest {
|
|
42
|
+
playSearchId: string;
|
|
43
|
+
playerId: string;
|
|
44
|
+
teamId: string;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export interface ApiAppVotingResultsPlaySearchIdTeamTeamIdGetRequest {
|
|
48
|
+
playSearchId: string;
|
|
49
|
+
teamId: string;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export interface ApiAppVotingStatsPlaySearchIdTeamTeamIdGetRequest {
|
|
53
|
+
playSearchId: string;
|
|
54
|
+
teamId: string;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export interface ApiAppVotingStatusPlaySearchIdGetRequest {
|
|
58
|
+
playSearchId: string;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export interface ApiAppVotingSubmitPostRequest {
|
|
62
|
+
submitRatingsRequest: SubmitRatingsRequest;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export interface ApiAppVotingTopPlaySearchIdTeamTeamIdGetRequest {
|
|
66
|
+
playSearchId: string;
|
|
67
|
+
teamId: string;
|
|
68
|
+
limit?: number;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
*
|
|
73
|
+
*/
|
|
74
|
+
export class VotingApi extends runtime.BaseAPI {
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Check if user has submitted ratings for a match
|
|
78
|
+
*/
|
|
79
|
+
async apiAppVotingHasVotedPlaySearchIdGetRaw(requestParameters: ApiAppVotingHasVotedPlaySearchIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiAppVotingHasVotedPlaySearchIdGet200Response>> {
|
|
80
|
+
if (requestParameters['playSearchId'] == null) {
|
|
81
|
+
throw new runtime.RequiredError(
|
|
82
|
+
'playSearchId',
|
|
83
|
+
'Required parameter "playSearchId" was null or undefined when calling apiAppVotingHasVotedPlaySearchIdGet().'
|
|
84
|
+
);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
const queryParameters: any = {};
|
|
88
|
+
|
|
89
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
90
|
+
|
|
91
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
92
|
+
const token = this.configuration.accessToken;
|
|
93
|
+
const tokenString = await token("bearerAuth", []);
|
|
94
|
+
|
|
95
|
+
if (tokenString) {
|
|
96
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
const response = await this.request({
|
|
100
|
+
path: `/api/app/voting/has-voted/{playSearchId}`.replace(`{${"playSearchId"}}`, encodeURIComponent(String(requestParameters['playSearchId']))),
|
|
101
|
+
method: 'GET',
|
|
102
|
+
headers: headerParameters,
|
|
103
|
+
query: queryParameters,
|
|
104
|
+
}, initOverrides);
|
|
105
|
+
|
|
106
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ApiAppVotingHasVotedPlaySearchIdGet200ResponseFromJSON(jsonValue));
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* Check if user has submitted ratings for a match
|
|
111
|
+
*/
|
|
112
|
+
async apiAppVotingHasVotedPlaySearchIdGet(requestParameters: ApiAppVotingHasVotedPlaySearchIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiAppVotingHasVotedPlaySearchIdGet200Response> {
|
|
113
|
+
const response = await this.apiAppVotingHasVotedPlaySearchIdGetRaw(requestParameters, initOverrides);
|
|
114
|
+
return await response.value();
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Get rating for a specific player in a match
|
|
119
|
+
*/
|
|
120
|
+
async apiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGetRaw(requestParameters: ApiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<PlayerRatingResponse>> {
|
|
121
|
+
if (requestParameters['playSearchId'] == null) {
|
|
122
|
+
throw new runtime.RequiredError(
|
|
123
|
+
'playSearchId',
|
|
124
|
+
'Required parameter "playSearchId" was null or undefined when calling apiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGet().'
|
|
125
|
+
);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
if (requestParameters['playerId'] == null) {
|
|
129
|
+
throw new runtime.RequiredError(
|
|
130
|
+
'playerId',
|
|
131
|
+
'Required parameter "playerId" was null or undefined when calling apiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGet().'
|
|
132
|
+
);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
if (requestParameters['teamId'] == null) {
|
|
136
|
+
throw new runtime.RequiredError(
|
|
137
|
+
'teamId',
|
|
138
|
+
'Required parameter "teamId" was null or undefined when calling apiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGet().'
|
|
139
|
+
);
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
const queryParameters: any = {};
|
|
143
|
+
|
|
144
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
145
|
+
|
|
146
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
147
|
+
const token = this.configuration.accessToken;
|
|
148
|
+
const tokenString = await token("bearerAuth", []);
|
|
149
|
+
|
|
150
|
+
if (tokenString) {
|
|
151
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
const response = await this.request({
|
|
155
|
+
path: `/api/app/voting/player/{playSearchId}/{playerId}/team/{teamId}`.replace(`{${"playSearchId"}}`, encodeURIComponent(String(requestParameters['playSearchId']))).replace(`{${"playerId"}}`, encodeURIComponent(String(requestParameters['playerId']))).replace(`{${"teamId"}}`, encodeURIComponent(String(requestParameters['teamId']))),
|
|
156
|
+
method: 'GET',
|
|
157
|
+
headers: headerParameters,
|
|
158
|
+
query: queryParameters,
|
|
159
|
+
}, initOverrides);
|
|
160
|
+
|
|
161
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => PlayerRatingResponseFromJSON(jsonValue));
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
* Get rating for a specific player in a match
|
|
166
|
+
*/
|
|
167
|
+
async apiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGet(requestParameters: ApiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<PlayerRatingResponse> {
|
|
168
|
+
const response = await this.apiAppVotingPlayerPlaySearchIdPlayerIdTeamTeamIdGetRaw(requestParameters, initOverrides);
|
|
169
|
+
return await response.value();
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Get rating results for a match
|
|
174
|
+
*/
|
|
175
|
+
async apiAppVotingResultsPlaySearchIdTeamTeamIdGetRaw(requestParameters: ApiAppVotingResultsPlaySearchIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<PlayerRatingResponse>>> {
|
|
176
|
+
if (requestParameters['playSearchId'] == null) {
|
|
177
|
+
throw new runtime.RequiredError(
|
|
178
|
+
'playSearchId',
|
|
179
|
+
'Required parameter "playSearchId" was null or undefined when calling apiAppVotingResultsPlaySearchIdTeamTeamIdGet().'
|
|
180
|
+
);
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
if (requestParameters['teamId'] == null) {
|
|
184
|
+
throw new runtime.RequiredError(
|
|
185
|
+
'teamId',
|
|
186
|
+
'Required parameter "teamId" was null or undefined when calling apiAppVotingResultsPlaySearchIdTeamTeamIdGet().'
|
|
187
|
+
);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
const queryParameters: any = {};
|
|
191
|
+
|
|
192
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
193
|
+
|
|
194
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
195
|
+
const token = this.configuration.accessToken;
|
|
196
|
+
const tokenString = await token("bearerAuth", []);
|
|
197
|
+
|
|
198
|
+
if (tokenString) {
|
|
199
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
const response = await this.request({
|
|
203
|
+
path: `/api/app/voting/results/{playSearchId}/team/{teamId}`.replace(`{${"playSearchId"}}`, encodeURIComponent(String(requestParameters['playSearchId']))).replace(`{${"teamId"}}`, encodeURIComponent(String(requestParameters['teamId']))),
|
|
204
|
+
method: 'GET',
|
|
205
|
+
headers: headerParameters,
|
|
206
|
+
query: queryParameters,
|
|
207
|
+
}, initOverrides);
|
|
208
|
+
|
|
209
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PlayerRatingResponseFromJSON));
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
/**
|
|
213
|
+
* Get rating results for a match
|
|
214
|
+
*/
|
|
215
|
+
async apiAppVotingResultsPlaySearchIdTeamTeamIdGet(requestParameters: ApiAppVotingResultsPlaySearchIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<PlayerRatingResponse>> {
|
|
216
|
+
const response = await this.apiAppVotingResultsPlaySearchIdTeamTeamIdGetRaw(requestParameters, initOverrides);
|
|
217
|
+
return await response.value();
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
/**
|
|
221
|
+
* Get voting statistics for a match
|
|
222
|
+
*/
|
|
223
|
+
async apiAppVotingStatsPlaySearchIdTeamTeamIdGetRaw(requestParameters: ApiAppVotingStatsPlaySearchIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<VotingStatsResponse>> {
|
|
224
|
+
if (requestParameters['playSearchId'] == null) {
|
|
225
|
+
throw new runtime.RequiredError(
|
|
226
|
+
'playSearchId',
|
|
227
|
+
'Required parameter "playSearchId" was null or undefined when calling apiAppVotingStatsPlaySearchIdTeamTeamIdGet().'
|
|
228
|
+
);
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
if (requestParameters['teamId'] == null) {
|
|
232
|
+
throw new runtime.RequiredError(
|
|
233
|
+
'teamId',
|
|
234
|
+
'Required parameter "teamId" was null or undefined when calling apiAppVotingStatsPlaySearchIdTeamTeamIdGet().'
|
|
235
|
+
);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
const queryParameters: any = {};
|
|
239
|
+
|
|
240
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
241
|
+
|
|
242
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
243
|
+
const token = this.configuration.accessToken;
|
|
244
|
+
const tokenString = await token("bearerAuth", []);
|
|
245
|
+
|
|
246
|
+
if (tokenString) {
|
|
247
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
248
|
+
}
|
|
249
|
+
}
|
|
250
|
+
const response = await this.request({
|
|
251
|
+
path: `/api/app/voting/stats/{playSearchId}/team/{teamId}`.replace(`{${"playSearchId"}}`, encodeURIComponent(String(requestParameters['playSearchId']))).replace(`{${"teamId"}}`, encodeURIComponent(String(requestParameters['teamId']))),
|
|
252
|
+
method: 'GET',
|
|
253
|
+
headers: headerParameters,
|
|
254
|
+
query: queryParameters,
|
|
255
|
+
}, initOverrides);
|
|
256
|
+
|
|
257
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => VotingStatsResponseFromJSON(jsonValue));
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
/**
|
|
261
|
+
* Get voting statistics for a match
|
|
262
|
+
*/
|
|
263
|
+
async apiAppVotingStatsPlaySearchIdTeamTeamIdGet(requestParameters: ApiAppVotingStatsPlaySearchIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<VotingStatsResponse> {
|
|
264
|
+
const response = await this.apiAppVotingStatsPlaySearchIdTeamTeamIdGetRaw(requestParameters, initOverrides);
|
|
265
|
+
return await response.value();
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
/**
|
|
269
|
+
* Check if voting is currently open for a match
|
|
270
|
+
*/
|
|
271
|
+
async apiAppVotingStatusPlaySearchIdGetRaw(requestParameters: ApiAppVotingStatusPlaySearchIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<VotingStatusResponse>> {
|
|
272
|
+
if (requestParameters['playSearchId'] == null) {
|
|
273
|
+
throw new runtime.RequiredError(
|
|
274
|
+
'playSearchId',
|
|
275
|
+
'Required parameter "playSearchId" was null or undefined when calling apiAppVotingStatusPlaySearchIdGet().'
|
|
276
|
+
);
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
const queryParameters: any = {};
|
|
280
|
+
|
|
281
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
282
|
+
|
|
283
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
284
|
+
const token = this.configuration.accessToken;
|
|
285
|
+
const tokenString = await token("bearerAuth", []);
|
|
286
|
+
|
|
287
|
+
if (tokenString) {
|
|
288
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
const response = await this.request({
|
|
292
|
+
path: `/api/app/voting/status/{playSearchId}`.replace(`{${"playSearchId"}}`, encodeURIComponent(String(requestParameters['playSearchId']))),
|
|
293
|
+
method: 'GET',
|
|
294
|
+
headers: headerParameters,
|
|
295
|
+
query: queryParameters,
|
|
296
|
+
}, initOverrides);
|
|
297
|
+
|
|
298
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => VotingStatusResponseFromJSON(jsonValue));
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
/**
|
|
302
|
+
* Check if voting is currently open for a match
|
|
303
|
+
*/
|
|
304
|
+
async apiAppVotingStatusPlaySearchIdGet(requestParameters: ApiAppVotingStatusPlaySearchIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<VotingStatusResponse> {
|
|
305
|
+
const response = await this.apiAppVotingStatusPlaySearchIdGetRaw(requestParameters, initOverrides);
|
|
306
|
+
return await response.value();
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
/**
|
|
310
|
+
* Submit ratings for players in a match
|
|
311
|
+
*/
|
|
312
|
+
async apiAppVotingSubmitPostRaw(requestParameters: ApiAppVotingSubmitPostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
313
|
+
if (requestParameters['submitRatingsRequest'] == null) {
|
|
314
|
+
throw new runtime.RequiredError(
|
|
315
|
+
'submitRatingsRequest',
|
|
316
|
+
'Required parameter "submitRatingsRequest" was null or undefined when calling apiAppVotingSubmitPost().'
|
|
317
|
+
);
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
const queryParameters: any = {};
|
|
321
|
+
|
|
322
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
323
|
+
|
|
324
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
325
|
+
|
|
326
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
327
|
+
const token = this.configuration.accessToken;
|
|
328
|
+
const tokenString = await token("bearerAuth", []);
|
|
329
|
+
|
|
330
|
+
if (tokenString) {
|
|
331
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
332
|
+
}
|
|
333
|
+
}
|
|
334
|
+
const response = await this.request({
|
|
335
|
+
path: `/api/app/voting/submit`,
|
|
336
|
+
method: 'POST',
|
|
337
|
+
headers: headerParameters,
|
|
338
|
+
query: queryParameters,
|
|
339
|
+
body: SubmitRatingsRequestToJSON(requestParameters['submitRatingsRequest']),
|
|
340
|
+
}, initOverrides);
|
|
341
|
+
|
|
342
|
+
return new runtime.VoidApiResponse(response);
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* Submit ratings for players in a match
|
|
347
|
+
*/
|
|
348
|
+
async apiAppVotingSubmitPost(requestParameters: ApiAppVotingSubmitPostRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
349
|
+
await this.apiAppVotingSubmitPostRaw(requestParameters, initOverrides);
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
/**
|
|
353
|
+
* Get top rated players for a match
|
|
354
|
+
*/
|
|
355
|
+
async apiAppVotingTopPlaySearchIdTeamTeamIdGetRaw(requestParameters: ApiAppVotingTopPlaySearchIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<PlayerRatingResponse>>> {
|
|
356
|
+
if (requestParameters['playSearchId'] == null) {
|
|
357
|
+
throw new runtime.RequiredError(
|
|
358
|
+
'playSearchId',
|
|
359
|
+
'Required parameter "playSearchId" was null or undefined when calling apiAppVotingTopPlaySearchIdTeamTeamIdGet().'
|
|
360
|
+
);
|
|
361
|
+
}
|
|
362
|
+
|
|
363
|
+
if (requestParameters['teamId'] == null) {
|
|
364
|
+
throw new runtime.RequiredError(
|
|
365
|
+
'teamId',
|
|
366
|
+
'Required parameter "teamId" was null or undefined when calling apiAppVotingTopPlaySearchIdTeamTeamIdGet().'
|
|
367
|
+
);
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
const queryParameters: any = {};
|
|
371
|
+
|
|
372
|
+
if (requestParameters['limit'] != null) {
|
|
373
|
+
queryParameters['limit'] = requestParameters['limit'];
|
|
374
|
+
}
|
|
375
|
+
|
|
376
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
377
|
+
|
|
378
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
379
|
+
const token = this.configuration.accessToken;
|
|
380
|
+
const tokenString = await token("bearerAuth", []);
|
|
381
|
+
|
|
382
|
+
if (tokenString) {
|
|
383
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
384
|
+
}
|
|
385
|
+
}
|
|
386
|
+
const response = await this.request({
|
|
387
|
+
path: `/api/app/voting/top/{playSearchId}/team/{teamId}`.replace(`{${"playSearchId"}}`, encodeURIComponent(String(requestParameters['playSearchId']))).replace(`{${"teamId"}}`, encodeURIComponent(String(requestParameters['teamId']))),
|
|
388
|
+
method: 'GET',
|
|
389
|
+
headers: headerParameters,
|
|
390
|
+
query: queryParameters,
|
|
391
|
+
}, initOverrides);
|
|
392
|
+
|
|
393
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(PlayerRatingResponseFromJSON));
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
/**
|
|
397
|
+
* Get top rated players for a match
|
|
398
|
+
*/
|
|
399
|
+
async apiAppVotingTopPlaySearchIdTeamTeamIdGet(requestParameters: ApiAppVotingTopPlaySearchIdTeamTeamIdGetRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<PlayerRatingResponse>> {
|
|
400
|
+
const response = await this.apiAppVotingTopPlaySearchIdTeamTeamIdGetRaw(requestParameters, initOverrides);
|
|
401
|
+
return await response.value();
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
}
|
package/apis/index.ts
CHANGED
|
@@ -29,5 +29,11 @@ export * from './MercadoPagoApi';
|
|
|
29
29
|
export * from './MercadoPagoIPNApi';
|
|
30
30
|
export * from './NotificationsApi';
|
|
31
31
|
export * from './PlaySpotsApi';
|
|
32
|
+
export * from './PositionsApi';
|
|
33
|
+
export * from './RecurringGamesApi';
|
|
32
34
|
export * from './ReservesApi';
|
|
35
|
+
export * from './SportEventsApi';
|
|
36
|
+
export * from './TeamFeedApi';
|
|
37
|
+
export * from './TeamsApi';
|
|
33
38
|
export * from './UsersApi';
|
|
39
|
+
export * from './VotingApi';
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Jugar Hoy - API
|
|
5
|
+
* API documentation for Jugar Hoy application
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.5.0
|
|
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 { ApiAppTeamsTeamIdEventsGet200ResponseEventsInner } from './ApiAppTeamsTeamIdEventsGet200ResponseEventsInner';
|
|
17
|
+
import {
|
|
18
|
+
ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerFromJSON,
|
|
19
|
+
ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerFromJSONTyped,
|
|
20
|
+
ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerToJSON,
|
|
21
|
+
ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerToJSONTyped,
|
|
22
|
+
} from './ApiAppTeamsTeamIdEventsGet200ResponseEventsInner';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface ApiAppTeamsTeamIdEventsGet200Response
|
|
28
|
+
*/
|
|
29
|
+
export interface ApiAppTeamsTeamIdEventsGet200Response {
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {Array<ApiAppTeamsTeamIdEventsGet200ResponseEventsInner>}
|
|
33
|
+
* @memberof ApiAppTeamsTeamIdEventsGet200Response
|
|
34
|
+
*/
|
|
35
|
+
events?: Array<ApiAppTeamsTeamIdEventsGet200ResponseEventsInner>;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Check if a given object implements the ApiAppTeamsTeamIdEventsGet200Response interface.
|
|
40
|
+
*/
|
|
41
|
+
export function instanceOfApiAppTeamsTeamIdEventsGet200Response(value: object): value is ApiAppTeamsTeamIdEventsGet200Response {
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseFromJSON(json: any): ApiAppTeamsTeamIdEventsGet200Response {
|
|
46
|
+
return ApiAppTeamsTeamIdEventsGet200ResponseFromJSONTyped(json, false);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiAppTeamsTeamIdEventsGet200Response {
|
|
50
|
+
if (json == null) {
|
|
51
|
+
return json;
|
|
52
|
+
}
|
|
53
|
+
return {
|
|
54
|
+
|
|
55
|
+
'events': json['events'] == null ? undefined : ((json['events'] as Array<any>).map(ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerFromJSON)),
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseToJSON(json: any): ApiAppTeamsTeamIdEventsGet200Response {
|
|
60
|
+
return ApiAppTeamsTeamIdEventsGet200ResponseToJSONTyped(json, false);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseToJSONTyped(value?: ApiAppTeamsTeamIdEventsGet200Response | null, ignoreDiscriminator: boolean = false): any {
|
|
64
|
+
if (value == null) {
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
return {
|
|
69
|
+
|
|
70
|
+
'events': value['events'] == null ? undefined : ((value['events'] as Array<any>).map(ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerToJSON)),
|
|
71
|
+
};
|
|
72
|
+
}
|
|
73
|
+
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Jugar Hoy - API
|
|
5
|
+
* API documentation for Jugar Hoy application
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.5.0
|
|
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 ApiAppTeamsTeamIdEventsGet200ResponseEventsInner
|
|
20
|
+
*/
|
|
21
|
+
export interface ApiAppTeamsTeamIdEventsGet200ResponseEventsInner {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof ApiAppTeamsTeamIdEventsGet200ResponseEventsInner
|
|
26
|
+
*/
|
|
27
|
+
code?: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof ApiAppTeamsTeamIdEventsGet200ResponseEventsInner
|
|
32
|
+
*/
|
|
33
|
+
icon?: string;
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @type {string}
|
|
37
|
+
* @memberof ApiAppTeamsTeamIdEventsGet200ResponseEventsInner
|
|
38
|
+
*/
|
|
39
|
+
displayName?: string;
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @type {string}
|
|
43
|
+
* @memberof ApiAppTeamsTeamIdEventsGet200ResponseEventsInner
|
|
44
|
+
*/
|
|
45
|
+
displayNameEs?: string;
|
|
46
|
+
/**
|
|
47
|
+
*
|
|
48
|
+
* @type {string}
|
|
49
|
+
* @memberof ApiAppTeamsTeamIdEventsGet200ResponseEventsInner
|
|
50
|
+
*/
|
|
51
|
+
color?: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/**
|
|
55
|
+
* Check if a given object implements the ApiAppTeamsTeamIdEventsGet200ResponseEventsInner interface.
|
|
56
|
+
*/
|
|
57
|
+
export function instanceOfApiAppTeamsTeamIdEventsGet200ResponseEventsInner(value: object): value is ApiAppTeamsTeamIdEventsGet200ResponseEventsInner {
|
|
58
|
+
return true;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerFromJSON(json: any): ApiAppTeamsTeamIdEventsGet200ResponseEventsInner {
|
|
62
|
+
return ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerFromJSONTyped(json, false);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): ApiAppTeamsTeamIdEventsGet200ResponseEventsInner {
|
|
66
|
+
if (json == null) {
|
|
67
|
+
return json;
|
|
68
|
+
}
|
|
69
|
+
return {
|
|
70
|
+
|
|
71
|
+
'code': json['code'] == null ? undefined : json['code'],
|
|
72
|
+
'icon': json['icon'] == null ? undefined : json['icon'],
|
|
73
|
+
'displayName': json['displayName'] == null ? undefined : json['displayName'],
|
|
74
|
+
'displayNameEs': json['displayNameEs'] == null ? undefined : json['displayNameEs'],
|
|
75
|
+
'color': json['color'] == null ? undefined : json['color'],
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerToJSON(json: any): ApiAppTeamsTeamIdEventsGet200ResponseEventsInner {
|
|
80
|
+
return ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerToJSONTyped(json, false);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export function ApiAppTeamsTeamIdEventsGet200ResponseEventsInnerToJSONTyped(value?: ApiAppTeamsTeamIdEventsGet200ResponseEventsInner | null, ignoreDiscriminator: boolean = false): any {
|
|
84
|
+
if (value == null) {
|
|
85
|
+
return value;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
return {
|
|
89
|
+
|
|
90
|
+
'code': value['code'],
|
|
91
|
+
'icon': value['icon'],
|
|
92
|
+
'displayName': value['displayName'],
|
|
93
|
+
'displayNameEs': value['displayNameEs'],
|
|
94
|
+
'color': value['color'],
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
|