@jugarhoy/api 1.1.43 → 1.1.45

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.
@@ -15,18 +15,9 @@
15
15
 
16
16
  import * as runtime from '../runtime';
17
17
  import type {
18
- ExpireUnpaidReservationResult,
19
- ExpireUnpaidReservations401Response,
20
- ExpireUnpaidReservations500Response,
21
18
  GenerateRecurringGames200Response,
22
19
  } from '../models/index';
23
20
  import {
24
- ExpireUnpaidReservationResultFromJSON,
25
- ExpireUnpaidReservationResultToJSON,
26
- ExpireUnpaidReservations401ResponseFromJSON,
27
- ExpireUnpaidReservations401ResponseToJSON,
28
- ExpireUnpaidReservations500ResponseFromJSON,
29
- ExpireUnpaidReservations500ResponseToJSON,
30
21
  GenerateRecurringGames200ResponseFromJSON,
31
22
  GenerateRecurringGames200ResponseToJSON,
32
23
  } from '../models/index';
@@ -36,36 +27,6 @@ import {
36
27
  */
37
28
  export class BackgroundApi extends runtime.BaseAPI {
38
29
 
39
- /**
40
- * Expire all unpaid reservations older than the configured timeout
41
- */
42
- async expireUnpaidReservationsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExpireUnpaidReservationResult>> {
43
- const queryParameters: any = {};
44
-
45
- const headerParameters: runtime.HTTPHeaders = {};
46
-
47
- if (this.configuration && this.configuration.apiKey) {
48
- headerParameters["x-jugarhoy-secret"] = await this.configuration.apiKey("x-jugarhoy-secret"); // jugarhoySecret authentication
49
- }
50
-
51
- const response = await this.request({
52
- path: `/api/background/expire-unpaid-reservations`,
53
- method: 'POST',
54
- headers: headerParameters,
55
- query: queryParameters,
56
- }, initOverrides);
57
-
58
- return new runtime.JSONApiResponse(response, (jsonValue) => ExpireUnpaidReservationResultFromJSON(jsonValue));
59
- }
60
-
61
- /**
62
- * Expire all unpaid reservations older than the configured timeout
63
- */
64
- async expireUnpaidReservations(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExpireUnpaidReservationResult> {
65
- const response = await this.expireUnpaidReservationsRaw(initOverrides);
66
- return await response.value();
67
- }
68
-
69
30
  /**
70
31
  * For each active recurring game, tops up future PlaySearch events to maintain a rolling window of 4 upcoming matches. Run weekly.
71
32
  * Ensure all active recurring games have 4 upcoming PlaySearch events
package/apis/ClubApi.ts CHANGED
@@ -19,7 +19,9 @@ import type {
19
19
  ClubMySubscriptionDto,
20
20
  ClubProfileDto,
21
21
  ClubSearchResponse,
22
+ CustomerDocument,
22
23
  MyClubDto,
24
+ RecordClubDocumentParams,
23
25
  RegisterClub400Response,
24
26
  RegisterClub401Response,
25
27
  RegisterClub500Response,
@@ -27,6 +29,7 @@ import type {
27
29
  RegisterClubResponse,
28
30
  SearchClubs400Response,
29
31
  SearchClubs500Response,
32
+ SendClubDocumentsParams,
30
33
  Sport,
31
34
  UpdateAppLocationParams,
32
35
  UpdateClubSettingsParams,
@@ -41,8 +44,12 @@ import {
41
44
  ClubProfileDtoToJSON,
42
45
  ClubSearchResponseFromJSON,
43
46
  ClubSearchResponseToJSON,
47
+ CustomerDocumentFromJSON,
48
+ CustomerDocumentToJSON,
44
49
  MyClubDtoFromJSON,
45
50
  MyClubDtoToJSON,
51
+ RecordClubDocumentParamsFromJSON,
52
+ RecordClubDocumentParamsToJSON,
46
53
  RegisterClub400ResponseFromJSON,
47
54
  RegisterClub400ResponseToJSON,
48
55
  RegisterClub401ResponseFromJSON,
@@ -57,6 +64,8 @@ import {
57
64
  SearchClubs400ResponseToJSON,
58
65
  SearchClubs500ResponseFromJSON,
59
66
  SearchClubs500ResponseToJSON,
67
+ SendClubDocumentsParamsFromJSON,
68
+ SendClubDocumentsParamsToJSON,
60
69
  SportFromJSON,
61
70
  SportToJSON,
62
71
  UpdateAppLocationParamsFromJSON,
@@ -72,6 +81,11 @@ export interface ApiClubClubCodeSubscriptionsSubscriptionIdRequestCancellationPo
72
81
  subscriptionId: string;
73
82
  }
74
83
 
84
+ export interface DeleteClubDocumentRequest {
85
+ clubCode: string;
86
+ documentId: string;
87
+ }
88
+
75
89
  export interface GetClubLocationRequest {
76
90
  clubCode: string;
77
91
  locationId: string;
@@ -85,10 +99,19 @@ export interface GetClubProfileRequest {
85
99
  clubCode: string;
86
100
  }
87
101
 
102
+ export interface ListClubDocumentsRequest {
103
+ clubCode: string;
104
+ }
105
+
88
106
  export interface ListClubLocationsRequest {
89
107
  clubCode: string;
90
108
  }
91
109
 
110
+ export interface RecordClubDocumentRequest {
111
+ clubCode: string;
112
+ recordClubDocumentParams: RecordClubDocumentParams;
113
+ }
114
+
92
115
  export interface RegisterClubRequest {
93
116
  registerClubParams: RegisterClubParams;
94
117
  }
@@ -103,6 +126,11 @@ export interface SearchClubsRequest {
103
126
  size?: number;
104
127
  }
105
128
 
129
+ export interface SendClubDocumentsRequest {
130
+ clubCode: string;
131
+ sendClubDocumentsParams: SendClubDocumentsParams;
132
+ }
133
+
106
134
  export interface UpdateClubLocationRequest {
107
135
  clubCode: string;
108
136
  locationId: string;
@@ -166,6 +194,53 @@ export class ClubApi extends runtime.BaseAPI {
166
194
  await this.apiClubClubCodeSubscriptionsSubscriptionIdRequestCancellationPostRaw(requestParameters, initOverrides);
167
195
  }
168
196
 
197
+ /**
198
+ * Delete a verification document for a club (admin only)
199
+ */
200
+ async deleteClubDocumentRaw(requestParameters: DeleteClubDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
201
+ if (requestParameters['clubCode'] == null) {
202
+ throw new runtime.RequiredError(
203
+ 'clubCode',
204
+ 'Required parameter "clubCode" was null or undefined when calling deleteClubDocument().'
205
+ );
206
+ }
207
+
208
+ if (requestParameters['documentId'] == null) {
209
+ throw new runtime.RequiredError(
210
+ 'documentId',
211
+ 'Required parameter "documentId" was null or undefined when calling deleteClubDocument().'
212
+ );
213
+ }
214
+
215
+ const queryParameters: any = {};
216
+
217
+ const headerParameters: runtime.HTTPHeaders = {};
218
+
219
+ if (this.configuration && this.configuration.accessToken) {
220
+ const token = this.configuration.accessToken;
221
+ const tokenString = await token("bearerAuth", []);
222
+
223
+ if (tokenString) {
224
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
225
+ }
226
+ }
227
+ const response = await this.request({
228
+ path: `/api/club/{clubCode}/documents/{documentId}`.replace(`{${"clubCode"}}`, encodeURIComponent(String(requestParameters['clubCode']))).replace(`{${"documentId"}}`, encodeURIComponent(String(requestParameters['documentId']))),
229
+ method: 'DELETE',
230
+ headers: headerParameters,
231
+ query: queryParameters,
232
+ }, initOverrides);
233
+
234
+ return new runtime.VoidApiResponse(response);
235
+ }
236
+
237
+ /**
238
+ * Delete a verification document for a club (admin only)
239
+ */
240
+ async deleteClubDocument(requestParameters: DeleteClubDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
241
+ await this.deleteClubDocumentRaw(requestParameters, initOverrides);
242
+ }
243
+
169
244
  /**
170
245
  * Get a single location with hours (club admin only)
171
246
  */
@@ -330,6 +405,47 @@ export class ClubApi extends runtime.BaseAPI {
330
405
  return await response.value();
331
406
  }
332
407
 
408
+ /**
409
+ * List verification documents for a club (admin only)
410
+ */
411
+ async listClubDocumentsRaw(requestParameters: ListClubDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<CustomerDocument>>> {
412
+ if (requestParameters['clubCode'] == null) {
413
+ throw new runtime.RequiredError(
414
+ 'clubCode',
415
+ 'Required parameter "clubCode" was null or undefined when calling listClubDocuments().'
416
+ );
417
+ }
418
+
419
+ const queryParameters: any = {};
420
+
421
+ const headerParameters: runtime.HTTPHeaders = {};
422
+
423
+ if (this.configuration && this.configuration.accessToken) {
424
+ const token = this.configuration.accessToken;
425
+ const tokenString = await token("bearerAuth", []);
426
+
427
+ if (tokenString) {
428
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
429
+ }
430
+ }
431
+ const response = await this.request({
432
+ path: `/api/club/{clubCode}/documents`.replace(`{${"clubCode"}}`, encodeURIComponent(String(requestParameters['clubCode']))),
433
+ method: 'GET',
434
+ headers: headerParameters,
435
+ query: queryParameters,
436
+ }, initOverrides);
437
+
438
+ return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(CustomerDocumentFromJSON));
439
+ }
440
+
441
+ /**
442
+ * List verification documents for a club (admin only)
443
+ */
444
+ async listClubDocuments(requestParameters: ListClubDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<CustomerDocument>> {
445
+ const response = await this.listClubDocumentsRaw(requestParameters, initOverrides);
446
+ return await response.value();
447
+ }
448
+
333
449
  /**
334
450
  * List locations for the club (club admin only)
335
451
  */
@@ -371,6 +487,59 @@ export class ClubApi extends runtime.BaseAPI {
371
487
  return await response.value();
372
488
  }
373
489
 
490
+ /**
491
+ * Persists metadata for a document the club admin has just uploaded directly to Firebase Storage via a CLUB_DOCUMENT signed URL. The fileUrl is verified against the caller\'s owner-scoped folder.
492
+ * Record a verification document for a club (admin only)
493
+ */
494
+ async recordClubDocumentRaw(requestParameters: RecordClubDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CustomerDocument>> {
495
+ if (requestParameters['clubCode'] == null) {
496
+ throw new runtime.RequiredError(
497
+ 'clubCode',
498
+ 'Required parameter "clubCode" was null or undefined when calling recordClubDocument().'
499
+ );
500
+ }
501
+
502
+ if (requestParameters['recordClubDocumentParams'] == null) {
503
+ throw new runtime.RequiredError(
504
+ 'recordClubDocumentParams',
505
+ 'Required parameter "recordClubDocumentParams" was null or undefined when calling recordClubDocument().'
506
+ );
507
+ }
508
+
509
+ const queryParameters: any = {};
510
+
511
+ const headerParameters: runtime.HTTPHeaders = {};
512
+
513
+ headerParameters['Content-Type'] = 'application/json';
514
+
515
+ if (this.configuration && this.configuration.accessToken) {
516
+ const token = this.configuration.accessToken;
517
+ const tokenString = await token("bearerAuth", []);
518
+
519
+ if (tokenString) {
520
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
521
+ }
522
+ }
523
+ const response = await this.request({
524
+ path: `/api/club/{clubCode}/documents`.replace(`{${"clubCode"}}`, encodeURIComponent(String(requestParameters['clubCode']))),
525
+ method: 'POST',
526
+ headers: headerParameters,
527
+ query: queryParameters,
528
+ body: RecordClubDocumentParamsToJSON(requestParameters['recordClubDocumentParams']),
529
+ }, initOverrides);
530
+
531
+ return new runtime.JSONApiResponse(response, (jsonValue) => CustomerDocumentFromJSON(jsonValue));
532
+ }
533
+
534
+ /**
535
+ * Persists metadata for a document the club admin has just uploaded directly to Firebase Storage via a CLUB_DOCUMENT signed URL. The fileUrl is verified against the caller\'s owner-scoped folder.
536
+ * Record a verification document for a club (admin only)
537
+ */
538
+ async recordClubDocument(requestParameters: RecordClubDocumentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CustomerDocument> {
539
+ const response = await this.recordClubDocumentRaw(requestParameters, initOverrides);
540
+ return await response.value();
541
+ }
542
+
374
543
  /**
375
544
  * Register a new club
376
545
  */
@@ -477,6 +646,59 @@ export class ClubApi extends runtime.BaseAPI {
477
646
  return await response.value();
478
647
  }
479
648
 
649
+ /**
650
+ * Records every document in the body for this club, then sends a single notification email to the support inbox. Used by the mobile \"Enviar Documentos\" confirm button so each user action triggers exactly one support email.
651
+ * Record + notify Jugar Hoy support of a batch of verification documents (admin only)
652
+ */
653
+ async sendClubDocumentsRaw(requestParameters: SendClubDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<CustomerDocument>>> {
654
+ if (requestParameters['clubCode'] == null) {
655
+ throw new runtime.RequiredError(
656
+ 'clubCode',
657
+ 'Required parameter "clubCode" was null or undefined when calling sendClubDocuments().'
658
+ );
659
+ }
660
+
661
+ if (requestParameters['sendClubDocumentsParams'] == null) {
662
+ throw new runtime.RequiredError(
663
+ 'sendClubDocumentsParams',
664
+ 'Required parameter "sendClubDocumentsParams" was null or undefined when calling sendClubDocuments().'
665
+ );
666
+ }
667
+
668
+ const queryParameters: any = {};
669
+
670
+ const headerParameters: runtime.HTTPHeaders = {};
671
+
672
+ headerParameters['Content-Type'] = 'application/json';
673
+
674
+ if (this.configuration && this.configuration.accessToken) {
675
+ const token = this.configuration.accessToken;
676
+ const tokenString = await token("bearerAuth", []);
677
+
678
+ if (tokenString) {
679
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
680
+ }
681
+ }
682
+ const response = await this.request({
683
+ path: `/api/club/{clubCode}/documents/send`.replace(`{${"clubCode"}}`, encodeURIComponent(String(requestParameters['clubCode']))),
684
+ method: 'POST',
685
+ headers: headerParameters,
686
+ query: queryParameters,
687
+ body: SendClubDocumentsParamsToJSON(requestParameters['sendClubDocumentsParams']),
688
+ }, initOverrides);
689
+
690
+ return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(CustomerDocumentFromJSON));
691
+ }
692
+
693
+ /**
694
+ * Records every document in the body for this club, then sends a single notification email to the support inbox. Used by the mobile \"Enviar Documentos\" confirm button so each user action triggers exactly one support email.
695
+ * Record + notify Jugar Hoy support of a batch of verification documents (admin only)
696
+ */
697
+ async sendClubDocuments(requestParameters: SendClubDocumentsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<CustomerDocument>> {
698
+ const response = await this.sendClubDocumentsRaw(requestParameters, initOverrides);
699
+ return await response.value();
700
+ }
701
+
480
702
  /**
481
703
  * Update a location and its hours (club admin only)
482
704
  */
package/apis/UsersApi.ts CHANGED
@@ -213,6 +213,39 @@ export class UsersApi extends runtime.BaseAPI {
213
213
  return await response.value();
214
214
  }
215
215
 
216
+ /**
217
+ * Delete the authenticated user\'s own account
218
+ */
219
+ async deleteOwnAccountRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
220
+ const queryParameters: any = {};
221
+
222
+ const headerParameters: runtime.HTTPHeaders = {};
223
+
224
+ if (this.configuration && this.configuration.accessToken) {
225
+ const token = this.configuration.accessToken;
226
+ const tokenString = await token("bearerAuth", []);
227
+
228
+ if (tokenString) {
229
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
230
+ }
231
+ }
232
+ const response = await this.request({
233
+ path: `/api/users/me`,
234
+ method: 'DELETE',
235
+ headers: headerParameters,
236
+ query: queryParameters,
237
+ }, initOverrides);
238
+
239
+ return new runtime.VoidApiResponse(response);
240
+ }
241
+
242
+ /**
243
+ * Delete the authenticated user\'s own account
244
+ */
245
+ async deleteOwnAccount(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
246
+ await this.deleteOwnAccountRaw(initOverrides);
247
+ }
248
+
216
249
  /**
217
250
  * Delete a notification preference for the current user
218
251
  */
@@ -34,7 +34,7 @@ export interface IssueUploadUrlRequest {
34
34
  */
35
35
  kind: UploadKind;
36
36
  /**
37
- * Content type the client will PUT. Must match the actual bytes.
37
+ * Content type the client will PUT. Must match the actual bytes. application/pdf is only valid for kind=CLUB_DOCUMENT.
38
38
  * @type {string}
39
39
  * @memberof IssueUploadUrlRequest
40
40
  */
@@ -47,7 +47,8 @@ export interface IssueUploadUrlRequest {
47
47
  */
48
48
  export const IssueUploadUrlRequestContentTypeEnum = {
49
49
  ImageJpeg: 'image/jpeg',
50
- ImagePng: 'image/png'
50
+ ImagePng: 'image/png',
51
+ ApplicationPdf: 'application/pdf'
51
52
  } as const;
52
53
  export type IssueUploadUrlRequestContentTypeEnum = typeof IssueUploadUrlRequestContentTypeEnum[keyof typeof IssueUploadUrlRequestContentTypeEnum];
53
54
 
@@ -0,0 +1,113 @@
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 RecordClubDocumentParams
20
+ */
21
+ export interface RecordClubDocumentParams {
22
+ /**
23
+ * Signed Firebase Storage URL returned by /api/app/media/upload-url with kind=CLUB_DOCUMENT.
24
+ * @type {string}
25
+ * @memberof RecordClubDocumentParams
26
+ */
27
+ fileUrl: string;
28
+ /**
29
+ * Original file name as picked by the user.
30
+ * @type {string}
31
+ * @memberof RecordClubDocumentParams
32
+ */
33
+ fileName: string;
34
+ /**
35
+ * File size in bytes (max 10MB).
36
+ * @type {number}
37
+ * @memberof RecordClubDocumentParams
38
+ */
39
+ fileSize: number;
40
+ /**
41
+ *
42
+ * @type {string}
43
+ * @memberof RecordClubDocumentParams
44
+ */
45
+ mimeType: RecordClubDocumentParamsMimeTypeEnum;
46
+ /**
47
+ * Optional description of the document.
48
+ * @type {string}
49
+ * @memberof RecordClubDocumentParams
50
+ */
51
+ description?: string | null;
52
+ }
53
+
54
+
55
+ /**
56
+ * @export
57
+ */
58
+ export const RecordClubDocumentParamsMimeTypeEnum = {
59
+ ApplicationPdf: 'application/pdf',
60
+ ImageJpeg: 'image/jpeg',
61
+ ImagePng: 'image/png'
62
+ } as const;
63
+ export type RecordClubDocumentParamsMimeTypeEnum = typeof RecordClubDocumentParamsMimeTypeEnum[keyof typeof RecordClubDocumentParamsMimeTypeEnum];
64
+
65
+
66
+ /**
67
+ * Check if a given object implements the RecordClubDocumentParams interface.
68
+ */
69
+ export function instanceOfRecordClubDocumentParams(value: object): value is RecordClubDocumentParams {
70
+ if (!('fileUrl' in value) || value['fileUrl'] === undefined) return false;
71
+ if (!('fileName' in value) || value['fileName'] === undefined) return false;
72
+ if (!('fileSize' in value) || value['fileSize'] === undefined) return false;
73
+ if (!('mimeType' in value) || value['mimeType'] === undefined) return false;
74
+ return true;
75
+ }
76
+
77
+ export function RecordClubDocumentParamsFromJSON(json: any): RecordClubDocumentParams {
78
+ return RecordClubDocumentParamsFromJSONTyped(json, false);
79
+ }
80
+
81
+ export function RecordClubDocumentParamsFromJSONTyped(json: any, ignoreDiscriminator: boolean): RecordClubDocumentParams {
82
+ if (json == null) {
83
+ return json;
84
+ }
85
+ return {
86
+
87
+ 'fileUrl': json['fileUrl'],
88
+ 'fileName': json['fileName'],
89
+ 'fileSize': json['fileSize'],
90
+ 'mimeType': json['mimeType'],
91
+ 'description': json['description'] == null ? undefined : json['description'],
92
+ };
93
+ }
94
+
95
+ export function RecordClubDocumentParamsToJSON(json: any): RecordClubDocumentParams {
96
+ return RecordClubDocumentParamsToJSONTyped(json, false);
97
+ }
98
+
99
+ export function RecordClubDocumentParamsToJSONTyped(value?: RecordClubDocumentParams | null, ignoreDiscriminator: boolean = false): any {
100
+ if (value == null) {
101
+ return value;
102
+ }
103
+
104
+ return {
105
+
106
+ 'fileUrl': value['fileUrl'],
107
+ 'fileName': value['fileName'],
108
+ 'fileSize': value['fileSize'],
109
+ 'mimeType': value['mimeType'],
110
+ 'description': value['description'],
111
+ };
112
+ }
113
+
@@ -46,11 +46,17 @@ export interface ReservationParams {
46
46
  */
47
47
  playPriceId: string;
48
48
  /**
49
- * The start date and time of the reservation.
50
- * @type {Date}
49
+ * Reservation date in YYYY-MM-DD format (location's local timezone).
50
+ * @type {string}
51
+ * @memberof ReservationParams
52
+ */
53
+ rentDate: string;
54
+ /**
55
+ * Reservation start hour in HH:MM format (location's local timezone).
56
+ * @type {string}
51
57
  * @memberof ReservationParams
52
58
  */
53
- rentedFrom: Date;
59
+ rentHour: string;
54
60
  /**
55
61
  * The duration of the reservation in minutes.
56
62
  * @type {number}
@@ -86,7 +92,8 @@ export function instanceOfReservationParams(value: object): value is Reservation
86
92
  if (!('locationId' in value) || value['locationId'] === undefined) return false;
87
93
  if (!('playSpotId' in value) || value['playSpotId'] === undefined) return false;
88
94
  if (!('playPriceId' in value) || value['playPriceId'] === undefined) return false;
89
- if (!('rentedFrom' in value) || value['rentedFrom'] === undefined) return false;
95
+ if (!('rentDate' in value) || value['rentDate'] === undefined) return false;
96
+ if (!('rentHour' in value) || value['rentHour'] === undefined) return false;
90
97
  if (!('duration' in value) || value['duration'] === undefined) return false;
91
98
  if (!('paymentMethod' in value) || value['paymentMethod'] === undefined) return false;
92
99
  return true;
@@ -105,7 +112,8 @@ export function ReservationParamsFromJSONTyped(json: any, ignoreDiscriminator: b
105
112
  'locationId': json['locationId'],
106
113
  'playSpotId': json['playSpotId'],
107
114
  'playPriceId': json['playPriceId'],
108
- 'rentedFrom': (new Date(json['rentedFrom'])),
115
+ 'rentDate': json['rentDate'],
116
+ 'rentHour': json['rentHour'],
109
117
  'duration': json['duration'],
110
118
  'paymentMethod': PaymentMethodFromJSON(json['paymentMethod']),
111
119
  'mobile': json['mobile'] == null ? undefined : json['mobile'],
@@ -127,7 +135,8 @@ export function ReservationParamsToJSONTyped(value?: ReservationParams | null, i
127
135
  'locationId': value['locationId'],
128
136
  'playSpotId': value['playSpotId'],
129
137
  'playPriceId': value['playPriceId'],
130
- 'rentedFrom': ((value['rentedFrom']).toISOString()),
138
+ 'rentDate': value['rentDate'],
139
+ 'rentHour': value['rentHour'],
131
140
  'duration': value['duration'],
132
141
  'paymentMethod': PaymentMethodToJSON(value['paymentMethod']),
133
142
  'mobile': value['mobile'],
@@ -0,0 +1,74 @@
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 { RecordClubDocumentParams } from './RecordClubDocumentParams';
17
+ import {
18
+ RecordClubDocumentParamsFromJSON,
19
+ RecordClubDocumentParamsFromJSONTyped,
20
+ RecordClubDocumentParamsToJSON,
21
+ RecordClubDocumentParamsToJSONTyped,
22
+ } from './RecordClubDocumentParams';
23
+
24
+ /**
25
+ *
26
+ * @export
27
+ * @interface SendClubDocumentsParams
28
+ */
29
+ export interface SendClubDocumentsParams {
30
+ /**
31
+ *
32
+ * @type {Array<RecordClubDocumentParams>}
33
+ * @memberof SendClubDocumentsParams
34
+ */
35
+ documents: Array<RecordClubDocumentParams>;
36
+ }
37
+
38
+ /**
39
+ * Check if a given object implements the SendClubDocumentsParams interface.
40
+ */
41
+ export function instanceOfSendClubDocumentsParams(value: object): value is SendClubDocumentsParams {
42
+ if (!('documents' in value) || value['documents'] === undefined) return false;
43
+ return true;
44
+ }
45
+
46
+ export function SendClubDocumentsParamsFromJSON(json: any): SendClubDocumentsParams {
47
+ return SendClubDocumentsParamsFromJSONTyped(json, false);
48
+ }
49
+
50
+ export function SendClubDocumentsParamsFromJSONTyped(json: any, ignoreDiscriminator: boolean): SendClubDocumentsParams {
51
+ if (json == null) {
52
+ return json;
53
+ }
54
+ return {
55
+
56
+ 'documents': ((json['documents'] as Array<any>).map(RecordClubDocumentParamsFromJSON)),
57
+ };
58
+ }
59
+
60
+ export function SendClubDocumentsParamsToJSON(json: any): SendClubDocumentsParams {
61
+ return SendClubDocumentsParamsToJSONTyped(json, false);
62
+ }
63
+
64
+ export function SendClubDocumentsParamsToJSONTyped(value?: SendClubDocumentsParams | null, ignoreDiscriminator: boolean = false): any {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+
69
+ return {
70
+
71
+ 'documents': ((value['documents'] as Array<any>).map(RecordClubDocumentParamsToJSON)),
72
+ };
73
+ }
74
+
@@ -14,7 +14,7 @@
14
14
 
15
15
 
16
16
  /**
17
- * Category of image being uploaded. Determines the storage folder and ownership scoping.
17
+ * Category of file being uploaded. Determines the storage folder, ownership scoping, and allowed content types (image-only for most kinds; image+pdf for CLUB_DOCUMENT).
18
18
  * @export
19
19
  */
20
20
  export const UploadKind = {
@@ -25,7 +25,8 @@ export const UploadKind = {
25
25
  TeamAvatar: 'TEAM_AVATAR',
26
26
  TeamBanner: 'TEAM_BANNER',
27
27
  ClubAvatar: 'CLUB_AVATAR',
28
- ClubHeader: 'CLUB_HEADER'
28
+ ClubHeader: 'CLUB_HEADER',
29
+ ClubDocument: 'CLUB_DOCUMENT'
29
30
  } as const;
30
31
  export type UploadKind = typeof UploadKind[keyof typeof UploadKind];
31
32
 
package/models/index.ts CHANGED
@@ -129,9 +129,6 @@ export * from './DominantPlaySide';
129
129
  export * from './DominantSide';
130
130
  export * from './EditTeamFeedPostRequest';
131
131
  export * from './ErrorResponse';
132
- export * from './ExpireUnpaidReservationResult';
133
- export * from './ExpireUnpaidReservations401Response';
134
- export * from './ExpireUnpaidReservations500Response';
135
132
  export * from './ExtendSubscriptions200Response';
136
133
  export * from './ExtendSubscriptions200ResponseDetailsInner';
137
134
  export * from './Feature';
@@ -257,6 +254,7 @@ export * from './ProcessMercadoPagoPaymentResponseResult';
257
254
  export * from './PublicAgendaSlotDto';
258
255
  export * from './PublicDayAgendaDto';
259
256
  export * from './PublicWeeklyAgendaDto';
257
+ export * from './RecordClubDocumentParams';
260
258
  export * from './RecurringGame';
261
259
  export * from './RecurringGameResponse';
262
260
  export * from './RefundPolicy';
@@ -295,6 +293,7 @@ export * from './SavePushTokenRequest';
295
293
  export * from './SaveTransferDetailsRequest';
296
294
  export * from './SearchClubs400Response';
297
295
  export * from './SearchClubs500Response';
296
+ export * from './SendClubDocumentsParams';
298
297
  export * from './SendEmailVerification500Response';
299
298
  export * from './SendEmailVerificationRequest';
300
299
  export * from './ServiceType';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jugarhoy/api",
3
- "version": "1.1.43",
3
+ "version": "1.1.45",
4
4
  "description": "TypeScript SDK for Jugar Hoy API",
5
5
  "main": "index.ts",
6
6
  "types": "index.ts",
@@ -1,81 +0,0 @@
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 { Reserve } from './Reserve';
17
- import {
18
- ReserveFromJSON,
19
- ReserveFromJSONTyped,
20
- ReserveToJSON,
21
- ReserveToJSONTyped,
22
- } from './Reserve';
23
-
24
- /**
25
- *
26
- * @export
27
- * @interface ExpireUnpaidReservationResult
28
- */
29
- export interface ExpireUnpaidReservationResult {
30
- /**
31
- * Number of reservations that were expired
32
- * @type {number}
33
- * @memberof ExpireUnpaidReservationResult
34
- */
35
- expiredCount?: number;
36
- /**
37
- * Array of expired reservations
38
- * @type {Array<Reserve>}
39
- * @memberof ExpireUnpaidReservationResult
40
- */
41
- expiredReservations?: Array<Reserve>;
42
- }
43
-
44
- /**
45
- * Check if a given object implements the ExpireUnpaidReservationResult interface.
46
- */
47
- export function instanceOfExpireUnpaidReservationResult(value: object): value is ExpireUnpaidReservationResult {
48
- return true;
49
- }
50
-
51
- export function ExpireUnpaidReservationResultFromJSON(json: any): ExpireUnpaidReservationResult {
52
- return ExpireUnpaidReservationResultFromJSONTyped(json, false);
53
- }
54
-
55
- export function ExpireUnpaidReservationResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExpireUnpaidReservationResult {
56
- if (json == null) {
57
- return json;
58
- }
59
- return {
60
-
61
- 'expiredCount': json['expiredCount'] == null ? undefined : json['expiredCount'],
62
- 'expiredReservations': json['expiredReservations'] == null ? undefined : ((json['expiredReservations'] as Array<any>).map(ReserveFromJSON)),
63
- };
64
- }
65
-
66
- export function ExpireUnpaidReservationResultToJSON(json: any): ExpireUnpaidReservationResult {
67
- return ExpireUnpaidReservationResultToJSONTyped(json, false);
68
- }
69
-
70
- export function ExpireUnpaidReservationResultToJSONTyped(value?: ExpireUnpaidReservationResult | null, ignoreDiscriminator: boolean = false): any {
71
- if (value == null) {
72
- return value;
73
- }
74
-
75
- return {
76
-
77
- 'expiredCount': value['expiredCount'],
78
- 'expiredReservations': value['expiredReservations'] == null ? undefined : ((value['expiredReservations'] as Array<any>).map(ReserveToJSON)),
79
- };
80
- }
81
-
@@ -1,65 +0,0 @@
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 ExpireUnpaidReservations401Response
20
- */
21
- export interface ExpireUnpaidReservations401Response {
22
- /**
23
- *
24
- * @type {string}
25
- * @memberof ExpireUnpaidReservations401Response
26
- */
27
- error?: string;
28
- }
29
-
30
- /**
31
- * Check if a given object implements the ExpireUnpaidReservations401Response interface.
32
- */
33
- export function instanceOfExpireUnpaidReservations401Response(value: object): value is ExpireUnpaidReservations401Response {
34
- return true;
35
- }
36
-
37
- export function ExpireUnpaidReservations401ResponseFromJSON(json: any): ExpireUnpaidReservations401Response {
38
- return ExpireUnpaidReservations401ResponseFromJSONTyped(json, false);
39
- }
40
-
41
- export function ExpireUnpaidReservations401ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExpireUnpaidReservations401Response {
42
- if (json == null) {
43
- return json;
44
- }
45
- return {
46
-
47
- 'error': json['error'] == null ? undefined : json['error'],
48
- };
49
- }
50
-
51
- export function ExpireUnpaidReservations401ResponseToJSON(json: any): ExpireUnpaidReservations401Response {
52
- return ExpireUnpaidReservations401ResponseToJSONTyped(json, false);
53
- }
54
-
55
- export function ExpireUnpaidReservations401ResponseToJSONTyped(value?: ExpireUnpaidReservations401Response | null, ignoreDiscriminator: boolean = false): any {
56
- if (value == null) {
57
- return value;
58
- }
59
-
60
- return {
61
-
62
- 'error': value['error'],
63
- };
64
- }
65
-
@@ -1,65 +0,0 @@
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 ExpireUnpaidReservations500Response
20
- */
21
- export interface ExpireUnpaidReservations500Response {
22
- /**
23
- *
24
- * @type {string}
25
- * @memberof ExpireUnpaidReservations500Response
26
- */
27
- error?: string;
28
- }
29
-
30
- /**
31
- * Check if a given object implements the ExpireUnpaidReservations500Response interface.
32
- */
33
- export function instanceOfExpireUnpaidReservations500Response(value: object): value is ExpireUnpaidReservations500Response {
34
- return true;
35
- }
36
-
37
- export function ExpireUnpaidReservations500ResponseFromJSON(json: any): ExpireUnpaidReservations500Response {
38
- return ExpireUnpaidReservations500ResponseFromJSONTyped(json, false);
39
- }
40
-
41
- export function ExpireUnpaidReservations500ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExpireUnpaidReservations500Response {
42
- if (json == null) {
43
- return json;
44
- }
45
- return {
46
-
47
- 'error': json['error'] == null ? undefined : json['error'],
48
- };
49
- }
50
-
51
- export function ExpireUnpaidReservations500ResponseToJSON(json: any): ExpireUnpaidReservations500Response {
52
- return ExpireUnpaidReservations500ResponseToJSONTyped(json, false);
53
- }
54
-
55
- export function ExpireUnpaidReservations500ResponseToJSONTyped(value?: ExpireUnpaidReservations500Response | null, ignoreDiscriminator: boolean = false): any {
56
- if (value == null) {
57
- return value;
58
- }
59
-
60
- return {
61
-
62
- 'error': value['error'],
63
- };
64
- }
65
-