@globalscoutme/api-client 1.0.6 → 1.0.9
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/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/sdk.gen.d.ts +8 -2
- package/dist/sdk.gen.js +19 -1
- package/dist/types.gen.d.ts +224 -242
- package/index.ts +15 -0
- package/package.json +1 -1
- package/sdk.gen.ts +43 -2
- package/types.gen.ts +246 -242
package/index.ts
CHANGED
|
@@ -11,15 +11,18 @@ export {
|
|
|
11
11
|
Organizations,
|
|
12
12
|
Players,
|
|
13
13
|
Profile,
|
|
14
|
+
Storage,
|
|
14
15
|
Videos,
|
|
15
16
|
} from './sdk.gen.js';
|
|
16
17
|
export type {
|
|
17
18
|
AchievementCatalogDto,
|
|
19
|
+
AuthMeResponseDto,
|
|
18
20
|
BodyMeasurementResponseDto,
|
|
19
21
|
CareerAchievementDto,
|
|
20
22
|
ClientOptions,
|
|
21
23
|
CreateBodyMeasurementDto,
|
|
22
24
|
CreateDocumentDto,
|
|
25
|
+
CreateUploadUrlDto,
|
|
23
26
|
CreateVideoDto,
|
|
24
27
|
DashboardResponseDto,
|
|
25
28
|
DeletePlayersMeData,
|
|
@@ -39,6 +42,8 @@ export type {
|
|
|
39
42
|
GetAchievementsResponse,
|
|
40
43
|
GetAchievementsResponses,
|
|
41
44
|
GetAuthMeData,
|
|
45
|
+
GetAuthMeErrors,
|
|
46
|
+
GetAuthMeResponse,
|
|
42
47
|
GetAuthMeResponses,
|
|
43
48
|
GetBodyMeasurementsMeData,
|
|
44
49
|
GetBodyMeasurementsMeErrors,
|
|
@@ -68,6 +73,10 @@ export type {
|
|
|
68
73
|
GetProfileMeErrors,
|
|
69
74
|
GetProfileMeResponse,
|
|
70
75
|
GetProfileMeResponses,
|
|
76
|
+
GetVideosByIdPlayUrlData,
|
|
77
|
+
GetVideosByIdPlayUrlErrors,
|
|
78
|
+
GetVideosByIdPlayUrlResponse,
|
|
79
|
+
GetVideosByIdPlayUrlResponses,
|
|
71
80
|
GetVideosMeData,
|
|
72
81
|
GetVideosMeErrors,
|
|
73
82
|
GetVideosMeResponse,
|
|
@@ -79,6 +88,7 @@ export type {
|
|
|
79
88
|
PatchPlayersMeResponse,
|
|
80
89
|
PatchPlayersMeResponses,
|
|
81
90
|
PlayerResponseDto,
|
|
91
|
+
PlayUrlResponseDto,
|
|
82
92
|
PostBodyMeasurementsData,
|
|
83
93
|
PostBodyMeasurementsErrors,
|
|
84
94
|
PostBodyMeasurementsResponse,
|
|
@@ -91,6 +101,10 @@ export type {
|
|
|
91
101
|
PostOrganizationsRegisterClubErrors,
|
|
92
102
|
PostOrganizationsRegisterClubResponse,
|
|
93
103
|
PostOrganizationsRegisterClubResponses,
|
|
104
|
+
PostStorageUploadUrlData,
|
|
105
|
+
PostStorageUploadUrlErrors,
|
|
106
|
+
PostStorageUploadUrlResponse,
|
|
107
|
+
PostStorageUploadUrlResponses,
|
|
94
108
|
PostVideosData,
|
|
95
109
|
PostVideosErrors,
|
|
96
110
|
PostVideosResponse,
|
|
@@ -110,6 +124,7 @@ export type {
|
|
|
110
124
|
UpdateOrganizationDto,
|
|
111
125
|
UpdatePlayerDto,
|
|
112
126
|
UpdateProfileDto,
|
|
127
|
+
UploadUrlResponseDto,
|
|
113
128
|
UserAchievementResponseDto,
|
|
114
129
|
VideoResponseDto,
|
|
115
130
|
} from './types.gen.js';
|
package/package.json
CHANGED
package/sdk.gen.ts
CHANGED
|
@@ -19,6 +19,7 @@ import type {
|
|
|
19
19
|
GetAchievementsMeResponses,
|
|
20
20
|
GetAchievementsResponses,
|
|
21
21
|
GetAuthMeData,
|
|
22
|
+
GetAuthMeErrors,
|
|
22
23
|
GetAuthMeResponses,
|
|
23
24
|
GetBodyMeasurementsMeData,
|
|
24
25
|
GetBodyMeasurementsMeErrors,
|
|
@@ -41,6 +42,9 @@ import type {
|
|
|
41
42
|
GetProfileMeData,
|
|
42
43
|
GetProfileMeErrors,
|
|
43
44
|
GetProfileMeResponses,
|
|
45
|
+
GetVideosByIdPlayUrlData,
|
|
46
|
+
GetVideosByIdPlayUrlErrors,
|
|
47
|
+
GetVideosByIdPlayUrlResponses,
|
|
44
48
|
GetVideosMeData,
|
|
45
49
|
GetVideosMeErrors,
|
|
46
50
|
GetVideosMeResponses,
|
|
@@ -56,6 +60,9 @@ import type {
|
|
|
56
60
|
PostOrganizationsRegisterClubData,
|
|
57
61
|
PostOrganizationsRegisterClubErrors,
|
|
58
62
|
PostOrganizationsRegisterClubResponses,
|
|
63
|
+
PostStorageUploadUrlData,
|
|
64
|
+
PostStorageUploadUrlErrors,
|
|
65
|
+
PostStorageUploadUrlResponses,
|
|
59
66
|
PostVideosData,
|
|
60
67
|
PostVideosErrors,
|
|
61
68
|
PostVideosResponses,
|
|
@@ -113,12 +120,12 @@ class HeyApiRegistry<T> {
|
|
|
113
120
|
}
|
|
114
121
|
|
|
115
122
|
export class Auth extends HeyApiClient {
|
|
116
|
-
public
|
|
123
|
+
public getAuthMe<ThrowOnError extends boolean = false>(
|
|
117
124
|
options?: Options<GetAuthMeData, ThrowOnError>,
|
|
118
125
|
) {
|
|
119
126
|
return (options?.client ?? this.client).get<
|
|
120
127
|
GetAuthMeResponses,
|
|
121
|
-
|
|
128
|
+
GetAuthMeErrors,
|
|
122
129
|
ThrowOnError
|
|
123
130
|
>({ url: '/auth/me', ...options });
|
|
124
131
|
}
|
|
@@ -340,6 +347,25 @@ export class Organizations extends HeyApiClient {
|
|
|
340
347
|
}
|
|
341
348
|
}
|
|
342
349
|
|
|
350
|
+
export class Storage extends HeyApiClient {
|
|
351
|
+
public createUploadUrl<ThrowOnError extends boolean = false>(
|
|
352
|
+
options: Options<PostStorageUploadUrlData, ThrowOnError>,
|
|
353
|
+
) {
|
|
354
|
+
return (options.client ?? this.client).post<
|
|
355
|
+
PostStorageUploadUrlResponses,
|
|
356
|
+
PostStorageUploadUrlErrors,
|
|
357
|
+
ThrowOnError
|
|
358
|
+
>({
|
|
359
|
+
url: '/storage/upload-url',
|
|
360
|
+
...options,
|
|
361
|
+
headers: {
|
|
362
|
+
'Content-Type': 'application/json',
|
|
363
|
+
...options.headers,
|
|
364
|
+
},
|
|
365
|
+
});
|
|
366
|
+
}
|
|
367
|
+
}
|
|
368
|
+
|
|
343
369
|
export class Videos extends HeyApiClient {
|
|
344
370
|
public getMyVideos<ThrowOnError extends boolean = false>(
|
|
345
371
|
options: Options<GetVideosMeData, ThrowOnError>,
|
|
@@ -368,6 +394,16 @@ export class Videos extends HeyApiClient {
|
|
|
368
394
|
});
|
|
369
395
|
}
|
|
370
396
|
|
|
397
|
+
public getVideoPlayUrl<ThrowOnError extends boolean = false>(
|
|
398
|
+
options: Options<GetVideosByIdPlayUrlData, ThrowOnError>,
|
|
399
|
+
) {
|
|
400
|
+
return (options.client ?? this.client).get<
|
|
401
|
+
GetVideosByIdPlayUrlResponses,
|
|
402
|
+
GetVideosByIdPlayUrlErrors,
|
|
403
|
+
ThrowOnError
|
|
404
|
+
>({ url: '/videos/{id}/play-url', ...options });
|
|
405
|
+
}
|
|
406
|
+
|
|
371
407
|
public deleteVideo<ThrowOnError extends boolean = false>(
|
|
372
408
|
options: Options<DeleteVideosByIdData, ThrowOnError>,
|
|
373
409
|
) {
|
|
@@ -427,6 +463,11 @@ export class GlobalScoutMeClient extends HeyApiClient {
|
|
|
427
463
|
return (this._organizations ??= new Organizations({ client: this.client }));
|
|
428
464
|
}
|
|
429
465
|
|
|
466
|
+
private _storage?: Storage;
|
|
467
|
+
get storage(): Storage {
|
|
468
|
+
return (this._storage ??= new Storage({ client: this.client }));
|
|
469
|
+
}
|
|
470
|
+
|
|
430
471
|
private _videos?: Videos;
|
|
431
472
|
get videos(): Videos {
|
|
432
473
|
return (this._videos ??= new Videos({ client: this.client }));
|