@opexa/portal-sdk 0.0.97 → 0.0.99
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.js +99 -81
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +687 -615
- package/dist/index.mjs.map +1 -1
- package/dist/sdk/types.d.ts +3 -0
- package/dist/services/types.d.ts +6 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var c = (
|
|
1
|
+
var Le = Object.defineProperty;
|
|
2
|
+
var Ve = (i, e, t) => e in i ? Le(i, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[e] = t;
|
|
3
|
+
var c = (i, e, t) => Ve(i, typeof e != "symbol" ? e + "" : e, t);
|
|
4
4
|
import { ObjectId as O } from "@opexa/object-id";
|
|
5
|
-
import { ObjectId as
|
|
5
|
+
import { ObjectId as Aa } from "@opexa/object-id";
|
|
6
6
|
const $ = {
|
|
7
7
|
Account: 8,
|
|
8
8
|
Deposit: 9,
|
|
@@ -13,23 +13,23 @@ const $ = {
|
|
|
13
13
|
GameSession: 204,
|
|
14
14
|
MayaSession: 230
|
|
15
15
|
};
|
|
16
|
-
function i
|
|
16
|
+
function o(i, ...e) {
|
|
17
17
|
let t = "";
|
|
18
|
-
for (const [
|
|
19
|
-
const s = e.at(
|
|
20
|
-
t = `${t}${
|
|
18
|
+
for (const [a, r] of i.entries()) {
|
|
19
|
+
const s = e.at(a) ?? "";
|
|
20
|
+
t = `${t}${r}${s}`;
|
|
21
21
|
}
|
|
22
22
|
return t.trim();
|
|
23
23
|
}
|
|
24
|
-
const
|
|
24
|
+
const De = o`
|
|
25
25
|
fragment FileFragment on File {
|
|
26
26
|
id
|
|
27
27
|
url
|
|
28
28
|
status
|
|
29
29
|
dateTimeCreated
|
|
30
30
|
}
|
|
31
|
-
`,
|
|
32
|
-
${
|
|
31
|
+
`, He = o`
|
|
32
|
+
${De}
|
|
33
33
|
|
|
34
34
|
query File($id: ObjectId!) {
|
|
35
35
|
node(id: $id) {
|
|
@@ -38,7 +38,7 @@ const ue = i`
|
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
|
-
`,
|
|
41
|
+
`, Ye = o`
|
|
42
42
|
mutation UploadPrivateImageFile($input: UploadFileInput!) {
|
|
43
43
|
uploadPrivateImageFile(input: $input) {
|
|
44
44
|
... on FileFormatNotSupportedError {
|
|
@@ -52,7 +52,7 @@ const ue = i`
|
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
|
-
`,
|
|
55
|
+
`, Qe = o`
|
|
56
56
|
query Wallet {
|
|
57
57
|
wallet {
|
|
58
58
|
id
|
|
@@ -62,7 +62,7 @@ const ue = i`
|
|
|
62
62
|
dateTimeLastUpdated
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
|
-
`,
|
|
65
|
+
`, je = o`
|
|
66
66
|
query PointsWallet {
|
|
67
67
|
pointsWallet {
|
|
68
68
|
id
|
|
@@ -71,7 +71,7 @@ const ue = i`
|
|
|
71
71
|
dateTimeCreated
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
|
-
`,
|
|
74
|
+
`, Ke = o`
|
|
75
75
|
mutation RedeemPointsToCash($input: RedeemPointsToCashInput!) {
|
|
76
76
|
redeemPointsToCash(input: $input) {
|
|
77
77
|
... on InsufficientPointsError {
|
|
@@ -79,7 +79,7 @@ const ue = i`
|
|
|
79
79
|
}
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
|
-
`,
|
|
82
|
+
`, ze = o`
|
|
83
83
|
query PointsWalletTransactions(
|
|
84
84
|
$first: Int
|
|
85
85
|
$after: Cursor
|
|
@@ -107,8 +107,8 @@ const ue = i`
|
|
|
107
107
|
}
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
|
-
`,
|
|
111
|
-
current:
|
|
110
|
+
`, Oe = {
|
|
111
|
+
current: o`
|
|
112
112
|
query GameSession($id: ObjectId!) {
|
|
113
113
|
node(id: $id) {
|
|
114
114
|
... on GameSession {
|
|
@@ -122,7 +122,7 @@ const ue = i`
|
|
|
122
122
|
}
|
|
123
123
|
}
|
|
124
124
|
`,
|
|
125
|
-
legacy:
|
|
125
|
+
legacy: o`
|
|
126
126
|
query GameSession($id: ObjectId!) {
|
|
127
127
|
node(id: $id) {
|
|
128
128
|
... on GameSession {
|
|
@@ -138,7 +138,7 @@ const ue = i`
|
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
140
|
`
|
|
141
|
-
},
|
|
141
|
+
}, $e = o`
|
|
142
142
|
mutation CreateGameSession($input: CreateGameSessionInput!) {
|
|
143
143
|
createGameSession(input: $input) {
|
|
144
144
|
... on GameDoesNotExistError {
|
|
@@ -146,13 +146,13 @@ const ue = i`
|
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
|
-
`,
|
|
150
|
-
current:
|
|
149
|
+
`, Ue = {
|
|
150
|
+
current: o`
|
|
151
151
|
mutation EndGameSession($input: EndGameSessionInput!) {
|
|
152
152
|
endGameSession(input: $input)
|
|
153
153
|
}
|
|
154
154
|
`,
|
|
155
|
-
legacy:
|
|
155
|
+
legacy: o`
|
|
156
156
|
mutation EndGameSession($input: EndGameSessionInput!) {
|
|
157
157
|
endGameSession(input: $input) {
|
|
158
158
|
... on GameSessionDoesNotExistError {
|
|
@@ -167,7 +167,7 @@ const ue = i`
|
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
169
|
`
|
|
170
|
-
},
|
|
170
|
+
}, Je = o`
|
|
171
171
|
query Announcements($first: Int, $after: Cursor, $filter: AnnouncementFilterInput) {
|
|
172
172
|
announcements(first: $first, after: $after, filter: $filter) {
|
|
173
173
|
edges {
|
|
@@ -193,7 +193,7 @@ const ue = i`
|
|
|
193
193
|
}
|
|
194
194
|
}
|
|
195
195
|
}
|
|
196
|
-
`,
|
|
196
|
+
`, Xe = o`
|
|
197
197
|
query WithdrawalRecords($first: Int, $after: Cursor, $filter: WithdrawalRecordFilterInput) {
|
|
198
198
|
member {
|
|
199
199
|
withdrawalRecords(first: $first, after: $after, filter: $filter) {
|
|
@@ -260,7 +260,7 @@ const ue = i`
|
|
|
260
260
|
}
|
|
261
261
|
}
|
|
262
262
|
}
|
|
263
|
-
`,
|
|
263
|
+
`, Ze = o`
|
|
264
264
|
mutation CreateGCashWithdrawal($input: CreateGCashWithdrawalInput!) {
|
|
265
265
|
createGCashWithdrawal(input: $input) {
|
|
266
266
|
... on AccountNotVerifiedError {
|
|
@@ -283,7 +283,7 @@ const ue = i`
|
|
|
283
283
|
}
|
|
284
284
|
}
|
|
285
285
|
}
|
|
286
|
-
`,
|
|
286
|
+
`, et = o`
|
|
287
287
|
mutation CreateMayaWithdrawal($input: CreateMayaWithdrawalInput!) {
|
|
288
288
|
createMayaWithdrawal(input: $input) {
|
|
289
289
|
... on AccountNotVerifiedError {
|
|
@@ -306,7 +306,7 @@ const ue = i`
|
|
|
306
306
|
}
|
|
307
307
|
}
|
|
308
308
|
}
|
|
309
|
-
`,
|
|
309
|
+
`, tt = o`
|
|
310
310
|
mutation CreateMayaAppWithdrawal($input: CreateMayaAppWithdrawalInput!) {
|
|
311
311
|
createMayaAppWithdrawal(input: $input) {
|
|
312
312
|
... on AccountNotVerifiedError {
|
|
@@ -326,7 +326,7 @@ const ue = i`
|
|
|
326
326
|
}
|
|
327
327
|
}
|
|
328
328
|
}
|
|
329
|
-
`,
|
|
329
|
+
`, at = o`
|
|
330
330
|
mutation CreateBankWithdrawal($input: CreateBankWithdrawalInput!) {
|
|
331
331
|
createBankWithdrawal(input: $input) {
|
|
332
332
|
... on MobileNumberNotVerifiedError {
|
|
@@ -349,11 +349,11 @@ const ue = i`
|
|
|
349
349
|
}
|
|
350
350
|
}
|
|
351
351
|
}
|
|
352
|
-
`,
|
|
352
|
+
`, rt = o`
|
|
353
353
|
query RemainingDailyWithdrawalsCount {
|
|
354
354
|
remainingDailyWithdrawalsCount
|
|
355
355
|
}
|
|
356
|
-
`,
|
|
356
|
+
`, nt = o`
|
|
357
357
|
query DepositRecords($after: Cursor, $first: Int, $filter: DepositRecordFilterInput) {
|
|
358
358
|
member {
|
|
359
359
|
depositRecords(after: $after, first: $first, filter: $filter) {
|
|
@@ -382,7 +382,7 @@ const ue = i`
|
|
|
382
382
|
}
|
|
383
383
|
}
|
|
384
384
|
}
|
|
385
|
-
`,
|
|
385
|
+
`, it = o`
|
|
386
386
|
mutation CreateGCashDeposit($input: CreateGCashDepositInput!) {
|
|
387
387
|
createGCashDeposit(input: $input) {
|
|
388
388
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -411,7 +411,7 @@ const ue = i`
|
|
|
411
411
|
}
|
|
412
412
|
}
|
|
413
413
|
}
|
|
414
|
-
`,
|
|
414
|
+
`, ot = o`
|
|
415
415
|
mutation CreateMayaDeposit($input: CreateMayaDepositInput!) {
|
|
416
416
|
createMayaDeposit(input: $input) {
|
|
417
417
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -440,7 +440,7 @@ const ue = i`
|
|
|
440
440
|
}
|
|
441
441
|
}
|
|
442
442
|
}
|
|
443
|
-
`,
|
|
443
|
+
`, st = o`
|
|
444
444
|
mutation CreateMayaAppDeposit($input: CreateMayaAppDepositInput!) {
|
|
445
445
|
createMayaAppDeposit(input: $input) {
|
|
446
446
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -469,7 +469,7 @@ const ue = i`
|
|
|
469
469
|
}
|
|
470
470
|
}
|
|
471
471
|
}
|
|
472
|
-
`,
|
|
472
|
+
`, mt = o`
|
|
473
473
|
mutation CreateAIOQRPHDeposit($input: CreateAIOQRPHDepositInput!) {
|
|
474
474
|
createAIOQRPHDeposit(input: $input) {
|
|
475
475
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -498,7 +498,7 @@ const ue = i`
|
|
|
498
498
|
}
|
|
499
499
|
}
|
|
500
500
|
}
|
|
501
|
-
`,
|
|
501
|
+
`, ct = o`
|
|
502
502
|
mutation CreateAIOOnlineBankDeposit($input: CreateAIOOnlineBankDepositInput!) {
|
|
503
503
|
createAIOOnlineBankDeposit(input: $input) {
|
|
504
504
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -527,7 +527,7 @@ const ue = i`
|
|
|
527
527
|
}
|
|
528
528
|
}
|
|
529
529
|
}
|
|
530
|
-
`,
|
|
530
|
+
`, lt = o`
|
|
531
531
|
query Deposit($id: ObjectId!) {
|
|
532
532
|
node(id: $id) {
|
|
533
533
|
... on GCashDeposit {
|
|
@@ -571,13 +571,13 @@ const ue = i`
|
|
|
571
571
|
}
|
|
572
572
|
}
|
|
573
573
|
}
|
|
574
|
-
`,
|
|
574
|
+
`, ut = o`
|
|
575
575
|
query DepositsCount {
|
|
576
576
|
member {
|
|
577
577
|
depositsCount
|
|
578
578
|
}
|
|
579
579
|
}
|
|
580
|
-
`,
|
|
580
|
+
`, dt = o`
|
|
581
581
|
query BetRecords($first: Int, $after: Cursor, $filter: BetRecordFilterInput) {
|
|
582
582
|
member {
|
|
583
583
|
betRecords(first: $first, after: $after, filter: $filter) {
|
|
@@ -618,7 +618,7 @@ const ue = i`
|
|
|
618
618
|
}
|
|
619
619
|
}
|
|
620
620
|
}
|
|
621
|
-
`,
|
|
621
|
+
`, pt = o`
|
|
622
622
|
query LatestBetRecords {
|
|
623
623
|
latestBetRecords {
|
|
624
624
|
id
|
|
@@ -638,7 +638,7 @@ const ue = i`
|
|
|
638
638
|
dateTimeCreated
|
|
639
639
|
}
|
|
640
640
|
}
|
|
641
|
-
`,
|
|
641
|
+
`, ft = o`
|
|
642
642
|
query TransactionRecords($first: Int, $after: Cursor, $filter: TransactionRecordFilter) {
|
|
643
643
|
member {
|
|
644
644
|
transactionRecords(first: $first, after: $after, filter: $filter) {
|
|
@@ -664,8 +664,8 @@ const ue = i`
|
|
|
664
664
|
}
|
|
665
665
|
}
|
|
666
666
|
}
|
|
667
|
-
`,
|
|
668
|
-
${
|
|
667
|
+
`, Ie = o`
|
|
668
|
+
${De}
|
|
669
669
|
|
|
670
670
|
fragment PromoFragment on Promo {
|
|
671
671
|
id
|
|
@@ -683,24 +683,24 @@ const ue = i`
|
|
|
683
683
|
dateTimeCreated
|
|
684
684
|
dateTimeLastUpdated
|
|
685
685
|
}
|
|
686
|
-
`,
|
|
687
|
-
${
|
|
686
|
+
`, wt = o`
|
|
687
|
+
${Ie}
|
|
688
688
|
|
|
689
689
|
query Promos {
|
|
690
690
|
promos {
|
|
691
691
|
...PromoFragment
|
|
692
692
|
}
|
|
693
693
|
}
|
|
694
|
-
`,
|
|
695
|
-
${
|
|
694
|
+
`, yt = o`
|
|
695
|
+
${Ie}
|
|
696
696
|
|
|
697
697
|
query AvailablePromos($filter: PromoFilterInput) {
|
|
698
698
|
availablePromos(filter: $filter) {
|
|
699
699
|
...PromoFragment
|
|
700
700
|
}
|
|
701
701
|
}
|
|
702
|
-
`,
|
|
703
|
-
${
|
|
702
|
+
`, Be = o`
|
|
703
|
+
${De}
|
|
704
704
|
|
|
705
705
|
fragment CashbackFragment on Cashback {
|
|
706
706
|
id
|
|
@@ -718,16 +718,16 @@ const ue = i`
|
|
|
718
718
|
dateTimeCreated
|
|
719
719
|
dateTimeLastUpdated
|
|
720
720
|
}
|
|
721
|
-
`,
|
|
722
|
-
${
|
|
721
|
+
`, ht = o`
|
|
722
|
+
${Be}
|
|
723
723
|
|
|
724
724
|
query Cashbacks {
|
|
725
725
|
cashbacks {
|
|
726
726
|
...CashbackFragment
|
|
727
727
|
}
|
|
728
728
|
}
|
|
729
|
-
`,
|
|
730
|
-
${
|
|
729
|
+
`, gt = o`
|
|
730
|
+
${Ie}
|
|
731
731
|
|
|
732
732
|
query Bonus {
|
|
733
733
|
bonus {
|
|
@@ -755,8 +755,8 @@ const ue = i`
|
|
|
755
755
|
dateTimeLastUpdated
|
|
756
756
|
}
|
|
757
757
|
}
|
|
758
|
-
`,
|
|
759
|
-
${
|
|
758
|
+
`, bt = o`
|
|
759
|
+
${Be}
|
|
760
760
|
|
|
761
761
|
query CashbackBonuses {
|
|
762
762
|
cashbackBonuses {
|
|
@@ -770,7 +770,7 @@ const ue = i`
|
|
|
770
770
|
dateTimeLastUpdated
|
|
771
771
|
}
|
|
772
772
|
}
|
|
773
|
-
`,
|
|
773
|
+
`, Et = o`
|
|
774
774
|
mutation ClaimCashbackBonus($input: ClaimCashbackBonusInput!) {
|
|
775
775
|
claimCashbackBonus(input: $input) {
|
|
776
776
|
... on CashbackBonusDoesNotExistError {
|
|
@@ -779,14 +779,14 @@ const ue = i`
|
|
|
779
779
|
}
|
|
780
780
|
}
|
|
781
781
|
`;
|
|
782
|
-
|
|
782
|
+
o`
|
|
783
783
|
query Member {
|
|
784
784
|
member {
|
|
785
785
|
dateTimeLastActive
|
|
786
786
|
}
|
|
787
787
|
}
|
|
788
788
|
`;
|
|
789
|
-
const
|
|
789
|
+
const At = o`
|
|
790
790
|
query MemberAccount {
|
|
791
791
|
memberAccount: self {
|
|
792
792
|
... on MemberAccount {
|
|
@@ -810,8 +810,8 @@ const at = i`
|
|
|
810
810
|
}
|
|
811
811
|
}
|
|
812
812
|
}
|
|
813
|
-
`,
|
|
814
|
-
${
|
|
813
|
+
`, St = o`
|
|
814
|
+
${De}
|
|
815
815
|
|
|
816
816
|
query MemberVerification {
|
|
817
817
|
memberAccount: self {
|
|
@@ -835,7 +835,7 @@ const at = i`
|
|
|
835
835
|
}
|
|
836
836
|
}
|
|
837
837
|
}
|
|
838
|
-
`,
|
|
838
|
+
`, kt = o`
|
|
839
839
|
mutation RegisterMemberAccount(
|
|
840
840
|
$input: RegisterMemberAccountInput!
|
|
841
841
|
$referralCode: String
|
|
@@ -871,7 +871,7 @@ const at = i`
|
|
|
871
871
|
}
|
|
872
872
|
}
|
|
873
873
|
}
|
|
874
|
-
`,
|
|
874
|
+
`, Ct = o`
|
|
875
875
|
mutation RegisterMemberAccountViaMobile(
|
|
876
876
|
$input: RegisterMemberAccountViaMobileInput!
|
|
877
877
|
$referralCode: String
|
|
@@ -898,7 +898,7 @@ const at = i`
|
|
|
898
898
|
}
|
|
899
899
|
}
|
|
900
900
|
}
|
|
901
|
-
`,
|
|
901
|
+
`, _t = o`
|
|
902
902
|
mutation RegisterMemberAccount(
|
|
903
903
|
$input: RegisterMemberAccountInput_next!
|
|
904
904
|
$reCAPTCHAResponse: String
|
|
@@ -930,7 +930,7 @@ const at = i`
|
|
|
930
930
|
}
|
|
931
931
|
}
|
|
932
932
|
}
|
|
933
|
-
`,
|
|
933
|
+
`, Tt = o`
|
|
934
934
|
mutation RegisterMayaMemberAccount($input: RegisterMayaMemberAccountInput!) {
|
|
935
935
|
registerMayaMemberAccount(input: $input) {
|
|
936
936
|
... on AccountNameNotAvailableError {
|
|
@@ -938,7 +938,7 @@ const at = i`
|
|
|
938
938
|
}
|
|
939
939
|
}
|
|
940
940
|
}
|
|
941
|
-
`,
|
|
941
|
+
`, Mt = o`
|
|
942
942
|
mutation UpdateMemberAccount($input: UpdateMemberAccountInput!) {
|
|
943
943
|
updateMemberAccount(input: $input) {
|
|
944
944
|
... on AccountNameNotAvailableError {
|
|
@@ -964,7 +964,7 @@ const at = i`
|
|
|
964
964
|
}
|
|
965
965
|
}
|
|
966
966
|
}
|
|
967
|
-
`,
|
|
967
|
+
`, Dt = o`
|
|
968
968
|
mutation ResetPassword($input: ResetPasswordInput!, $verificationCode: String) {
|
|
969
969
|
resetPassword(input: $input, verificationCode: $verificationCode) {
|
|
970
970
|
... on AccountNotFoundError {
|
|
@@ -975,11 +975,11 @@ const at = i`
|
|
|
975
975
|
}
|
|
976
976
|
}
|
|
977
977
|
}
|
|
978
|
-
`,
|
|
978
|
+
`, vt = o`
|
|
979
979
|
mutation DeleteMemberAccount($input: DeleteMemberAccountInput!) {
|
|
980
980
|
deleteMemberAccount(input: $input)
|
|
981
981
|
}
|
|
982
|
-
`,
|
|
982
|
+
`, Rt = o`
|
|
983
983
|
mutation VerifyMobileNumber($input: VerifyMobileNumberInput!) {
|
|
984
984
|
verifyMobileNumber(input: $input) {
|
|
985
985
|
... on InvalidSMSVerificationCodeError {
|
|
@@ -990,7 +990,7 @@ const at = i`
|
|
|
990
990
|
}
|
|
991
991
|
}
|
|
992
992
|
}
|
|
993
|
-
`,
|
|
993
|
+
`, Nt = o`
|
|
994
994
|
mutation CreateMemberVerification($input: CreateMemberVerificationInput!) {
|
|
995
995
|
createMemberVerification(input: $input) {
|
|
996
996
|
... on FileDoesNotExistError {
|
|
@@ -1004,7 +1004,7 @@ const at = i`
|
|
|
1004
1004
|
}
|
|
1005
1005
|
}
|
|
1006
1006
|
}
|
|
1007
|
-
`,
|
|
1007
|
+
`, It = o`
|
|
1008
1008
|
mutation UpdateMemberVerification($input: UpdateMemberVerificationInput!) {
|
|
1009
1009
|
updateMemberVerification(input: $input) {
|
|
1010
1010
|
... on FileDoesNotExistError {
|
|
@@ -1021,7 +1021,7 @@ const at = i`
|
|
|
1021
1021
|
}
|
|
1022
1022
|
}
|
|
1023
1023
|
}
|
|
1024
|
-
`,
|
|
1024
|
+
`, Gt = o`
|
|
1025
1025
|
query ProfileCompletion {
|
|
1026
1026
|
profileCompletion {
|
|
1027
1027
|
completionPercentage
|
|
@@ -1032,7 +1032,7 @@ const at = i`
|
|
|
1032
1032
|
accountPassword
|
|
1033
1033
|
}
|
|
1034
1034
|
}
|
|
1035
|
-
`,
|
|
1035
|
+
`, Pt = o`
|
|
1036
1036
|
mutation SendVerificationCode($input: SendVerificationCodeInput!) {
|
|
1037
1037
|
sendVerificationCode(input: $input) {
|
|
1038
1038
|
... on InvalidPlatformError {
|
|
@@ -1043,7 +1043,7 @@ const at = i`
|
|
|
1043
1043
|
}
|
|
1044
1044
|
}
|
|
1045
1045
|
}
|
|
1046
|
-
`,
|
|
1046
|
+
`, Wt = o`
|
|
1047
1047
|
fragment DepositGatewaySettingsCoreData on DepositGatewaySettings {
|
|
1048
1048
|
minimumAmount
|
|
1049
1049
|
maximumAmount
|
|
@@ -1083,6 +1083,12 @@ const at = i`
|
|
|
1083
1083
|
mayaAppDepositGatewaySettings: depositGatewaySettings(gateway: MAYA_APP) {
|
|
1084
1084
|
...DepositGatewaySettingsCoreData
|
|
1085
1085
|
}
|
|
1086
|
+
onlineBankDepositGatewaySettings: depositGatewaySettings(gateway: ONLINE_BANK) {
|
|
1087
|
+
...DepositGatewaySettingsCoreData
|
|
1088
|
+
}
|
|
1089
|
+
qrphDepositGatewaySettings: depositGatewaySettings(gateway: QR_PH) {
|
|
1090
|
+
...DepositGatewaySettingsCoreData
|
|
1091
|
+
}
|
|
1086
1092
|
bankWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: BANK) {
|
|
1087
1093
|
...WithdrawalGatewaySettingsCoreData
|
|
1088
1094
|
}
|
|
@@ -1095,16 +1101,19 @@ const at = i`
|
|
|
1095
1101
|
mayaAppWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: MAYA_APP) {
|
|
1096
1102
|
...WithdrawalGatewaySettingsCoreData
|
|
1097
1103
|
}
|
|
1104
|
+
instapayWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: INSTAPAY) {
|
|
1105
|
+
...WithdrawalGatewaySettingsCoreData
|
|
1106
|
+
}
|
|
1098
1107
|
pointsClubSettings {
|
|
1099
1108
|
multiplier
|
|
1100
1109
|
}
|
|
1101
1110
|
}
|
|
1102
|
-
`,
|
|
1111
|
+
`, xt = o`
|
|
1103
1112
|
query Platform {
|
|
1104
1113
|
timezone
|
|
1105
1114
|
currency
|
|
1106
1115
|
}
|
|
1107
|
-
`,
|
|
1116
|
+
`, Ot = o`
|
|
1108
1117
|
fragment DepositGatewaySettingsCoreData on DepositGatewaySettings {
|
|
1109
1118
|
minimumAmount
|
|
1110
1119
|
maximumAmount
|
|
@@ -1142,6 +1151,12 @@ const at = i`
|
|
|
1142
1151
|
mayaAppDepositGatewaySettings: depositGatewaySettings(gateway: MAYA_APP) {
|
|
1143
1152
|
...DepositGatewaySettingsCoreData
|
|
1144
1153
|
}
|
|
1154
|
+
onlineBankDepositGatewaySettings: depositGatewaySettings(gateway: ONLINE_BANK) {
|
|
1155
|
+
...DepositGatewaySettingsCoreData
|
|
1156
|
+
}
|
|
1157
|
+
qrphDepositGatewaySettings: depositGatewaySettings(gateway: QR_PH) {
|
|
1158
|
+
...DepositGatewaySettingsCoreData
|
|
1159
|
+
}
|
|
1145
1160
|
bankWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: BANK) {
|
|
1146
1161
|
...WithdrawalGatewaySettingsCoreData
|
|
1147
1162
|
}
|
|
@@ -1154,8 +1169,11 @@ const at = i`
|
|
|
1154
1169
|
mayaAppWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: MAYA_APP) {
|
|
1155
1170
|
...WithdrawalGatewaySettingsCoreData
|
|
1156
1171
|
}
|
|
1172
|
+
instapayWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: INSTAPAY) {
|
|
1173
|
+
...WithdrawalGatewaySettingsCoreData
|
|
1174
|
+
}
|
|
1157
1175
|
}
|
|
1158
|
-
`,
|
|
1176
|
+
`, $t = o`
|
|
1159
1177
|
query MayaSession($id: ObjectId!) {
|
|
1160
1178
|
mayaSession(id: $id) {
|
|
1161
1179
|
id
|
|
@@ -1163,11 +1181,11 @@ const at = i`
|
|
|
1163
1181
|
dateTimeCreated
|
|
1164
1182
|
}
|
|
1165
1183
|
}
|
|
1166
|
-
`,
|
|
1184
|
+
`, Ut = o`
|
|
1167
1185
|
mutation ValidateMayaSession {
|
|
1168
1186
|
validateMayaSession: validMayaSession
|
|
1169
1187
|
}
|
|
1170
|
-
`,
|
|
1188
|
+
`, Bt = o`
|
|
1171
1189
|
query ActivityRecords($after: Cursor, $first: Int, $filter: ActivityRecordsFilterInput) {
|
|
1172
1190
|
member {
|
|
1173
1191
|
activityRecords(after: $after, first: $first, filter: $filter) {
|
|
@@ -1192,11 +1210,11 @@ const at = i`
|
|
|
1192
1210
|
}
|
|
1193
1211
|
}
|
|
1194
1212
|
}
|
|
1195
|
-
`,
|
|
1213
|
+
`, qt = o`
|
|
1196
1214
|
query ReferralCode {
|
|
1197
1215
|
referralCode
|
|
1198
1216
|
}
|
|
1199
|
-
`,
|
|
1217
|
+
`, Ft = o`
|
|
1200
1218
|
mutation UpdateReferralCode($input: UpdateReferralCodeInput!) {
|
|
1201
1219
|
updateReferralCode(input: $input) {
|
|
1202
1220
|
... on ReferralCodeNotAvailableError {
|
|
@@ -1204,7 +1222,7 @@ const at = i`
|
|
|
1204
1222
|
}
|
|
1205
1223
|
}
|
|
1206
1224
|
}
|
|
1207
|
-
`,
|
|
1225
|
+
`, Ge = o`
|
|
1208
1226
|
fragment ReferralFragment on Referral {
|
|
1209
1227
|
id
|
|
1210
1228
|
upline {
|
|
@@ -1222,7 +1240,7 @@ const at = i`
|
|
|
1222
1240
|
commission
|
|
1223
1241
|
dateTimeCreated
|
|
1224
1242
|
}
|
|
1225
|
-
`,
|
|
1243
|
+
`, Lt = o`
|
|
1226
1244
|
query Referrals($first: Int, $after: Cursor, $filter: ReferralFilterInput) {
|
|
1227
1245
|
member {
|
|
1228
1246
|
referrals(first: $first, after: $after, filter: $filter) {
|
|
@@ -1243,24 +1261,24 @@ const at = i`
|
|
|
1243
1261
|
}
|
|
1244
1262
|
}
|
|
1245
1263
|
|
|
1246
|
-
${
|
|
1247
|
-
`,
|
|
1264
|
+
${Ge}
|
|
1265
|
+
`, Vt = o`
|
|
1248
1266
|
query UplinesByName($search: String!, $first: Int) {
|
|
1249
1267
|
uplinesByName(search: $search, first: $first) {
|
|
1250
1268
|
...ReferralFragment
|
|
1251
1269
|
}
|
|
1252
1270
|
}
|
|
1253
1271
|
|
|
1254
|
-
${
|
|
1255
|
-
`,
|
|
1272
|
+
${Ge}
|
|
1273
|
+
`, Ht = o`
|
|
1256
1274
|
query DownlinesByName($search: String!, $first: Int) {
|
|
1257
1275
|
downlinesByName(search: $search, first: $first) {
|
|
1258
1276
|
...ReferralFragment
|
|
1259
1277
|
}
|
|
1260
1278
|
}
|
|
1261
1279
|
|
|
1262
|
-
${
|
|
1263
|
-
`,
|
|
1280
|
+
${Ge}
|
|
1281
|
+
`, Yt = o`
|
|
1264
1282
|
query ReferralCommission {
|
|
1265
1283
|
member {
|
|
1266
1284
|
referralCommission {
|
|
@@ -1279,13 +1297,13 @@ const at = i`
|
|
|
1279
1297
|
}
|
|
1280
1298
|
}
|
|
1281
1299
|
}
|
|
1282
|
-
`,
|
|
1300
|
+
`, Qt = o`
|
|
1283
1301
|
query PointsClubSettings {
|
|
1284
1302
|
pointsClubSettings {
|
|
1285
1303
|
multiplier
|
|
1286
1304
|
}
|
|
1287
1305
|
}
|
|
1288
|
-
`,
|
|
1306
|
+
`, jt = o`
|
|
1289
1307
|
query Messages($first: Int, $after: Cursor, $filter: MessageFilterInput) {
|
|
1290
1308
|
messages(first: $first, after: $after, filter: $filter) {
|
|
1291
1309
|
edges {
|
|
@@ -1313,24 +1331,24 @@ const at = i`
|
|
|
1313
1331
|
}
|
|
1314
1332
|
}
|
|
1315
1333
|
}
|
|
1316
|
-
`,
|
|
1334
|
+
`, Kt = o`
|
|
1317
1335
|
query UnreadMessagesCount($filter: MessageFilterInput) {
|
|
1318
1336
|
messages(filter: $filter) {
|
|
1319
1337
|
totalCount
|
|
1320
1338
|
}
|
|
1321
1339
|
}
|
|
1322
|
-
`,
|
|
1340
|
+
`, zt = o`
|
|
1323
1341
|
mutation MarkMessageAsRead($id: ObjectId!) {
|
|
1324
1342
|
markMessageAsRead(id: $id)
|
|
1325
1343
|
}
|
|
1326
|
-
`,
|
|
1344
|
+
`, Jt = o`
|
|
1327
1345
|
mutation MarkAllMessageAsRead {
|
|
1328
1346
|
markAllMessageAsRead
|
|
1329
1347
|
}
|
|
1330
1348
|
`;
|
|
1331
|
-
function
|
|
1349
|
+
function l(i) {
|
|
1332
1350
|
return {
|
|
1333
|
-
name:
|
|
1351
|
+
name: i,
|
|
1334
1352
|
message: {
|
|
1335
1353
|
AccountNameNotAvailableError: "Username is no longer available",
|
|
1336
1354
|
AccountNotFoundError: "Account does not exist",
|
|
@@ -1380,60 +1398,60 @@ function u(n) {
|
|
|
1380
1398
|
InvalidTokenOrSecretAnswerError: "Invalid token or secret answer",
|
|
1381
1399
|
SessionExpiredError: "Session expired",
|
|
1382
1400
|
RateLimitExceededError: "Maximum number of requests reached"
|
|
1383
|
-
}[
|
|
1401
|
+
}[i]
|
|
1384
1402
|
};
|
|
1385
1403
|
}
|
|
1386
|
-
class
|
|
1404
|
+
class Xt {
|
|
1387
1405
|
constructor(e) {
|
|
1388
1406
|
c(this, "client");
|
|
1389
1407
|
this.client = e;
|
|
1390
1408
|
}
|
|
1391
1409
|
/** aka `Query.self` */
|
|
1392
1410
|
async memberAccount() {
|
|
1393
|
-
const e = await this.client.request(
|
|
1411
|
+
const e = await this.client.request(At);
|
|
1394
1412
|
return e.ok ? {
|
|
1395
1413
|
ok: !0,
|
|
1396
1414
|
data: e.data.memberAccount
|
|
1397
1415
|
} : e;
|
|
1398
1416
|
}
|
|
1399
1417
|
async registerMemberAccount(e) {
|
|
1400
|
-
const t = await this.client.request(
|
|
1418
|
+
const t = await this.client.request(kt, e);
|
|
1401
1419
|
return t.ok ? t.data.registerMemberAccount ? {
|
|
1402
1420
|
ok: !1,
|
|
1403
|
-
error:
|
|
1421
|
+
error: l(t.data.registerMemberAccount.__typename)
|
|
1404
1422
|
} : {
|
|
1405
1423
|
ok: !0
|
|
1406
1424
|
} : t;
|
|
1407
1425
|
}
|
|
1408
1426
|
async registerMemberAccountViaMobile(e) {
|
|
1409
|
-
const t = await this.client.request(
|
|
1427
|
+
const t = await this.client.request(Ct, e);
|
|
1410
1428
|
return t.ok ? t.data.registerMemberAccountViaMobile ? {
|
|
1411
1429
|
ok: !1,
|
|
1412
|
-
error:
|
|
1430
|
+
error: l(t.data.registerMemberAccountViaMobile.__typename)
|
|
1413
1431
|
} : {
|
|
1414
1432
|
ok: !0
|
|
1415
1433
|
} : t;
|
|
1416
1434
|
}
|
|
1417
1435
|
async registerMemberAccount__next(e) {
|
|
1418
|
-
const t = await this.client.request(
|
|
1436
|
+
const t = await this.client.request(_t, e);
|
|
1419
1437
|
return t.ok ? t.data.registerMemberAccount ? {
|
|
1420
1438
|
ok: !1,
|
|
1421
|
-
error:
|
|
1439
|
+
error: l(t.data.registerMemberAccount.__typename)
|
|
1422
1440
|
} : {
|
|
1423
1441
|
ok: !0
|
|
1424
1442
|
} : t;
|
|
1425
1443
|
}
|
|
1426
1444
|
async updateMemberAccount(e) {
|
|
1427
|
-
const t = await this.client.request(
|
|
1445
|
+
const t = await this.client.request(Mt, e);
|
|
1428
1446
|
return t.ok ? t.data.updateMemberAccount ? {
|
|
1429
1447
|
ok: !1,
|
|
1430
|
-
error:
|
|
1448
|
+
error: l(t.data.updateMemberAccount.__typename)
|
|
1431
1449
|
} : {
|
|
1432
1450
|
ok: !0
|
|
1433
1451
|
} : t;
|
|
1434
1452
|
}
|
|
1435
1453
|
async deleteMemberAccount(e) {
|
|
1436
|
-
const t = await this.client.request(
|
|
1454
|
+
const t = await this.client.request(vt, e);
|
|
1437
1455
|
return t.ok ? t.data.deleteMemberAccount ? {
|
|
1438
1456
|
ok: !0
|
|
1439
1457
|
} : {
|
|
@@ -1446,66 +1464,66 @@ class Pt {
|
|
|
1446
1464
|
}
|
|
1447
1465
|
async resetPassword(e) {
|
|
1448
1466
|
const t = await this.client.request(
|
|
1449
|
-
|
|
1467
|
+
Dt,
|
|
1450
1468
|
e
|
|
1451
1469
|
);
|
|
1452
1470
|
return t.ok ? t.data.resetPassword ? {
|
|
1453
1471
|
ok: !1,
|
|
1454
|
-
error:
|
|
1472
|
+
error: l(t.data.resetPassword.__typename)
|
|
1455
1473
|
} : {
|
|
1456
1474
|
ok: !0
|
|
1457
1475
|
} : t;
|
|
1458
1476
|
}
|
|
1459
1477
|
async profileCompletion() {
|
|
1460
|
-
const e = await this.client.request(
|
|
1478
|
+
const e = await this.client.request(Gt);
|
|
1461
1479
|
return e.ok ? { ok: !0, data: e.data.profileCompletion } : e;
|
|
1462
1480
|
}
|
|
1463
1481
|
/** @deprecated */
|
|
1464
1482
|
async platform() {
|
|
1465
|
-
return await this.client.request(
|
|
1483
|
+
return await this.client.request(Wt);
|
|
1466
1484
|
}
|
|
1467
1485
|
/** @deprecated */
|
|
1468
1486
|
async sendVerificationCode(e) {
|
|
1469
|
-
const t = await this.client.request(
|
|
1487
|
+
const t = await this.client.request(Pt, e);
|
|
1470
1488
|
return t.ok ? t.data.sendVerificationCode ? {
|
|
1471
1489
|
ok: !1,
|
|
1472
|
-
error:
|
|
1490
|
+
error: l(t.data.sendVerificationCode.__typename)
|
|
1473
1491
|
} : {
|
|
1474
1492
|
ok: !0
|
|
1475
1493
|
} : t;
|
|
1476
1494
|
}
|
|
1477
1495
|
async paymentSettings() {
|
|
1478
|
-
return await this.client.request(
|
|
1496
|
+
return await this.client.request(Ot);
|
|
1479
1497
|
}
|
|
1480
1498
|
async verifyMobileNumber(e) {
|
|
1481
|
-
const t = await this.client.request(
|
|
1499
|
+
const t = await this.client.request(Rt, e);
|
|
1482
1500
|
return t.ok ? t.data.verifyMobileNumber ? {
|
|
1483
1501
|
ok: !1,
|
|
1484
|
-
error:
|
|
1502
|
+
error: l(t.data.verifyMobileNumber.__typename)
|
|
1485
1503
|
} : {
|
|
1486
1504
|
ok: !0
|
|
1487
1505
|
} : t;
|
|
1488
1506
|
}
|
|
1489
1507
|
async createMemberVerification(e) {
|
|
1490
|
-
const t = await this.client.request(
|
|
1508
|
+
const t = await this.client.request(Nt, e);
|
|
1491
1509
|
return t.ok ? t.data.createMemberVerification ? {
|
|
1492
1510
|
ok: !1,
|
|
1493
|
-
error:
|
|
1511
|
+
error: l(t.data.createMemberVerification.__typename)
|
|
1494
1512
|
} : {
|
|
1495
1513
|
ok: !0
|
|
1496
1514
|
} : t;
|
|
1497
1515
|
}
|
|
1498
1516
|
async updateMemberVerification(e) {
|
|
1499
|
-
const t = await this.client.request(
|
|
1517
|
+
const t = await this.client.request(It, e);
|
|
1500
1518
|
return t.ok ? t.data.updateMemberVerification ? {
|
|
1501
1519
|
ok: !1,
|
|
1502
|
-
error:
|
|
1520
|
+
error: l(t.data.updateMemberVerification.__typename)
|
|
1503
1521
|
} : {
|
|
1504
1522
|
ok: !0
|
|
1505
1523
|
} : t;
|
|
1506
1524
|
}
|
|
1507
1525
|
async memberVerification() {
|
|
1508
|
-
const e = await this.client.request(
|
|
1526
|
+
const e = await this.client.request(St);
|
|
1509
1527
|
return e.ok ? {
|
|
1510
1528
|
ok: !0,
|
|
1511
1529
|
data: e.data.memberAccount.verification
|
|
@@ -1513,7 +1531,7 @@ class Pt {
|
|
|
1513
1531
|
}
|
|
1514
1532
|
async announcements(e) {
|
|
1515
1533
|
const t = await this.client.request(
|
|
1516
|
-
|
|
1534
|
+
Je,
|
|
1517
1535
|
e
|
|
1518
1536
|
);
|
|
1519
1537
|
return t.ok ? {
|
|
@@ -1522,43 +1540,43 @@ class Pt {
|
|
|
1522
1540
|
} : t;
|
|
1523
1541
|
}
|
|
1524
1542
|
async registerMayaMemberAccount(e) {
|
|
1525
|
-
const t = await this.client.request(
|
|
1543
|
+
const t = await this.client.request(Tt, e);
|
|
1526
1544
|
return t.ok ? t.data.registerMayaMemberAccount ? {
|
|
1527
1545
|
ok: !1,
|
|
1528
|
-
error:
|
|
1546
|
+
error: l(t.data.registerMayaMemberAccount.__typename)
|
|
1529
1547
|
} : {
|
|
1530
1548
|
ok: !0
|
|
1531
1549
|
} : t;
|
|
1532
1550
|
}
|
|
1533
1551
|
async referralCode() {
|
|
1534
|
-
const e = await this.client.request(
|
|
1552
|
+
const e = await this.client.request(qt);
|
|
1535
1553
|
return e.ok ? {
|
|
1536
1554
|
ok: !0,
|
|
1537
1555
|
data: e.data.referralCode
|
|
1538
1556
|
} : e;
|
|
1539
1557
|
}
|
|
1540
1558
|
async updateReferralCode(e) {
|
|
1541
|
-
const t = await this.client.request(
|
|
1559
|
+
const t = await this.client.request(Ft, e);
|
|
1542
1560
|
return t.ok ? t.data.updateReferralCode ? {
|
|
1543
1561
|
ok: !1,
|
|
1544
|
-
error:
|
|
1562
|
+
error: l(t.data.updateReferralCode.__typename)
|
|
1545
1563
|
} : {
|
|
1546
1564
|
ok: !0
|
|
1547
1565
|
} : t;
|
|
1548
1566
|
}
|
|
1549
1567
|
async pointsClubSettings() {
|
|
1550
|
-
const e = await this.client.request(
|
|
1568
|
+
const e = await this.client.request(Qt);
|
|
1551
1569
|
return e.ok ? { ok: !0, data: e.data.pointsClubSettings } : e;
|
|
1552
1570
|
}
|
|
1553
1571
|
}
|
|
1554
|
-
function
|
|
1555
|
-
const t =
|
|
1572
|
+
function y(i, e) {
|
|
1573
|
+
const t = ve[i] ? ve[i] : ve[500];
|
|
1556
1574
|
return {
|
|
1557
1575
|
name: t.name,
|
|
1558
1576
|
message: e ?? t.message
|
|
1559
1577
|
};
|
|
1560
1578
|
}
|
|
1561
|
-
const
|
|
1579
|
+
const ve = {
|
|
1562
1580
|
400: { name: "HttpBadRequest", message: "Bad Request" },
|
|
1563
1581
|
401: { name: "HttpUnauthorized", message: "Unauthorized" },
|
|
1564
1582
|
403: { name: "HttpForbidden", message: "Forbidden" },
|
|
@@ -1567,7 +1585,7 @@ const de = {
|
|
|
1567
1585
|
429: { name: "HttpTooManyRequests", message: "Too Many Requests" },
|
|
1568
1586
|
500: { name: "HttpInternalServerError", message: "Internal Server Error" }
|
|
1569
1587
|
};
|
|
1570
|
-
class
|
|
1588
|
+
class Zt {
|
|
1571
1589
|
constructor(e) {
|
|
1572
1590
|
c(this, "url");
|
|
1573
1591
|
c(this, "platform");
|
|
@@ -1580,33 +1598,33 @@ class xt {
|
|
|
1580
1598
|
async createSession(e) {
|
|
1581
1599
|
const t = new Headers(this.headers);
|
|
1582
1600
|
if (e.name) {
|
|
1583
|
-
const
|
|
1584
|
-
t.set("Authorization", `Basic ${
|
|
1601
|
+
const a = `${e.name}:${e.password}`, r = Buffer.from(a).toString("base64");
|
|
1602
|
+
t.set("Authorization", `Basic ${r}`);
|
|
1585
1603
|
}
|
|
1586
1604
|
if (e.mobileNumber) {
|
|
1587
|
-
const
|
|
1588
|
-
console.log(`MobileNumberOTP ${
|
|
1605
|
+
const a = `${e.mobileNumber}:${e.verificationCode}`, r = Buffer.from(a).toString("base64");
|
|
1606
|
+
console.log(`MobileNumberOTP ${r}`), t.set("Authorization", `MobileNumberOTP ${r}`);
|
|
1589
1607
|
}
|
|
1590
1608
|
e.sessionId && t.set("Authorization", `MayaSession ${e.sessionId}`), e.token && t.set("Authorization", `Token ${e.token}`);
|
|
1591
1609
|
try {
|
|
1592
|
-
const
|
|
1610
|
+
const a = await fetch(`${this.url}/sessions`, {
|
|
1593
1611
|
method: "POST",
|
|
1594
1612
|
headers: t
|
|
1595
|
-
}),
|
|
1596
|
-
return
|
|
1613
|
+
}), r = await a.json();
|
|
1614
|
+
return a.ok ? {
|
|
1597
1615
|
ok: !0,
|
|
1598
|
-
data:
|
|
1599
|
-
} :
|
|
1616
|
+
data: r
|
|
1617
|
+
} : r.code === "ACCOUNT_BLACKLISTED" ? {
|
|
1600
1618
|
ok: !1,
|
|
1601
|
-
error:
|
|
1619
|
+
error: l("AccountBlacklistedError")
|
|
1602
1620
|
} : {
|
|
1603
1621
|
ok: !1,
|
|
1604
|
-
error:
|
|
1622
|
+
error: y(a.status)
|
|
1605
1623
|
};
|
|
1606
1624
|
} catch {
|
|
1607
1625
|
return {
|
|
1608
1626
|
ok: !1,
|
|
1609
|
-
error:
|
|
1627
|
+
error: y(500)
|
|
1610
1628
|
};
|
|
1611
1629
|
}
|
|
1612
1630
|
}
|
|
@@ -1615,27 +1633,27 @@ class xt {
|
|
|
1615
1633
|
if (e.type === "SECURITY_QUESTION") {
|
|
1616
1634
|
t.set("Authorization", `Bearer ${e.token}`);
|
|
1617
1635
|
try {
|
|
1618
|
-
const
|
|
1636
|
+
const a = await fetch(`${this.url}/session/${e.token}/authenticate`, {
|
|
1619
1637
|
method: "POST",
|
|
1620
1638
|
headers: t,
|
|
1621
1639
|
body: JSON.stringify({
|
|
1622
1640
|
secretAnswer: e.secretAnswer
|
|
1623
1641
|
})
|
|
1624
|
-
}),
|
|
1625
|
-
return
|
|
1642
|
+
}), r = await a.json();
|
|
1643
|
+
return a.ok ? {
|
|
1626
1644
|
ok: !0,
|
|
1627
|
-
data:
|
|
1628
|
-
} :
|
|
1645
|
+
data: r
|
|
1646
|
+
} : a.status === 401 || a.status === 403 ? {
|
|
1629
1647
|
ok: !1,
|
|
1630
|
-
error:
|
|
1648
|
+
error: l("InvalidTokenOrSecretAnswerError")
|
|
1631
1649
|
} : {
|
|
1632
1650
|
ok: !1,
|
|
1633
|
-
error:
|
|
1651
|
+
error: y(a.status)
|
|
1634
1652
|
};
|
|
1635
1653
|
} catch {
|
|
1636
1654
|
return {
|
|
1637
1655
|
ok: !1,
|
|
1638
|
-
error:
|
|
1656
|
+
error: y(500)
|
|
1639
1657
|
};
|
|
1640
1658
|
}
|
|
1641
1659
|
}
|
|
@@ -1645,27 +1663,27 @@ class xt {
|
|
|
1645
1663
|
const t = new Headers(this.headers);
|
|
1646
1664
|
t.append("Authorization", `Bearer ${e}`);
|
|
1647
1665
|
try {
|
|
1648
|
-
const
|
|
1666
|
+
const a = await fetch(`${this.url}/session:refresh`, {
|
|
1649
1667
|
method: "POST",
|
|
1650
1668
|
headers: t
|
|
1651
|
-
}),
|
|
1652
|
-
return
|
|
1669
|
+
}), r = await a.json();
|
|
1670
|
+
return a.ok ? {
|
|
1653
1671
|
ok: !0,
|
|
1654
|
-
data:
|
|
1655
|
-
} :
|
|
1672
|
+
data: r
|
|
1673
|
+
} : r.code === "ACCOUNT_BLACKLISTED" ? {
|
|
1656
1674
|
ok: !1,
|
|
1657
|
-
error:
|
|
1658
|
-
} :
|
|
1675
|
+
error: l("AccountBlacklistedError")
|
|
1676
|
+
} : a.status === 403 || a.status === 401 ? {
|
|
1659
1677
|
ok: !1,
|
|
1660
|
-
error:
|
|
1678
|
+
error: l("InvalidTokenError")
|
|
1661
1679
|
} : {
|
|
1662
1680
|
ok: !1,
|
|
1663
|
-
error:
|
|
1681
|
+
error: y(a.status)
|
|
1664
1682
|
};
|
|
1665
1683
|
} catch {
|
|
1666
1684
|
return {
|
|
1667
1685
|
ok: !1,
|
|
1668
|
-
error:
|
|
1686
|
+
error: y(500)
|
|
1669
1687
|
};
|
|
1670
1688
|
}
|
|
1671
1689
|
}
|
|
@@ -1673,13 +1691,13 @@ class xt {
|
|
|
1673
1691
|
const t = new Headers(this.headers);
|
|
1674
1692
|
t.append("Authorization", `Bearer ${e}`);
|
|
1675
1693
|
try {
|
|
1676
|
-
const
|
|
1694
|
+
const a = await fetch(`${this.url}/session`, {
|
|
1677
1695
|
method: "DELETE",
|
|
1678
1696
|
headers: t
|
|
1679
1697
|
});
|
|
1680
|
-
return
|
|
1698
|
+
return a.ok ? { ok: !0 } : { ok: !1, error: y(a.status) };
|
|
1681
1699
|
} catch {
|
|
1682
|
-
return { ok: !1, error:
|
|
1700
|
+
return { ok: !1, error: y(500) };
|
|
1683
1701
|
}
|
|
1684
1702
|
}
|
|
1685
1703
|
async verifySession(e) {
|
|
@@ -1696,8 +1714,8 @@ class xt {
|
|
|
1696
1714
|
}
|
|
1697
1715
|
async sendVerificationCode(e) {
|
|
1698
1716
|
if (e.channel === "EMAIL") throw new Error("Email channel is not yet supported");
|
|
1699
|
-
function t(
|
|
1700
|
-
switch (
|
|
1717
|
+
function t(a) {
|
|
1718
|
+
switch (a) {
|
|
1701
1719
|
case "MEMBER_NOT_FOUND":
|
|
1702
1720
|
return "AccountNotFoundError";
|
|
1703
1721
|
case "RATE_LIMIT_REACH":
|
|
@@ -1709,34 +1727,34 @@ class xt {
|
|
|
1709
1727
|
}
|
|
1710
1728
|
}
|
|
1711
1729
|
try {
|
|
1712
|
-
const
|
|
1730
|
+
const a = await fetch(`${this.url}/otps`, {
|
|
1713
1731
|
method: "POST",
|
|
1714
1732
|
headers: this.headers,
|
|
1715
1733
|
body: JSON.stringify(e)
|
|
1716
1734
|
});
|
|
1717
|
-
if (
|
|
1718
|
-
const
|
|
1735
|
+
if (a.status === 403) {
|
|
1736
|
+
const r = await a.json(), s = t(r.message);
|
|
1719
1737
|
return s ? {
|
|
1720
1738
|
ok: !1,
|
|
1721
|
-
error:
|
|
1739
|
+
error: l(s)
|
|
1722
1740
|
} : {
|
|
1723
1741
|
ok: !1,
|
|
1724
|
-
error:
|
|
1742
|
+
error: y(a.status, r.message)
|
|
1725
1743
|
};
|
|
1726
1744
|
}
|
|
1727
|
-
return
|
|
1745
|
+
return a.ok ? { ok: !0 } : {
|
|
1728
1746
|
ok: !1,
|
|
1729
|
-
error:
|
|
1747
|
+
error: y(a.status)
|
|
1730
1748
|
};
|
|
1731
1749
|
} catch {
|
|
1732
1750
|
return {
|
|
1733
1751
|
ok: !1,
|
|
1734
|
-
error:
|
|
1752
|
+
error: y(500)
|
|
1735
1753
|
};
|
|
1736
1754
|
}
|
|
1737
1755
|
}
|
|
1738
1756
|
}
|
|
1739
|
-
class
|
|
1757
|
+
class ea {
|
|
1740
1758
|
constructor(e) {
|
|
1741
1759
|
c(this, "url");
|
|
1742
1760
|
c(this, "siteId");
|
|
@@ -1751,35 +1769,35 @@ class Wt {
|
|
|
1751
1769
|
} : e;
|
|
1752
1770
|
}
|
|
1753
1771
|
async games(e) {
|
|
1754
|
-
var
|
|
1772
|
+
var r, s, m, u, p, f, w, d, k, C, _, T, M, D, h, v, R, A, N, I, G, P, S, W;
|
|
1755
1773
|
const t = new URLSearchParams();
|
|
1756
|
-
e != null && e.first && t.set("first", e.first.toString()), e != null && e.after && t.set("after", e.after), e != null && e.search && t.set("search", e.search), (s = (
|
|
1774
|
+
e != null && e.first && t.set("first", e.first.toString()), e != null && e.after && t.set("after", e.after), e != null && e.search && t.set("search", e.search), (s = (r = e == null ? void 0 : e.filter) == null ? void 0 : r.type) != null && s.equal && t.set("filter[type][eq]", e.filter.type.equal), (u = (m = e == null ? void 0 : e.filter) == null ? void 0 : m.type) != null && u.notEqual && t.set("filter[type][neq]", e.filter.type.notEqual), (f = (p = e == null ? void 0 : e.filter) == null ? void 0 : p.type) != null && f.in && t.set("filter[type][in]", e.filter.type.in.join(",")), (d = (w = e == null ? void 0 : e.filter) == null ? void 0 : w.type) != null && d.notIn && t.set("filter[type][nin]", e.filter.type.notIn.join(",")), (C = (k = e == null ? void 0 : e.filter) == null ? void 0 : k.provider) != null && C.equal && t.set("filter[provider][eq]", e.filter.provider.equal), (T = (_ = e == null ? void 0 : e.filter) == null ? void 0 : _.provider) != null && T.notEqual && t.set("filter[provider][neq]", e.filter.provider.notEqual), (D = (M = e == null ? void 0 : e.filter) == null ? void 0 : M.provider) != null && D.in && t.set("filter[provider][in]", e.filter.provider.in.join(",")), (v = (h = e == null ? void 0 : e.filter) == null ? void 0 : h.provider) != null && v.notIn && t.set("filter[provider][nin]", e.filter.provider.notIn.join(",")), (A = (R = e == null ? void 0 : e.filter) == null ? void 0 : R.tags) != null && A.equal && t.set("filter[tags][eq]", e.filter.tags.equal.toLowerCase()), (I = (N = e == null ? void 0 : e.filter) == null ? void 0 : N.tags) != null && I.notEqual && t.set("filter[tags][neq]", e.filter.tags.notEqual.toLowerCase()), (P = (G = e == null ? void 0 : e.filter) == null ? void 0 : G.tags) != null && P.in && t.set(
|
|
1757
1775
|
"filter[tags][in]",
|
|
1758
1776
|
e.filter.tags.in.map((E) => E.toLowerCase()).join(",")
|
|
1759
|
-
), (
|
|
1777
|
+
), (W = (S = e == null ? void 0 : e.filter) == null ? void 0 : S.tags) != null && W.notIn && t.set(
|
|
1760
1778
|
"filter[tags][nin]",
|
|
1761
1779
|
e.filter.tags.notIn.map((E) => E.toLowerCase()).join(",")
|
|
1762
1780
|
);
|
|
1763
|
-
const
|
|
1764
|
-
return
|
|
1781
|
+
const a = await this.getJson("/games", t);
|
|
1782
|
+
return a.ok ? {
|
|
1765
1783
|
ok: !0,
|
|
1766
1784
|
data: {
|
|
1767
|
-
edges:
|
|
1785
|
+
edges: a.data.data.map((E) => ({
|
|
1768
1786
|
node: E,
|
|
1769
1787
|
cursor: E.cursor
|
|
1770
1788
|
})),
|
|
1771
|
-
totalCount:
|
|
1789
|
+
totalCount: a.data.totalCount ?? 0,
|
|
1772
1790
|
pageInfo: {
|
|
1773
|
-
hasNextPage: !!
|
|
1774
|
-
endCursor:
|
|
1791
|
+
hasNextPage: !!a.data.next,
|
|
1792
|
+
endCursor: a.data.next
|
|
1775
1793
|
}
|
|
1776
1794
|
}
|
|
1777
|
-
} :
|
|
1795
|
+
} : a;
|
|
1778
1796
|
}
|
|
1779
1797
|
async game(e) {
|
|
1780
|
-
var
|
|
1798
|
+
var a;
|
|
1781
1799
|
const t = await this.getJson(`/games/${e}`);
|
|
1782
|
-
return ((
|
|
1800
|
+
return ((a = t.error) == null ? void 0 : a.name) === "HttpNotFound" ? {
|
|
1783
1801
|
ok: !0,
|
|
1784
1802
|
data: null
|
|
1785
1803
|
} : t.ok ? {
|
|
@@ -1788,7 +1806,7 @@ class Wt {
|
|
|
1788
1806
|
} : t;
|
|
1789
1807
|
}
|
|
1790
1808
|
async getJson(e, t) {
|
|
1791
|
-
const
|
|
1809
|
+
const a = new Request(`${this.url}${e}?${(t == null ? void 0 : t.toString()) ?? ""}`, {
|
|
1792
1810
|
method: "GET",
|
|
1793
1811
|
headers: {
|
|
1794
1812
|
Accept: "application/json",
|
|
@@ -1798,52 +1816,52 @@ class Wt {
|
|
|
1798
1816
|
}
|
|
1799
1817
|
});
|
|
1800
1818
|
try {
|
|
1801
|
-
const
|
|
1802
|
-
return
|
|
1819
|
+
const r = await fetch(a);
|
|
1820
|
+
return r.ok ? {
|
|
1803
1821
|
ok: !0,
|
|
1804
|
-
data: await
|
|
1822
|
+
data: await r.json()
|
|
1805
1823
|
} : {
|
|
1806
1824
|
ok: !1,
|
|
1807
|
-
error:
|
|
1825
|
+
error: y(r.status)
|
|
1808
1826
|
};
|
|
1809
1827
|
} catch {
|
|
1810
1828
|
return {
|
|
1811
1829
|
ok: !1,
|
|
1812
|
-
error:
|
|
1830
|
+
error: y(500)
|
|
1813
1831
|
};
|
|
1814
1832
|
}
|
|
1815
1833
|
}
|
|
1816
1834
|
}
|
|
1817
|
-
class
|
|
1835
|
+
class ta {
|
|
1818
1836
|
constructor(e) {
|
|
1819
1837
|
c(this, "client");
|
|
1820
1838
|
this.client = e;
|
|
1821
1839
|
}
|
|
1822
1840
|
async file(e) {
|
|
1823
|
-
const t = await this.client.request(
|
|
1841
|
+
const t = await this.client.request(He, e);
|
|
1824
1842
|
return t.ok ? {
|
|
1825
1843
|
ok: !0,
|
|
1826
1844
|
data: t.data.node
|
|
1827
1845
|
} : t;
|
|
1828
1846
|
}
|
|
1829
1847
|
async uploadPrivateImageFile(e) {
|
|
1830
|
-
const t = await this.client.upload(
|
|
1848
|
+
const t = await this.client.upload(Ye, e);
|
|
1831
1849
|
return t.ok ? t.data.uploadPrivateImageFile ? {
|
|
1832
1850
|
ok: !1,
|
|
1833
|
-
error:
|
|
1851
|
+
error: l(t.data.uploadPrivateImageFile.__typename)
|
|
1834
1852
|
} : {
|
|
1835
1853
|
ok: !0
|
|
1836
1854
|
} : t;
|
|
1837
1855
|
}
|
|
1838
1856
|
}
|
|
1839
|
-
class
|
|
1857
|
+
class aa {
|
|
1840
1858
|
constructor(e) {
|
|
1841
1859
|
c(this, "client");
|
|
1842
1860
|
this.client = e;
|
|
1843
1861
|
}
|
|
1844
1862
|
async gameSession(e) {
|
|
1845
1863
|
const t = await this.client.request(
|
|
1846
|
-
|
|
1864
|
+
Oe.legacy,
|
|
1847
1865
|
e
|
|
1848
1866
|
);
|
|
1849
1867
|
return t.ok ? {
|
|
@@ -1852,16 +1870,16 @@ class $t {
|
|
|
1852
1870
|
} : t;
|
|
1853
1871
|
}
|
|
1854
1872
|
async createGameSession(e) {
|
|
1855
|
-
const t = await this.client.request(
|
|
1873
|
+
const t = await this.client.request($e, e);
|
|
1856
1874
|
return t.ok ? t.data.createGameSession ? {
|
|
1857
1875
|
ok: !1,
|
|
1858
|
-
error:
|
|
1876
|
+
error: l(t.data.createGameSession.__typename)
|
|
1859
1877
|
} : {
|
|
1860
1878
|
ok: !0
|
|
1861
1879
|
} : t;
|
|
1862
1880
|
}
|
|
1863
1881
|
async endGameSession(e) {
|
|
1864
|
-
const t = await this.client.request(
|
|
1882
|
+
const t = await this.client.request(Ue.legacy, e);
|
|
1865
1883
|
return t.ok ? t.data.endGameSession ? {
|
|
1866
1884
|
ok: !1,
|
|
1867
1885
|
error: {
|
|
@@ -1873,98 +1891,98 @@ class $t {
|
|
|
1873
1891
|
} : t;
|
|
1874
1892
|
}
|
|
1875
1893
|
}
|
|
1876
|
-
class
|
|
1894
|
+
class ra {
|
|
1877
1895
|
constructor(e) {
|
|
1878
1896
|
c(this, "client");
|
|
1879
1897
|
this.client = e;
|
|
1880
1898
|
}
|
|
1881
1899
|
async latestBetRecords() {
|
|
1882
|
-
const e = await this.client.request(
|
|
1900
|
+
const e = await this.client.request(pt);
|
|
1883
1901
|
return e.ok ? {
|
|
1884
1902
|
ok: !0,
|
|
1885
1903
|
data: e.data.latestBetRecords
|
|
1886
1904
|
} : e;
|
|
1887
1905
|
}
|
|
1888
1906
|
async platform() {
|
|
1889
|
-
const e = await this.client.request(
|
|
1907
|
+
const e = await this.client.request(xt);
|
|
1890
1908
|
return e.ok ? {
|
|
1891
1909
|
ok: !0,
|
|
1892
1910
|
data: e.data
|
|
1893
1911
|
} : e;
|
|
1894
1912
|
}
|
|
1895
1913
|
}
|
|
1896
|
-
class
|
|
1914
|
+
class na {
|
|
1897
1915
|
constructor(e) {
|
|
1898
1916
|
c(this, "client");
|
|
1899
1917
|
this.client = e;
|
|
1900
1918
|
}
|
|
1901
1919
|
async betRecords(e) {
|
|
1902
1920
|
const t = await this.client.request(
|
|
1903
|
-
|
|
1921
|
+
dt,
|
|
1904
1922
|
e
|
|
1905
1923
|
);
|
|
1906
1924
|
return t.ok ? { ok: t.ok, data: t.data.member.betRecords } : t;
|
|
1907
1925
|
}
|
|
1908
1926
|
async transactionRecords(e) {
|
|
1909
|
-
const t = await this.client.request(
|
|
1927
|
+
const t = await this.client.request(ft, e);
|
|
1910
1928
|
return t.ok ? { ok: t.ok, data: t.data.member.transactionRecords } : t;
|
|
1911
1929
|
}
|
|
1912
1930
|
async withdrawalRecords(e) {
|
|
1913
1931
|
const t = await this.client.request(
|
|
1914
|
-
|
|
1932
|
+
Xe,
|
|
1915
1933
|
e
|
|
1916
1934
|
);
|
|
1917
1935
|
return t.ok ? { ok: t.ok, data: t.data.member.withdrawalRecords } : t;
|
|
1918
1936
|
}
|
|
1919
1937
|
async depositRecords(e) {
|
|
1920
1938
|
const t = await this.client.request(
|
|
1921
|
-
|
|
1939
|
+
nt,
|
|
1922
1940
|
e
|
|
1923
1941
|
);
|
|
1924
1942
|
return t.ok ? { ok: t.ok, data: t.data.member.depositRecords } : t;
|
|
1925
1943
|
}
|
|
1926
1944
|
async depositsCount() {
|
|
1927
|
-
const e = await this.client.request(
|
|
1945
|
+
const e = await this.client.request(ut);
|
|
1928
1946
|
return e.ok ? { ok: e.ok, data: e.data.member.depositsCount } : e;
|
|
1929
1947
|
}
|
|
1930
1948
|
async pointsWalletTransactions(e) {
|
|
1931
|
-
const t = await this.client.request(
|
|
1949
|
+
const t = await this.client.request(ze, e);
|
|
1932
1950
|
return t.ok ? { ok: t.ok, data: t.data.member.pointsWalletTransactions } : t;
|
|
1933
1951
|
}
|
|
1934
1952
|
async activityRecords(e) {
|
|
1935
1953
|
const t = await this.client.request(
|
|
1936
|
-
|
|
1954
|
+
Bt,
|
|
1937
1955
|
e
|
|
1938
1956
|
);
|
|
1939
1957
|
return t.ok ? { ok: t.ok, data: t.data.member.activityRecords } : t;
|
|
1940
1958
|
}
|
|
1941
1959
|
async referrals(e) {
|
|
1942
1960
|
const t = await this.client.request(
|
|
1943
|
-
|
|
1961
|
+
Lt,
|
|
1944
1962
|
e
|
|
1945
1963
|
);
|
|
1946
1964
|
return t.ok ? { ok: t.ok, data: t.data.member.referrals } : t;
|
|
1947
1965
|
}
|
|
1948
1966
|
async referralCommission() {
|
|
1949
|
-
const e = await this.client.request(
|
|
1967
|
+
const e = await this.client.request(Yt);
|
|
1950
1968
|
return e.ok ? { ok: e.ok, data: e.data.member.referralCommission } : e;
|
|
1951
1969
|
}
|
|
1952
1970
|
async uplinesByName(e) {
|
|
1953
1971
|
const t = await this.client.request(
|
|
1954
|
-
|
|
1972
|
+
Vt,
|
|
1955
1973
|
e
|
|
1956
1974
|
);
|
|
1957
1975
|
return t.ok ? { ok: t.ok, data: t.data.uplinesByName } : t;
|
|
1958
1976
|
}
|
|
1959
1977
|
async downlinesByName(e) {
|
|
1960
1978
|
const t = await this.client.request(
|
|
1961
|
-
|
|
1979
|
+
Ht,
|
|
1962
1980
|
e
|
|
1963
1981
|
);
|
|
1964
1982
|
return t.ok ? { ok: t.ok, data: t.data.downlinesByName } : t;
|
|
1965
1983
|
}
|
|
1966
1984
|
}
|
|
1967
|
-
class
|
|
1985
|
+
class ia {
|
|
1968
1986
|
constructor(e) {
|
|
1969
1987
|
c(this, "url");
|
|
1970
1988
|
this.url = e.url;
|
|
@@ -1976,21 +1994,21 @@ class qt {
|
|
|
1976
1994
|
];
|
|
1977
1995
|
}
|
|
1978
1996
|
}
|
|
1979
|
-
class
|
|
1997
|
+
class oa {
|
|
1980
1998
|
constructor(e) {
|
|
1981
1999
|
c(this, "client");
|
|
1982
2000
|
this.client = e;
|
|
1983
2001
|
}
|
|
1984
2002
|
async messages(e) {
|
|
1985
2003
|
const t = await this.client.request(
|
|
1986
|
-
|
|
2004
|
+
jt,
|
|
1987
2005
|
e
|
|
1988
2006
|
);
|
|
1989
2007
|
return t.ok ? { ok: t.ok, data: t.data.messages } : t;
|
|
1990
2008
|
}
|
|
1991
2009
|
async unreadMessagesCount(e) {
|
|
1992
2010
|
const t = await this.client.request(
|
|
1993
|
-
|
|
2011
|
+
Kt,
|
|
1994
2012
|
{
|
|
1995
2013
|
...e,
|
|
1996
2014
|
filter: {
|
|
@@ -2004,7 +2022,7 @@ class Ft {
|
|
|
2004
2022
|
return t.ok ? { ok: t.ok, data: t.data.messages.totalCount } : t;
|
|
2005
2023
|
}
|
|
2006
2024
|
async markMessageAsRead(e) {
|
|
2007
|
-
const t = await this.client.request(
|
|
2025
|
+
const t = await this.client.request(zt, e);
|
|
2008
2026
|
return t.ok ? t.data.markMessageAsRead ? {
|
|
2009
2027
|
ok: !0
|
|
2010
2028
|
} : {
|
|
@@ -2017,7 +2035,7 @@ class Ft {
|
|
|
2017
2035
|
}
|
|
2018
2036
|
async markAllMessageAsRead() {
|
|
2019
2037
|
const e = await this.client.request(
|
|
2020
|
-
|
|
2038
|
+
Jt
|
|
2021
2039
|
);
|
|
2022
2040
|
return e.ok ? e.data.markAllMessageAsRead ? {
|
|
2023
2041
|
ok: !0
|
|
@@ -2030,35 +2048,35 @@ class Ft {
|
|
|
2030
2048
|
} : e;
|
|
2031
2049
|
}
|
|
2032
2050
|
}
|
|
2033
|
-
class
|
|
2051
|
+
class sa {
|
|
2034
2052
|
constructor(e) {
|
|
2035
2053
|
c(this, "client");
|
|
2036
2054
|
this.client = e;
|
|
2037
2055
|
}
|
|
2038
2056
|
async promos() {
|
|
2039
|
-
const e = await this.client.request(
|
|
2057
|
+
const e = await this.client.request(wt);
|
|
2040
2058
|
return e.ok ? { ok: e.ok, data: e.data.promos } : e;
|
|
2041
2059
|
}
|
|
2042
2060
|
async cashbacks() {
|
|
2043
|
-
const e = await this.client.request(
|
|
2061
|
+
const e = await this.client.request(ht);
|
|
2044
2062
|
return e.ok ? { ok: e.ok, data: e.data.cashbacks } : e;
|
|
2045
2063
|
}
|
|
2046
2064
|
async availablePromos(e) {
|
|
2047
2065
|
const t = await this.client.request(
|
|
2048
|
-
|
|
2066
|
+
yt,
|
|
2049
2067
|
e
|
|
2050
2068
|
);
|
|
2051
2069
|
return t.ok ? { ok: t.ok, data: t.data.availablePromos } : t;
|
|
2052
2070
|
}
|
|
2053
2071
|
async cashbackBonuses() {
|
|
2054
|
-
const e = await this.client.request(
|
|
2072
|
+
const e = await this.client.request(bt);
|
|
2055
2073
|
return e.ok ? { ok: e.ok, data: e.data.cashbackBonuses } : e;
|
|
2056
2074
|
}
|
|
2057
2075
|
async claimCashbackBonus(e) {
|
|
2058
|
-
const t = await this.client.request(
|
|
2076
|
+
const t = await this.client.request(Et, e);
|
|
2059
2077
|
return t.ok ? t.data.claimCashbackBonus ? {
|
|
2060
2078
|
ok: !1,
|
|
2061
|
-
error:
|
|
2079
|
+
error: l(t.data.claimCashbackBonus.__typename)
|
|
2062
2080
|
} : {
|
|
2063
2081
|
ok: !0
|
|
2064
2082
|
} : {
|
|
@@ -2067,146 +2085,146 @@ class Lt {
|
|
|
2067
2085
|
};
|
|
2068
2086
|
}
|
|
2069
2087
|
async bonus() {
|
|
2070
|
-
const e = await this.client.request(
|
|
2088
|
+
const e = await this.client.request(gt);
|
|
2071
2089
|
return e.ok ? { ok: e.ok, data: e.data.bonus } : e;
|
|
2072
2090
|
}
|
|
2073
2091
|
async wallet() {
|
|
2074
|
-
const e = await this.client.request(
|
|
2092
|
+
const e = await this.client.request(Qe);
|
|
2075
2093
|
return e.ok ? { ok: e.ok, data: e.data.wallet } : e;
|
|
2076
2094
|
}
|
|
2077
2095
|
async deposit(e) {
|
|
2078
2096
|
const t = await this.client.request(
|
|
2079
|
-
|
|
2097
|
+
lt,
|
|
2080
2098
|
e
|
|
2081
2099
|
);
|
|
2082
2100
|
return t.ok ? { ok: t.ok, data: t.data.node } : t;
|
|
2083
2101
|
}
|
|
2084
2102
|
async createGCashDeposit(e) {
|
|
2085
|
-
const t = await this.client.request(
|
|
2103
|
+
const t = await this.client.request(it, e);
|
|
2086
2104
|
return t.ok ? t.data.createGCashDeposit ? {
|
|
2087
2105
|
ok: !1,
|
|
2088
|
-
error:
|
|
2106
|
+
error: l(t.data.createGCashDeposit.__typename)
|
|
2089
2107
|
} : {
|
|
2090
2108
|
ok: !0
|
|
2091
2109
|
} : t;
|
|
2092
2110
|
}
|
|
2093
2111
|
async createMayaDeposit(e) {
|
|
2094
|
-
const t = await this.client.request(
|
|
2112
|
+
const t = await this.client.request(ot, e);
|
|
2095
2113
|
return t.ok ? t.data.createMayaDeposit ? {
|
|
2096
2114
|
ok: !1,
|
|
2097
|
-
error:
|
|
2115
|
+
error: l(t.data.createMayaDeposit.__typename)
|
|
2098
2116
|
} : {
|
|
2099
2117
|
ok: !0
|
|
2100
2118
|
} : t;
|
|
2101
2119
|
}
|
|
2102
2120
|
async createAIOQRPHDeposit(e) {
|
|
2103
|
-
const t = await this.client.request(
|
|
2121
|
+
const t = await this.client.request(mt, e);
|
|
2104
2122
|
return t.ok ? t.data.createAIOQRPHDeposit ? {
|
|
2105
2123
|
ok: !1,
|
|
2106
|
-
error:
|
|
2124
|
+
error: l(t.data.createAIOQRPHDeposit.__typename)
|
|
2107
2125
|
} : {
|
|
2108
2126
|
ok: !0
|
|
2109
2127
|
} : t;
|
|
2110
2128
|
}
|
|
2111
2129
|
async createAIOOnlineBankDeposit(e) {
|
|
2112
|
-
const t = await this.client.request(
|
|
2130
|
+
const t = await this.client.request(ct, e);
|
|
2113
2131
|
return t.ok ? t.data.createAIOOnlineBankDeposit ? {
|
|
2114
2132
|
ok: !1,
|
|
2115
|
-
error:
|
|
2133
|
+
error: l(t.data.createAIOOnlineBankDeposit.__typename)
|
|
2116
2134
|
} : {
|
|
2117
2135
|
ok: !0
|
|
2118
2136
|
} : t;
|
|
2119
2137
|
}
|
|
2120
2138
|
async createMayaAppDeposit(e) {
|
|
2121
|
-
const t = await this.client.request(
|
|
2139
|
+
const t = await this.client.request(st, e);
|
|
2122
2140
|
return t.ok ? t.data.createMayaAppDeposit ? {
|
|
2123
2141
|
ok: !1,
|
|
2124
|
-
error:
|
|
2142
|
+
error: l(t.data.createMayaAppDeposit.__typename)
|
|
2125
2143
|
} : {
|
|
2126
2144
|
ok: !0
|
|
2127
2145
|
} : t;
|
|
2128
2146
|
}
|
|
2129
2147
|
async createGCashWithdrawal(e) {
|
|
2130
|
-
const t = await this.client.request(
|
|
2148
|
+
const t = await this.client.request(Ze, e);
|
|
2131
2149
|
return t.ok ? t.data.createGCashWithdrawal ? {
|
|
2132
2150
|
ok: !1,
|
|
2133
|
-
error:
|
|
2151
|
+
error: l(t.data.createGCashWithdrawal.__typename)
|
|
2134
2152
|
} : {
|
|
2135
2153
|
ok: !0
|
|
2136
2154
|
} : t;
|
|
2137
2155
|
}
|
|
2138
2156
|
async createMayaWithdrawal(e) {
|
|
2139
|
-
const t = await this.client.request(
|
|
2157
|
+
const t = await this.client.request(et, e);
|
|
2140
2158
|
return t.ok ? t.data.createMayaWithdrawal ? {
|
|
2141
2159
|
ok: !1,
|
|
2142
|
-
error:
|
|
2160
|
+
error: l(t.data.createMayaWithdrawal.__typename)
|
|
2143
2161
|
} : {
|
|
2144
2162
|
ok: !0
|
|
2145
2163
|
} : t;
|
|
2146
2164
|
}
|
|
2147
2165
|
async createMayaAppWithdrawal(e) {
|
|
2148
|
-
const t = await this.client.request(
|
|
2166
|
+
const t = await this.client.request(tt, e);
|
|
2149
2167
|
return t.ok ? t.data.createMayaAppWithdrawal ? {
|
|
2150
2168
|
ok: !1,
|
|
2151
|
-
error:
|
|
2169
|
+
error: l(t.data.createMayaAppWithdrawal.__typename)
|
|
2152
2170
|
} : {
|
|
2153
2171
|
ok: !0
|
|
2154
2172
|
} : t;
|
|
2155
2173
|
}
|
|
2156
2174
|
async createBankWithdrawal(e) {
|
|
2157
|
-
const t = await this.client.request(
|
|
2175
|
+
const t = await this.client.request(at, e);
|
|
2158
2176
|
return t.ok ? t.data.createBankWithdrawal ? {
|
|
2159
2177
|
ok: !1,
|
|
2160
|
-
error:
|
|
2178
|
+
error: l(t.data.createBankWithdrawal.__typename)
|
|
2161
2179
|
} : {
|
|
2162
2180
|
ok: !0
|
|
2163
2181
|
} : t;
|
|
2164
2182
|
}
|
|
2165
2183
|
async remainingDailyWithdrawalsCount() {
|
|
2166
2184
|
const e = await this.client.request(
|
|
2167
|
-
|
|
2185
|
+
rt
|
|
2168
2186
|
);
|
|
2169
2187
|
return e.ok ? { ok: e.ok, data: e.data.remainingDailyWithdrawalsCount } : e;
|
|
2170
2188
|
}
|
|
2171
2189
|
async pointsWallet() {
|
|
2172
|
-
const e = await this.client.request(
|
|
2190
|
+
const e = await this.client.request(je);
|
|
2173
2191
|
return e.ok ? { ok: e.ok, data: e.data.pointsWallet } : e;
|
|
2174
2192
|
}
|
|
2175
2193
|
async redeemPointsToCash(e) {
|
|
2176
|
-
const t = await this.client.request(
|
|
2194
|
+
const t = await this.client.request(Ke, e);
|
|
2177
2195
|
return t.ok ? t.data.redeemPointsToCash ? {
|
|
2178
2196
|
ok: !1,
|
|
2179
|
-
error:
|
|
2197
|
+
error: l(t.data.redeemPointsToCash.__typename)
|
|
2180
2198
|
} : {
|
|
2181
2199
|
ok: !0
|
|
2182
2200
|
} : t;
|
|
2183
2201
|
}
|
|
2184
2202
|
async mayaSession(e) {
|
|
2185
2203
|
const t = await this.client.request(
|
|
2186
|
-
|
|
2204
|
+
$t,
|
|
2187
2205
|
e
|
|
2188
2206
|
);
|
|
2189
2207
|
return t.ok ? { ok: t.ok, data: t.data.mayaSession } : t;
|
|
2190
2208
|
}
|
|
2191
2209
|
async gameSession(e) {
|
|
2192
2210
|
const t = await this.client.request(
|
|
2193
|
-
|
|
2211
|
+
Oe.current,
|
|
2194
2212
|
e
|
|
2195
2213
|
);
|
|
2196
2214
|
return t.ok ? { ok: !0, data: t.data.node } : t;
|
|
2197
2215
|
}
|
|
2198
2216
|
async createGameSession(e) {
|
|
2199
|
-
const t = await this.client.request(
|
|
2217
|
+
const t = await this.client.request($e, e);
|
|
2200
2218
|
return t.ok ? t.data.createGameSession ? {
|
|
2201
2219
|
ok: !1,
|
|
2202
|
-
error:
|
|
2220
|
+
error: l(t.data.createGameSession.__typename)
|
|
2203
2221
|
} : {
|
|
2204
2222
|
ok: !0
|
|
2205
2223
|
} : t;
|
|
2206
2224
|
}
|
|
2207
2225
|
async endGameSession(e) {
|
|
2208
2226
|
const t = await this.client.request(
|
|
2209
|
-
|
|
2227
|
+
Ue.current,
|
|
2210
2228
|
e
|
|
2211
2229
|
);
|
|
2212
2230
|
return t.ok ? t.data.endGameSession ? {
|
|
@@ -2221,7 +2239,7 @@ class Lt {
|
|
|
2221
2239
|
}
|
|
2222
2240
|
async validateMayaSession() {
|
|
2223
2241
|
const e = await this.client.request(
|
|
2224
|
-
|
|
2242
|
+
Ut
|
|
2225
2243
|
);
|
|
2226
2244
|
return e.ok ? e.data.validateMayaSession ? {
|
|
2227
2245
|
ok: !0
|
|
@@ -2234,17 +2252,17 @@ class Lt {
|
|
|
2234
2252
|
} : e;
|
|
2235
2253
|
}
|
|
2236
2254
|
}
|
|
2237
|
-
function
|
|
2238
|
-
return new Date(
|
|
2255
|
+
function Pe(i) {
|
|
2256
|
+
return new Date(i.getTime());
|
|
2239
2257
|
}
|
|
2240
|
-
function B(
|
|
2241
|
-
const t =
|
|
2258
|
+
function B(i, e) {
|
|
2259
|
+
const t = Pe(i);
|
|
2242
2260
|
return t.setMinutes(t.getMinutes() + e), t;
|
|
2243
2261
|
}
|
|
2244
|
-
function
|
|
2245
|
-
return
|
|
2262
|
+
function Re(i, e) {
|
|
2263
|
+
return i.getTime() > e.getTime();
|
|
2246
2264
|
}
|
|
2247
|
-
class
|
|
2265
|
+
class ma {
|
|
2248
2266
|
constructor(e) {
|
|
2249
2267
|
c(this, "config");
|
|
2250
2268
|
c(this, "cache");
|
|
@@ -2254,56 +2272,56 @@ class Vt {
|
|
|
2254
2272
|
};
|
|
2255
2273
|
}
|
|
2256
2274
|
set(e, t) {
|
|
2257
|
-
const
|
|
2275
|
+
const a = B(/* @__PURE__ */ new Date(), this.config.cacheTime);
|
|
2258
2276
|
this.cache[e] = {
|
|
2259
2277
|
value: t,
|
|
2260
|
-
validUntil:
|
|
2278
|
+
validUntil: a
|
|
2261
2279
|
};
|
|
2262
2280
|
}
|
|
2263
2281
|
get(e) {
|
|
2264
2282
|
const t = this.cache[e];
|
|
2265
|
-
return !t ||
|
|
2283
|
+
return !t || Re(/* @__PURE__ */ new Date(), t.validUntil) ? null : t.value;
|
|
2266
2284
|
}
|
|
2267
2285
|
}
|
|
2268
|
-
function
|
|
2269
|
-
return
|
|
2286
|
+
function ca(i, e, t) {
|
|
2287
|
+
return i < e ? e : i > t ? t : i;
|
|
2270
2288
|
}
|
|
2271
|
-
function
|
|
2272
|
-
return Object.prototype.toString.call(
|
|
2289
|
+
function Ne(i) {
|
|
2290
|
+
return Object.prototype.toString.call(i) === "[object Object]" && Object(i) === i;
|
|
2273
2291
|
}
|
|
2274
|
-
function
|
|
2292
|
+
function la(i) {
|
|
2275
2293
|
const e = [];
|
|
2276
|
-
function t(
|
|
2277
|
-
for (const s in
|
|
2278
|
-
const m =
|
|
2279
|
-
|
|
2280
|
-
key: [...
|
|
2294
|
+
function t(a, r = []) {
|
|
2295
|
+
for (const s in a) {
|
|
2296
|
+
const m = a[s];
|
|
2297
|
+
Ne(m) ? t(m, [...r, s]) : Array.isArray(m) ? t(ua(m), [...r, s]) : e.push({
|
|
2298
|
+
key: [...r, s],
|
|
2281
2299
|
value: m
|
|
2282
2300
|
});
|
|
2283
2301
|
}
|
|
2284
2302
|
}
|
|
2285
|
-
return t(
|
|
2303
|
+
return t(i), e;
|
|
2286
2304
|
}
|
|
2287
|
-
function
|
|
2288
|
-
return
|
|
2305
|
+
function ua(i) {
|
|
2306
|
+
return i.reduce((e, t, a) => (e[a] = t, e), {});
|
|
2289
2307
|
}
|
|
2290
2308
|
class U {
|
|
2291
2309
|
constructor(e, t) {
|
|
2292
2310
|
c(this, "url");
|
|
2293
2311
|
c(this, "options");
|
|
2294
2312
|
c(this, "middlewares");
|
|
2295
|
-
var
|
|
2296
|
-
const
|
|
2297
|
-
this.url = e, this.options = { ...t == null ? void 0 : t.fetchOptions, headers:
|
|
2313
|
+
var r;
|
|
2314
|
+
const a = new Headers((r = t == null ? void 0 : t.fetchOptions) == null ? void 0 : r.headers);
|
|
2315
|
+
this.url = e, this.options = { ...t == null ? void 0 : t.fetchOptions, headers: a }, this.middlewares = (t == null ? void 0 : t.middlewares) ?? [];
|
|
2298
2316
|
}
|
|
2299
2317
|
async request(e, t) {
|
|
2300
|
-
const
|
|
2301
|
-
|
|
2318
|
+
const a = JSON.stringify({ query: e, variables: t }), r = new Headers(this.options.headers);
|
|
2319
|
+
r.set("Content-Type", "application/json"), r.set("Accept", "application/json");
|
|
2302
2320
|
const s = await this.runMiddlewares(
|
|
2303
2321
|
new Request(this.url, {
|
|
2304
2322
|
...this.options,
|
|
2305
|
-
body:
|
|
2306
|
-
headers:
|
|
2323
|
+
body: a,
|
|
2324
|
+
headers: r,
|
|
2307
2325
|
method: "POST"
|
|
2308
2326
|
})
|
|
2309
2327
|
);
|
|
@@ -2311,50 +2329,50 @@ class U {
|
|
|
2311
2329
|
}
|
|
2312
2330
|
/** Single file upload */
|
|
2313
2331
|
async upload(e, t) {
|
|
2314
|
-
const
|
|
2315
|
-
|
|
2332
|
+
const a = this.createUploadBody(e, t), r = new Headers(this.options.headers);
|
|
2333
|
+
r.delete("Content-Type");
|
|
2316
2334
|
const s = await this.runMiddlewares(
|
|
2317
2335
|
new Request(this.url, {
|
|
2318
2336
|
...this.options,
|
|
2319
|
-
body:
|
|
2320
|
-
headers:
|
|
2337
|
+
body: a,
|
|
2338
|
+
headers: r,
|
|
2321
2339
|
method: "POST"
|
|
2322
2340
|
})
|
|
2323
2341
|
);
|
|
2324
2342
|
return await this.exec(s);
|
|
2325
2343
|
}
|
|
2326
2344
|
async exec(e) {
|
|
2327
|
-
var t,
|
|
2345
|
+
var t, a, r, s, m, u;
|
|
2328
2346
|
try {
|
|
2329
2347
|
const p = await fetch(e);
|
|
2330
2348
|
if (!p.ok)
|
|
2331
|
-
return { ok: !1, error:
|
|
2332
|
-
const f = await p.json(),
|
|
2333
|
-
return
|
|
2349
|
+
return { ok: !1, error: y(p.status) };
|
|
2350
|
+
const f = await p.json(), w = f.data, d = (t = f.errors) == null ? void 0 : t.at(0);
|
|
2351
|
+
return d ? ((a = d.extensions) == null ? void 0 : a.code) === "FORBIDDEN" || ((r = d.extensions) == null ? void 0 : r.code) === "ACCESS_TOKEN_EXPIRED" ? { ok: !1, error: y(403, d.message) } : ((s = d.extensions) == null ? void 0 : s.code) === "UNAUTHORIZED" ? { ok: !1, error: y(401, d.message) } : ((m = d.extensions) == null ? void 0 : m.code) === "BAD_USER_INPUT" || ((u = d.extensions) == null ? void 0 : u.code) === "BAD_REQUEST" ? { ok: !1, error: y(400, d.message) } : {
|
|
2334
2352
|
ok: !1,
|
|
2335
|
-
error:
|
|
2353
|
+
error: y(500, d.message)
|
|
2336
2354
|
} : {
|
|
2337
2355
|
ok: !0,
|
|
2338
|
-
data:
|
|
2356
|
+
data: w
|
|
2339
2357
|
};
|
|
2340
2358
|
} catch {
|
|
2341
2359
|
return {
|
|
2342
2360
|
ok: !1,
|
|
2343
|
-
error:
|
|
2361
|
+
error: y(500)
|
|
2344
2362
|
};
|
|
2345
2363
|
}
|
|
2346
2364
|
}
|
|
2347
2365
|
async runMiddlewares(e) {
|
|
2348
2366
|
let t = e.clone();
|
|
2349
|
-
for (const
|
|
2350
|
-
t = await
|
|
2367
|
+
for (const a of this.middlewares)
|
|
2368
|
+
t = await a(t);
|
|
2351
2369
|
return t;
|
|
2352
2370
|
}
|
|
2353
2371
|
createUploadBody(e, t) {
|
|
2354
|
-
const
|
|
2372
|
+
const a = la(t).filter(
|
|
2355
2373
|
(m) => m.value instanceof File || m.value instanceof Blob
|
|
2356
|
-
),
|
|
2357
|
-
|
|
2374
|
+
), r = new FormData();
|
|
2375
|
+
r.append(
|
|
2358
2376
|
"operations",
|
|
2359
2377
|
JSON.stringify({
|
|
2360
2378
|
query: e,
|
|
@@ -2362,28 +2380,28 @@ class U {
|
|
|
2362
2380
|
})
|
|
2363
2381
|
);
|
|
2364
2382
|
const s = {};
|
|
2365
|
-
return
|
|
2366
|
-
s[
|
|
2367
|
-
}),
|
|
2368
|
-
|
|
2369
|
-
}),
|
|
2383
|
+
return a.forEach((m, u) => {
|
|
2384
|
+
s[u.toString()] = [`variables.${m.key.join(".")}`];
|
|
2385
|
+
}), r.append("map", JSON.stringify(s)), a.forEach((m, u) => {
|
|
2386
|
+
r.append(u.toString(), m.value);
|
|
2387
|
+
}), r;
|
|
2370
2388
|
}
|
|
2371
2389
|
}
|
|
2372
|
-
function
|
|
2373
|
-
return
|
|
2390
|
+
function da(i) {
|
|
2391
|
+
return i === "INR" ? "en-IN" : i === "MYR" ? "en-MY" : i === "IDR" ? "en-ID" : i === "USD" ? "en-US" : "en-PH";
|
|
2374
2392
|
}
|
|
2375
|
-
function
|
|
2376
|
-
return
|
|
2393
|
+
function pa(i) {
|
|
2394
|
+
return i === "en-IN" ? "+91" : i === "en-MY" ? "+60" : i === "en-ID" ? "+62" : i === "en-US" ? "+1" : "+63";
|
|
2377
2395
|
}
|
|
2378
|
-
function
|
|
2379
|
-
const t =
|
|
2380
|
-
return
|
|
2396
|
+
function x(i, e) {
|
|
2397
|
+
const t = pa(e);
|
|
2398
|
+
return i.startsWith(t) ? i : i.startsWith(t.substring(1)) ? `+${i}` : i.startsWith("0") ? `${t}${i.substring(1)}` : `${t}${i}`;
|
|
2381
2399
|
}
|
|
2382
|
-
async function g(
|
|
2383
|
-
const e = new TextEncoder().encode(
|
|
2400
|
+
async function g(i) {
|
|
2401
|
+
const e = new TextEncoder().encode(i), t = await crypto.subtle.digest("SHA-256", e);
|
|
2384
2402
|
return Array.from(new Uint8Array(t)).map((s) => s.toString(16).padStart(2, "0")).join("");
|
|
2385
2403
|
}
|
|
2386
|
-
class
|
|
2404
|
+
class qe {
|
|
2387
2405
|
constructor(e) {
|
|
2388
2406
|
c(this, "enabled");
|
|
2389
2407
|
this.enabled = (e == null ? void 0 : e.enabled) ?? !0;
|
|
@@ -2401,40 +2419,40 @@ class ke {
|
|
|
2401
2419
|
this.enabled && console.log(`\x1B[32m[success] ${e}`);
|
|
2402
2420
|
}
|
|
2403
2421
|
}
|
|
2404
|
-
function q(
|
|
2405
|
-
const t =
|
|
2422
|
+
function q(i, e) {
|
|
2423
|
+
const t = Pe(i);
|
|
2406
2424
|
return t.setDate(t.getDate() + e), t;
|
|
2407
2425
|
}
|
|
2408
|
-
function
|
|
2426
|
+
function Fe(i) {
|
|
2409
2427
|
return new Promise((e) => {
|
|
2410
|
-
setTimeout(e,
|
|
2428
|
+
setTimeout(e, i);
|
|
2411
2429
|
});
|
|
2412
2430
|
}
|
|
2413
|
-
function
|
|
2431
|
+
function xe(i, e) {
|
|
2414
2432
|
const {
|
|
2415
2433
|
until: t,
|
|
2416
|
-
interval:
|
|
2417
|
-
maxAttempt:
|
|
2434
|
+
interval: a = 1e3,
|
|
2435
|
+
maxAttempt: r = 3
|
|
2418
2436
|
/**/
|
|
2419
2437
|
} = e;
|
|
2420
|
-
async function s(m,
|
|
2421
|
-
const p =
|
|
2422
|
-
return t(f) ? f : p > 1 ? (await
|
|
2438
|
+
async function s(m, u) {
|
|
2439
|
+
const p = u ?? r, f = await i(...m);
|
|
2440
|
+
return t(f) ? f : p > 1 ? (await Fe(a * ((r - p) / 2)), s(m, p - 1)) : f;
|
|
2423
2441
|
}
|
|
2424
2442
|
return async (...m) => await s(m);
|
|
2425
2443
|
}
|
|
2426
|
-
function F(
|
|
2427
|
-
const t =
|
|
2444
|
+
function F(i, e) {
|
|
2445
|
+
const t = Pe(i);
|
|
2428
2446
|
return t.setMinutes(t.getMinutes() - e), t;
|
|
2429
2447
|
}
|
|
2430
|
-
class
|
|
2448
|
+
class fa {
|
|
2431
2449
|
constructor(e) {
|
|
2432
2450
|
c(this, "logger");
|
|
2433
2451
|
c(this, "storageKey", "session");
|
|
2434
2452
|
c(this, "authService");
|
|
2435
2453
|
c(this, "walletService");
|
|
2436
2454
|
c(this, "_refreshing", !1);
|
|
2437
|
-
this.authService = e.authService, this.walletService = e.walletService, this.logger = new
|
|
2455
|
+
this.authService = e.authService, this.walletService = e.walletService, this.logger = new qe({
|
|
2438
2456
|
enabled: e.logs ?? !1
|
|
2439
2457
|
});
|
|
2440
2458
|
}
|
|
@@ -2445,7 +2463,7 @@ class zt {
|
|
|
2445
2463
|
this._refreshing = e;
|
|
2446
2464
|
}
|
|
2447
2465
|
async create(e) {
|
|
2448
|
-
var
|
|
2466
|
+
var r;
|
|
2449
2467
|
if (this.isServer)
|
|
2450
2468
|
return this.logger.warn("'localStorage' is not available on the server."), {
|
|
2451
2469
|
ok: !1,
|
|
@@ -2455,16 +2473,16 @@ class zt {
|
|
|
2455
2473
|
}
|
|
2456
2474
|
};
|
|
2457
2475
|
if (e.type === "MAYA") {
|
|
2458
|
-
const m = await
|
|
2459
|
-
until: (
|
|
2460
|
-
var
|
|
2461
|
-
return
|
|
2476
|
+
const m = await xe(() => this.walletService.mayaSession({ id: e.sessionId }), {
|
|
2477
|
+
until: (w) => {
|
|
2478
|
+
var d;
|
|
2479
|
+
return w.ok && ((d = w.data) == null ? void 0 : d.member) != null;
|
|
2462
2480
|
},
|
|
2463
2481
|
interval: 1e3,
|
|
2464
2482
|
maxAttempt: 5
|
|
2465
2483
|
})();
|
|
2466
2484
|
if (!m.ok) return m;
|
|
2467
|
-
if (!((
|
|
2485
|
+
if (!((r = m.data) != null && r.member))
|
|
2468
2486
|
return {
|
|
2469
2487
|
ok: !1,
|
|
2470
2488
|
error: {
|
|
@@ -2472,8 +2490,8 @@ class zt {
|
|
|
2472
2490
|
message: "Forbidden"
|
|
2473
2491
|
}
|
|
2474
2492
|
};
|
|
2475
|
-
const p = await
|
|
2476
|
-
until: (
|
|
2493
|
+
const p = await xe(() => this.authService.createSession(e), {
|
|
2494
|
+
until: (w) => w.ok,
|
|
2477
2495
|
interval: 1e3,
|
|
2478
2496
|
maxAttempt: 5
|
|
2479
2497
|
})();
|
|
@@ -2536,13 +2554,13 @@ class zt {
|
|
|
2536
2554
|
authenticator: t.data.authenticator
|
|
2537
2555
|
}
|
|
2538
2556
|
};
|
|
2539
|
-
const
|
|
2557
|
+
const a = /* @__PURE__ */ new Date();
|
|
2540
2558
|
return window.localStorage.setItem(
|
|
2541
2559
|
this.storageKey,
|
|
2542
2560
|
JSON.stringify({
|
|
2543
2561
|
...t.data,
|
|
2544
|
-
accessTokenExpiresAt: B(
|
|
2545
|
-
refreshTokenExpiresAt: F(q(
|
|
2562
|
+
accessTokenExpiresAt: B(a, 8).getTime(),
|
|
2563
|
+
refreshTokenExpiresAt: F(q(a, 30), 2).getTime()
|
|
2546
2564
|
})
|
|
2547
2565
|
), {
|
|
2548
2566
|
ok: !0,
|
|
@@ -2552,13 +2570,13 @@ class zt {
|
|
|
2552
2570
|
async createFromAuthenticator(e) {
|
|
2553
2571
|
const t = await this.authService.authenticate(e);
|
|
2554
2572
|
if (t.ok) {
|
|
2555
|
-
const
|
|
2573
|
+
const a = /* @__PURE__ */ new Date();
|
|
2556
2574
|
return this.isServer ? this.logger.warn("'localStorage' is not available on the server.") : window.localStorage.setItem(
|
|
2557
2575
|
this.storageKey,
|
|
2558
2576
|
JSON.stringify({
|
|
2559
2577
|
...t.data,
|
|
2560
|
-
accessTokenExpiresAt: B(
|
|
2561
|
-
refreshTokenExpiresAt: F(q(
|
|
2578
|
+
accessTokenExpiresAt: B(a, 8).getTime(),
|
|
2579
|
+
refreshTokenExpiresAt: F(q(a, 30), 2).getTime()
|
|
2562
2580
|
})
|
|
2563
2581
|
), { ok: !0 };
|
|
2564
2582
|
} else
|
|
@@ -2571,7 +2589,7 @@ class zt {
|
|
|
2571
2589
|
data: null
|
|
2572
2590
|
};
|
|
2573
2591
|
if (this.refreshing)
|
|
2574
|
-
return await
|
|
2592
|
+
return await Fe(1e3), await this.get();
|
|
2575
2593
|
const e = window.localStorage.getItem(this.storageKey);
|
|
2576
2594
|
if (!e)
|
|
2577
2595
|
return {
|
|
@@ -2579,9 +2597,9 @@ class zt {
|
|
|
2579
2597
|
data: null
|
|
2580
2598
|
};
|
|
2581
2599
|
try {
|
|
2582
|
-
let t = JSON.parse(e),
|
|
2583
|
-
const
|
|
2584
|
-
if (
|
|
2600
|
+
let t = JSON.parse(e), a = /* @__PURE__ */ new Date();
|
|
2601
|
+
const r = new Date(t.accessTokenExpiresAt), s = new Date(t.refreshTokenExpiresAt);
|
|
2602
|
+
if (Re(a, s))
|
|
2585
2603
|
return this.logger.warn("Session expired. Logging out.."), window.localStorage.removeItem(this.storageKey), {
|
|
2586
2604
|
ok: !1,
|
|
2587
2605
|
error: {
|
|
@@ -2589,7 +2607,7 @@ class zt {
|
|
|
2589
2607
|
message: "Session expired."
|
|
2590
2608
|
}
|
|
2591
2609
|
};
|
|
2592
|
-
if (
|
|
2610
|
+
if (Re(a, r)) {
|
|
2593
2611
|
this.logger.info("Refreshing session..."), this.refreshing = !0;
|
|
2594
2612
|
const m = await this.authService.refreshSession(t.refreshToken);
|
|
2595
2613
|
if (this.refreshing = !1, !m.ok)
|
|
@@ -2600,11 +2618,11 @@ class zt {
|
|
|
2600
2618
|
ok: !0,
|
|
2601
2619
|
data: t
|
|
2602
2620
|
});
|
|
2603
|
-
this.logger.success("Session refreshed!"),
|
|
2621
|
+
this.logger.success("Session refreshed!"), a = /* @__PURE__ */ new Date(), t = {
|
|
2604
2622
|
...t,
|
|
2605
2623
|
...m.data,
|
|
2606
|
-
accessTokenExpiresAt: B(
|
|
2607
|
-
refreshTokenExpiresAt: F(q(
|
|
2624
|
+
accessTokenExpiresAt: B(a, 8).getTime(),
|
|
2625
|
+
refreshTokenExpiresAt: F(q(a, 30), 2).getTime()
|
|
2608
2626
|
}, window.localStorage.setItem(this.storageKey, JSON.stringify(t));
|
|
2609
2627
|
}
|
|
2610
2628
|
return {
|
|
@@ -2631,11 +2649,11 @@ class zt {
|
|
|
2631
2649
|
(t = e.data) != null && t.accessToken && await this.authService.destroySession(e.data.accessToken), window.localStorage.removeItem(this.storageKey);
|
|
2632
2650
|
}
|
|
2633
2651
|
async verify() {
|
|
2634
|
-
var
|
|
2652
|
+
var a, r, s;
|
|
2635
2653
|
if (this.isServer)
|
|
2636
2654
|
return this.logger.warn("'localStorage' is not available on the server."), !0;
|
|
2637
2655
|
const e = await this.get();
|
|
2638
|
-
if (((
|
|
2656
|
+
if (((a = e.error) == null ? void 0 : a.name) === "InvalidTokenError" || ((r = e.error) == null ? void 0 : r.name) === "SessionExpiredError" || ((s = e.error) == null ? void 0 : s.name) === "AccountBlacklistedError") return !1;
|
|
2639
2657
|
if (!e.data) return !0;
|
|
2640
2658
|
const t = await this.authService.verifySession(e.data.accessToken);
|
|
2641
2659
|
return t || window.localStorage.removeItem(this.storageKey), t;
|
|
@@ -2644,39 +2662,39 @@ class zt {
|
|
|
2644
2662
|
return typeof window > "u";
|
|
2645
2663
|
}
|
|
2646
2664
|
}
|
|
2647
|
-
function b(
|
|
2665
|
+
function b(i) {
|
|
2648
2666
|
const e = {};
|
|
2649
|
-
for (const t in
|
|
2650
|
-
const
|
|
2651
|
-
if (
|
|
2652
|
-
if (
|
|
2653
|
-
e[t] = b(
|
|
2667
|
+
for (const t in i) {
|
|
2668
|
+
const a = i[t];
|
|
2669
|
+
if (a !== null && a !== void 0) {
|
|
2670
|
+
if (Ne(a)) {
|
|
2671
|
+
e[t] = b(a);
|
|
2654
2672
|
continue;
|
|
2655
2673
|
}
|
|
2656
|
-
if (Array.isArray(
|
|
2657
|
-
e[t] =
|
|
2674
|
+
if (Array.isArray(a)) {
|
|
2675
|
+
e[t] = a.map((r) => Ne(r) ? b(r) : r);
|
|
2658
2676
|
continue;
|
|
2659
2677
|
}
|
|
2660
|
-
e[t] =
|
|
2678
|
+
e[t] = a;
|
|
2661
2679
|
}
|
|
2662
2680
|
}
|
|
2663
2681
|
return e;
|
|
2664
2682
|
}
|
|
2665
|
-
function
|
|
2666
|
-
if (typeof
|
|
2667
|
-
return
|
|
2668
|
-
if (typeof
|
|
2669
|
-
const t = Number.parseFloat(
|
|
2683
|
+
function n(i, e) {
|
|
2684
|
+
if (typeof i == "number" && !Number.isNaN(i))
|
|
2685
|
+
return i;
|
|
2686
|
+
if (typeof i == "string") {
|
|
2687
|
+
const t = Number.parseFloat(i);
|
|
2670
2688
|
if (!Number.isNaN(t))
|
|
2671
2689
|
return t;
|
|
2672
2690
|
}
|
|
2673
2691
|
return e;
|
|
2674
2692
|
}
|
|
2675
|
-
class
|
|
2693
|
+
class wa {
|
|
2676
2694
|
constructor(e) {
|
|
2677
2695
|
c(this, "staticService");
|
|
2678
2696
|
const t = (e == null ? void 0 : e.environment) === "development";
|
|
2679
|
-
this.staticService = new
|
|
2697
|
+
this.staticService = new ia({
|
|
2680
2698
|
url: t ? "https://static.development.opexa.io" : "https://static.opexa.io"
|
|
2681
2699
|
});
|
|
2682
2700
|
}
|
|
@@ -2724,90 +2742,117 @@ class Jt {
|
|
|
2724
2742
|
}
|
|
2725
2743
|
/** @deprecated */
|
|
2726
2744
|
platform(e) {
|
|
2727
|
-
var t,
|
|
2745
|
+
var t, a, r, s, m, u, p, f, w, d, k, C, _, T, M, D, h, v, R, A, N, I, G, P, S, W, E, L, V, H, Y, Q, j, K, z, J, X, Z, ee, te, ae, re, ne, ie, oe, se, me, ce, le, ue, de, pe, fe, we, ye, he, ge, be, Ee, Ae, Se, ke, Ce, _e, Te, Me, We;
|
|
2728
2746
|
return {
|
|
2729
2747
|
timezone: e.timezone,
|
|
2730
2748
|
currency: e.currency,
|
|
2731
2749
|
paymentSettings: {
|
|
2732
|
-
minimumFirstDepositAmount:
|
|
2750
|
+
minimumFirstDepositAmount: n(e.minimumFirstDepositAmount),
|
|
2733
2751
|
restrictWithdrawalsToVerifiedMembers: e.restrictWithdrawalsToVerifiedMembers,
|
|
2734
2752
|
depositGateway: {
|
|
2735
2753
|
bank: {
|
|
2736
2754
|
androidEnabled: ((t = e.bankDepositGatewaySettings) == null ? void 0 : t.androidEnabled) ?? !1,
|
|
2737
|
-
iosEnabled: ((
|
|
2738
|
-
webEnabled: ((
|
|
2755
|
+
iosEnabled: ((a = e.bankDepositGatewaySettings) == null ? void 0 : a.iosEnabled) ?? !1,
|
|
2756
|
+
webEnabled: ((r = e.bankDepositGatewaySettings) == null ? void 0 : r.webEnabled) ?? !1,
|
|
2739
2757
|
mobileWebEnabled: ((s = e.bankDepositGatewaySettings) == null ? void 0 : s.mobileWebEnabled) ?? !1,
|
|
2740
|
-
minimumAmount:
|
|
2741
|
-
maximumAmount:
|
|
2758
|
+
minimumAmount: n((m = e.bankDepositGatewaySettings) == null ? void 0 : m.minimumAmount),
|
|
2759
|
+
maximumAmount: n((u = e.bankDepositGatewaySettings) == null ? void 0 : u.maximumAmount)
|
|
2742
2760
|
},
|
|
2743
2761
|
gcash: {
|
|
2744
2762
|
androidEnabled: ((p = e.gcashDepositGatewaySettings) == null ? void 0 : p.androidEnabled) ?? !1,
|
|
2745
2763
|
iosEnabled: ((f = e.gcashDepositGatewaySettings) == null ? void 0 : f.iosEnabled) ?? !1,
|
|
2746
|
-
webEnabled: ((
|
|
2747
|
-
mobileWebEnabled: ((
|
|
2748
|
-
minimumAmount:
|
|
2749
|
-
maximumAmount:
|
|
2764
|
+
webEnabled: ((w = e.gcashDepositGatewaySettings) == null ? void 0 : w.webEnabled) ?? !1,
|
|
2765
|
+
mobileWebEnabled: ((d = e.gcashDepositGatewaySettings) == null ? void 0 : d.mobileWebEnabled) ?? !1,
|
|
2766
|
+
minimumAmount: n((k = e.gcashDepositGatewaySettings) == null ? void 0 : k.minimumAmount),
|
|
2767
|
+
maximumAmount: n((C = e.gcashDepositGatewaySettings) == null ? void 0 : C.maximumAmount)
|
|
2750
2768
|
},
|
|
2751
2769
|
maya: {
|
|
2752
2770
|
androidEnabled: ((_ = e.mayaDepositGatewaySettings) == null ? void 0 : _.androidEnabled) ?? !1,
|
|
2753
2771
|
iosEnabled: ((T = e.mayaDepositGatewaySettings) == null ? void 0 : T.iosEnabled) ?? !1,
|
|
2754
2772
|
webEnabled: ((M = e.mayaDepositGatewaySettings) == null ? void 0 : M.webEnabled) ?? !1,
|
|
2755
|
-
mobileWebEnabled: ((
|
|
2756
|
-
minimumAmount:
|
|
2757
|
-
maximumAmount:
|
|
2773
|
+
mobileWebEnabled: ((D = e.mayaDepositGatewaySettings) == null ? void 0 : D.mobileWebEnabled) ?? !1,
|
|
2774
|
+
minimumAmount: n((h = e.mayaDepositGatewaySettings) == null ? void 0 : h.minimumAmount),
|
|
2775
|
+
maximumAmount: n((v = e.mayaDepositGatewaySettings) == null ? void 0 : v.maximumAmount)
|
|
2758
2776
|
},
|
|
2759
2777
|
mayaApp: {
|
|
2760
|
-
androidEnabled: ((
|
|
2778
|
+
androidEnabled: ((R = e.mayaAppDepositGatewaySettings) == null ? void 0 : R.androidEnabled) ?? !1,
|
|
2761
2779
|
iosEnabled: ((A = e.mayaAppDepositGatewaySettings) == null ? void 0 : A.iosEnabled) ?? !1,
|
|
2762
|
-
webEnabled: ((
|
|
2780
|
+
webEnabled: ((N = e.mayaAppDepositGatewaySettings) == null ? void 0 : N.webEnabled) ?? !1,
|
|
2763
2781
|
mobileWebEnabled: ((I = e.mayaAppDepositGatewaySettings) == null ? void 0 : I.mobileWebEnabled) ?? !1,
|
|
2764
|
-
minimumAmount:
|
|
2765
|
-
maximumAmount:
|
|
2782
|
+
minimumAmount: n((G = e.mayaAppDepositGatewaySettings) == null ? void 0 : G.minimumAmount),
|
|
2783
|
+
maximumAmount: n((P = e.mayaAppDepositGatewaySettings) == null ? void 0 : P.maximumAmount)
|
|
2784
|
+
},
|
|
2785
|
+
onlineBank: {
|
|
2786
|
+
androidEnabled: ((S = e.onlineBankDepositGatewaySettings) == null ? void 0 : S.androidEnabled) ?? !1,
|
|
2787
|
+
iosEnabled: ((W = e.onlineBankDepositGatewaySettings) == null ? void 0 : W.iosEnabled) ?? !1,
|
|
2788
|
+
webEnabled: ((E = e.onlineBankDepositGatewaySettings) == null ? void 0 : E.webEnabled) ?? !1,
|
|
2789
|
+
mobileWebEnabled: ((L = e.onlineBankDepositGatewaySettings) == null ? void 0 : L.mobileWebEnabled) ?? !1,
|
|
2790
|
+
minimumAmount: n((V = e.onlineBankDepositGatewaySettings) == null ? void 0 : V.minimumAmount),
|
|
2791
|
+
maximumAmount: n((H = e.onlineBankDepositGatewaySettings) == null ? void 0 : H.maximumAmount)
|
|
2792
|
+
},
|
|
2793
|
+
qrph: {
|
|
2794
|
+
androidEnabled: ((Y = e.qrphDepositGatewaySettings) == null ? void 0 : Y.androidEnabled) ?? !1,
|
|
2795
|
+
iosEnabled: ((Q = e.qrphDepositGatewaySettings) == null ? void 0 : Q.iosEnabled) ?? !1,
|
|
2796
|
+
webEnabled: ((j = e.qrphDepositGatewaySettings) == null ? void 0 : j.webEnabled) ?? !1,
|
|
2797
|
+
mobileWebEnabled: ((K = e.qrphDepositGatewaySettings) == null ? void 0 : K.mobileWebEnabled) ?? !1,
|
|
2798
|
+
minimumAmount: n((z = e.qrphDepositGatewaySettings) == null ? void 0 : z.minimumAmount),
|
|
2799
|
+
maximumAmount: n((J = e.qrphDepositGatewaySettings) == null ? void 0 : J.maximumAmount)
|
|
2766
2800
|
}
|
|
2767
2801
|
},
|
|
2768
2802
|
withdrawalGateway: {
|
|
2769
2803
|
bank: {
|
|
2770
|
-
androidEnabled: ((
|
|
2771
|
-
iosEnabled: ((
|
|
2772
|
-
webEnabled: ((
|
|
2773
|
-
mobileWebEnabled: ((
|
|
2774
|
-
minimumAmount:
|
|
2775
|
-
maximumAmount:
|
|
2804
|
+
androidEnabled: ((X = e.bankWithdrawalGatewaySettings) == null ? void 0 : X.androidEnabled) ?? !1,
|
|
2805
|
+
iosEnabled: ((Z = e.bankWithdrawalGatewaySettings) == null ? void 0 : Z.iosEnabled) ?? !1,
|
|
2806
|
+
webEnabled: ((ee = e.bankWithdrawalGatewaySettings) == null ? void 0 : ee.webEnabled) ?? !1,
|
|
2807
|
+
mobileWebEnabled: ((te = e.bankWithdrawalGatewaySettings) == null ? void 0 : te.mobileWebEnabled) ?? !1,
|
|
2808
|
+
minimumAmount: n((ae = e.bankWithdrawalGatewaySettings) == null ? void 0 : ae.minimumAmount),
|
|
2809
|
+
maximumAmount: n((re = e.bankWithdrawalGatewaySettings) == null ? void 0 : re.maximumAmount)
|
|
2776
2810
|
},
|
|
2777
2811
|
gcash: {
|
|
2778
|
-
androidEnabled: ((
|
|
2779
|
-
iosEnabled: ((
|
|
2780
|
-
webEnabled: ((
|
|
2781
|
-
mobileWebEnabled: ((
|
|
2782
|
-
minimumAmount:
|
|
2783
|
-
maximumAmount:
|
|
2784
|
-
(
|
|
2812
|
+
androidEnabled: ((ne = e.gcashWithdrawalGatewaySettings) == null ? void 0 : ne.androidEnabled) ?? !1,
|
|
2813
|
+
iosEnabled: ((ie = e.gcashWithdrawalGatewaySettings) == null ? void 0 : ie.iosEnabled) ?? !1,
|
|
2814
|
+
webEnabled: ((oe = e.gcashWithdrawalGatewaySettings) == null ? void 0 : oe.webEnabled) ?? !1,
|
|
2815
|
+
mobileWebEnabled: ((se = e.gcashWithdrawalGatewaySettings) == null ? void 0 : se.mobileWebEnabled) ?? !1,
|
|
2816
|
+
minimumAmount: n((me = e.gcashWithdrawalGatewaySettings) == null ? void 0 : me.minimumAmount),
|
|
2817
|
+
maximumAmount: n(
|
|
2818
|
+
(ce = e.gcashWithdrawalGatewaySettings) == null ? void 0 : ce.maximumAmount,
|
|
2785
2819
|
1e6
|
|
2786
2820
|
)
|
|
2787
2821
|
},
|
|
2788
2822
|
maya: {
|
|
2789
|
-
androidEnabled: ((
|
|
2790
|
-
iosEnabled: ((
|
|
2791
|
-
webEnabled: ((
|
|
2792
|
-
mobileWebEnabled: ((
|
|
2793
|
-
minimumAmount:
|
|
2794
|
-
maximumAmount:
|
|
2823
|
+
androidEnabled: ((le = e.mayaWithdrawalGatewaySettings) == null ? void 0 : le.androidEnabled) ?? !1,
|
|
2824
|
+
iosEnabled: ((ue = e.mayaWithdrawalGatewaySettings) == null ? void 0 : ue.iosEnabled) ?? !1,
|
|
2825
|
+
webEnabled: ((de = e.mayaWithdrawalGatewaySettings) == null ? void 0 : de.webEnabled) ?? !1,
|
|
2826
|
+
mobileWebEnabled: ((pe = e.mayaWithdrawalGatewaySettings) == null ? void 0 : pe.mobileWebEnabled) ?? !1,
|
|
2827
|
+
minimumAmount: n((fe = e.mayaWithdrawalGatewaySettings) == null ? void 0 : fe.minimumAmount),
|
|
2828
|
+
maximumAmount: n((we = e.mayaWithdrawalGatewaySettings) == null ? void 0 : we.maximumAmount)
|
|
2795
2829
|
},
|
|
2796
2830
|
mayaApp: {
|
|
2797
|
-
androidEnabled: ((
|
|
2798
|
-
iosEnabled: ((
|
|
2799
|
-
webEnabled: ((
|
|
2800
|
-
mobileWebEnabled: ((
|
|
2801
|
-
minimumAmount:
|
|
2802
|
-
maximumAmount:
|
|
2803
|
-
(
|
|
2831
|
+
androidEnabled: ((ye = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ye.androidEnabled) ?? !1,
|
|
2832
|
+
iosEnabled: ((he = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : he.iosEnabled) ?? !1,
|
|
2833
|
+
webEnabled: ((ge = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ge.webEnabled) ?? !1,
|
|
2834
|
+
mobileWebEnabled: ((be = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : be.mobileWebEnabled) ?? !1,
|
|
2835
|
+
minimumAmount: n((Ee = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : Ee.minimumAmount),
|
|
2836
|
+
maximumAmount: n(
|
|
2837
|
+
(Ae = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : Ae.maximumAmount,
|
|
2838
|
+
1e6
|
|
2839
|
+
)
|
|
2840
|
+
},
|
|
2841
|
+
instapay: {
|
|
2842
|
+
androidEnabled: ((Se = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Se.androidEnabled) ?? !1,
|
|
2843
|
+
iosEnabled: ((ke = e.instapayWithdrawalGatewaySettings) == null ? void 0 : ke.iosEnabled) ?? !1,
|
|
2844
|
+
webEnabled: ((Ce = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Ce.webEnabled) ?? !1,
|
|
2845
|
+
mobileWebEnabled: ((_e = e.instapayWithdrawalGatewaySettings) == null ? void 0 : _e.mobileWebEnabled) ?? !1,
|
|
2846
|
+
minimumAmount: n((Te = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Te.minimumAmount),
|
|
2847
|
+
maximumAmount: n(
|
|
2848
|
+
(Me = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Me.maximumAmount,
|
|
2804
2849
|
1e6
|
|
2805
2850
|
)
|
|
2806
2851
|
}
|
|
2807
2852
|
}
|
|
2808
2853
|
},
|
|
2809
2854
|
pointsClubSettings: {
|
|
2810
|
-
multiplier:
|
|
2855
|
+
multiplier: n((We = e.pointsClubSettings) == null ? void 0 : We.multiplier, 0)
|
|
2811
2856
|
}
|
|
2812
2857
|
};
|
|
2813
2858
|
}
|
|
@@ -2815,86 +2860,113 @@ class Jt {
|
|
|
2815
2860
|
return {
|
|
2816
2861
|
currency: e.currency,
|
|
2817
2862
|
timezone: e.timezone,
|
|
2818
|
-
locale:
|
|
2863
|
+
locale: da(e.currency)
|
|
2819
2864
|
};
|
|
2820
2865
|
}
|
|
2821
2866
|
pointsClubSettings(e) {
|
|
2822
2867
|
return {
|
|
2823
|
-
multiplier:
|
|
2868
|
+
multiplier: n(e.multiplier, 0)
|
|
2824
2869
|
};
|
|
2825
2870
|
}
|
|
2826
2871
|
paymentSettings(e) {
|
|
2827
|
-
var t,
|
|
2872
|
+
var t, a, r, s, m, u, p, f, w, d, k, C, _, T, M, D, h, v, R, A, N, I, G, P, S, W, E, L, V, H, Y, Q, j, K, z, J, X, Z, ee, te, ae, re, ne, ie, oe, se, me, ce, le, ue, de, pe, fe, we, ye, he, ge, be, Ee, Ae, Se, ke, Ce, _e, Te, Me;
|
|
2828
2873
|
return {
|
|
2829
|
-
minimumFirstDepositAmount:
|
|
2874
|
+
minimumFirstDepositAmount: n(e.minimumFirstDepositAmount),
|
|
2830
2875
|
restrictWithdrawalsToVerifiedMembers: e.restrictWithdrawalsToVerifiedMembers,
|
|
2831
2876
|
depositGateway: {
|
|
2832
2877
|
bank: {
|
|
2833
2878
|
androidEnabled: ((t = e.bankDepositGatewaySettings) == null ? void 0 : t.androidEnabled) ?? !1,
|
|
2834
|
-
iosEnabled: ((
|
|
2835
|
-
webEnabled: ((
|
|
2879
|
+
iosEnabled: ((a = e.bankDepositGatewaySettings) == null ? void 0 : a.iosEnabled) ?? !1,
|
|
2880
|
+
webEnabled: ((r = e.bankDepositGatewaySettings) == null ? void 0 : r.webEnabled) ?? !1,
|
|
2836
2881
|
mobileWebEnabled: ((s = e.bankDepositGatewaySettings) == null ? void 0 : s.mobileWebEnabled) ?? !1,
|
|
2837
|
-
minimumAmount:
|
|
2838
|
-
maximumAmount:
|
|
2882
|
+
minimumAmount: n((m = e.bankDepositGatewaySettings) == null ? void 0 : m.minimumAmount),
|
|
2883
|
+
maximumAmount: n((u = e.bankDepositGatewaySettings) == null ? void 0 : u.maximumAmount)
|
|
2839
2884
|
},
|
|
2840
2885
|
gcash: {
|
|
2841
2886
|
androidEnabled: ((p = e.gcashDepositGatewaySettings) == null ? void 0 : p.androidEnabled) ?? !1,
|
|
2842
2887
|
iosEnabled: ((f = e.gcashDepositGatewaySettings) == null ? void 0 : f.iosEnabled) ?? !1,
|
|
2843
|
-
webEnabled: ((
|
|
2844
|
-
mobileWebEnabled: ((
|
|
2845
|
-
minimumAmount:
|
|
2846
|
-
maximumAmount:
|
|
2888
|
+
webEnabled: ((w = e.gcashDepositGatewaySettings) == null ? void 0 : w.webEnabled) ?? !1,
|
|
2889
|
+
mobileWebEnabled: ((d = e.gcashDepositGatewaySettings) == null ? void 0 : d.mobileWebEnabled) ?? !1,
|
|
2890
|
+
minimumAmount: n((k = e.gcashDepositGatewaySettings) == null ? void 0 : k.minimumAmount),
|
|
2891
|
+
maximumAmount: n((C = e.gcashDepositGatewaySettings) == null ? void 0 : C.maximumAmount)
|
|
2847
2892
|
},
|
|
2848
2893
|
maya: {
|
|
2849
2894
|
androidEnabled: ((_ = e.mayaDepositGatewaySettings) == null ? void 0 : _.androidEnabled) ?? !1,
|
|
2850
2895
|
iosEnabled: ((T = e.mayaDepositGatewaySettings) == null ? void 0 : T.iosEnabled) ?? !1,
|
|
2851
2896
|
webEnabled: ((M = e.mayaDepositGatewaySettings) == null ? void 0 : M.webEnabled) ?? !1,
|
|
2852
|
-
mobileWebEnabled: ((
|
|
2853
|
-
minimumAmount:
|
|
2854
|
-
maximumAmount:
|
|
2897
|
+
mobileWebEnabled: ((D = e.mayaDepositGatewaySettings) == null ? void 0 : D.mobileWebEnabled) ?? !1,
|
|
2898
|
+
minimumAmount: n((h = e.mayaDepositGatewaySettings) == null ? void 0 : h.minimumAmount),
|
|
2899
|
+
maximumAmount: n((v = e.mayaDepositGatewaySettings) == null ? void 0 : v.maximumAmount)
|
|
2855
2900
|
},
|
|
2856
2901
|
mayaApp: {
|
|
2857
|
-
androidEnabled: ((
|
|
2902
|
+
androidEnabled: ((R = e.mayaAppDepositGatewaySettings) == null ? void 0 : R.androidEnabled) ?? !1,
|
|
2858
2903
|
iosEnabled: ((A = e.mayaAppDepositGatewaySettings) == null ? void 0 : A.iosEnabled) ?? !1,
|
|
2859
|
-
webEnabled: ((
|
|
2904
|
+
webEnabled: ((N = e.mayaAppDepositGatewaySettings) == null ? void 0 : N.webEnabled) ?? !1,
|
|
2860
2905
|
mobileWebEnabled: ((I = e.mayaAppDepositGatewaySettings) == null ? void 0 : I.mobileWebEnabled) ?? !1,
|
|
2861
|
-
minimumAmount:
|
|
2862
|
-
maximumAmount:
|
|
2906
|
+
minimumAmount: n((G = e.mayaAppDepositGatewaySettings) == null ? void 0 : G.minimumAmount),
|
|
2907
|
+
maximumAmount: n((P = e.mayaAppDepositGatewaySettings) == null ? void 0 : P.maximumAmount)
|
|
2908
|
+
},
|
|
2909
|
+
onlineBank: {
|
|
2910
|
+
androidEnabled: ((S = e.onlineBankDepositGatewaySettings) == null ? void 0 : S.androidEnabled) ?? !1,
|
|
2911
|
+
iosEnabled: ((W = e.onlineBankDepositGatewaySettings) == null ? void 0 : W.iosEnabled) ?? !1,
|
|
2912
|
+
webEnabled: ((E = e.onlineBankDepositGatewaySettings) == null ? void 0 : E.webEnabled) ?? !1,
|
|
2913
|
+
mobileWebEnabled: ((L = e.onlineBankDepositGatewaySettings) == null ? void 0 : L.mobileWebEnabled) ?? !1,
|
|
2914
|
+
minimumAmount: n((V = e.onlineBankDepositGatewaySettings) == null ? void 0 : V.minimumAmount),
|
|
2915
|
+
maximumAmount: n((H = e.onlineBankDepositGatewaySettings) == null ? void 0 : H.maximumAmount)
|
|
2916
|
+
},
|
|
2917
|
+
qrph: {
|
|
2918
|
+
androidEnabled: ((Y = e.qrphDepositGatewaySettings) == null ? void 0 : Y.androidEnabled) ?? !1,
|
|
2919
|
+
iosEnabled: ((Q = e.qrphDepositGatewaySettings) == null ? void 0 : Q.iosEnabled) ?? !1,
|
|
2920
|
+
webEnabled: ((j = e.qrphDepositGatewaySettings) == null ? void 0 : j.webEnabled) ?? !1,
|
|
2921
|
+
mobileWebEnabled: ((K = e.qrphDepositGatewaySettings) == null ? void 0 : K.mobileWebEnabled) ?? !1,
|
|
2922
|
+
minimumAmount: n((z = e.qrphDepositGatewaySettings) == null ? void 0 : z.minimumAmount),
|
|
2923
|
+
maximumAmount: n((J = e.qrphDepositGatewaySettings) == null ? void 0 : J.maximumAmount)
|
|
2863
2924
|
}
|
|
2864
2925
|
},
|
|
2865
2926
|
withdrawalGateway: {
|
|
2866
2927
|
bank: {
|
|
2867
|
-
androidEnabled: ((
|
|
2868
|
-
iosEnabled: ((
|
|
2869
|
-
webEnabled: ((
|
|
2870
|
-
mobileWebEnabled: ((
|
|
2871
|
-
minimumAmount:
|
|
2872
|
-
maximumAmount:
|
|
2928
|
+
androidEnabled: ((X = e.bankWithdrawalGatewaySettings) == null ? void 0 : X.androidEnabled) ?? !1,
|
|
2929
|
+
iosEnabled: ((Z = e.bankWithdrawalGatewaySettings) == null ? void 0 : Z.iosEnabled) ?? !1,
|
|
2930
|
+
webEnabled: ((ee = e.bankWithdrawalGatewaySettings) == null ? void 0 : ee.webEnabled) ?? !1,
|
|
2931
|
+
mobileWebEnabled: ((te = e.bankWithdrawalGatewaySettings) == null ? void 0 : te.mobileWebEnabled) ?? !1,
|
|
2932
|
+
minimumAmount: n((ae = e.bankWithdrawalGatewaySettings) == null ? void 0 : ae.minimumAmount),
|
|
2933
|
+
maximumAmount: n((re = e.bankWithdrawalGatewaySettings) == null ? void 0 : re.maximumAmount)
|
|
2873
2934
|
},
|
|
2874
2935
|
gcash: {
|
|
2875
|
-
androidEnabled: ((
|
|
2876
|
-
iosEnabled: ((
|
|
2877
|
-
webEnabled: ((
|
|
2878
|
-
mobileWebEnabled: ((
|
|
2879
|
-
minimumAmount:
|
|
2880
|
-
maximumAmount:
|
|
2936
|
+
androidEnabled: ((ne = e.gcashWithdrawalGatewaySettings) == null ? void 0 : ne.androidEnabled) ?? !1,
|
|
2937
|
+
iosEnabled: ((ie = e.gcashWithdrawalGatewaySettings) == null ? void 0 : ie.iosEnabled) ?? !1,
|
|
2938
|
+
webEnabled: ((oe = e.gcashWithdrawalGatewaySettings) == null ? void 0 : oe.webEnabled) ?? !1,
|
|
2939
|
+
mobileWebEnabled: ((se = e.gcashWithdrawalGatewaySettings) == null ? void 0 : se.mobileWebEnabled) ?? !1,
|
|
2940
|
+
minimumAmount: n((me = e.gcashWithdrawalGatewaySettings) == null ? void 0 : me.minimumAmount),
|
|
2941
|
+
maximumAmount: n((ce = e.gcashWithdrawalGatewaySettings) == null ? void 0 : ce.maximumAmount, 1e6)
|
|
2881
2942
|
},
|
|
2882
2943
|
maya: {
|
|
2883
|
-
androidEnabled: ((
|
|
2884
|
-
iosEnabled: ((
|
|
2885
|
-
webEnabled: ((
|
|
2886
|
-
mobileWebEnabled: ((
|
|
2887
|
-
minimumAmount:
|
|
2888
|
-
maximumAmount:
|
|
2944
|
+
androidEnabled: ((le = e.mayaWithdrawalGatewaySettings) == null ? void 0 : le.androidEnabled) ?? !1,
|
|
2945
|
+
iosEnabled: ((ue = e.mayaWithdrawalGatewaySettings) == null ? void 0 : ue.iosEnabled) ?? !1,
|
|
2946
|
+
webEnabled: ((de = e.mayaWithdrawalGatewaySettings) == null ? void 0 : de.webEnabled) ?? !1,
|
|
2947
|
+
mobileWebEnabled: ((pe = e.mayaWithdrawalGatewaySettings) == null ? void 0 : pe.mobileWebEnabled) ?? !1,
|
|
2948
|
+
minimumAmount: n((fe = e.mayaWithdrawalGatewaySettings) == null ? void 0 : fe.minimumAmount),
|
|
2949
|
+
maximumAmount: n((we = e.mayaWithdrawalGatewaySettings) == null ? void 0 : we.maximumAmount)
|
|
2889
2950
|
},
|
|
2890
2951
|
mayaApp: {
|
|
2891
|
-
androidEnabled: ((
|
|
2892
|
-
iosEnabled: ((
|
|
2893
|
-
webEnabled: ((
|
|
2894
|
-
mobileWebEnabled: ((
|
|
2895
|
-
minimumAmount:
|
|
2896
|
-
maximumAmount:
|
|
2897
|
-
(
|
|
2952
|
+
androidEnabled: ((ye = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ye.androidEnabled) ?? !1,
|
|
2953
|
+
iosEnabled: ((he = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : he.iosEnabled) ?? !1,
|
|
2954
|
+
webEnabled: ((ge = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ge.webEnabled) ?? !1,
|
|
2955
|
+
mobileWebEnabled: ((be = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : be.mobileWebEnabled) ?? !1,
|
|
2956
|
+
minimumAmount: n((Ee = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : Ee.minimumAmount),
|
|
2957
|
+
maximumAmount: n(
|
|
2958
|
+
(Ae = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : Ae.maximumAmount,
|
|
2959
|
+
1e6
|
|
2960
|
+
)
|
|
2961
|
+
},
|
|
2962
|
+
instapay: {
|
|
2963
|
+
androidEnabled: ((Se = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Se.androidEnabled) ?? !1,
|
|
2964
|
+
iosEnabled: ((ke = e.instapayWithdrawalGatewaySettings) == null ? void 0 : ke.iosEnabled) ?? !1,
|
|
2965
|
+
webEnabled: ((Ce = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Ce.webEnabled) ?? !1,
|
|
2966
|
+
mobileWebEnabled: ((_e = e.instapayWithdrawalGatewaySettings) == null ? void 0 : _e.mobileWebEnabled) ?? !1,
|
|
2967
|
+
minimumAmount: n((Te = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Te.minimumAmount),
|
|
2968
|
+
maximumAmount: n(
|
|
2969
|
+
(Me = e.instapayWithdrawalGatewaySettings) == null ? void 0 : Me.maximumAmount,
|
|
2898
2970
|
1e6
|
|
2899
2971
|
)
|
|
2900
2972
|
}
|
|
@@ -2926,7 +2998,7 @@ class Jt {
|
|
|
2926
2998
|
wallet(e) {
|
|
2927
2999
|
return {
|
|
2928
3000
|
id: e.id,
|
|
2929
|
-
balance:
|
|
3001
|
+
balance: n(e.balance, 0),
|
|
2930
3002
|
currency: e.currency,
|
|
2931
3003
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2932
3004
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
@@ -2953,7 +3025,7 @@ class Jt {
|
|
|
2953
3025
|
mobileNumberVerification: e.mobileNumberVerification ?? !1,
|
|
2954
3026
|
personalInformation: e.personalInformation ?? !1,
|
|
2955
3027
|
transactionPassword: e.transactionPassword ?? !1,
|
|
2956
|
-
completionPercentage:
|
|
3028
|
+
completionPercentage: n(e.completionPercentage, 0)
|
|
2957
3029
|
};
|
|
2958
3030
|
}
|
|
2959
3031
|
announcement(e) {
|
|
@@ -2975,9 +3047,9 @@ class Jt {
|
|
|
2975
3047
|
type: e.type,
|
|
2976
3048
|
bank: e.bank,
|
|
2977
3049
|
status: e.status,
|
|
2978
|
-
amount:
|
|
2979
|
-
netAmount:
|
|
2980
|
-
fee:
|
|
3050
|
+
amount: n(e.amount, 0),
|
|
3051
|
+
netAmount: n(e.netAmount, 0),
|
|
3052
|
+
fee: n(e.fee, 0),
|
|
2981
3053
|
reference: e.reference ?? void 0,
|
|
2982
3054
|
withdrawalNumber: e.withdrawalNumber,
|
|
2983
3055
|
recipientMobileNumber: e.recipientMobileNumber ?? void 0,
|
|
@@ -3001,9 +3073,9 @@ class Jt {
|
|
|
3001
3073
|
id: e.id,
|
|
3002
3074
|
type: e.type,
|
|
3003
3075
|
status: e.status,
|
|
3004
|
-
amount:
|
|
3005
|
-
fee:
|
|
3006
|
-
netAmount:
|
|
3076
|
+
amount: n(e.amount, 0),
|
|
3077
|
+
fee: n(e.fee, 0),
|
|
3078
|
+
netAmount: n(e.netAmount, 0),
|
|
3007
3079
|
reference: e.reference ?? void 0,
|
|
3008
3080
|
depositNumber: e.depositNumber,
|
|
3009
3081
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
@@ -3012,16 +3084,16 @@ class Jt {
|
|
|
3012
3084
|
return b(t);
|
|
3013
3085
|
}
|
|
3014
3086
|
betRecord(e) {
|
|
3015
|
-
var
|
|
3087
|
+
var a;
|
|
3016
3088
|
const t = {
|
|
3017
3089
|
id: e.id,
|
|
3018
|
-
bet:
|
|
3019
|
-
payout:
|
|
3090
|
+
bet: n(e.bet, 0),
|
|
3091
|
+
payout: n(e.payout, 0),
|
|
3020
3092
|
status: e.status,
|
|
3021
|
-
jackpotContribution:
|
|
3022
|
-
jackpotPayout:
|
|
3023
|
-
winloss:
|
|
3024
|
-
validBet:
|
|
3093
|
+
jackpotContribution: n(e.jackpotContribution, 0),
|
|
3094
|
+
jackpotPayout: n(e.jackpotPayout, 0),
|
|
3095
|
+
winloss: n(e.winloss),
|
|
3096
|
+
validBet: n(e.validBet, 0),
|
|
3025
3097
|
vendorRoundId: e.vendorRoundId ?? void 0,
|
|
3026
3098
|
game: {
|
|
3027
3099
|
name: e.game.name,
|
|
@@ -3037,7 +3109,7 @@ class Jt {
|
|
|
3037
3109
|
contestName: e.contestName ?? void 0,
|
|
3038
3110
|
externalCategory: e.externalCategory ?? void 0,
|
|
3039
3111
|
metadata: {
|
|
3040
|
-
odds: ((
|
|
3112
|
+
odds: ((a = e.metadata) == null ? void 0 : a.odds) ?? void 0
|
|
3041
3113
|
}
|
|
3042
3114
|
};
|
|
3043
3115
|
return b(t);
|
|
@@ -3052,9 +3124,9 @@ class Jt {
|
|
|
3052
3124
|
images: this.staticService.gameThumbnails(e.game),
|
|
3053
3125
|
provider: e.game.provider
|
|
3054
3126
|
},
|
|
3055
|
-
bet:
|
|
3056
|
-
payout:
|
|
3057
|
-
validBet:
|
|
3127
|
+
bet: n(e.bet, 0),
|
|
3128
|
+
payout: n(e.payout, 0),
|
|
3129
|
+
validBet: n(e.validBet, 0),
|
|
3058
3130
|
dateTimeSettled: new Date(e.dateTimeSettled),
|
|
3059
3131
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
3060
3132
|
};
|
|
@@ -3063,9 +3135,9 @@ class Jt {
|
|
|
3063
3135
|
const t = {
|
|
3064
3136
|
id: e.id,
|
|
3065
3137
|
type: e.type,
|
|
3066
|
-
amount:
|
|
3138
|
+
amount: n(e.amount, 0),
|
|
3067
3139
|
content: e.content ?? void 0,
|
|
3068
|
-
currentBalance:
|
|
3140
|
+
currentBalance: n(e.currentBalance, 0),
|
|
3069
3141
|
referenceNumber: e.referenceNumber,
|
|
3070
3142
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
3071
3143
|
};
|
|
@@ -3100,8 +3172,8 @@ class Jt {
|
|
|
3100
3172
|
status: e.status,
|
|
3101
3173
|
description: e.description,
|
|
3102
3174
|
banner: this.file(e.banner),
|
|
3103
|
-
maximumBonusAmount:
|
|
3104
|
-
minimumBonusAmount:
|
|
3175
|
+
maximumBonusAmount: n(e.maximumBonusAmount),
|
|
3176
|
+
minimumBonusAmount: n(e.minimumBonusAmount),
|
|
3105
3177
|
activationEndDateTime: new Date(e.activationEndDateTime),
|
|
3106
3178
|
activationStartDateTime: new Date(e.activationStartDateTime),
|
|
3107
3179
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
@@ -3114,8 +3186,8 @@ class Jt {
|
|
|
3114
3186
|
name: e.name,
|
|
3115
3187
|
description: e.description,
|
|
3116
3188
|
status: e.status,
|
|
3117
|
-
minimumCashback:
|
|
3118
|
-
maximumMonthlyCashback:
|
|
3189
|
+
minimumCashback: n(e.minimumCashback, 0),
|
|
3190
|
+
maximumMonthlyCashback: n(e.maximumMonthlyCashback),
|
|
3119
3191
|
banner: this.file(e.banner),
|
|
3120
3192
|
activationEndDateTime: new Date(e.activationEndDateTime),
|
|
3121
3193
|
activationStartDateTime: new Date(e.activationStartDateTime),
|
|
@@ -3123,7 +3195,7 @@ class Jt {
|
|
|
3123
3195
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated),
|
|
3124
3196
|
turnoverContributionPercentagePerGameProvider: Object.entries(
|
|
3125
3197
|
e.turnoverContributionPercentagePerGameProvider
|
|
3126
|
-
).reduce((
|
|
3198
|
+
).reduce((a, [r, s]) => (a[r] = n(s, 0), a), {})
|
|
3127
3199
|
};
|
|
3128
3200
|
}
|
|
3129
3201
|
bonus(e) {
|
|
@@ -3133,22 +3205,22 @@ class Jt {
|
|
|
3133
3205
|
deposit: e.deposit ? {
|
|
3134
3206
|
type: e.deposit.type,
|
|
3135
3207
|
status: e.deposit.status,
|
|
3136
|
-
fee:
|
|
3137
|
-
amount:
|
|
3138
|
-
netAmount:
|
|
3208
|
+
fee: n(e.deposit.fee, 0),
|
|
3209
|
+
amount: n(e.deposit.amount, 0),
|
|
3210
|
+
netAmount: n(e.deposit.netAmount, 0),
|
|
3139
3211
|
reference: e.deposit.reference ?? void 0,
|
|
3140
3212
|
dateTimeCreated: new Date(e.deposit.dateTimeCreated),
|
|
3141
3213
|
dateTimeLastUpdated: new Date(e.deposit.dateTimeLastUpdated)
|
|
3142
3214
|
} : void 0,
|
|
3143
|
-
balance:
|
|
3144
|
-
amount:
|
|
3215
|
+
balance: n(e.balance, 0),
|
|
3216
|
+
amount: n(e.amount, 0),
|
|
3145
3217
|
expiration: new Date(e.expiration),
|
|
3146
|
-
turnoverRequirement:
|
|
3147
|
-
currentTurnoverRequirementContribution:
|
|
3218
|
+
turnoverRequirement: n(e.turnoverRequirement, 0),
|
|
3219
|
+
currentTurnoverRequirementContribution: n(
|
|
3148
3220
|
e.currentTurnoverRequirementContribution,
|
|
3149
3221
|
0
|
|
3150
3222
|
),
|
|
3151
|
-
currentTurnoverRequirementContributionPercentage:
|
|
3223
|
+
currentTurnoverRequirementContributionPercentage: n(
|
|
3152
3224
|
e.currentTurnoverRequirementContributionPercentage,
|
|
3153
3225
|
0
|
|
3154
3226
|
),
|
|
@@ -3160,8 +3232,8 @@ class Jt {
|
|
|
3160
3232
|
cashbackBonus(e) {
|
|
3161
3233
|
return {
|
|
3162
3234
|
id: e.id,
|
|
3163
|
-
total:
|
|
3164
|
-
balance:
|
|
3235
|
+
total: n(e.total, 0),
|
|
3236
|
+
balance: n(e.balance, 0),
|
|
3165
3237
|
cashback: this.cashback(e.cashback),
|
|
3166
3238
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
3167
3239
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
@@ -3179,7 +3251,7 @@ class Jt {
|
|
|
3179
3251
|
pointsWallet(e) {
|
|
3180
3252
|
return {
|
|
3181
3253
|
id: e.id,
|
|
3182
|
-
points:
|
|
3254
|
+
points: n(e.points, 0),
|
|
3183
3255
|
account: e.account,
|
|
3184
3256
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
3185
3257
|
};
|
|
@@ -3188,8 +3260,8 @@ class Jt {
|
|
|
3188
3260
|
return {
|
|
3189
3261
|
id: e.id,
|
|
3190
3262
|
type: e.type,
|
|
3191
|
-
amount:
|
|
3192
|
-
balance:
|
|
3263
|
+
amount: n(e.amount, 0),
|
|
3264
|
+
balance: n(e.balance, 0),
|
|
3193
3265
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
3194
3266
|
};
|
|
3195
3267
|
}
|
|
@@ -3197,7 +3269,7 @@ class Jt {
|
|
|
3197
3269
|
const t = {
|
|
3198
3270
|
id: e.id,
|
|
3199
3271
|
type: e.type,
|
|
3200
|
-
amount: e.amount ?
|
|
3272
|
+
amount: e.amount ? n(e.amount, 0) : void 0,
|
|
3201
3273
|
domain: e.domain ?? void 0,
|
|
3202
3274
|
details: e.details,
|
|
3203
3275
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
@@ -3210,18 +3282,18 @@ class Jt {
|
|
|
3210
3282
|
level: e.level,
|
|
3211
3283
|
upline: e.upline,
|
|
3212
3284
|
downline: e.downline,
|
|
3213
|
-
turnover:
|
|
3214
|
-
commission:
|
|
3285
|
+
turnover: n(e.turnover, 0),
|
|
3286
|
+
commission: n(e.commission, 0),
|
|
3215
3287
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
3216
3288
|
};
|
|
3217
3289
|
}
|
|
3218
3290
|
referralCommission(e) {
|
|
3219
3291
|
return {
|
|
3220
3292
|
id: e.id,
|
|
3221
|
-
commission:
|
|
3222
|
-
level1Commission:
|
|
3223
|
-
level2Commission:
|
|
3224
|
-
level3Commission:
|
|
3293
|
+
commission: n(e.commission, 0),
|
|
3294
|
+
level1Commission: n(e.level1Commission, 0),
|
|
3295
|
+
level2Commission: n(e.level2Commission, 0),
|
|
3296
|
+
level3Commission: n(e.level3Commission, 0),
|
|
3225
3297
|
referralsCount: e.referralsCount,
|
|
3226
3298
|
level1ReferralsCount: e.level1ReferralsCount,
|
|
3227
3299
|
level2ReferralsCount: e.level2ReferralsCount,
|
|
@@ -3244,7 +3316,7 @@ class Jt {
|
|
|
3244
3316
|
};
|
|
3245
3317
|
}
|
|
3246
3318
|
}
|
|
3247
|
-
class
|
|
3319
|
+
class ga {
|
|
3248
3320
|
constructor(e) {
|
|
3249
3321
|
c(this, "cmsPortalService");
|
|
3250
3322
|
c(this, "authService");
|
|
@@ -3262,37 +3334,37 @@ class er {
|
|
|
3262
3334
|
const {
|
|
3263
3335
|
/**/
|
|
3264
3336
|
site: t,
|
|
3265
|
-
sitePlatform:
|
|
3266
|
-
platform:
|
|
3337
|
+
sitePlatform: a,
|
|
3338
|
+
platform: r,
|
|
3267
3339
|
environment: s,
|
|
3268
3340
|
logs: m
|
|
3269
|
-
} = e,
|
|
3270
|
-
this.transformer = new
|
|
3341
|
+
} = e, u = s === "production";
|
|
3342
|
+
this.transformer = new wa({
|
|
3271
3343
|
environment: s
|
|
3272
|
-
}), this.logger = new
|
|
3344
|
+
}), this.logger = new qe({
|
|
3273
3345
|
enabled: m ?? !1
|
|
3274
3346
|
});
|
|
3275
|
-
const p =
|
|
3347
|
+
const p = u ? "https://auth.opexa.io" : "https://auth.development.opexa.io", f = u ? "https://wallet.opexa.io/graphql" : "https://wallet.development.opexa.io/graphql", w = u ? "https://report.opexa.io/graphql" : "https://report.development.opexa.io/graphql", d = u ? "https://account.opexa.io/graphql" : "https://account.development.opexa.io/graphql", k = u ? "https://portal.opexa.io/graphql" : "https://portal.development.opexa.io/graphql", C = u ? "https://file.opexa.io/graphql" : "https://file.development.opexa.io/graphql", _ = u ? "https://game.opexa.io/graphql" : "https://game.development.opexa.io/graphql", T = u ? "https://trigger.opexa.io/graphql" : "https://trigger.development.opexa.io/graphql", M = "https://portal-api.opexacms.io/v1", D = new ea({
|
|
3276
3348
|
url: M,
|
|
3277
3349
|
site: t,
|
|
3278
|
-
platform:
|
|
3279
|
-
}),
|
|
3350
|
+
platform: a
|
|
3351
|
+
}), h = {
|
|
3280
3352
|
middlewares: [this.authMiddleware],
|
|
3281
3353
|
fetchOptions: {
|
|
3282
3354
|
headers: {
|
|
3283
3355
|
Role: "MEMBER",
|
|
3284
|
-
"Platform-Code":
|
|
3356
|
+
"Platform-Code": r
|
|
3285
3357
|
}
|
|
3286
3358
|
}
|
|
3287
|
-
},
|
|
3359
|
+
}, v = new aa(new U(_, h)), R = new ta(new U(C, h)), A = new sa(new U(f, h)), N = new Xt(new U(d, h)), I = new na(new U(w, h)), G = new ra(new U(k, h)), P = new oa(new U(T, h)), S = new Zt({
|
|
3288
3360
|
url: p,
|
|
3289
|
-
platform:
|
|
3290
|
-
}),
|
|
3361
|
+
platform: r
|
|
3362
|
+
}), W = new fa({
|
|
3291
3363
|
logs: m,
|
|
3292
3364
|
authService: S,
|
|
3293
3365
|
walletService: A
|
|
3294
3366
|
});
|
|
3295
|
-
this.authService = S, this.gameService =
|
|
3367
|
+
this.authService = S, this.gameService = v, this.fileService = R, this.walletService = A, this.accountService = N, this.reportService = I, this.portalService = G, this.triggerService = P, this.sessionManager = W, this.cmsPortalService = D, this.cache = new ma();
|
|
3296
3368
|
}
|
|
3297
3369
|
get authMiddleware() {
|
|
3298
3370
|
return async (e) => {
|
|
@@ -3303,10 +3375,10 @@ class er {
|
|
|
3303
3375
|
}
|
|
3304
3376
|
get locale() {
|
|
3305
3377
|
return new Promise((e) => {
|
|
3306
|
-
const t = "locale",
|
|
3307
|
-
if (
|
|
3308
|
-
this.platform__next().then((
|
|
3309
|
-
|
|
3378
|
+
const t = "locale", a = this.cache.get(t);
|
|
3379
|
+
if (a) return e(a);
|
|
3380
|
+
this.platform__next().then((r) => {
|
|
3381
|
+
r.ok ? (this.cache.set(t, r.data.locale), e(r.data.locale)) : (this.logger.warn("Failed to fetch currency. Using 'PH' as fallback"), e("en-PH"));
|
|
3310
3382
|
});
|
|
3311
3383
|
});
|
|
3312
3384
|
}
|
|
@@ -3340,7 +3412,7 @@ class er {
|
|
|
3340
3412
|
case "MOBILE_NUMBER": {
|
|
3341
3413
|
const t = await this.sessionManager.create({
|
|
3342
3414
|
type: "MOBILE_NUMBER",
|
|
3343
|
-
mobileNumber:
|
|
3415
|
+
mobileNumber: x(e.mobileNumber, await this.locale),
|
|
3344
3416
|
verificationCode: e.verificationCode
|
|
3345
3417
|
});
|
|
3346
3418
|
return t.ok ? { ok: !0 } : t;
|
|
@@ -3373,13 +3445,13 @@ class er {
|
|
|
3373
3445
|
await this.sessionManager.destroy();
|
|
3374
3446
|
}
|
|
3375
3447
|
watchSession(e) {
|
|
3376
|
-
const t =
|
|
3377
|
-
let
|
|
3378
|
-
const
|
|
3379
|
-
await this.sessionManager.verify() || await e.onInvalid(),
|
|
3448
|
+
const t = ca(e.interval ?? 3e4, 3e4, 6e4);
|
|
3449
|
+
let a = null;
|
|
3450
|
+
const r = () => setTimeout(async () => {
|
|
3451
|
+
await this.sessionManager.verify() || await e.onInvalid(), a = r();
|
|
3380
3452
|
}, t);
|
|
3381
|
-
return
|
|
3382
|
-
|
|
3453
|
+
return a = r(), function() {
|
|
3454
|
+
a && clearTimeout(a);
|
|
3383
3455
|
};
|
|
3384
3456
|
}
|
|
3385
3457
|
async session() {
|
|
@@ -3450,7 +3522,7 @@ class er {
|
|
|
3450
3522
|
* @deprecated use `createAccount__next`
|
|
3451
3523
|
*/
|
|
3452
3524
|
async createAccount(e) {
|
|
3453
|
-
const t = e.id ?? O.generate($.Account).toString(),
|
|
3525
|
+
const t = e.id ?? O.generate($.Account).toString(), a = await this.accountService.registerMemberAccount({
|
|
3454
3526
|
input: {
|
|
3455
3527
|
id: t,
|
|
3456
3528
|
btag: e.btag,
|
|
@@ -3458,38 +3530,38 @@ class er {
|
|
|
3458
3530
|
domain: e.domain,
|
|
3459
3531
|
birthDay: typeof e.dateOfBirth == "string" ? e.dateOfBirth : e.dateOfBirth.toISOString(),
|
|
3460
3532
|
password: await g(e.password),
|
|
3461
|
-
mobileNumber:
|
|
3533
|
+
mobileNumber: x(e.mobileNumber, await this.locale)
|
|
3462
3534
|
},
|
|
3463
3535
|
referralCode: e.referralCode,
|
|
3464
3536
|
verificationCode: e.verificationCode,
|
|
3465
3537
|
reCAPTCHAResponse: e.reCAPTCHAResponse
|
|
3466
3538
|
});
|
|
3467
|
-
return
|
|
3539
|
+
return a.ok ? { ok: !0, data: { id: t } } : a;
|
|
3468
3540
|
}
|
|
3469
3541
|
async createAccount__next(e) {
|
|
3470
3542
|
const t = e.id ?? O.generate($.Account).toString();
|
|
3471
3543
|
if (e.type === "MOBILE_NUMBER") {
|
|
3472
|
-
const
|
|
3544
|
+
const r = await this.accountService.registerMemberAccountViaMobile({
|
|
3473
3545
|
input: {
|
|
3474
3546
|
id: t,
|
|
3475
|
-
mobileNumber:
|
|
3547
|
+
mobileNumber: x(e.mobileNumber, await this.locale)
|
|
3476
3548
|
},
|
|
3477
3549
|
referralCode: e.referralCode,
|
|
3478
3550
|
reCAPTCHAResponse: e.reCAPTCHAResponse,
|
|
3479
3551
|
verificationCode: e.verificationCode
|
|
3480
3552
|
});
|
|
3481
|
-
return
|
|
3553
|
+
return r.ok ? { ok: !0, data: { id: t } } : r;
|
|
3482
3554
|
}
|
|
3483
|
-
const
|
|
3555
|
+
const a = await this.accountService.registerMemberAccount__next({
|
|
3484
3556
|
input: {
|
|
3485
3557
|
id: t,
|
|
3486
3558
|
name: e.name,
|
|
3487
3559
|
password: await g(e.password),
|
|
3488
|
-
mobileNumber: e.mobileNumber ?
|
|
3560
|
+
mobileNumber: e.mobileNumber ? x(e.mobileNumber, await this.locale) : void 0
|
|
3489
3561
|
},
|
|
3490
3562
|
reCAPTCHAResponse: e.reCAPTCHAResponse
|
|
3491
3563
|
});
|
|
3492
|
-
return
|
|
3564
|
+
return a.ok ? { ok: !0, data: { id: t } } : a;
|
|
3493
3565
|
}
|
|
3494
3566
|
async registerMayaAccount(e) {
|
|
3495
3567
|
return await this.accountService.registerMayaMemberAccount({
|
|
@@ -3509,7 +3581,7 @@ class er {
|
|
|
3509
3581
|
password: t.password ? await g(t.password) : void 0,
|
|
3510
3582
|
transactionPassword: t.transactionPassword ? await g(t.transactionPassword) : void 0,
|
|
3511
3583
|
...t.mobileNumber && {
|
|
3512
|
-
mobileNumber:
|
|
3584
|
+
mobileNumber: x(t.mobileNumber, await this.locale)
|
|
3513
3585
|
},
|
|
3514
3586
|
secretAnswer: t.secretAnswer ? await g(t.secretAnswer) : void 0
|
|
3515
3587
|
}
|
|
@@ -3531,13 +3603,13 @@ class er {
|
|
|
3531
3603
|
} : e;
|
|
3532
3604
|
}
|
|
3533
3605
|
async submitVerificationDetails(e) {
|
|
3534
|
-
const t = e.id ?? O.generate($.Verification).toString(),
|
|
3606
|
+
const t = e.id ?? O.generate($.Verification).toString(), a = await this.accountService.createMemberVerification({
|
|
3535
3607
|
input: {
|
|
3536
3608
|
id: t,
|
|
3537
3609
|
...e
|
|
3538
3610
|
}
|
|
3539
3611
|
});
|
|
3540
|
-
return
|
|
3612
|
+
return a.ok ? { ok: !0, data: { id: t } } : a;
|
|
3541
3613
|
}
|
|
3542
3614
|
async updateVerificationDetails(e, t) {
|
|
3543
3615
|
return await this.accountService.updateMemberVerification({
|
|
@@ -3552,7 +3624,7 @@ class er {
|
|
|
3552
3624
|
async resetPassword(e) {
|
|
3553
3625
|
return await this.accountService.resetPassword({
|
|
3554
3626
|
input: {
|
|
3555
|
-
mobileNumber:
|
|
3627
|
+
mobileNumber: x(e.mobileNumber, await this.locale),
|
|
3556
3628
|
newPassword: await g(e.newPassword)
|
|
3557
3629
|
},
|
|
3558
3630
|
verificationCode: e.verificationCode
|
|
@@ -3579,7 +3651,7 @@ class er {
|
|
|
3579
3651
|
return await this.accountService.sendVerificationCode({
|
|
3580
3652
|
input: {
|
|
3581
3653
|
channel: "SMS",
|
|
3582
|
-
recipient:
|
|
3654
|
+
recipient: x(e, await this.locale)
|
|
3583
3655
|
}
|
|
3584
3656
|
});
|
|
3585
3657
|
}
|
|
@@ -3587,7 +3659,7 @@ class er {
|
|
|
3587
3659
|
if (e.type === "SMS")
|
|
3588
3660
|
return this.authService.sendVerificationCode({
|
|
3589
3661
|
channel: "SMS",
|
|
3590
|
-
recipient:
|
|
3662
|
+
recipient: x(e.mobileNumber, await this.locale),
|
|
3591
3663
|
...e.strict && {
|
|
3592
3664
|
verificationType: "MEMBER"
|
|
3593
3665
|
}
|
|
@@ -3619,9 +3691,9 @@ class er {
|
|
|
3619
3691
|
return t.ok ? {
|
|
3620
3692
|
ok: !0,
|
|
3621
3693
|
data: {
|
|
3622
|
-
announcements: t.data.edges.map(({ cursor:
|
|
3623
|
-
...this.transformer.transform.announcement(
|
|
3624
|
-
cursor:
|
|
3694
|
+
announcements: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
3695
|
+
...this.transformer.transform.announcement(r),
|
|
3696
|
+
cursor: a
|
|
3625
3697
|
})),
|
|
3626
3698
|
totalCount: t.data.totalCount,
|
|
3627
3699
|
endCursor: t.data.pageInfo.endCursor ?? void 0,
|
|
@@ -3637,46 +3709,46 @@ class er {
|
|
|
3637
3709
|
async createWithdrawal(e) {
|
|
3638
3710
|
const t = e.id ?? O.generate($.Withdrawal).toString();
|
|
3639
3711
|
if (e.type === "BANK") {
|
|
3640
|
-
const
|
|
3712
|
+
const a = await this.walletService.createBankWithdrawal({
|
|
3641
3713
|
input: {
|
|
3642
3714
|
id: t,
|
|
3643
3715
|
amount: e.amount.toString(),
|
|
3644
3716
|
transactionPassword: await g(e.transactionPassword)
|
|
3645
3717
|
}
|
|
3646
3718
|
});
|
|
3647
|
-
if (!
|
|
3719
|
+
if (!a.ok) return a;
|
|
3648
3720
|
}
|
|
3649
3721
|
if (e.type === "GCASH") {
|
|
3650
|
-
const
|
|
3722
|
+
const a = await this.walletService.createGCashWithdrawal({
|
|
3651
3723
|
input: {
|
|
3652
3724
|
id: t,
|
|
3653
3725
|
amount: e.amount.toString(),
|
|
3654
3726
|
transactionPassword: await g(e.transactionPassword),
|
|
3655
|
-
recipientMobileNumber:
|
|
3727
|
+
recipientMobileNumber: x(e.recipientMobileNumber, await this.locale)
|
|
3656
3728
|
}
|
|
3657
3729
|
});
|
|
3658
|
-
if (!
|
|
3730
|
+
if (!a.ok) return a;
|
|
3659
3731
|
}
|
|
3660
3732
|
if (e.type === "MAYA") {
|
|
3661
|
-
const
|
|
3733
|
+
const a = await this.walletService.createMayaWithdrawal({
|
|
3662
3734
|
input: {
|
|
3663
3735
|
id: t,
|
|
3664
3736
|
amount: e.amount.toString(),
|
|
3665
3737
|
transactionPassword: await g(e.transactionPassword),
|
|
3666
|
-
recipientMobileNumber:
|
|
3738
|
+
recipientMobileNumber: x(e.recipientMobileNumber, await this.locale)
|
|
3667
3739
|
}
|
|
3668
3740
|
});
|
|
3669
|
-
if (!
|
|
3741
|
+
if (!a.ok) return a;
|
|
3670
3742
|
}
|
|
3671
3743
|
if (e.type === "MAYA_APP") {
|
|
3672
|
-
const
|
|
3744
|
+
const a = await this.walletService.createMayaAppWithdrawal({
|
|
3673
3745
|
input: {
|
|
3674
3746
|
id: t,
|
|
3675
3747
|
amount: e.amount.toString(),
|
|
3676
3748
|
transactionPassword: await g(e.transactionPassword)
|
|
3677
3749
|
}
|
|
3678
3750
|
});
|
|
3679
|
-
if (!
|
|
3751
|
+
if (!a.ok) return a;
|
|
3680
3752
|
}
|
|
3681
3753
|
return { ok: !0, data: { id: t } };
|
|
3682
3754
|
}
|
|
@@ -3685,9 +3757,9 @@ class er {
|
|
|
3685
3757
|
return t.ok ? {
|
|
3686
3758
|
ok: !0,
|
|
3687
3759
|
data: {
|
|
3688
|
-
withdrawalRecords: t.data.edges.map(({ cursor:
|
|
3689
|
-
...this.transformer.transform.withdrawalRecord(
|
|
3690
|
-
cursor:
|
|
3760
|
+
withdrawalRecords: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
3761
|
+
...this.transformer.transform.withdrawalRecord(r),
|
|
3762
|
+
cursor: a
|
|
3691
3763
|
})),
|
|
3692
3764
|
totalCount: t.data.totalCount,
|
|
3693
3765
|
endCursor: t.data.pageInfo.endCursor ?? void 0,
|
|
@@ -3706,54 +3778,54 @@ class er {
|
|
|
3706
3778
|
async createDeposit(e) {
|
|
3707
3779
|
const t = e.id ?? O.generate($.Deposit).toString();
|
|
3708
3780
|
if (e.type === "MAYA") {
|
|
3709
|
-
const
|
|
3781
|
+
const a = await this.walletService.createMayaDeposit({
|
|
3710
3782
|
input: {
|
|
3711
3783
|
id: t,
|
|
3712
3784
|
amount: e.amount.toString(),
|
|
3713
3785
|
promo: e.promo
|
|
3714
3786
|
}
|
|
3715
3787
|
});
|
|
3716
|
-
if (!
|
|
3788
|
+
if (!a.ok) return a;
|
|
3717
3789
|
}
|
|
3718
3790
|
if (e.type === "MAYA_APP") {
|
|
3719
|
-
const
|
|
3791
|
+
const a = await this.walletService.createMayaAppDeposit({
|
|
3720
3792
|
input: {
|
|
3721
3793
|
id: t,
|
|
3722
3794
|
amount: e.amount.toString(),
|
|
3723
3795
|
promo: e.promo
|
|
3724
3796
|
}
|
|
3725
3797
|
});
|
|
3726
|
-
if (!
|
|
3798
|
+
if (!a.ok) return a;
|
|
3727
3799
|
}
|
|
3728
3800
|
if (e.type === "GCASH") {
|
|
3729
|
-
const
|
|
3801
|
+
const a = await this.walletService.createGCashDeposit({
|
|
3730
3802
|
input: {
|
|
3731
3803
|
id: t,
|
|
3732
3804
|
amount: e.amount.toString(),
|
|
3733
3805
|
promo: e.promo
|
|
3734
3806
|
}
|
|
3735
3807
|
});
|
|
3736
|
-
if (!
|
|
3808
|
+
if (!a.ok) return a;
|
|
3737
3809
|
}
|
|
3738
3810
|
if (e.type === "AIO_ONLINE_BANK") {
|
|
3739
|
-
const
|
|
3811
|
+
const a = await this.walletService.createAIOOnlineBankDeposit({
|
|
3740
3812
|
input: {
|
|
3741
3813
|
id: t,
|
|
3742
3814
|
amount: e.amount.toString(),
|
|
3743
3815
|
promo: e.promo
|
|
3744
3816
|
}
|
|
3745
3817
|
});
|
|
3746
|
-
if (!
|
|
3818
|
+
if (!a.ok) return a;
|
|
3747
3819
|
}
|
|
3748
3820
|
if (e.type === "AIO_QRPH") {
|
|
3749
|
-
const
|
|
3821
|
+
const a = await this.walletService.createAIOQRPHDeposit({
|
|
3750
3822
|
input: {
|
|
3751
3823
|
id: t,
|
|
3752
3824
|
amount: e.amount.toString(),
|
|
3753
3825
|
promo: e.promo
|
|
3754
3826
|
}
|
|
3755
3827
|
});
|
|
3756
|
-
if (!
|
|
3828
|
+
if (!a.ok) return a;
|
|
3757
3829
|
}
|
|
3758
3830
|
return { ok: !0, data: { id: t } };
|
|
3759
3831
|
}
|
|
@@ -3769,9 +3841,9 @@ class er {
|
|
|
3769
3841
|
return t.ok ? {
|
|
3770
3842
|
ok: !0,
|
|
3771
3843
|
data: {
|
|
3772
|
-
depositRecords: t.data.edges.map(({ cursor:
|
|
3773
|
-
...this.transformer.transform.depositRecord(
|
|
3774
|
-
cursor:
|
|
3844
|
+
depositRecords: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
3845
|
+
...this.transformer.transform.depositRecord(r),
|
|
3846
|
+
cursor: a
|
|
3775
3847
|
})),
|
|
3776
3848
|
totalCount: t.data.totalCount,
|
|
3777
3849
|
endCursor: t.data.pageInfo.endCursor ?? void 0,
|
|
@@ -3816,9 +3888,9 @@ class er {
|
|
|
3816
3888
|
return t.ok ? {
|
|
3817
3889
|
ok: !0,
|
|
3818
3890
|
data: {
|
|
3819
|
-
betRecords: t.data.edges.map(({ cursor:
|
|
3820
|
-
...this.transformer.transform.betRecord(
|
|
3821
|
-
cursor:
|
|
3891
|
+
betRecords: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
3892
|
+
...this.transformer.transform.betRecord(r),
|
|
3893
|
+
cursor: a
|
|
3822
3894
|
})),
|
|
3823
3895
|
totalCount: t.data.totalCount,
|
|
3824
3896
|
endCursor: t.data.pageInfo.endCursor ?? void 0,
|
|
@@ -3843,9 +3915,9 @@ class er {
|
|
|
3843
3915
|
return t.ok ? {
|
|
3844
3916
|
ok: !0,
|
|
3845
3917
|
data: {
|
|
3846
|
-
transactionRecords: t.data.edges.map(({ cursor:
|
|
3847
|
-
...this.transformer.transform.transactionRecord(
|
|
3848
|
-
cursor:
|
|
3918
|
+
transactionRecords: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
3919
|
+
...this.transformer.transform.transactionRecord(r),
|
|
3920
|
+
cursor: a
|
|
3849
3921
|
})),
|
|
3850
3922
|
totalCount: t.data.totalCount,
|
|
3851
3923
|
endCursor: t.data.pageInfo.endCursor ?? void 0,
|
|
@@ -3913,9 +3985,9 @@ class er {
|
|
|
3913
3985
|
return t.ok ? {
|
|
3914
3986
|
ok: !0,
|
|
3915
3987
|
data: {
|
|
3916
|
-
games: t.data.edges.map(({ cursor:
|
|
3917
|
-
...this.transformer.transform.game(
|
|
3918
|
-
cursor:
|
|
3988
|
+
games: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
3989
|
+
...this.transformer.transform.game(r),
|
|
3990
|
+
cursor: a
|
|
3919
3991
|
})),
|
|
3920
3992
|
totalCount: t.data.totalCount,
|
|
3921
3993
|
hasNextPage: t.data.pageInfo.hasNextPage,
|
|
@@ -3931,27 +4003,27 @@ class er {
|
|
|
3931
4003
|
ok: !0,
|
|
3932
4004
|
data: this.transformer.transform.gameSession(t.data)
|
|
3933
4005
|
};
|
|
3934
|
-
const
|
|
3935
|
-
return
|
|
4006
|
+
const a = await this.gameService.gameSession({ id: e });
|
|
4007
|
+
return a.ok ? {
|
|
3936
4008
|
ok: !0,
|
|
3937
|
-
data:
|
|
3938
|
-
} :
|
|
4009
|
+
data: a.data ? this.transformer.transform.gameSession(a.data) : null
|
|
4010
|
+
} : a;
|
|
3939
4011
|
}
|
|
3940
4012
|
async createGameSession(e) {
|
|
3941
4013
|
const t = e.id ?? O.generate($.GameSession).toString();
|
|
3942
4014
|
if (e.game.startsWith("SPORTS:")) {
|
|
3943
4015
|
const f = await O.generateFromKey($.Game, e.game).then(
|
|
3944
|
-
(
|
|
3945
|
-
),
|
|
4016
|
+
(d) => d.toString()
|
|
4017
|
+
), w = await this.gameService.createGameSession({
|
|
3946
4018
|
input: {
|
|
3947
4019
|
id: t,
|
|
3948
4020
|
game: f
|
|
3949
4021
|
}
|
|
3950
4022
|
});
|
|
3951
|
-
return
|
|
4023
|
+
return w.ok ? { ok: !0, data: { id: t } } : w;
|
|
3952
4024
|
}
|
|
3953
|
-
const
|
|
3954
|
-
if (!
|
|
4025
|
+
const r = await this.game(e.game);
|
|
4026
|
+
if (!r.data)
|
|
3955
4027
|
return {
|
|
3956
4028
|
ok: !1,
|
|
3957
4029
|
error: {
|
|
@@ -3959,7 +4031,7 @@ class er {
|
|
|
3959
4031
|
message: "Game does not exist"
|
|
3960
4032
|
}
|
|
3961
4033
|
};
|
|
3962
|
-
const { provider: s, reference: m } =
|
|
4034
|
+
const { provider: s, reference: m } = r.data, p = [
|
|
3963
4035
|
/**/
|
|
3964
4036
|
"RTG",
|
|
3965
4037
|
"DARWIN",
|
|
@@ -3988,13 +4060,13 @@ class er {
|
|
|
3988
4060
|
} : t;
|
|
3989
4061
|
}
|
|
3990
4062
|
async uploadImageFile(e) {
|
|
3991
|
-
const t = e.id ?? O.generate($.File).toString(),
|
|
4063
|
+
const t = e.id ?? O.generate($.File).toString(), a = await this.fileService.uploadPrivateImageFile({
|
|
3992
4064
|
input: {
|
|
3993
4065
|
id: t,
|
|
3994
4066
|
file: e.file
|
|
3995
4067
|
}
|
|
3996
4068
|
});
|
|
3997
|
-
return
|
|
4069
|
+
return a.ok ? { ok: !0, data: { id: t } } : a;
|
|
3998
4070
|
}
|
|
3999
4071
|
/**/
|
|
4000
4072
|
/*+----------------------------------------+*/
|
|
@@ -4020,9 +4092,9 @@ class er {
|
|
|
4020
4092
|
return t.ok ? {
|
|
4021
4093
|
ok: !0,
|
|
4022
4094
|
data: {
|
|
4023
|
-
pointsWalletTransactions: t.data.edges.map(({ cursor:
|
|
4024
|
-
...this.transformer.transform.pointsWalletTransaction(
|
|
4025
|
-
cursor:
|
|
4095
|
+
pointsWalletTransactions: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
4096
|
+
...this.transformer.transform.pointsWalletTransaction(r),
|
|
4097
|
+
cursor: a
|
|
4026
4098
|
})),
|
|
4027
4099
|
totalCount: t.data.totalCount,
|
|
4028
4100
|
hasNextPage: t.data.pageInfo.hasNextPage,
|
|
@@ -4040,9 +4112,9 @@ class er {
|
|
|
4040
4112
|
return t.ok ? {
|
|
4041
4113
|
ok: !0,
|
|
4042
4114
|
data: {
|
|
4043
|
-
activityRecords: t.data.edges.map(({ cursor:
|
|
4044
|
-
...this.transformer.transform.activityRecord(
|
|
4045
|
-
cursor:
|
|
4115
|
+
activityRecords: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
4116
|
+
...this.transformer.transform.activityRecord(r),
|
|
4117
|
+
cursor: a
|
|
4046
4118
|
})),
|
|
4047
4119
|
totalCount: t.data.totalCount,
|
|
4048
4120
|
hasNextPage: t.data.pageInfo.hasNextPage,
|
|
@@ -4070,9 +4142,9 @@ class er {
|
|
|
4070
4142
|
return t.ok ? {
|
|
4071
4143
|
ok: !0,
|
|
4072
4144
|
data: {
|
|
4073
|
-
referrals: t.data.edges.map(({ cursor:
|
|
4074
|
-
...this.transformer.transform.referral(
|
|
4075
|
-
cursor:
|
|
4145
|
+
referrals: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
4146
|
+
...this.transformer.transform.referral(r),
|
|
4147
|
+
cursor: a
|
|
4076
4148
|
})),
|
|
4077
4149
|
totalCount: t.data.totalCount,
|
|
4078
4150
|
hasNextPage: t.data.pageInfo.hasNextPage,
|
|
@@ -4118,9 +4190,9 @@ class er {
|
|
|
4118
4190
|
return t.ok ? {
|
|
4119
4191
|
ok: !0,
|
|
4120
4192
|
data: {
|
|
4121
|
-
messages: t.data.edges.map(({ cursor:
|
|
4122
|
-
...this.transformer.transform.message(
|
|
4123
|
-
cursor:
|
|
4193
|
+
messages: t.data.edges.map(({ cursor: a, node: r }) => ({
|
|
4194
|
+
...this.transformer.transform.message(r),
|
|
4195
|
+
cursor: a
|
|
4124
4196
|
})),
|
|
4125
4197
|
totalCount: t.data.totalCount,
|
|
4126
4198
|
hasNextPage: t.data.pageInfo.hasNextPage,
|
|
@@ -4139,8 +4211,8 @@ class er {
|
|
|
4139
4211
|
}
|
|
4140
4212
|
}
|
|
4141
4213
|
export {
|
|
4142
|
-
|
|
4214
|
+
Aa as ObjectId,
|
|
4143
4215
|
$ as ObjectType,
|
|
4144
|
-
|
|
4216
|
+
ga as Sdk
|
|
4145
4217
|
};
|
|
4146
4218
|
//# sourceMappingURL=index.mjs.map
|