@globalscoutme/api-client 1.0.10 → 1.0.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/types.gen.ts CHANGED
@@ -150,6 +150,228 @@ export type UpdatePlayerDto = {
150
150
  bio?: string;
151
151
  };
152
152
 
153
+ export type PlayerSearchRequestDto = {
154
+ /**
155
+ * Search by first or last name
156
+ */
157
+ search?: string;
158
+ /**
159
+ * Page number (1-based)
160
+ */
161
+ page?: number;
162
+ /**
163
+ * Items per page
164
+ */
165
+ pageSize?: number;
166
+ /**
167
+ * Sort order
168
+ */
169
+ sortBy?:
170
+ | 'relevance'
171
+ | 'age_asc'
172
+ | 'age_desc'
173
+ | 'gsi_score_asc'
174
+ | 'gsi_score_desc'
175
+ | 'nationality_asc'
176
+ | 'nationality_desc';
177
+ /**
178
+ * Minimum age (inclusive)
179
+ */
180
+ ageMin?: number;
181
+ /**
182
+ * Maximum age (inclusive)
183
+ */
184
+ ageMax?: number;
185
+ /**
186
+ * Nationality codes (ISO 2-letter)
187
+ */
188
+ nationalities?: Array<string>;
189
+ /**
190
+ * Position codes (multi-select)
191
+ */
192
+ positions?: Array<string>;
193
+ /**
194
+ * Base foot
195
+ */
196
+ baseFoot?: 'left' | 'right';
197
+ /**
198
+ * Preferred formation names (multi-select)
199
+ */
200
+ preferredFormations?: Array<string>;
201
+ /**
202
+ * Height operator — must be paired with heightCm
203
+ */
204
+ heightOperator?: 'gt' | 'lt' | 'gte' | 'lte';
205
+ /**
206
+ * Height value in cm — must be paired with heightOperator
207
+ */
208
+ heightCm?: number;
209
+ /**
210
+ * Only free agents
211
+ */
212
+ isFreeAgent?: boolean;
213
+ /**
214
+ * Only EU visa holders
215
+ */
216
+ isEuVisaHolder?: boolean;
217
+ /**
218
+ * Only players with at least one video
219
+ */
220
+ hasVideo?: boolean;
221
+ /**
222
+ * Only players on the caller watchlist
223
+ */
224
+ onlyWatchlist?: boolean;
225
+ };
226
+
227
+ export type PlayerSearchItemDto = {
228
+ id: string;
229
+ firstName?: string | null;
230
+ lastName?: string | null;
231
+ avatarUrl?: string | null;
232
+ /**
233
+ * Age computed from date_of_birth
234
+ */
235
+ age?: number | null;
236
+ /**
237
+ * ISO 2-letter nationality code
238
+ */
239
+ nationality?: string | null;
240
+ isFreeAgent: boolean;
241
+ isEuVisaHolder: boolean;
242
+ /**
243
+ * Height in cm
244
+ */
245
+ heightCm?: number | null;
246
+ /**
247
+ * Preferred foot code
248
+ */
249
+ baseFoot?: string | null;
250
+ /**
251
+ * Primary position code
252
+ */
253
+ primaryPosition?: string | null;
254
+ /**
255
+ * Additional position codes
256
+ */
257
+ additionalPositions: Array<string>;
258
+ /**
259
+ * Preferred formation name
260
+ */
261
+ preferredFormation?: string | null;
262
+ /**
263
+ * Has at least one non-deleted video
264
+ */
265
+ hasVideo: boolean;
266
+ };
267
+
268
+ export type PlayerSearchResultDto = {
269
+ items: Array<PlayerSearchItemDto>;
270
+ /**
271
+ * Total matching records
272
+ */
273
+ total: number;
274
+ page: number;
275
+ pageSize: number;
276
+ };
277
+
278
+ export type PlayerClubDto = {
279
+ clubName: string;
280
+ /**
281
+ * Year joined
282
+ */
283
+ joinedYear?: number | null;
284
+ /**
285
+ * Year left
286
+ */
287
+ leftYear?: number | null;
288
+ };
289
+
290
+ export type PlayerAchievementDto = {
291
+ id: string;
292
+ title: string;
293
+ /**
294
+ * Year of achievement
295
+ */
296
+ year?: number | null;
297
+ /**
298
+ * Recurrence label (e.g. "Annual")
299
+ */
300
+ recurrence?: string | null;
301
+ };
302
+
303
+ export type PlayerVideoDto = {
304
+ id: string;
305
+ title: string;
306
+ videoUrl: string;
307
+ thumbnailUrl?: string | null;
308
+ /**
309
+ * Duration in seconds
310
+ */
311
+ durationSeconds?: number | null;
312
+ /**
313
+ * Video type code
314
+ */
315
+ videoType?: string | null;
316
+ };
317
+
318
+ export type WatchingOrgDto = {
319
+ name: string;
320
+ logoUrl?: string | null;
321
+ };
322
+
323
+ export type PlayerByIdDto = {
324
+ id: string;
325
+ firstName?: string | null;
326
+ lastName?: string | null;
327
+ avatarUrl?: string | null;
328
+ age?: number | null;
329
+ /**
330
+ * Date of birth
331
+ */
332
+ dateOfBirth?: string | null;
333
+ bio?: string | null;
334
+ /**
335
+ * ISO 2-letter nationality code
336
+ */
337
+ nationality?: string | null;
338
+ isFreeAgent: boolean;
339
+ isEuVisaHolder: boolean;
340
+ visaExpirationDate?: string | null;
341
+ /**
342
+ * Marital status label
343
+ */
344
+ maritalStatus?: string | null;
345
+ heightCm?: number | null;
346
+ weightKg?: number | null;
347
+ baseFoot?: string | null;
348
+ /**
349
+ * Primary position code
350
+ */
351
+ primaryPosition?: string | null;
352
+ additionalPositions: Array<string>;
353
+ preferredFormation?: string | null;
354
+ /**
355
+ * Spoken language names
356
+ */
357
+ languages: Array<string>;
358
+ /**
359
+ * Current club name
360
+ */
361
+ currentClub?: string | null;
362
+ previousClubs: Array<PlayerClubDto>;
363
+ achievements: Array<PlayerAchievementDto>;
364
+ videos: Array<PlayerVideoDto>;
365
+ /**
366
+ * Clubs watching this player
367
+ */
368
+ clubsWatching: Array<WatchingOrgDto>;
369
+ /**
370
+ * Scout agencies watching this player
371
+ */
372
+ agentsWatching: Array<WatchingOrgDto>;
373
+ };
374
+
153
375
  export type PreviousClubDto = {
154
376
  /**
155
377
  * Club name
@@ -185,6 +407,10 @@ export type ProfileResponseDto = {
185
407
  * Internal user_data id
186
408
  */
187
409
  id: string;
410
+ /**
411
+ * Email address
412
+ */
413
+ email?: string | null;
188
414
  /**
189
415
  * First name
190
416
  */
@@ -520,6 +746,115 @@ export type IndexItemDto = {
520
746
  displayOrder: number | null;
521
747
  };
522
748
 
749
+ export type ConversationParticipantDto = {
750
+ /**
751
+ * user_data id
752
+ */
753
+ id: string;
754
+ firstName?: string | null;
755
+ lastName?: string | null;
756
+ avatarUrl?: string | null;
757
+ /**
758
+ * Age computed from date_of_birth
759
+ */
760
+ age?: number | null;
761
+ /**
762
+ * Primary position code
763
+ */
764
+ primaryPosition?: string | null;
765
+ };
766
+
767
+ export type ConversationItemDto = {
768
+ /**
769
+ * Conversation UUID
770
+ */
771
+ id: string;
772
+ participant: ConversationParticipantDto;
773
+ /**
774
+ * Last message text
775
+ */
776
+ lastMessage?: string | null;
777
+ /**
778
+ * Unread message count for the current user
779
+ */
780
+ unreadCount: number;
781
+ /**
782
+ * Conversation status code
783
+ */
784
+ status: string;
785
+ createdAt: string;
786
+ updatedAt: string;
787
+ };
788
+
789
+ export type ConversationListResultDto = {
790
+ items: Array<ConversationItemDto>;
791
+ /**
792
+ * Total matching records
793
+ */
794
+ total: number;
795
+ page: number;
796
+ pageSize: number;
797
+ };
798
+
799
+ export type CreateConversationDto = {
800
+ /**
801
+ * Player user_data id to send offer to
802
+ */
803
+ playerId: string;
804
+ /**
805
+ * Opening message text
806
+ */
807
+ initialMessage?: string;
808
+ };
809
+
810
+ export type ConversationDetailDto = {
811
+ id: string;
812
+ playerId: string;
813
+ scouterId: string;
814
+ lastMessage?: string | null;
815
+ unreadCount: number;
816
+ status: string;
817
+ createdAt: string;
818
+ updatedAt: string;
819
+ };
820
+
821
+ export type MessageSenderDto = {
822
+ id: string;
823
+ firstName?: string | null;
824
+ lastName?: string | null;
825
+ avatarUrl?: string | null;
826
+ };
827
+
828
+ export type MessageItemDto = {
829
+ id: string;
830
+ conversationId: string;
831
+ sender: MessageSenderDto;
832
+ /**
833
+ * true when this message belongs to the caller
834
+ */
835
+ isOwn: boolean;
836
+ body: string;
837
+ sentAt: string;
838
+ readAt?: string | null;
839
+ };
840
+
841
+ export type MessageListResultDto = {
842
+ items: Array<MessageItemDto>;
843
+ /**
844
+ * Total matching records
845
+ */
846
+ total: number;
847
+ page: number;
848
+ pageSize: number;
849
+ };
850
+
851
+ export type SendMessageDto = {
852
+ /**
853
+ * Message body text
854
+ */
855
+ body: string;
856
+ };
857
+
523
858
  export type RegisterClubDto = {
524
859
  /**
525
860
  * Club name
@@ -575,6 +910,10 @@ export type OrganizationResponseDto = {
575
910
  * Club name
576
911
  */
577
912
  name: string;
913
+ /**
914
+ * Club crest / logo URL
915
+ */
916
+ logoUrl?: string | null;
578
917
  /**
579
918
  * Slug
580
919
  */
@@ -622,6 +961,10 @@ export type UpdateOrganizationDto = {
622
961
  * Club name
623
962
  */
624
963
  name?: string;
964
+ /**
965
+ * Club crest / logo URL, null to clear
966
+ */
967
+ logoUrl?: string | null;
625
968
  /**
626
969
  * Country code (2-letter ISO)
627
970
  */
@@ -860,6 +1203,58 @@ export type GetPlayersMeDashboardResponses = {
860
1203
  export type GetPlayersMeDashboardResponse =
861
1204
  GetPlayersMeDashboardResponses[keyof GetPlayersMeDashboardResponses];
862
1205
 
1206
+ export type PostPlayersSearchData = {
1207
+ body: PlayerSearchRequestDto;
1208
+ path?: never;
1209
+ query?: never;
1210
+ url: '/players/search';
1211
+ };
1212
+
1213
+ export type PostPlayersSearchErrors = {
1214
+ /**
1215
+ * Invalid filter combination
1216
+ */
1217
+ 400: unknown;
1218
+ /**
1219
+ * Unauthorized
1220
+ */
1221
+ 401: unknown;
1222
+ };
1223
+
1224
+ export type PostPlayersSearchResponses = {
1225
+ 200: PlayerSearchResultDto;
1226
+ };
1227
+
1228
+ export type PostPlayersSearchResponse =
1229
+ PostPlayersSearchResponses[keyof PostPlayersSearchResponses];
1230
+
1231
+ export type GetPlayersByIdData = {
1232
+ body?: never;
1233
+ path: {
1234
+ id: string;
1235
+ };
1236
+ query?: never;
1237
+ url: '/players/{id}';
1238
+ };
1239
+
1240
+ export type GetPlayersByIdErrors = {
1241
+ /**
1242
+ * Unauthorized
1243
+ */
1244
+ 401: unknown;
1245
+ /**
1246
+ * Player not found
1247
+ */
1248
+ 404: unknown;
1249
+ };
1250
+
1251
+ export type GetPlayersByIdResponses = {
1252
+ 200: PlayerByIdDto;
1253
+ };
1254
+
1255
+ export type GetPlayersByIdResponse =
1256
+ GetPlayersByIdResponses[keyof GetPlayersByIdResponses];
1257
+
863
1258
  export type GetProfileMeData = {
864
1259
  body?: never;
865
1260
  path?: never;
@@ -1077,6 +1472,145 @@ export type GetIndexByTableNameResponses = {
1077
1472
  export type GetIndexByTableNameResponse =
1078
1473
  GetIndexByTableNameResponses[keyof GetIndexByTableNameResponses];
1079
1474
 
1475
+ export type GetOffersConversationsData = {
1476
+ body?: never;
1477
+ path?: never;
1478
+ query?: {
1479
+ filter?: 'all' | 'unread' | 'read';
1480
+ page?: number;
1481
+ pageSize?: number;
1482
+ };
1483
+ url: '/offers/conversations';
1484
+ };
1485
+
1486
+ export type GetOffersConversationsErrors = {
1487
+ /**
1488
+ * Unauthorized
1489
+ */
1490
+ 401: unknown;
1491
+ };
1492
+
1493
+ export type GetOffersConversationsResponses = {
1494
+ 200: ConversationListResultDto;
1495
+ };
1496
+
1497
+ export type GetOffersConversationsResponse =
1498
+ GetOffersConversationsResponses[keyof GetOffersConversationsResponses];
1499
+
1500
+ export type PostOffersConversationsData = {
1501
+ body: CreateConversationDto;
1502
+ path?: never;
1503
+ query?: never;
1504
+ url: '/offers/conversations';
1505
+ };
1506
+
1507
+ export type PostOffersConversationsErrors = {
1508
+ /**
1509
+ * Unauthorized
1510
+ */
1511
+ 401: unknown;
1512
+ };
1513
+
1514
+ export type PostOffersConversationsResponses = {
1515
+ 201: ConversationDetailDto;
1516
+ };
1517
+
1518
+ export type PostOffersConversationsResponse =
1519
+ PostOffersConversationsResponses[keyof PostOffersConversationsResponses];
1520
+
1521
+ export type GetOffersConversationsByIdMessagesData = {
1522
+ body?: never;
1523
+ path: {
1524
+ id: string;
1525
+ };
1526
+ query?: {
1527
+ page?: number;
1528
+ pageSize?: number;
1529
+ };
1530
+ url: '/offers/conversations/{id}/messages';
1531
+ };
1532
+
1533
+ export type GetOffersConversationsByIdMessagesErrors = {
1534
+ /**
1535
+ * Unauthorized
1536
+ */
1537
+ 401: unknown;
1538
+ /**
1539
+ * Not a participant
1540
+ */
1541
+ 403: unknown;
1542
+ /**
1543
+ * Conversation not found
1544
+ */
1545
+ 404: unknown;
1546
+ };
1547
+
1548
+ export type GetOffersConversationsByIdMessagesResponses = {
1549
+ 200: MessageListResultDto;
1550
+ };
1551
+
1552
+ export type GetOffersConversationsByIdMessagesResponse =
1553
+ GetOffersConversationsByIdMessagesResponses[keyof GetOffersConversationsByIdMessagesResponses];
1554
+
1555
+ export type PostOffersConversationsByIdMessagesData = {
1556
+ body: SendMessageDto;
1557
+ path: {
1558
+ id: string;
1559
+ };
1560
+ query?: never;
1561
+ url: '/offers/conversations/{id}/messages';
1562
+ };
1563
+
1564
+ export type PostOffersConversationsByIdMessagesErrors = {
1565
+ /**
1566
+ * Unauthorized
1567
+ */
1568
+ 401: unknown;
1569
+ /**
1570
+ * Not a participant
1571
+ */
1572
+ 403: unknown;
1573
+ /**
1574
+ * Conversation not found
1575
+ */
1576
+ 404: unknown;
1577
+ };
1578
+
1579
+ export type PostOffersConversationsByIdMessagesResponses = {
1580
+ 201: MessageItemDto;
1581
+ };
1582
+
1583
+ export type PostOffersConversationsByIdMessagesResponse =
1584
+ PostOffersConversationsByIdMessagesResponses[keyof PostOffersConversationsByIdMessagesResponses];
1585
+
1586
+ export type PatchOffersConversationsByIdReadData = {
1587
+ body?: never;
1588
+ path: {
1589
+ id: string;
1590
+ };
1591
+ query?: never;
1592
+ url: '/offers/conversations/{id}/read';
1593
+ };
1594
+
1595
+ export type PatchOffersConversationsByIdReadErrors = {
1596
+ /**
1597
+ * Unauthorized
1598
+ */
1599
+ 401: unknown;
1600
+ /**
1601
+ * Not a participant
1602
+ */
1603
+ 403: unknown;
1604
+ /**
1605
+ * Conversation not found
1606
+ */
1607
+ 404: unknown;
1608
+ };
1609
+
1610
+ export type PatchOffersConversationsByIdReadResponses = {
1611
+ 200: unknown;
1612
+ };
1613
+
1080
1614
  export type PostOrganizationsRegisterClubData = {
1081
1615
  body: RegisterClubDto;
1082
1616
  path?: never;