@vertikalx/vtx-backend-client 3.0.0-dev.9 → 3.0.1-dev-max.0

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 (111) hide show
  1. package/package.json +16 -3
  2. package/src/api/api-call-headers.ts +35 -0
  3. package/src/api/backend-response.ts +14 -0
  4. package/src/api/domains.ts +6 -0
  5. package/src/api/response-builder.ts +165 -0
  6. package/src/api/types.ts +9 -0
  7. package/src/api/vtx-apikey-api.ts +23 -0
  8. package/src/api/vtx-base-api.ts +2253 -0
  9. package/src/api/vtx-mobile-api.ts +43 -0
  10. package/src/api/vtx-web-browser-api.ts +46 -0
  11. package/src/api/vtx-web-server-api.ts +41 -0
  12. package/src/client/index.ts +65 -0
  13. package/src/client/runtime/batcher.ts +275 -0
  14. package/src/client/runtime/createClient.ts +68 -0
  15. package/src/client/runtime/error.ts +29 -0
  16. package/src/client/runtime/fetcher.ts +97 -0
  17. package/src/client/runtime/generateGraphqlOperation.ts +225 -0
  18. package/src/client/runtime/index.ts +13 -0
  19. package/src/client/runtime/linkTypeMap.ts +156 -0
  20. package/src/client/runtime/typeSelection.ts +95 -0
  21. package/src/client/runtime/types.ts +69 -0
  22. package/src/client/schema.graphql +4256 -0
  23. package/src/client/schema.ts +8329 -0
  24. package/src/client/{types.js → types.ts} +6012 -2232
  25. package/src/generated/graphql.ts +12445 -0
  26. package/src/{index.d.ts → index.ts} +7 -2
  27. package/src/operations/admin.graphql +19 -0
  28. package/src/operations/ai-coach.graphql +117 -0
  29. package/src/operations/athlete.graphql +1764 -0
  30. package/src/operations/auth.graphql +301 -0
  31. package/src/operations/campaign.graphql +775 -0
  32. package/src/operations/email-campaign.graphql +160 -0
  33. package/src/operations/followers.graphql +45 -0
  34. package/src/operations/integrations.graphql +216 -0
  35. package/src/operations/leaderboard.graphql +54 -0
  36. package/src/operations/media.graphql +179 -0
  37. package/src/operations/notifications.graphql +93 -0
  38. package/src/operations/offers.graphql +368 -0
  39. package/src/operations/onboarding.graphql +29 -0
  40. package/src/operations/sponsor.graphql +368 -0
  41. package/src/operations/sport.graphql +132 -0
  42. package/src/operations/user.graphql +446 -0
  43. package/tsconfig.lib.json +10 -0
  44. package/src/api/api-call-headers.d.ts +0 -12
  45. package/src/api/api-call-headers.js +0 -16
  46. package/src/api/api-call-headers.js.map +0 -1
  47. package/src/api/backend-response.d.ts +0 -10
  48. package/src/api/backend-response.js +0 -3
  49. package/src/api/backend-response.js.map +0 -1
  50. package/src/api/domains.d.ts +0 -4
  51. package/src/api/domains.js +0 -8
  52. package/src/api/domains.js.map +0 -1
  53. package/src/api/response-builder.d.ts +0 -4
  54. package/src/api/response-builder.js +0 -123
  55. package/src/api/response-builder.js.map +0 -1
  56. package/src/api/types.d.ts +0 -2
  57. package/src/api/types.js +0 -3
  58. package/src/api/types.js.map +0 -1
  59. package/src/api/vtx-apikey-api.d.ts +0 -6
  60. package/src/api/vtx-apikey-api.js +0 -19
  61. package/src/api/vtx-apikey-api.js.map +0 -1
  62. package/src/api/vtx-base-api.d.ts +0 -134
  63. package/src/api/vtx-base-api.js +0 -8586
  64. package/src/api/vtx-base-api.js.map +0 -1
  65. package/src/api/vtx-mobile-api.d.ts +0 -9
  66. package/src/api/vtx-mobile-api.js +0 -62
  67. package/src/api/vtx-mobile-api.js.map +0 -1
  68. package/src/api/vtx-web-browser-api.d.ts +0 -7
  69. package/src/api/vtx-web-browser-api.js +0 -36
  70. package/src/api/vtx-web-browser-api.js.map +0 -1
  71. package/src/api/vtx-web-server-api.d.ts +0 -7
  72. package/src/api/vtx-web-server-api.js +0 -33
  73. package/src/api/vtx-web-server-api.js.map +0 -1
  74. package/src/client/index.d.ts +0 -25
  75. package/src/client/index.js +0 -44
  76. package/src/client/index.js.map +0 -1
  77. package/src/client/runtime/batcher.d.ts +0 -36
  78. package/src/client/runtime/batcher.js +0 -123
  79. package/src/client/runtime/batcher.js.map +0 -1
  80. package/src/client/runtime/createClient.d.ts +0 -17
  81. package/src/client/runtime/createClient.js +0 -28
  82. package/src/client/runtime/createClient.js.map +0 -1
  83. package/src/client/runtime/error.d.ts +0 -15
  84. package/src/client/runtime/error.js +0 -19
  85. package/src/client/runtime/error.js.map +0 -1
  86. package/src/client/runtime/fetcher.d.ts +0 -10
  87. package/src/client/runtime/fetcher.js +0 -68
  88. package/src/client/runtime/fetcher.js.map +0 -1
  89. package/src/client/runtime/generateGraphqlOperation.d.ts +0 -30
  90. package/src/client/runtime/generateGraphqlOperation.js +0 -134
  91. package/src/client/runtime/generateGraphqlOperation.js.map +0 -1
  92. package/src/client/runtime/index.d.ts +0 -11
  93. package/src/client/runtime/index.js +0 -17
  94. package/src/client/runtime/index.js.map +0 -1
  95. package/src/client/runtime/linkTypeMap.d.ts +0 -9
  96. package/src/client/runtime/linkTypeMap.js +0 -95
  97. package/src/client/runtime/linkTypeMap.js.map +0 -1
  98. package/src/client/runtime/typeSelection.d.ts +0 -28
  99. package/src/client/runtime/typeSelection.js +0 -3
  100. package/src/client/runtime/typeSelection.js.map +0 -1
  101. package/src/client/runtime/types.d.ts +0 -55
  102. package/src/client/runtime/types.js +0 -3
  103. package/src/client/runtime/types.js.map +0 -1
  104. package/src/client/schema.d.ts +0 -4890
  105. package/src/client/schema.js +0 -1051
  106. package/src/client/schema.js.map +0 -1
  107. package/src/client/types.d.ts +0 -2603
  108. package/src/client/types.js.map +0 -1
  109. package/src/index.js +0 -28
  110. package/src/index.js.map +0 -1
  111. package/tsconfig.lib.tsbuildinfo +0 -1
@@ -0,0 +1,1764 @@
1
+ # Athlete profile, query, scores, competitions, memberships, budgets, sports events, and dashboard operations
2
+ # Extracted from vtx-base-api.ts
3
+
4
+ # ============================================================
5
+ # FRAGMENTS - Reusable field selections
6
+ # ============================================================
7
+
8
+ fragment FileFields on AWSS3File {
9
+ _id
10
+ name
11
+ contentType
12
+ size
13
+ useType
14
+ url
15
+ key
16
+ }
17
+
18
+ fragment CityFields on City {
19
+ _id
20
+ name
21
+ localizedName
22
+ state {
23
+ _id
24
+ name
25
+ country {
26
+ _id
27
+ name
28
+ }
29
+ }
30
+ latitude
31
+ longitude
32
+ timezone
33
+ }
34
+
35
+ fragment LocationFields on WorldLocation {
36
+ userProvidedLatitude
37
+ userProvidedLongitude
38
+ cityNameGeocode
39
+ stateNameGeocode
40
+ countryIso2CodeGeocode
41
+ timeZoneGeocode
42
+ latitudeGeocode
43
+ longitudeGeocode
44
+ city {
45
+ ...CityFields
46
+ }
47
+ }
48
+
49
+ fragment RankingFields on AthleteRankings {
50
+ worldRanking {
51
+ scope
52
+ scopeId
53
+ scopeName
54
+ position
55
+ total
56
+ }
57
+ countryRanking {
58
+ scope
59
+ scopeId
60
+ scopeName
61
+ position
62
+ total
63
+ }
64
+ stateRanking {
65
+ scope
66
+ scopeId
67
+ scopeName
68
+ position
69
+ total
70
+ }
71
+ cityRanking {
72
+ scope
73
+ scopeId
74
+ scopeName
75
+ position
76
+ total
77
+ }
78
+ }
79
+
80
+ fragment CompetitionEventFields on SportsEvent {
81
+ _id
82
+ name
83
+ mainSport {
84
+ _id
85
+ name
86
+ }
87
+ eventWebSite
88
+ startDate
89
+ endDate
90
+ verified
91
+ banner {
92
+ ...FileFields
93
+ }
94
+ location {
95
+ _id
96
+ ...LocationFields
97
+ }
98
+ }
99
+
100
+ fragment StandardAthleteFields on Athlete {
101
+ _id
102
+ firstName
103
+ lastName
104
+ screenName
105
+ dob
106
+ lgbt
107
+ competitionGender
108
+ country {
109
+ _id
110
+ name
111
+ }
112
+ location {
113
+ ...LocationFields
114
+ }
115
+ trainer
116
+ trainerUrl
117
+ aboutMe
118
+ followStats {
119
+ followers
120
+ followed
121
+ raves
122
+ favorites
123
+ }
124
+ mainSport {
125
+ _id
126
+ name
127
+ }
128
+ mainSportLevel {
129
+ _id
130
+ label
131
+ index
132
+ }
133
+ scores {
134
+ vtxScore
135
+ socialScore
136
+ trainingScore
137
+ competitionScore
138
+ }
139
+ rankings {
140
+ ...RankingFields
141
+ }
142
+ allSports {
143
+ _id
144
+ name
145
+ }
146
+ teams {
147
+ _id
148
+ name
149
+ description
150
+ approved
151
+ logo {
152
+ ...FileFields
153
+ }
154
+ banner {
155
+ ...FileFields
156
+ }
157
+ }
158
+ sponsorBrands {
159
+ _id
160
+ name
161
+ slogan
162
+ website
163
+ description
164
+ approved
165
+ published
166
+ logo {
167
+ ...FileFields
168
+ }
169
+ stats {
170
+ campaigns
171
+ sponsorships
172
+ sports
173
+ athletes
174
+ }
175
+ operatorIds
176
+ }
177
+ competitions {
178
+ _id
179
+ event {
180
+ ...CompetitionEventFields
181
+ }
182
+ participationDate
183
+ result {
184
+ _id
185
+ resultType
186
+ position
187
+ score
188
+ finishTimeMS
189
+ resultWebLink
190
+ }
191
+ }
192
+ totalUpcomingCompetitions
193
+ totalPastCompetitions
194
+ profilePicture {
195
+ ...FileFields
196
+ }
197
+ cardPicture {
198
+ ...FileFields
199
+ }
200
+ preferences {
201
+ _id
202
+ showProfileHelper
203
+ }
204
+ }
205
+
206
+ fragment CampaignLocationFields on WorldLocation {
207
+ _id
208
+ userProvidedLatitude
209
+ userProvidedLongitude
210
+ cityNameGeocode
211
+ stateNameGeocode
212
+ countryIso2CodeGeocode
213
+ timeZoneGeocode
214
+ latitudeGeocode
215
+ longitudeGeocode
216
+ city {
217
+ ...CityFields
218
+ }
219
+ }
220
+
221
+ fragment CurrentCampaignFields on FundRaisingCampaign {
222
+ _id
223
+ slug
224
+ budgetMode
225
+ status
226
+ title
227
+ motivation
228
+ website
229
+ fundsRequired
230
+ initialFundsObtained
231
+ fundsObtained
232
+ vtxComissionPct
233
+ video {
234
+ _id
235
+ source
236
+ url
237
+ sourceData
238
+ }
239
+ coverImage {
240
+ ...FileFields
241
+ }
242
+ location {
243
+ ...CampaignLocationFields
244
+ }
245
+ endingDate
246
+ budget {
247
+ _id
248
+ initialFunds
249
+ totalRequired
250
+ items {
251
+ _id
252
+ quantity
253
+ concept
254
+ itemCost
255
+ unit
256
+ }
257
+ }
258
+ competitions {
259
+ _id
260
+ event {
261
+ _id
262
+ name
263
+ mainSport {
264
+ _id
265
+ name
266
+ }
267
+ eventWebSite
268
+ startDate
269
+ endDate
270
+ verified
271
+ banner {
272
+ ...FileFields
273
+ }
274
+ location {
275
+ _id
276
+ ...LocationFields
277
+ }
278
+ }
279
+ budget {
280
+ _id
281
+ initialFunds
282
+ totalRequired
283
+ items {
284
+ _id
285
+ quantity
286
+ concept
287
+ itemCost
288
+ unit
289
+ }
290
+ }
291
+ participationDate
292
+ result {
293
+ _id
294
+ resultType
295
+ position
296
+ score
297
+ finishTimeMS
298
+ resultWebLink
299
+ }
300
+ }
301
+ }
302
+
303
+ fragment HistoricalScoreFields on HistoricalScore {
304
+ _id
305
+ scoreType
306
+ score
307
+ date
308
+ athleteId
309
+ }
310
+
311
+ fragment HistoricalScoresPeriodFields on HistoricalScoresPeriod {
312
+ athleteId
313
+ athleteFirstName
314
+ athleteLastName
315
+ screenName
316
+ minTimestampInclusive
317
+ maxTimestampExclusive
318
+ vtxScores {
319
+ ...HistoricalScoreFields
320
+ }
321
+ tpiScores {
322
+ ...HistoricalScoreFields
323
+ }
324
+ spiScores {
325
+ ...HistoricalScoreFields
326
+ }
327
+ apiScores {
328
+ ...HistoricalScoreFields
329
+ }
330
+ }
331
+
332
+ # ============================================================
333
+ # PROFILE & REGISTRATION
334
+ # ============================================================
335
+
336
+ mutation RegisterAthlete($input: RegisterAthleteDto!) {
337
+ registerAthlete(input: $input) {
338
+ ...StandardAthleteFields
339
+ }
340
+ }
341
+
342
+ query FindAthleteForUser($loginEmail: String!) {
343
+ findAthleteForUser(loginEmail: $loginEmail) {
344
+ ...StandardAthleteFields
345
+ biography
346
+ onboardingComplete
347
+ onboardingStep
348
+ affiliations {
349
+ _id
350
+ organization {
351
+ _id
352
+ shortName
353
+ acronym
354
+ fullName
355
+ website
356
+ logo {
357
+ ...FileFields
358
+ }
359
+ }
360
+ membershipNumber
361
+ membershipType
362
+ issueDate
363
+ expirationDate
364
+ }
365
+ bannerPicture {
366
+ ...FileFields
367
+ }
368
+ preferences {
369
+ _id
370
+ showProfileHelper
371
+ defaultAlbum {
372
+ _id
373
+ label
374
+ description
375
+ }
376
+ }
377
+ currentCampaign {
378
+ ...CurrentCampaignFields
379
+ }
380
+ stripeAccountReference {
381
+ _id
382
+ stripeAccountId
383
+ account {
384
+ id
385
+ object
386
+ business_type
387
+ country
388
+ email
389
+ capabilities {
390
+ acss_debit_payments
391
+ affirm_payments
392
+ afterpay_clearpay_payments
393
+ alma_payments
394
+ amazon_pay_payments
395
+ au_becs_debit_payments
396
+ bacs_debit_payments
397
+ bancontact_payments
398
+ bank_transfer_payments
399
+ blik_payments
400
+ boleto_payments
401
+ card_issuing
402
+ card_payments
403
+ cartes_bancaires_payments
404
+ cashapp_payments
405
+ eps_payments
406
+ fpx_payments
407
+ gb_bank_transfer_payments
408
+ giropay_payments
409
+ grabpay_payments
410
+ ideal_payments
411
+ india_international_payments
412
+ jcb_payments
413
+ jp_bank_transfer_payments
414
+ kakao_pay_payments
415
+ klarna_payments
416
+ konbini_payments
417
+ kr_card_payments
418
+ legacy_payments
419
+ link_payments
420
+ mobilepay_payments
421
+ multibanco_payments
422
+ mx_bank_transfer_payments
423
+ naver_pay_payments
424
+ oxxo_payments
425
+ p24_payments
426
+ pay_by_bank_payments
427
+ payco_payments
428
+ paynow_payments
429
+ promptpay_payments
430
+ revolut_pay_payments
431
+ samsung_pay_payments
432
+ sepa_bank_transfer_payments
433
+ sepa_debit_payments
434
+ sofort_payments
435
+ swish_payments
436
+ tax_reporting_us_1099_k
437
+ tax_reporting_us_1099_misc
438
+ transfers
439
+ treasury
440
+ twint_payments
441
+ us_bank_account_ach_payments
442
+ us_bank_transfer_payments
443
+ zip_payments
444
+ }
445
+ requirements {
446
+ alternatives {
447
+ alternative_fields_due
448
+ original_fields_due
449
+ }
450
+ current_deadline
451
+ currently_due
452
+ disabled_reason
453
+ errors {
454
+ code
455
+ reason
456
+ requirement
457
+ }
458
+ eventually_due
459
+ past_due
460
+ pending_verification
461
+ }
462
+ future_requirements {
463
+ alternatives {
464
+ alternative_fields_due
465
+ original_fields_due
466
+ }
467
+ current_deadline
468
+ currently_due
469
+ disabled_reason
470
+ errors {
471
+ code
472
+ reason
473
+ requirement
474
+ }
475
+ eventually_due
476
+ past_due
477
+ pending_verification
478
+ }
479
+ type
480
+ charges_enabled
481
+ payouts_enabled
482
+ created
483
+ default_currency
484
+ }
485
+ }
486
+ }
487
+ }
488
+
489
+ query FindAthleteForIdPublic($athleteId: String!) {
490
+ findAthletebyIdpublic(athleteId: $athleteId) {
491
+ ...StandardAthleteFields
492
+ suspended
493
+ biography
494
+ affiliations {
495
+ _id
496
+ organization {
497
+ _id
498
+ shortName
499
+ acronym
500
+ fullName
501
+ website
502
+ logo {
503
+ ...FileFields
504
+ }
505
+ }
506
+ membershipNumber
507
+ membershipType
508
+ issueDate
509
+ expirationDate
510
+ }
511
+ bannerPicture {
512
+ ...FileFields
513
+ }
514
+ competitions {
515
+ _id
516
+ event {
517
+ _id
518
+ name
519
+ mainSport {
520
+ _id
521
+ name
522
+ }
523
+ eventWebSite
524
+ startDate
525
+ endDate
526
+ verified
527
+ location {
528
+ _id
529
+ ...LocationFields
530
+ }
531
+ banner {
532
+ ...FileFields
533
+ }
534
+ }
535
+ participationDate
536
+ result {
537
+ _id
538
+ resultType
539
+ position
540
+ score
541
+ finishTimeMS
542
+ resultWebLink
543
+ totalParticipants
544
+ outcome
545
+ genderPosition
546
+ genderParticipants
547
+ categoryPosition
548
+ categoryParticipants
549
+ categoryName
550
+ }
551
+ }
552
+ preferences {
553
+ _id
554
+ showProfileHelper
555
+ defaultAlbum {
556
+ _id
557
+ label
558
+ description
559
+ photos {
560
+ _id
561
+ photo {
562
+ ...FileFields
563
+ }
564
+ }
565
+ }
566
+ }
567
+ currentCampaign {
568
+ _id
569
+ slug
570
+ budgetMode
571
+ status
572
+ title
573
+ motivation
574
+ website
575
+ fundsRequired
576
+ initialFundsObtained
577
+ fundsObtained
578
+ vtxComissionPct
579
+ video {
580
+ _id
581
+ source
582
+ url
583
+ sourceData
584
+ }
585
+ coverImage {
586
+ ...FileFields
587
+ }
588
+ location {
589
+ ...CampaignLocationFields
590
+ }
591
+ endingDate
592
+ budget {
593
+ _id
594
+ initialFunds
595
+ totalRequired
596
+ items {
597
+ _id
598
+ quantity
599
+ concept
600
+ itemCost
601
+ unit
602
+ }
603
+ }
604
+ competitions {
605
+ _id
606
+ event {
607
+ _id
608
+ name
609
+ mainSport {
610
+ _id
611
+ name
612
+ }
613
+ eventWebSite
614
+ startDate
615
+ endDate
616
+ verified
617
+ banner {
618
+ ...FileFields
619
+ }
620
+ location {
621
+ _id
622
+ ...LocationFields
623
+ }
624
+ }
625
+ participationDate
626
+ result {
627
+ _id
628
+ resultType
629
+ position
630
+ score
631
+ finishTimeMS
632
+ resultWebLink
633
+ totalParticipants
634
+ }
635
+ budget {
636
+ _id
637
+ initialFunds
638
+ totalRequired
639
+ items {
640
+ _id
641
+ quantity
642
+ concept
643
+ itemCost
644
+ unit
645
+ }
646
+ }
647
+ }
648
+ }
649
+ }
650
+ }
651
+
652
+ query GetAthletes {
653
+ getAthletes {
654
+ ...StandardAthleteFields
655
+ }
656
+ }
657
+
658
+ query SearchAthletes($searchString: String!) {
659
+ searchAthletes(searchString: $searchString) {
660
+ ...StandardAthleteFields
661
+ }
662
+ }
663
+
664
+ query GetRecommendedAthletes($loginEmail: String!) {
665
+ getRecommendedAthletes(loginEmail: $loginEmail) {
666
+ ...StandardAthleteFields
667
+ }
668
+ }
669
+
670
+ query GetSponsorAthletesForTenant {
671
+ getSponsorAthletesForTenant {
672
+ ...StandardAthleteFields
673
+ }
674
+ }
675
+
676
+ query QueryAthleteFundingCampaigns($input: AthleteQueryDto!) {
677
+ queryAthleteFundingCampaigns(input: $input) {
678
+ athletes {
679
+ _id
680
+ firstName
681
+ lastName
682
+ screenName
683
+ dob
684
+ lgbt
685
+ competitionGender
686
+ country {
687
+ _id
688
+ }
689
+ location {
690
+ city {
691
+ name
692
+ state {
693
+ name
694
+ country {
695
+ _id
696
+ }
697
+ }
698
+ }
699
+ }
700
+ aboutMe
701
+ mainSport {
702
+ name
703
+ }
704
+ mainSportLevel {
705
+ label
706
+ }
707
+ scores {
708
+ vtxScore
709
+ }
710
+ profilePicture {
711
+ url
712
+ }
713
+ currentCampaign {
714
+ _id
715
+ slug
716
+ budgetMode
717
+ status
718
+ title
719
+ motivation
720
+ fundsRequired
721
+ initialFundsObtained
722
+ fundsObtained
723
+ vtxComissionPct
724
+ video {
725
+ _id
726
+ source
727
+ url
728
+ sourceData
729
+ }
730
+ coverImage {
731
+ ...FileFields
732
+ }
733
+ endingDate
734
+ competitions {
735
+ _id
736
+ event {
737
+ _id
738
+ name
739
+ mainSport {
740
+ _id
741
+ name
742
+ }
743
+ eventWebSite
744
+ startDate
745
+ endDate
746
+ verified
747
+ banner {
748
+ ...FileFields
749
+ }
750
+ location {
751
+ _id
752
+ ...LocationFields
753
+ }
754
+ }
755
+ participationDate
756
+ result {
757
+ _id
758
+ resultType
759
+ position
760
+ score
761
+ finishTimeMS
762
+ resultWebLink
763
+ }
764
+ }
765
+ }
766
+ }
767
+ cursor {
768
+ sort {
769
+ sortField
770
+ order
771
+ }
772
+ initialCursorId
773
+ nextCursorId
774
+ initialCursorValue
775
+ nextCursorValue
776
+ limit
777
+ retrieved
778
+ isLastPage
779
+ }
780
+ }
781
+ }
782
+
783
+ query QueryAthletesWithFilters($input: AthleteQueryDto!) {
784
+ queryAthleteWithFilter(input: $input) {
785
+ athletes {
786
+ _id
787
+ firstName
788
+ lastName
789
+ screenName
790
+ dob
791
+ competitionGender
792
+ country {
793
+ _id
794
+ }
795
+ location {
796
+ _id
797
+ city {
798
+ _id
799
+ name
800
+ state {
801
+ name
802
+ country {
803
+ _id
804
+ }
805
+ }
806
+ }
807
+ }
808
+ aboutMe
809
+ mainSport {
810
+ _id
811
+ name
812
+ }
813
+ mainSportLevel {
814
+ _id
815
+ label
816
+ }
817
+ scores {
818
+ vtxScore
819
+ socialScore
820
+ trainingScore
821
+ competitionScore
822
+ }
823
+ competitions {
824
+ _id
825
+ event {
826
+ _id
827
+ name
828
+ }
829
+ participationDate
830
+ }
831
+ profilePicture {
832
+ url
833
+ }
834
+ currentCampaign {
835
+ _id
836
+ slug
837
+ budgetMode
838
+ status
839
+ title
840
+ motivation
841
+ website
842
+ fundsRequired
843
+ initialFundsObtained
844
+ fundsObtained
845
+ vtxComissionPct
846
+ video {
847
+ _id
848
+ source
849
+ url
850
+ sourceData
851
+ }
852
+ coverImage {
853
+ ...FileFields
854
+ }
855
+ endingDate
856
+ competitions {
857
+ _id
858
+ event {
859
+ _id
860
+ name
861
+ mainSport {
862
+ _id
863
+ name
864
+ }
865
+ eventWebSite
866
+ startDate
867
+ endDate
868
+ verified
869
+ banner {
870
+ ...FileFields
871
+ }
872
+ location {
873
+ _id
874
+ ...LocationFields
875
+ }
876
+ }
877
+ participationDate
878
+ result {
879
+ _id
880
+ resultType
881
+ position
882
+ score
883
+ finishTimeMS
884
+ resultWebLink
885
+ }
886
+ budget {
887
+ _id
888
+ initialFunds
889
+ totalRequired
890
+ items {
891
+ _id
892
+ quantity
893
+ concept
894
+ itemCost
895
+ unit
896
+ }
897
+ }
898
+ }
899
+ }
900
+ }
901
+ cursor {
902
+ sort {
903
+ sortField
904
+ order
905
+ }
906
+ initialCursorId
907
+ nextCursorId
908
+ initialCursorValue
909
+ nextCursorValue
910
+ limit
911
+ retrieved
912
+ isLastPage
913
+ }
914
+ }
915
+ }
916
+
917
+ # ============================================================
918
+ # PROFILE EDITING
919
+ # ============================================================
920
+
921
+ mutation EditAboutMe($input: EditValueDto!) {
922
+ editProfileValue(input: $input) {
923
+ field
924
+ oldValue
925
+ newValue
926
+ changed
927
+ }
928
+ }
929
+
930
+ mutation EditProfileValue($input: EditValueDto!) {
931
+ editProfileValue(input: $input) {
932
+ field
933
+ oldValue
934
+ newValue
935
+ changed
936
+ }
937
+ }
938
+
939
+ mutation EditPicture($input: EditPictureDto!) {
940
+ editPicture(input: $input) {
941
+ field
942
+ oldValue {
943
+ ...FileFields
944
+ }
945
+ newValue {
946
+ ...FileFields
947
+ }
948
+ changed
949
+ }
950
+ }
951
+
952
+ # ============================================================
953
+ # COMPETITIONS & MEMBERSHIPS
954
+ # ============================================================
955
+
956
+ mutation AddAthleteCompetition($input: CreateAthleteCompetitionDto!) {
957
+ addAthleteCompetition(input: $input) {
958
+ _id
959
+ event {
960
+ _id
961
+ name
962
+ mainSport {
963
+ _id
964
+ name
965
+ }
966
+ eventWebSite
967
+ startDate
968
+ endDate
969
+ verified
970
+ banner {
971
+ ...FileFields
972
+ }
973
+ location {
974
+ _id
975
+ ...LocationFields
976
+ }
977
+ }
978
+ participationDate
979
+ competitionNumber
980
+ result {
981
+ resultType
982
+ position
983
+ score
984
+ finishTimeMS
985
+ resultWebLink
986
+ }
987
+ fundRaisingCampaignIds
988
+ }
989
+ }
990
+
991
+ query GetAthleteCompetitions($input: GetAthleteCompetitionsDto!) {
992
+ getAthleteCompetitions(input: $input) {
993
+ _id
994
+ event {
995
+ _id
996
+ name
997
+ mainSport {
998
+ _id
999
+ name
1000
+ resultType
1001
+ }
1002
+ eventWebSite
1003
+ startDate
1004
+ endDate
1005
+ verified
1006
+ banner {
1007
+ ...FileFields
1008
+ }
1009
+ location {
1010
+ _id
1011
+ ...LocationFields
1012
+ }
1013
+ }
1014
+ participationDate
1015
+ competitionNumber
1016
+ result {
1017
+ resultType
1018
+ position
1019
+ score
1020
+ finishTimeMS
1021
+ resultWebLink
1022
+ outcome
1023
+ totalParticipants
1024
+ adversary
1025
+ genderPosition
1026
+ genderParticipants
1027
+ categoryPosition
1028
+ categoryParticipants
1029
+ categoryName
1030
+ }
1031
+ fundRaisingCampaignIds
1032
+ budget {
1033
+ _id
1034
+ totalRequired
1035
+ initialFunds
1036
+ items {
1037
+ _id
1038
+ quantity
1039
+ concept
1040
+ itemCost
1041
+ unit
1042
+ }
1043
+ }
1044
+ }
1045
+ }
1046
+
1047
+ query GetAthleteMemberships($athleteId: String!) {
1048
+ getAthleteMemberships(athleteId: $athleteId) {
1049
+ _id
1050
+ organization {
1051
+ _id
1052
+ shortName
1053
+ acronym
1054
+ fullName
1055
+ website
1056
+ verified
1057
+ logo {
1058
+ ...FileFields
1059
+ }
1060
+ country {
1061
+ _id
1062
+ name
1063
+ }
1064
+ sport {
1065
+ _id
1066
+ name
1067
+ }
1068
+ }
1069
+ athlete {
1070
+ _id
1071
+ firstName
1072
+ lastName
1073
+ screenName
1074
+ dob
1075
+ lgbt
1076
+ competitionGender
1077
+ country {
1078
+ _id
1079
+ name
1080
+ }
1081
+ location {
1082
+ ...LocationFields
1083
+ }
1084
+ trainer
1085
+ trainerUrl
1086
+ aboutMe
1087
+ followStats {
1088
+ followers
1089
+ followed
1090
+ raves
1091
+ favorites
1092
+ }
1093
+ mainSport {
1094
+ _id
1095
+ name
1096
+ }
1097
+ mainSportLevel {
1098
+ _id
1099
+ label
1100
+ index
1101
+ }
1102
+ scores {
1103
+ vtxScore
1104
+ socialScore
1105
+ trainingScore
1106
+ competitionScore
1107
+ }
1108
+ rankings {
1109
+ ...RankingFields
1110
+ }
1111
+ totalUpcomingCompetitions
1112
+ totalPastCompetitions
1113
+ profilePicture {
1114
+ ...FileFields
1115
+ }
1116
+ cardPicture {
1117
+ ...FileFields
1118
+ }
1119
+ }
1120
+ membershipNumber
1121
+ membershipType
1122
+ issueDate
1123
+ expirationDate
1124
+ }
1125
+ }
1126
+
1127
+ mutation DeleteAthleteCompetition($input: DeleteSingleValueDto!) {
1128
+ deleteAthleteCompetition(input: $input) {
1129
+ idToDelete
1130
+ deleted
1131
+ failureReason {
1132
+ code
1133
+ message
1134
+ }
1135
+ }
1136
+ }
1137
+
1138
+ query VerifyAthleteCompetitionLinkedForDelete($input: existValueDto!) {
1139
+ verifyAthleteCompetitionLinkedForDelete(input: $input) {
1140
+ reasons {
1141
+ code
1142
+ message
1143
+ details
1144
+ }
1145
+ }
1146
+ }
1147
+
1148
+ mutation ForceDeleteAthleteCompetition($input: DeleteSingleValueDto!) {
1149
+ forceDeleteAthleteCompetition(input: $input) {
1150
+ idToDelete
1151
+ deleted
1152
+ failureReason {
1153
+ code
1154
+ message
1155
+ }
1156
+ }
1157
+ }
1158
+
1159
+ mutation SaveAthleteCompetitionResult($input: SetCompetitionResultDto!) {
1160
+ saveAthleteCompetitionResult(input: $input) {
1161
+ _id
1162
+ resultType
1163
+ position
1164
+ score
1165
+ finishTimeMS
1166
+ resultWebLink
1167
+ totalParticipants
1168
+ outcome
1169
+ adversary
1170
+ genderPosition
1171
+ genderParticipants
1172
+ categoryPosition
1173
+ categoryParticipants
1174
+ categoryName
1175
+ }
1176
+ }
1177
+
1178
+ mutation CreateMembershipOrganization($input: CreateMembershipOrganizationDto!) {
1179
+ createMembershipOrganization(input: $input) {
1180
+ _id
1181
+ }
1182
+ }
1183
+
1184
+ query GetMembershipOrganizations {
1185
+ getMembershipOrganizations {
1186
+ _id
1187
+ shortName
1188
+ acronym
1189
+ fullName
1190
+ website
1191
+ verified
1192
+ logo {
1193
+ ...FileFields
1194
+ }
1195
+ country {
1196
+ _id
1197
+ name
1198
+ }
1199
+ sport {
1200
+ _id
1201
+ name
1202
+ }
1203
+ }
1204
+ }
1205
+
1206
+ mutation CreateAthleteMembershipAffilation($input: CreateAthleteMembershipDto!) {
1207
+ createAthleteMembershipAffilation(input: $input) {
1208
+ _id
1209
+ }
1210
+ }
1211
+
1212
+ mutation DeleteMembershipAffiliation($input: DeleteSingleValueDto!) {
1213
+ deleteAthleteMembershipAffilation(input: $input) {
1214
+ idToDelete
1215
+ deleted
1216
+ failureReason {
1217
+ code
1218
+ message
1219
+ }
1220
+ }
1221
+ }
1222
+
1223
+ # ============================================================
1224
+ # SCORES & DASHBOARD
1225
+ # ============================================================
1226
+
1227
+ mutation UpdateAthleteScores {
1228
+ updateAthleteScores {
1229
+ _id
1230
+ firstName
1231
+ lastName
1232
+ scores {
1233
+ vtxScore
1234
+ socialScore
1235
+ trainingScore
1236
+ competitionScore
1237
+ }
1238
+ }
1239
+ }
1240
+
1241
+ mutation UpdateAthleteCompetitionScores {
1242
+ updateAthleteCompetitionScores {
1243
+ _id
1244
+ firstName
1245
+ lastName
1246
+ scores {
1247
+ vtxScore
1248
+ socialScore
1249
+ trainingScore
1250
+ competitionScore
1251
+ }
1252
+ }
1253
+ }
1254
+
1255
+ mutation ForceRefreshAthleteScores($input: ForceScoreRefreshDto!) {
1256
+ forceRefreshAthleteScores(input: $input) {
1257
+ results {
1258
+ athleteId
1259
+ athleteName
1260
+ status
1261
+ message
1262
+ tpi {
1263
+ status
1264
+ message
1265
+ }
1266
+ spi {
1267
+ status
1268
+ message
1269
+ }
1270
+ api {
1271
+ status
1272
+ message
1273
+ }
1274
+ diagnostics {
1275
+ activitiesDeleted
1276
+ activitiesFetched
1277
+ activitiesDateRange
1278
+ activityRefsSaved
1279
+ historicalDatesProcessed
1280
+ historicalRebuildStatus
1281
+ }
1282
+ }
1283
+ successCount
1284
+ failureCount
1285
+ skippedCount
1286
+ }
1287
+ }
1288
+
1289
+ query CheckScoreRefreshCapabilities($input: CheckScoreRefreshCapabilityDto!) {
1290
+ checkScoreRefreshCapabilities(input: $input) {
1291
+ capabilities {
1292
+ athleteId
1293
+ athleteName
1294
+ canRefreshTpi
1295
+ canRefreshSpi
1296
+ canRefreshApi
1297
+ tpiReason
1298
+ spiReason
1299
+ apiReason
1300
+ }
1301
+ }
1302
+ }
1303
+
1304
+ query GetAthleteHistoricalScores($input: GetHistoricalScoresDto!) {
1305
+ getAthleteHistoricalScores(input: $input) {
1306
+ ...HistoricalScoreFields
1307
+ }
1308
+ }
1309
+
1310
+ query GetMyHistoricalScores($input: GetMyHistoricalScoresDto!) {
1311
+ getMyHistoricalScores(input: $input) {
1312
+ ...HistoricalScoreFields
1313
+ }
1314
+ }
1315
+
1316
+ query GetAthleteHistoricalScoresPeriod($input: GetHistoricalScoresDto!) {
1317
+ getAthleteHistoricalScoresPeriod(input: $input) {
1318
+ ...HistoricalScoresPeriodFields
1319
+ }
1320
+ }
1321
+
1322
+ query GetMyHistoricalScoresPeriod($input: GetMyHistoricalScoresDto!) {
1323
+ getMyHistoricalScoresPeriod(input: $input) {
1324
+ ...HistoricalScoresPeriodFields
1325
+ }
1326
+ }
1327
+
1328
+ query GetAthleteDashboard($athleteId: String!) {
1329
+ athleteDashboard(athleteId: $athleteId) {
1330
+ vtxScore
1331
+ socialScore
1332
+ trainingScore
1333
+ competitionScore
1334
+ lastUpdated
1335
+ }
1336
+ }
1337
+
1338
+ query GetAthleteScoreHistory($input: ScoreHistoryQueryDto!) {
1339
+ athleteScoreHistory(input: $input) {
1340
+ date
1341
+ vtxScore
1342
+ socialScore
1343
+ trainingScore
1344
+ competitionScore
1345
+ }
1346
+ }
1347
+
1348
+ query GetAthleteRankHistory($input: RankHistoryQueryDto!) {
1349
+ athleteRankHistory(input: $input) {
1350
+ date
1351
+ globalRank
1352
+ countryRank
1353
+ }
1354
+ }
1355
+
1356
+ query GetAthleteRankContext($input: RankContextQueryDto!) {
1357
+ athleteRankContext(input: $input) {
1358
+ globalRank
1359
+ countryRank
1360
+ rankChange
1361
+ percentile
1362
+ gapToNext
1363
+ gapFromPrevious
1364
+ totalAthletes
1365
+ }
1366
+ }
1367
+
1368
+ query GetAthleteActivities($input: ActivitiesQueryDto!) {
1369
+ athleteActivities(input: $input) {
1370
+ items {
1371
+ id
1372
+ date
1373
+ type
1374
+ metrics
1375
+ pointsEarned
1376
+ counted
1377
+ notCountedReason
1378
+ prMetrics
1379
+ }
1380
+ total
1381
+ hasMore
1382
+ }
1383
+ }
1384
+
1385
+ query GetAthleteActivityDetail($input: ActivityDetailQueryDto!) {
1386
+ athleteActivityDetail(input: $input) {
1387
+ id
1388
+ date
1389
+ type
1390
+ category
1391
+ metrics {
1392
+ name
1393
+ value
1394
+ unit
1395
+ athleteAverage
1396
+ athleteMax
1397
+ comparisonPercent
1398
+ }
1399
+ scoreInfo {
1400
+ earned
1401
+ maxPossible
1402
+ componentAverage
1403
+ }
1404
+ prMetrics
1405
+ }
1406
+ }
1407
+
1408
+ query GetAthleteComponentSummary($input: ComponentSummaryQueryDto!) {
1409
+ athleteComponentSummary(input: $input) {
1410
+ name
1411
+ score
1412
+ maxScore
1413
+ trend
1414
+ trendPeriod
1415
+ activityCount
1416
+ avgScorePerActivity
1417
+ topMetrics {
1418
+ name
1419
+ status
1420
+ }
1421
+ newMaxActivityIds
1422
+ metricMaxes
1423
+ }
1424
+ }
1425
+
1426
+ query GetAthleteActivityDates($input: ActivityDatesQueryDto!) {
1427
+ athleteActivityDates(input: $input) {
1428
+ dates {
1429
+ date
1430
+ category
1431
+ count
1432
+ types
1433
+ }
1434
+ }
1435
+ }
1436
+
1437
+ query GetSocialAggregates($athleteId: ID!, $platform: Platform!, $range: DateRangeInput!, $periodType: PeriodType) {
1438
+ socialAggregates(athleteId: $athleteId, platform: $platform, range: $range, periodType: $periodType) {
1439
+ _id
1440
+ athleteId
1441
+ platform
1442
+ contentType
1443
+ periodType
1444
+ periodLabel
1445
+ periodStart
1446
+ periodEnd
1447
+ totalLikes
1448
+ totalComments
1449
+ totalShares
1450
+ totalSaves
1451
+ totalReach
1452
+ totalViews
1453
+ totalImpressions
1454
+ postCount
1455
+ followerCount
1456
+ avgEngagementRate
1457
+ avgPostEngagement
1458
+ }
1459
+ }
1460
+
1461
+ query GetPostsWithComparison($athleteId: ID!, $platform: Platform!, $options: PostComparisonInput) {
1462
+ postsWithComparison(athleteId: $athleteId, platform: $platform, options: $options) {
1463
+ posts {
1464
+ id
1465
+ postId
1466
+ permalink
1467
+ thumbnailUrl
1468
+ contentType
1469
+ caption
1470
+ postedAt
1471
+ likes
1472
+ comments
1473
+ shares
1474
+ saves
1475
+ reach
1476
+ vsAvgPercent
1477
+ }
1478
+ averages {
1479
+ likes
1480
+ comments
1481
+ reach
1482
+ engagementRate
1483
+ }
1484
+ total
1485
+ hasMore
1486
+ }
1487
+ }
1488
+
1489
+ query GetPublicAthleteIntegrationStatus($athleteId: String!) {
1490
+ getPublicAthleteIntegrationStatus(athleteId: $athleteId) {
1491
+ hasStravaIntegration
1492
+ stravaAthleteId
1493
+ hasInstagramIntegration
1494
+ instagramUsername
1495
+ }
1496
+ }
1497
+
1498
+ # ============================================================
1499
+ # SPORTS EVENTS
1500
+ # ============================================================
1501
+
1502
+ query GetSportsEvents($input: GetSportEventsDto!) {
1503
+ getSportsEvents(input: $input) {
1504
+ _id
1505
+ name
1506
+ eventWebSite
1507
+ mainSport {
1508
+ _id
1509
+ name
1510
+ resultType
1511
+ }
1512
+ startDate
1513
+ endDate
1514
+ verified
1515
+ banner {
1516
+ ...FileFields
1517
+ }
1518
+ location {
1519
+ _id
1520
+ ...LocationFields
1521
+ }
1522
+ registeredAthletesCount
1523
+ }
1524
+ }
1525
+
1526
+ query GetSportsEventsPaginated($query: EventQueryDto) {
1527
+ getSportsEventsPaginated(query: $query) {
1528
+ items {
1529
+ _id
1530
+ name
1531
+ verified
1532
+ startDate
1533
+ endDate
1534
+ eventWebSite
1535
+ registeredAthletesCount
1536
+ mainSport {
1537
+ _id
1538
+ name
1539
+ }
1540
+ location {
1541
+ _id
1542
+ cityNameGeocode
1543
+ countryIso2CodeGeocode
1544
+ city {
1545
+ _id
1546
+ name
1547
+ state {
1548
+ _id
1549
+ name
1550
+ country {
1551
+ _id
1552
+ name
1553
+ }
1554
+ }
1555
+ }
1556
+ }
1557
+ banner {
1558
+ _id
1559
+ url
1560
+ useType
1561
+ }
1562
+ }
1563
+ pagination {
1564
+ currentPage
1565
+ totalPages
1566
+ totalItems
1567
+ itemsPerPage
1568
+ hasNextPage
1569
+ hasPreviousPage
1570
+ }
1571
+ }
1572
+ }
1573
+
1574
+ mutation CreateSportsEvent($input: CreateSportEventDto!) {
1575
+ createSportsEvent(input: $input) {
1576
+ _id
1577
+ name
1578
+ eventWebSite
1579
+ mainSport {
1580
+ _id
1581
+ name
1582
+ }
1583
+ startDate
1584
+ endDate
1585
+ verified
1586
+ banner {
1587
+ ...FileFields
1588
+ }
1589
+ location {
1590
+ _id
1591
+ ...LocationFields
1592
+ }
1593
+ }
1594
+ }
1595
+
1596
+ mutation UpdateSportsEvent($input: UpdateSportEventDto!) {
1597
+ updateSportsEvent(input: $input) {
1598
+ _id
1599
+ name
1600
+ mainSport {
1601
+ _id
1602
+ name
1603
+ resultType
1604
+ }
1605
+ eventWebSite
1606
+ startDate
1607
+ endDate
1608
+ verified
1609
+ banner {
1610
+ _id
1611
+ url
1612
+ useType
1613
+ }
1614
+ location {
1615
+ _id
1616
+ cityNameGeocode
1617
+ countryIso2CodeGeocode
1618
+ city {
1619
+ _id
1620
+ name
1621
+ state {
1622
+ _id
1623
+ name
1624
+ country {
1625
+ _id
1626
+ name
1627
+ }
1628
+ }
1629
+ }
1630
+ }
1631
+ }
1632
+ }
1633
+
1634
+ mutation DeleteSportsEvent($eventId: String!) {
1635
+ deleteSportsEvent(eventId: $eventId) {
1636
+ field
1637
+ changed
1638
+ oldValue
1639
+ newValue
1640
+ }
1641
+ }
1642
+
1643
+ mutation MergeSportsEvents($input: MergeSportsEventsDto!) {
1644
+ mergeSportsEvents(input: $input) {
1645
+ success
1646
+ mergedEvent {
1647
+ _id
1648
+ name
1649
+ mainSport {
1650
+ _id
1651
+ name
1652
+ resultType
1653
+ }
1654
+ eventWebSite
1655
+ startDate
1656
+ endDate
1657
+ verified
1658
+ banner {
1659
+ ...FileFields
1660
+ }
1661
+ location {
1662
+ _id
1663
+ ...LocationFields
1664
+ }
1665
+ }
1666
+ }
1667
+ }
1668
+
1669
+ # ============================================================
1670
+ # BUDGETS
1671
+ # ============================================================
1672
+
1673
+ query GetBudgetsByAthlete {
1674
+ getBudgetsByAthlete {
1675
+ competitions {
1676
+ id
1677
+ dateCreated
1678
+ type
1679
+ name
1680
+ eventDate
1681
+ budget
1682
+ campaign
1683
+ items {
1684
+ _id
1685
+ concept
1686
+ quantity
1687
+ itemCost
1688
+ totalCost
1689
+ unit
1690
+ }
1691
+ }
1692
+ campaigns {
1693
+ id
1694
+ dateCreated
1695
+ type
1696
+ name
1697
+ fundsRequired
1698
+ initialFundsObtained
1699
+ status
1700
+ budgetMode
1701
+ endingDate
1702
+ budget
1703
+ competitions
1704
+ items {
1705
+ _id
1706
+ concept
1707
+ quantity
1708
+ itemCost
1709
+ totalCost
1710
+ unit
1711
+ }
1712
+ competitionBudgets {
1713
+ competitionId
1714
+ eventName
1715
+ budget {
1716
+ _id
1717
+ items {
1718
+ _id
1719
+ concept
1720
+ quantity
1721
+ itemCost
1722
+ totalCost
1723
+ unit
1724
+ }
1725
+ totalAmount
1726
+ }
1727
+ }
1728
+ }
1729
+ }
1730
+ }
1731
+
1732
+ mutation DeleteCompetitionBudget($competitionId: String!) {
1733
+ deleteCompetitionBudget(competitionId: $competitionId)
1734
+ }
1735
+
1736
+ mutation AddCompetitionBudget($input: AddCompetitionBudgetDto!) {
1737
+ addCompetitionBudget(input: $input)
1738
+ }
1739
+
1740
+ mutation EditCompetitionBudget($input: EditCompetitionBudgetDto!) {
1741
+ editCompetitionBudget(input: $input)
1742
+ }
1743
+
1744
+ mutation EditCampaignBudget($input: EditCampaignBudgetDto!) {
1745
+ editCampaignBudget(input: $input)
1746
+ }
1747
+
1748
+ mutation EditCompetitionBudgetForCampaign($input: EditCampaignBudgetDto!) {
1749
+ editCompetitionBudgetForCampaign(input: $input)
1750
+ }
1751
+
1752
+ query GetBudgetConcepts {
1753
+ getBudgetConcepts {
1754
+ _id
1755
+ label
1756
+ }
1757
+ }
1758
+
1759
+ query GetBudgetItemsUnits {
1760
+ getBudgetItemUnits {
1761
+ _id
1762
+ label
1763
+ }
1764
+ }