@opexa/portal-sdk 0.0.86 → 0.0.88
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 +137 -75
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +673 -426
- package/dist/index.mjs.map +1 -1
- package/dist/sdk/sdk.d.ts +7 -1
- package/dist/sdk/transformer.d.ts +7 -0
- package/dist/sdk/types.d.ts +34 -9
- package/dist/services/account.service.d.ts +4 -1
- package/dist/services/portal.service.d.ts +2 -1
- package/dist/services/queries.d.ts +4 -0
- package/dist/services/types.d.ts +28 -5
- package/dist/utils/cache.d.ts +15 -0
- package/dist/utils/locale.d.ts +4 -0
- package/dist/utils/mobile-number.d.ts +7 -5
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { ObjectId as
|
|
5
|
-
import { ObjectId as
|
|
6
|
-
const
|
|
1
|
+
var _e = Object.defineProperty;
|
|
2
|
+
var Te = (n, e, t) => e in n ? _e(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
|
|
3
|
+
var c = (n, e, t) => Te(n, typeof e != "symbol" ? e + "" : e, t);
|
|
4
|
+
import { ObjectId as $ } from "@opexa/object-id";
|
|
5
|
+
import { ObjectId as zt } from "@opexa/object-id";
|
|
6
|
+
const U = {
|
|
7
7
|
Account: 8,
|
|
8
8
|
Deposit: 9,
|
|
9
9
|
Withdrawal: 14,
|
|
@@ -13,23 +13,23 @@ const T = {
|
|
|
13
13
|
GameSession: 204,
|
|
14
14
|
MayaSession: 230
|
|
15
15
|
};
|
|
16
|
-
function
|
|
16
|
+
function o(n, ...e) {
|
|
17
17
|
let t = "";
|
|
18
|
-
for (const [r, a] of
|
|
18
|
+
for (const [r, a] of n.entries()) {
|
|
19
19
|
const s = e.at(r) ?? "";
|
|
20
20
|
t = `${t}${a}${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
|
-
`, ve =
|
|
32
|
-
${
|
|
31
|
+
`, ve = o`
|
|
32
|
+
${de}
|
|
33
33
|
|
|
34
34
|
query File($id: ObjectId!) {
|
|
35
35
|
node(id: $id) {
|
|
@@ -38,7 +38,7 @@ const L = i`
|
|
|
38
38
|
}
|
|
39
39
|
}
|
|
40
40
|
}
|
|
41
|
-
`, Me =
|
|
41
|
+
`, Me = o`
|
|
42
42
|
mutation UploadPrivateImageFile($input: UploadFileInput!) {
|
|
43
43
|
uploadPrivateImageFile(input: $input) {
|
|
44
44
|
... on FileFormatNotSupportedError {
|
|
@@ -52,7 +52,7 @@ const L = i`
|
|
|
52
52
|
}
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
|
-
`, Re =
|
|
55
|
+
`, Re = o`
|
|
56
56
|
query Wallet {
|
|
57
57
|
wallet {
|
|
58
58
|
id
|
|
@@ -62,7 +62,7 @@ const L = i`
|
|
|
62
62
|
dateTimeLastUpdated
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
|
-
`, Ne =
|
|
65
|
+
`, Ne = o`
|
|
66
66
|
query PointsWallet {
|
|
67
67
|
pointsWallet {
|
|
68
68
|
id
|
|
@@ -71,7 +71,7 @@ const L = i`
|
|
|
71
71
|
dateTimeCreated
|
|
72
72
|
}
|
|
73
73
|
}
|
|
74
|
-
`,
|
|
74
|
+
`, De = o`
|
|
75
75
|
mutation RedeemPointsToCash($input: RedeemPointsToCashInput!) {
|
|
76
76
|
redeemPointsToCash(input: $input) {
|
|
77
77
|
... on InsufficientPointsError {
|
|
@@ -79,7 +79,7 @@ const L = i`
|
|
|
79
79
|
}
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
|
-
`,
|
|
82
|
+
`, Ie = o`
|
|
83
83
|
query PointsWalletTransactions(
|
|
84
84
|
$first: Int
|
|
85
85
|
$after: Cursor
|
|
@@ -107,8 +107,8 @@ const L = i`
|
|
|
107
107
|
}
|
|
108
108
|
}
|
|
109
109
|
}
|
|
110
|
-
`,
|
|
111
|
-
current:
|
|
110
|
+
`, be = {
|
|
111
|
+
current: o`
|
|
112
112
|
query GameSession($id: ObjectId!) {
|
|
113
113
|
node(id: $id) {
|
|
114
114
|
... on GameSession {
|
|
@@ -122,7 +122,7 @@ const L = 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 L = i`
|
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
140
|
`
|
|
141
|
-
},
|
|
141
|
+
}, Ee = o`
|
|
142
142
|
mutation CreateGameSession($input: CreateGameSessionInput!) {
|
|
143
143
|
createGameSession(input: $input) {
|
|
144
144
|
... on GameDoesNotExistError {
|
|
@@ -146,13 +146,13 @@ const L = i`
|
|
|
146
146
|
}
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
|
-
`,
|
|
150
|
-
current:
|
|
149
|
+
`, Se = {
|
|
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 L = i`
|
|
|
167
167
|
}
|
|
168
168
|
}
|
|
169
169
|
`
|
|
170
|
-
},
|
|
170
|
+
}, Ge = 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 L = i`
|
|
|
193
193
|
}
|
|
194
194
|
}
|
|
195
195
|
}
|
|
196
|
-
`,
|
|
196
|
+
`, Pe = 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 L = i`
|
|
|
260
260
|
}
|
|
261
261
|
}
|
|
262
262
|
}
|
|
263
|
-
`,
|
|
263
|
+
`, We = o`
|
|
264
264
|
mutation CreateGCashWithdrawal($input: CreateGCashWithdrawalInput!) {
|
|
265
265
|
createGCashWithdrawal(input: $input) {
|
|
266
266
|
... on AccountNotVerifiedError {
|
|
@@ -283,7 +283,7 @@ const L = i`
|
|
|
283
283
|
}
|
|
284
284
|
}
|
|
285
285
|
}
|
|
286
|
-
`,
|
|
286
|
+
`, xe = o`
|
|
287
287
|
mutation CreateMayaWithdrawal($input: CreateMayaWithdrawalInput!) {
|
|
288
288
|
createMayaWithdrawal(input: $input) {
|
|
289
289
|
... on AccountNotVerifiedError {
|
|
@@ -306,7 +306,7 @@ const L = i`
|
|
|
306
306
|
}
|
|
307
307
|
}
|
|
308
308
|
}
|
|
309
|
-
`,
|
|
309
|
+
`, $e = o`
|
|
310
310
|
mutation CreateMayaAppWithdrawal($input: CreateMayaAppWithdrawalInput!) {
|
|
311
311
|
createMayaAppWithdrawal(input: $input) {
|
|
312
312
|
... on AccountNotVerifiedError {
|
|
@@ -326,7 +326,7 @@ const L = i`
|
|
|
326
326
|
}
|
|
327
327
|
}
|
|
328
328
|
}
|
|
329
|
-
`,
|
|
329
|
+
`, Ue = o`
|
|
330
330
|
mutation CreateBankWithdrawal($input: CreateBankWithdrawalInput!) {
|
|
331
331
|
createBankWithdrawal(input: $input) {
|
|
332
332
|
... on MobileNumberNotVerifiedError {
|
|
@@ -349,11 +349,11 @@ const L = i`
|
|
|
349
349
|
}
|
|
350
350
|
}
|
|
351
351
|
}
|
|
352
|
-
`,
|
|
352
|
+
`, Oe = o`
|
|
353
353
|
query RemainingDailyWithdrawalsCount {
|
|
354
354
|
remainingDailyWithdrawalsCount
|
|
355
355
|
}
|
|
356
|
-
`, Be =
|
|
356
|
+
`, Be = 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 L = i`
|
|
|
382
382
|
}
|
|
383
383
|
}
|
|
384
384
|
}
|
|
385
|
-
`, qe =
|
|
385
|
+
`, qe = o`
|
|
386
386
|
mutation CreateGCashDeposit($input: CreateGCashDepositInput!) {
|
|
387
387
|
createGCashDeposit(input: $input) {
|
|
388
388
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -411,7 +411,7 @@ const L = i`
|
|
|
411
411
|
}
|
|
412
412
|
}
|
|
413
413
|
}
|
|
414
|
-
`, Fe =
|
|
414
|
+
`, Fe = o`
|
|
415
415
|
mutation CreateMayaDeposit($input: CreateMayaDepositInput!) {
|
|
416
416
|
createMayaDeposit(input: $input) {
|
|
417
417
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -440,7 +440,7 @@ const L = i`
|
|
|
440
440
|
}
|
|
441
441
|
}
|
|
442
442
|
}
|
|
443
|
-
`, Le =
|
|
443
|
+
`, Le = o`
|
|
444
444
|
mutation CreateMayaAppDeposit($input: CreateMayaAppDepositInput!) {
|
|
445
445
|
createMayaAppDeposit(input: $input) {
|
|
446
446
|
... on DepositPromoMaximumAmountExceededError {
|
|
@@ -469,7 +469,7 @@ const L = i`
|
|
|
469
469
|
}
|
|
470
470
|
}
|
|
471
471
|
}
|
|
472
|
-
`, Ve =
|
|
472
|
+
`, Ve = o`
|
|
473
473
|
query Deposit($id: ObjectId!) {
|
|
474
474
|
node(id: $id) {
|
|
475
475
|
... on GCashDeposit {
|
|
@@ -501,13 +501,13 @@ const L = i`
|
|
|
501
501
|
}
|
|
502
502
|
}
|
|
503
503
|
}
|
|
504
|
-
`, He =
|
|
504
|
+
`, He = o`
|
|
505
505
|
query DepositsCount {
|
|
506
506
|
member {
|
|
507
507
|
depositsCount
|
|
508
508
|
}
|
|
509
509
|
}
|
|
510
|
-
`, Ye =
|
|
510
|
+
`, Ye = o`
|
|
511
511
|
query BetRecords($first: Int, $after: Cursor, $filter: BetRecordFilterInput) {
|
|
512
512
|
member {
|
|
513
513
|
betRecords(first: $first, after: $after, filter: $filter) {
|
|
@@ -548,7 +548,7 @@ const L = i`
|
|
|
548
548
|
}
|
|
549
549
|
}
|
|
550
550
|
}
|
|
551
|
-
`, je =
|
|
551
|
+
`, je = o`
|
|
552
552
|
query LatestBetRecords {
|
|
553
553
|
latestBetRecords {
|
|
554
554
|
id
|
|
@@ -568,7 +568,7 @@ const L = i`
|
|
|
568
568
|
dateTimeCreated
|
|
569
569
|
}
|
|
570
570
|
}
|
|
571
|
-
`, Qe =
|
|
571
|
+
`, Qe = o`
|
|
572
572
|
query TransactionRecords($first: Int, $after: Cursor, $filter: TransactionRecordFilter) {
|
|
573
573
|
member {
|
|
574
574
|
transactionRecords(first: $first, after: $after, filter: $filter) {
|
|
@@ -594,8 +594,8 @@ const L = i`
|
|
|
594
594
|
}
|
|
595
595
|
}
|
|
596
596
|
}
|
|
597
|
-
`,
|
|
598
|
-
${
|
|
597
|
+
`, fe = o`
|
|
598
|
+
${de}
|
|
599
599
|
|
|
600
600
|
fragment PromoFragment on Promo {
|
|
601
601
|
id
|
|
@@ -613,24 +613,24 @@ const L = i`
|
|
|
613
613
|
dateTimeCreated
|
|
614
614
|
dateTimeLastUpdated
|
|
615
615
|
}
|
|
616
|
-
`, Ke =
|
|
617
|
-
${
|
|
616
|
+
`, Ke = o`
|
|
617
|
+
${fe}
|
|
618
618
|
|
|
619
619
|
query Promos {
|
|
620
620
|
promos {
|
|
621
621
|
...PromoFragment
|
|
622
622
|
}
|
|
623
623
|
}
|
|
624
|
-
`, ze =
|
|
625
|
-
${
|
|
624
|
+
`, ze = o`
|
|
625
|
+
${fe}
|
|
626
626
|
|
|
627
627
|
query AvailablePromos($filter: PromoFilterInput) {
|
|
628
628
|
availablePromos(filter: $filter) {
|
|
629
629
|
...PromoFragment
|
|
630
630
|
}
|
|
631
631
|
}
|
|
632
|
-
`,
|
|
633
|
-
${
|
|
632
|
+
`, Ae = o`
|
|
633
|
+
${de}
|
|
634
634
|
|
|
635
635
|
fragment CashbackFragment on Cashback {
|
|
636
636
|
id
|
|
@@ -648,16 +648,16 @@ const L = i`
|
|
|
648
648
|
dateTimeCreated
|
|
649
649
|
dateTimeLastUpdated
|
|
650
650
|
}
|
|
651
|
-
`, Je =
|
|
652
|
-
${
|
|
651
|
+
`, Je = o`
|
|
652
|
+
${Ae}
|
|
653
653
|
|
|
654
654
|
query Cashbacks {
|
|
655
655
|
cashbacks {
|
|
656
656
|
...CashbackFragment
|
|
657
657
|
}
|
|
658
658
|
}
|
|
659
|
-
`, Xe =
|
|
660
|
-
${
|
|
659
|
+
`, Xe = o`
|
|
660
|
+
${fe}
|
|
661
661
|
|
|
662
662
|
query Bonus {
|
|
663
663
|
bonus {
|
|
@@ -685,8 +685,8 @@ const L = i`
|
|
|
685
685
|
dateTimeLastUpdated
|
|
686
686
|
}
|
|
687
687
|
}
|
|
688
|
-
`, Ze =
|
|
689
|
-
${
|
|
688
|
+
`, Ze = o`
|
|
689
|
+
${Ae}
|
|
690
690
|
|
|
691
691
|
query CashbackBonuses {
|
|
692
692
|
cashbackBonuses {
|
|
@@ -700,7 +700,7 @@ const L = i`
|
|
|
700
700
|
dateTimeLastUpdated
|
|
701
701
|
}
|
|
702
702
|
}
|
|
703
|
-
`, et =
|
|
703
|
+
`, et = o`
|
|
704
704
|
mutation ClaimCashbackBonus($input: ClaimCashbackBonusInput!) {
|
|
705
705
|
claimCashbackBonus(input: $input) {
|
|
706
706
|
... on CashbackBonusDoesNotExistError {
|
|
@@ -709,14 +709,14 @@ const L = i`
|
|
|
709
709
|
}
|
|
710
710
|
}
|
|
711
711
|
`;
|
|
712
|
-
|
|
712
|
+
o`
|
|
713
713
|
query Member {
|
|
714
714
|
member {
|
|
715
715
|
dateTimeLastActive
|
|
716
716
|
}
|
|
717
717
|
}
|
|
718
718
|
`;
|
|
719
|
-
const tt =
|
|
719
|
+
const tt = o`
|
|
720
720
|
query MemberAccount {
|
|
721
721
|
memberAccount: self {
|
|
722
722
|
... on MemberAccount {
|
|
@@ -740,8 +740,8 @@ const tt = i`
|
|
|
740
740
|
}
|
|
741
741
|
}
|
|
742
742
|
}
|
|
743
|
-
`, rt =
|
|
744
|
-
${
|
|
743
|
+
`, rt = o`
|
|
744
|
+
${de}
|
|
745
745
|
|
|
746
746
|
query MemberVerification {
|
|
747
747
|
memberAccount: self {
|
|
@@ -765,7 +765,7 @@ const tt = i`
|
|
|
765
765
|
}
|
|
766
766
|
}
|
|
767
767
|
}
|
|
768
|
-
`, at =
|
|
768
|
+
`, at = o`
|
|
769
769
|
mutation RegisterMemberAccount(
|
|
770
770
|
$input: RegisterMemberAccountInput!
|
|
771
771
|
$referralCode: String
|
|
@@ -801,7 +801,7 @@ const tt = i`
|
|
|
801
801
|
}
|
|
802
802
|
}
|
|
803
803
|
}
|
|
804
|
-
`,
|
|
804
|
+
`, nt = o`
|
|
805
805
|
mutation RegisterMemberAccountViaMobile(
|
|
806
806
|
$input: RegisterMemberAccountViaMobileInput!
|
|
807
807
|
$referralCode: String
|
|
@@ -828,7 +828,7 @@ const tt = i`
|
|
|
828
828
|
}
|
|
829
829
|
}
|
|
830
830
|
}
|
|
831
|
-
`,
|
|
831
|
+
`, it = o`
|
|
832
832
|
mutation RegisterMemberAccount(
|
|
833
833
|
$input: RegisterMemberAccountInput_next!
|
|
834
834
|
$reCAPTCHAResponse: String
|
|
@@ -860,7 +860,7 @@ const tt = i`
|
|
|
860
860
|
}
|
|
861
861
|
}
|
|
862
862
|
}
|
|
863
|
-
`,
|
|
863
|
+
`, ot = o`
|
|
864
864
|
mutation RegisterMayaMemberAccount($input: RegisterMayaMemberAccountInput!) {
|
|
865
865
|
registerMayaMemberAccount(input: $input) {
|
|
866
866
|
... on AccountNameNotAvailableError {
|
|
@@ -868,7 +868,7 @@ const tt = i`
|
|
|
868
868
|
}
|
|
869
869
|
}
|
|
870
870
|
}
|
|
871
|
-
`, st =
|
|
871
|
+
`, st = o`
|
|
872
872
|
mutation UpdateMemberAccount($input: UpdateMemberAccountInput!) {
|
|
873
873
|
updateMemberAccount(input: $input) {
|
|
874
874
|
... on AccountNameNotAvailableError {
|
|
@@ -894,7 +894,7 @@ const tt = i`
|
|
|
894
894
|
}
|
|
895
895
|
}
|
|
896
896
|
}
|
|
897
|
-
`,
|
|
897
|
+
`, mt = o`
|
|
898
898
|
mutation ResetPassword($input: ResetPasswordInput!, $verificationCode: String) {
|
|
899
899
|
resetPassword(input: $input, verificationCode: $verificationCode) {
|
|
900
900
|
... on AccountNotFoundError {
|
|
@@ -905,11 +905,11 @@ const tt = i`
|
|
|
905
905
|
}
|
|
906
906
|
}
|
|
907
907
|
}
|
|
908
|
-
`,
|
|
908
|
+
`, ct = o`
|
|
909
909
|
mutation DeleteMemberAccount($input: DeleteMemberAccountInput!) {
|
|
910
910
|
deleteMemberAccount(input: $input)
|
|
911
911
|
}
|
|
912
|
-
`, dt =
|
|
912
|
+
`, dt = o`
|
|
913
913
|
mutation VerifyMobileNumber($input: VerifyMobileNumberInput!) {
|
|
914
914
|
verifyMobileNumber(input: $input) {
|
|
915
915
|
... on InvalidSMSVerificationCodeError {
|
|
@@ -920,7 +920,7 @@ const tt = i`
|
|
|
920
920
|
}
|
|
921
921
|
}
|
|
922
922
|
}
|
|
923
|
-
`, ut =
|
|
923
|
+
`, ut = o`
|
|
924
924
|
mutation CreateMemberVerification($input: CreateMemberVerificationInput!) {
|
|
925
925
|
createMemberVerification(input: $input) {
|
|
926
926
|
... on FileDoesNotExistError {
|
|
@@ -934,7 +934,7 @@ const tt = i`
|
|
|
934
934
|
}
|
|
935
935
|
}
|
|
936
936
|
}
|
|
937
|
-
`, lt =
|
|
937
|
+
`, lt = o`
|
|
938
938
|
mutation UpdateMemberVerification($input: UpdateMemberVerificationInput!) {
|
|
939
939
|
updateMemberVerification(input: $input) {
|
|
940
940
|
... on FileDoesNotExistError {
|
|
@@ -951,7 +951,7 @@ const tt = i`
|
|
|
951
951
|
}
|
|
952
952
|
}
|
|
953
953
|
}
|
|
954
|
-
`, pt =
|
|
954
|
+
`, pt = o`
|
|
955
955
|
query ProfileCompletion {
|
|
956
956
|
profileCompletion {
|
|
957
957
|
completionPercentage
|
|
@@ -962,7 +962,7 @@ const tt = i`
|
|
|
962
962
|
accountPassword
|
|
963
963
|
}
|
|
964
964
|
}
|
|
965
|
-
`, ft =
|
|
965
|
+
`, ft = o`
|
|
966
966
|
mutation SendVerificationCode($input: SendVerificationCodeInput!) {
|
|
967
967
|
sendVerificationCode(input: $input) {
|
|
968
968
|
... on InvalidPlatformError {
|
|
@@ -973,7 +973,7 @@ const tt = i`
|
|
|
973
973
|
}
|
|
974
974
|
}
|
|
975
975
|
}
|
|
976
|
-
`, ht =
|
|
976
|
+
`, ht = o`
|
|
977
977
|
fragment DepositGatewaySettingsCoreData on DepositGatewaySettings {
|
|
978
978
|
minimumAmount
|
|
979
979
|
maximumAmount
|
|
@@ -1029,7 +1029,63 @@ const tt = i`
|
|
|
1029
1029
|
multiplier
|
|
1030
1030
|
}
|
|
1031
1031
|
}
|
|
1032
|
-
`,
|
|
1032
|
+
`, wt = o`
|
|
1033
|
+
query Platform {
|
|
1034
|
+
timezone
|
|
1035
|
+
currency
|
|
1036
|
+
}
|
|
1037
|
+
`, yt = o`
|
|
1038
|
+
fragment DepositGatewaySettingsCoreData on DepositGatewaySettings {
|
|
1039
|
+
minimumAmount
|
|
1040
|
+
maximumAmount
|
|
1041
|
+
fixedFee
|
|
1042
|
+
percentageFee
|
|
1043
|
+
webEnabled
|
|
1044
|
+
mobileWebEnabled
|
|
1045
|
+
androidEnabled
|
|
1046
|
+
iosEnabled
|
|
1047
|
+
}
|
|
1048
|
+
|
|
1049
|
+
fragment WithdrawalGatewaySettingsCoreData on WithdrawalGatewaySettings {
|
|
1050
|
+
minimumAmount
|
|
1051
|
+
maximumAmount
|
|
1052
|
+
fixedFee
|
|
1053
|
+
percentageFee
|
|
1054
|
+
webEnabled
|
|
1055
|
+
mobileWebEnabled
|
|
1056
|
+
androidEnabled
|
|
1057
|
+
iosEnabled
|
|
1058
|
+
}
|
|
1059
|
+
|
|
1060
|
+
query PaymentSettings {
|
|
1061
|
+
minimumFirstDepositAmount
|
|
1062
|
+
restrictWithdrawalsToVerifiedMembers
|
|
1063
|
+
bankDepositGatewaySettings: depositGatewaySettings(gateway: BANK) {
|
|
1064
|
+
...DepositGatewaySettingsCoreData
|
|
1065
|
+
}
|
|
1066
|
+
gcashDepositGatewaySettings: depositGatewaySettings(gateway: GCASH) {
|
|
1067
|
+
...DepositGatewaySettingsCoreData
|
|
1068
|
+
}
|
|
1069
|
+
mayaDepositGatewaySettings: depositGatewaySettings(gateway: MAYA) {
|
|
1070
|
+
...DepositGatewaySettingsCoreData
|
|
1071
|
+
}
|
|
1072
|
+
mayaAppDepositGatewaySettings: depositGatewaySettings(gateway: MAYA_APP) {
|
|
1073
|
+
...DepositGatewaySettingsCoreData
|
|
1074
|
+
}
|
|
1075
|
+
bankWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: BANK) {
|
|
1076
|
+
...WithdrawalGatewaySettingsCoreData
|
|
1077
|
+
}
|
|
1078
|
+
gcashWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: GCASH) {
|
|
1079
|
+
...WithdrawalGatewaySettingsCoreData
|
|
1080
|
+
}
|
|
1081
|
+
mayaWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: MAYA) {
|
|
1082
|
+
...WithdrawalGatewaySettingsCoreData
|
|
1083
|
+
}
|
|
1084
|
+
mayaAppWithdrawalGatewaySettings: withdrawalGatewaySettings(gateway: MAYA_APP) {
|
|
1085
|
+
...WithdrawalGatewaySettingsCoreData
|
|
1086
|
+
}
|
|
1087
|
+
}
|
|
1088
|
+
`, gt = o`
|
|
1033
1089
|
query MayaSession($id: ObjectId!) {
|
|
1034
1090
|
mayaSession(id: $id) {
|
|
1035
1091
|
id
|
|
@@ -1037,11 +1093,11 @@ const tt = i`
|
|
|
1037
1093
|
dateTimeCreated
|
|
1038
1094
|
}
|
|
1039
1095
|
}
|
|
1040
|
-
`,
|
|
1096
|
+
`, bt = o`
|
|
1041
1097
|
mutation ValidateMayaSession {
|
|
1042
1098
|
validateMayaSession: validMayaSession
|
|
1043
1099
|
}
|
|
1044
|
-
`,
|
|
1100
|
+
`, Et = o`
|
|
1045
1101
|
query ActivityRecords($after: Cursor, $first: Int, $filter: ActivityRecordsFilterInput) {
|
|
1046
1102
|
member {
|
|
1047
1103
|
activityRecords(after: $after, first: $first, filter: $filter) {
|
|
@@ -1066,11 +1122,11 @@ const tt = i`
|
|
|
1066
1122
|
}
|
|
1067
1123
|
}
|
|
1068
1124
|
}
|
|
1069
|
-
`,
|
|
1125
|
+
`, St = o`
|
|
1070
1126
|
query ReferralCode {
|
|
1071
1127
|
referralCode
|
|
1072
1128
|
}
|
|
1073
|
-
`,
|
|
1129
|
+
`, At = o`
|
|
1074
1130
|
mutation UpdateReferralCode($input: UpdateReferralCodeInput!) {
|
|
1075
1131
|
updateReferralCode(input: $input) {
|
|
1076
1132
|
... on ReferralCodeNotAvailableError {
|
|
@@ -1078,7 +1134,7 @@ const tt = i`
|
|
|
1078
1134
|
}
|
|
1079
1135
|
}
|
|
1080
1136
|
}
|
|
1081
|
-
`,
|
|
1137
|
+
`, he = o`
|
|
1082
1138
|
fragment ReferralFragment on Referral {
|
|
1083
1139
|
id
|
|
1084
1140
|
upline {
|
|
@@ -1096,7 +1152,7 @@ const tt = i`
|
|
|
1096
1152
|
commission
|
|
1097
1153
|
dateTimeCreated
|
|
1098
1154
|
}
|
|
1099
|
-
`,
|
|
1155
|
+
`, Ct = o`
|
|
1100
1156
|
query Referrals($first: Int, $after: Cursor, $filter: ReferralFilterInput) {
|
|
1101
1157
|
member {
|
|
1102
1158
|
referrals(first: $first, after: $after, filter: $filter) {
|
|
@@ -1117,24 +1173,24 @@ const tt = i`
|
|
|
1117
1173
|
}
|
|
1118
1174
|
}
|
|
1119
1175
|
|
|
1120
|
-
${
|
|
1121
|
-
`,
|
|
1176
|
+
${he}
|
|
1177
|
+
`, kt = o`
|
|
1122
1178
|
query UplinesByName($search: String!, $first: Int) {
|
|
1123
1179
|
uplinesByName(search: $search, first: $first) {
|
|
1124
1180
|
...ReferralFragment
|
|
1125
1181
|
}
|
|
1126
1182
|
}
|
|
1127
1183
|
|
|
1128
|
-
${
|
|
1129
|
-
`,
|
|
1184
|
+
${he}
|
|
1185
|
+
`, _t = o`
|
|
1130
1186
|
query DownlinesByName($search: String!, $first: Int) {
|
|
1131
1187
|
downlinesByName(search: $search, first: $first) {
|
|
1132
1188
|
...ReferralFragment
|
|
1133
1189
|
}
|
|
1134
1190
|
}
|
|
1135
1191
|
|
|
1136
|
-
${
|
|
1137
|
-
`,
|
|
1192
|
+
${he}
|
|
1193
|
+
`, Tt = o`
|
|
1138
1194
|
query ReferralCommission {
|
|
1139
1195
|
member {
|
|
1140
1196
|
referralCommission {
|
|
@@ -1153,10 +1209,16 @@ const tt = i`
|
|
|
1153
1209
|
}
|
|
1154
1210
|
}
|
|
1155
1211
|
}
|
|
1212
|
+
`, vt = o`
|
|
1213
|
+
query PointsClubSettings {
|
|
1214
|
+
pointsClubSettings {
|
|
1215
|
+
multiplier
|
|
1216
|
+
}
|
|
1217
|
+
}
|
|
1156
1218
|
`;
|
|
1157
|
-
function d(
|
|
1219
|
+
function d(n) {
|
|
1158
1220
|
return {
|
|
1159
|
-
name:
|
|
1221
|
+
name: n,
|
|
1160
1222
|
message: {
|
|
1161
1223
|
AccountNameNotAvailableError: "Username is no longer available",
|
|
1162
1224
|
AccountNotFoundError: "Account does not exist",
|
|
@@ -1206,12 +1268,12 @@ function d(o) {
|
|
|
1206
1268
|
InvalidTokenOrSecretAnswerError: "Invalid token or secret answer",
|
|
1207
1269
|
SessionExpiredError: "Session expired",
|
|
1208
1270
|
RateLimitExceededError: "Maximum number of requests reached"
|
|
1209
|
-
}[
|
|
1271
|
+
}[n]
|
|
1210
1272
|
};
|
|
1211
1273
|
}
|
|
1212
|
-
class
|
|
1274
|
+
class Mt {
|
|
1213
1275
|
constructor(e) {
|
|
1214
|
-
|
|
1276
|
+
c(this, "client");
|
|
1215
1277
|
this.client = e;
|
|
1216
1278
|
}
|
|
1217
1279
|
/** aka `Query.self` */
|
|
@@ -1232,7 +1294,7 @@ class Tt {
|
|
|
1232
1294
|
} : t;
|
|
1233
1295
|
}
|
|
1234
1296
|
async registerMemberAccountViaMobile(e) {
|
|
1235
|
-
const t = await this.client.request(
|
|
1297
|
+
const t = await this.client.request(nt, e);
|
|
1236
1298
|
return t.ok ? t.data.registerMemberAccountViaMobile ? {
|
|
1237
1299
|
ok: !1,
|
|
1238
1300
|
error: d(t.data.registerMemberAccountViaMobile.__typename)
|
|
@@ -1241,7 +1303,7 @@ class Tt {
|
|
|
1241
1303
|
} : t;
|
|
1242
1304
|
}
|
|
1243
1305
|
async registerMemberAccount__next(e) {
|
|
1244
|
-
const t = await this.client.request(
|
|
1306
|
+
const t = await this.client.request(it, e);
|
|
1245
1307
|
return t.ok ? t.data.registerMemberAccount ? {
|
|
1246
1308
|
ok: !1,
|
|
1247
1309
|
error: d(t.data.registerMemberAccount.__typename)
|
|
@@ -1259,7 +1321,7 @@ class Tt {
|
|
|
1259
1321
|
} : t;
|
|
1260
1322
|
}
|
|
1261
1323
|
async deleteMemberAccount(e) {
|
|
1262
|
-
const t = await this.client.request(
|
|
1324
|
+
const t = await this.client.request(ct, e);
|
|
1263
1325
|
return t.ok ? t.data.deleteMemberAccount ? {
|
|
1264
1326
|
ok: !0
|
|
1265
1327
|
} : {
|
|
@@ -1272,7 +1334,7 @@ class Tt {
|
|
|
1272
1334
|
}
|
|
1273
1335
|
async resetPassword(e) {
|
|
1274
1336
|
const t = await this.client.request(
|
|
1275
|
-
|
|
1337
|
+
mt,
|
|
1276
1338
|
e
|
|
1277
1339
|
);
|
|
1278
1340
|
return t.ok ? t.data.resetPassword ? {
|
|
@@ -1286,6 +1348,7 @@ class Tt {
|
|
|
1286
1348
|
const e = await this.client.request(pt);
|
|
1287
1349
|
return e.ok ? { ok: !0, data: e.data.profileCompletion } : e;
|
|
1288
1350
|
}
|
|
1351
|
+
/** @deprecated */
|
|
1289
1352
|
async platform() {
|
|
1290
1353
|
return await this.client.request(ht);
|
|
1291
1354
|
}
|
|
@@ -1299,6 +1362,9 @@ class Tt {
|
|
|
1299
1362
|
ok: !0
|
|
1300
1363
|
} : t;
|
|
1301
1364
|
}
|
|
1365
|
+
async paymentSettings() {
|
|
1366
|
+
return await this.client.request(yt);
|
|
1367
|
+
}
|
|
1302
1368
|
async verifyMobileNumber(e) {
|
|
1303
1369
|
const t = await this.client.request(dt, e);
|
|
1304
1370
|
return t.ok ? t.data.verifyMobileNumber ? {
|
|
@@ -1335,7 +1401,7 @@ class Tt {
|
|
|
1335
1401
|
}
|
|
1336
1402
|
async announcements(e) {
|
|
1337
1403
|
const t = await this.client.request(
|
|
1338
|
-
|
|
1404
|
+
Ge,
|
|
1339
1405
|
e
|
|
1340
1406
|
);
|
|
1341
1407
|
return t.ok ? {
|
|
@@ -1344,7 +1410,7 @@ class Tt {
|
|
|
1344
1410
|
} : t;
|
|
1345
1411
|
}
|
|
1346
1412
|
async registerMayaMemberAccount(e) {
|
|
1347
|
-
const t = await this.client.request(
|
|
1413
|
+
const t = await this.client.request(ot, e);
|
|
1348
1414
|
return t.ok ? t.data.registerMayaMemberAccount ? {
|
|
1349
1415
|
ok: !1,
|
|
1350
1416
|
error: d(t.data.registerMayaMemberAccount.__typename)
|
|
@@ -1353,14 +1419,14 @@ class Tt {
|
|
|
1353
1419
|
} : t;
|
|
1354
1420
|
}
|
|
1355
1421
|
async referralCode() {
|
|
1356
|
-
const e = await this.client.request(
|
|
1422
|
+
const e = await this.client.request(St);
|
|
1357
1423
|
return e.ok ? {
|
|
1358
1424
|
ok: !0,
|
|
1359
1425
|
data: e.data.referralCode
|
|
1360
1426
|
} : e;
|
|
1361
1427
|
}
|
|
1362
1428
|
async updateReferralCode(e) {
|
|
1363
|
-
const t = await this.client.request(
|
|
1429
|
+
const t = await this.client.request(At, e);
|
|
1364
1430
|
return t.ok ? t.data.updateReferralCode ? {
|
|
1365
1431
|
ok: !1,
|
|
1366
1432
|
error: d(t.data.updateReferralCode.__typename)
|
|
@@ -1368,18 +1434,19 @@ class Tt {
|
|
|
1368
1434
|
ok: !0
|
|
1369
1435
|
} : t;
|
|
1370
1436
|
}
|
|
1437
|
+
async pointsClubSettings() {
|
|
1438
|
+
const e = await this.client.request(vt);
|
|
1439
|
+
return e.ok ? { ok: !0, data: e.data.pointsClubSettings } : e;
|
|
1440
|
+
}
|
|
1371
1441
|
}
|
|
1372
|
-
function
|
|
1373
|
-
|
|
1374
|
-
}
|
|
1375
|
-
function h(o, e) {
|
|
1376
|
-
const t = V[o] ? V[o] : V[500];
|
|
1442
|
+
function w(n, e) {
|
|
1443
|
+
const t = ue[n] ? ue[n] : ue[500];
|
|
1377
1444
|
return {
|
|
1378
1445
|
name: t.name,
|
|
1379
1446
|
message: e ?? t.message
|
|
1380
1447
|
};
|
|
1381
1448
|
}
|
|
1382
|
-
const
|
|
1449
|
+
const ue = {
|
|
1383
1450
|
400: { name: "HttpBadRequest", message: "Bad Request" },
|
|
1384
1451
|
401: { name: "HttpUnauthorized", message: "Unauthorized" },
|
|
1385
1452
|
403: { name: "HttpForbidden", message: "Forbidden" },
|
|
@@ -1388,10 +1455,10 @@ const V = {
|
|
|
1388
1455
|
429: { name: "HttpTooManyRequests", message: "Too Many Requests" },
|
|
1389
1456
|
500: { name: "HttpInternalServerError", message: "Internal Server Error" }
|
|
1390
1457
|
};
|
|
1391
|
-
class
|
|
1458
|
+
class Rt {
|
|
1392
1459
|
constructor(e) {
|
|
1393
|
-
|
|
1394
|
-
|
|
1460
|
+
c(this, "url");
|
|
1461
|
+
c(this, "platform");
|
|
1395
1462
|
this.url = e.url, this.platform = e.platform;
|
|
1396
1463
|
}
|
|
1397
1464
|
get headers() {
|
|
@@ -1405,8 +1472,8 @@ class _t {
|
|
|
1405
1472
|
t.set("Authorization", `Basic ${a}`);
|
|
1406
1473
|
}
|
|
1407
1474
|
if (e.mobileNumber) {
|
|
1408
|
-
const
|
|
1409
|
-
console.log(`MobileNumberOTP ${
|
|
1475
|
+
const r = `${e.mobileNumber}:${e.verificationCode}`, a = Buffer.from(r).toString("base64");
|
|
1476
|
+
console.log(`MobileNumberOTP ${a}`), t.set("Authorization", `MobileNumberOTP ${a}`);
|
|
1410
1477
|
}
|
|
1411
1478
|
e.sessionId && t.set("Authorization", `MayaSession ${e.sessionId}`);
|
|
1412
1479
|
try {
|
|
@@ -1422,12 +1489,12 @@ class _t {
|
|
|
1422
1489
|
error: d("AccountBlacklistedError")
|
|
1423
1490
|
} : {
|
|
1424
1491
|
ok: !1,
|
|
1425
|
-
error:
|
|
1492
|
+
error: w(r.status)
|
|
1426
1493
|
};
|
|
1427
1494
|
} catch {
|
|
1428
1495
|
return {
|
|
1429
1496
|
ok: !1,
|
|
1430
|
-
error:
|
|
1497
|
+
error: w(500)
|
|
1431
1498
|
};
|
|
1432
1499
|
}
|
|
1433
1500
|
}
|
|
@@ -1451,12 +1518,12 @@ class _t {
|
|
|
1451
1518
|
error: d("InvalidTokenOrSecretAnswerError")
|
|
1452
1519
|
} : {
|
|
1453
1520
|
ok: !1,
|
|
1454
|
-
error:
|
|
1521
|
+
error: w(r.status)
|
|
1455
1522
|
};
|
|
1456
1523
|
} catch {
|
|
1457
1524
|
return {
|
|
1458
1525
|
ok: !1,
|
|
1459
|
-
error:
|
|
1526
|
+
error: w(500)
|
|
1460
1527
|
};
|
|
1461
1528
|
}
|
|
1462
1529
|
}
|
|
@@ -1481,12 +1548,12 @@ class _t {
|
|
|
1481
1548
|
error: d("InvalidTokenError")
|
|
1482
1549
|
} : {
|
|
1483
1550
|
ok: !1,
|
|
1484
|
-
error:
|
|
1551
|
+
error: w(r.status)
|
|
1485
1552
|
};
|
|
1486
1553
|
} catch {
|
|
1487
1554
|
return {
|
|
1488
1555
|
ok: !1,
|
|
1489
|
-
error:
|
|
1556
|
+
error: w(500)
|
|
1490
1557
|
};
|
|
1491
1558
|
}
|
|
1492
1559
|
}
|
|
@@ -1498,9 +1565,9 @@ class _t {
|
|
|
1498
1565
|
method: "DELETE",
|
|
1499
1566
|
headers: t
|
|
1500
1567
|
});
|
|
1501
|
-
return r.ok ? { ok: !0 } : { ok: !1, error:
|
|
1568
|
+
return r.ok ? { ok: !0 } : { ok: !1, error: w(r.status) };
|
|
1502
1569
|
} catch {
|
|
1503
|
-
return { ok: !1, error:
|
|
1570
|
+
return { ok: !1, error: w(500) };
|
|
1504
1571
|
}
|
|
1505
1572
|
}
|
|
1506
1573
|
async verifySession(e) {
|
|
@@ -1518,8 +1585,16 @@ class _t {
|
|
|
1518
1585
|
async sendVerificationCode(e) {
|
|
1519
1586
|
if (e.channel === "EMAIL") throw new Error("Email channel is not yet supported");
|
|
1520
1587
|
function t(r) {
|
|
1521
|
-
|
|
1522
|
-
|
|
1588
|
+
switch (r) {
|
|
1589
|
+
case "MEMBER_NOT_FOUND":
|
|
1590
|
+
return "AccountNotFoundError";
|
|
1591
|
+
case "RATE_LIMIT_REACH":
|
|
1592
|
+
return "RateLimitExceededError";
|
|
1593
|
+
case "NOT_READY_TO_SEND_VERIFICATION_ERROR":
|
|
1594
|
+
return "NotReadyToSendVerficationCodeError";
|
|
1595
|
+
default:
|
|
1596
|
+
return null;
|
|
1597
|
+
}
|
|
1523
1598
|
}
|
|
1524
1599
|
try {
|
|
1525
1600
|
const r = await fetch(`${this.url}/otps`, {
|
|
@@ -1534,26 +1609,26 @@ class _t {
|
|
|
1534
1609
|
error: d(s)
|
|
1535
1610
|
} : {
|
|
1536
1611
|
ok: !1,
|
|
1537
|
-
error:
|
|
1612
|
+
error: w(r.status, a.message)
|
|
1538
1613
|
};
|
|
1539
1614
|
}
|
|
1540
1615
|
return r.ok ? { ok: !0 } : {
|
|
1541
1616
|
ok: !1,
|
|
1542
|
-
error:
|
|
1617
|
+
error: w(r.status)
|
|
1543
1618
|
};
|
|
1544
1619
|
} catch {
|
|
1545
1620
|
return {
|
|
1546
1621
|
ok: !1,
|
|
1547
|
-
error:
|
|
1622
|
+
error: w(500)
|
|
1548
1623
|
};
|
|
1549
1624
|
}
|
|
1550
1625
|
}
|
|
1551
1626
|
}
|
|
1552
|
-
class
|
|
1627
|
+
class Nt {
|
|
1553
1628
|
constructor(e) {
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1629
|
+
c(this, "url");
|
|
1630
|
+
c(this, "siteId");
|
|
1631
|
+
c(this, "platformId");
|
|
1557
1632
|
this.url = e.url, this.siteId = e.site, this.platformId = e.platform;
|
|
1558
1633
|
}
|
|
1559
1634
|
async self() {
|
|
@@ -1564,22 +1639,22 @@ class vt {
|
|
|
1564
1639
|
} : e;
|
|
1565
1640
|
}
|
|
1566
1641
|
async games(e) {
|
|
1567
|
-
var a, s,
|
|
1642
|
+
var a, s, m, u, p, f, h, l, C, k, _, T, v, y, M, R, S, N, D, I, A, G, W, x;
|
|
1568
1643
|
const t = new URLSearchParams();
|
|
1569
|
-
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 = (a = e == null ? void 0 : e.filter) == null ? void 0 : a.type) != null && s.equal && t.set("filter[type][eq]", e.filter.type.equal), (u = (
|
|
1644
|
+
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 = (a = e == null ? void 0 : e.filter) == null ? void 0 : a.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(",")), (l = (h = e == null ? void 0 : e.filter) == null ? void 0 : h.type) != null && l.notIn && t.set("filter[type][nin]", e.filter.type.notIn.join(",")), (k = (C = e == null ? void 0 : e.filter) == null ? void 0 : C.provider) != null && k.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), (y = (v = e == null ? void 0 : e.filter) == null ? void 0 : v.provider) != null && y.in && t.set("filter[provider][in]", e.filter.provider.in.join(",")), (R = (M = e == null ? void 0 : e.filter) == null ? void 0 : M.provider) != null && R.notIn && t.set("filter[provider][nin]", e.filter.provider.notIn.join(",")), (N = (S = e == null ? void 0 : e.filter) == null ? void 0 : S.tags) != null && N.equal && t.set("filter[tags][eq]", e.filter.tags.equal.toLowerCase()), (I = (D = e == null ? void 0 : e.filter) == null ? void 0 : D.tags) != null && I.notEqual && t.set("filter[tags][neq]", e.filter.tags.notEqual.toLowerCase()), (G = (A = e == null ? void 0 : e.filter) == null ? void 0 : A.tags) != null && G.in && t.set(
|
|
1570
1645
|
"filter[tags][in]",
|
|
1571
|
-
e.filter.tags.in.map((
|
|
1572
|
-
), (
|
|
1646
|
+
e.filter.tags.in.map((E) => E.toLowerCase()).join(",")
|
|
1647
|
+
), (x = (W = e == null ? void 0 : e.filter) == null ? void 0 : W.tags) != null && x.notIn && t.set(
|
|
1573
1648
|
"filter[tags][nin]",
|
|
1574
|
-
e.filter.tags.notIn.map((
|
|
1649
|
+
e.filter.tags.notIn.map((E) => E.toLowerCase()).join(",")
|
|
1575
1650
|
);
|
|
1576
1651
|
const r = await this.getJson("/games", t);
|
|
1577
1652
|
return r.ok ? {
|
|
1578
1653
|
ok: !0,
|
|
1579
1654
|
data: {
|
|
1580
|
-
edges: r.data.data.map((
|
|
1581
|
-
node:
|
|
1582
|
-
cursor:
|
|
1655
|
+
edges: r.data.data.map((E) => ({
|
|
1656
|
+
node: E,
|
|
1657
|
+
cursor: E.cursor
|
|
1583
1658
|
})),
|
|
1584
1659
|
totalCount: r.data.totalCount ?? 0,
|
|
1585
1660
|
pageInfo: {
|
|
@@ -1617,19 +1692,19 @@ class vt {
|
|
|
1617
1692
|
data: await a.json()
|
|
1618
1693
|
} : {
|
|
1619
1694
|
ok: !1,
|
|
1620
|
-
error:
|
|
1695
|
+
error: w(a.status)
|
|
1621
1696
|
};
|
|
1622
1697
|
} catch {
|
|
1623
1698
|
return {
|
|
1624
1699
|
ok: !1,
|
|
1625
|
-
error:
|
|
1700
|
+
error: w(500)
|
|
1626
1701
|
};
|
|
1627
1702
|
}
|
|
1628
1703
|
}
|
|
1629
1704
|
}
|
|
1630
|
-
class
|
|
1705
|
+
class Dt {
|
|
1631
1706
|
constructor(e) {
|
|
1632
|
-
|
|
1707
|
+
c(this, "client");
|
|
1633
1708
|
this.client = e;
|
|
1634
1709
|
}
|
|
1635
1710
|
async file(e) {
|
|
@@ -1649,14 +1724,14 @@ class Mt {
|
|
|
1649
1724
|
} : t;
|
|
1650
1725
|
}
|
|
1651
1726
|
}
|
|
1652
|
-
class
|
|
1727
|
+
class It {
|
|
1653
1728
|
constructor(e) {
|
|
1654
|
-
|
|
1729
|
+
c(this, "client");
|
|
1655
1730
|
this.client = e;
|
|
1656
1731
|
}
|
|
1657
1732
|
async gameSession(e) {
|
|
1658
1733
|
const t = await this.client.request(
|
|
1659
|
-
|
|
1734
|
+
be.legacy,
|
|
1660
1735
|
e
|
|
1661
1736
|
);
|
|
1662
1737
|
return t.ok ? {
|
|
@@ -1665,7 +1740,7 @@ class Rt {
|
|
|
1665
1740
|
} : t;
|
|
1666
1741
|
}
|
|
1667
1742
|
async createGameSession(e) {
|
|
1668
|
-
const t = await this.client.request(
|
|
1743
|
+
const t = await this.client.request(Ee, e);
|
|
1669
1744
|
return t.ok ? t.data.createGameSession ? {
|
|
1670
1745
|
ok: !1,
|
|
1671
1746
|
error: d(t.data.createGameSession.__typename)
|
|
@@ -1674,7 +1749,7 @@ class Rt {
|
|
|
1674
1749
|
} : t;
|
|
1675
1750
|
}
|
|
1676
1751
|
async endGameSession(e) {
|
|
1677
|
-
const t = await this.client.request(
|
|
1752
|
+
const t = await this.client.request(Se.legacy, e);
|
|
1678
1753
|
return t.ok ? t.data.endGameSession ? {
|
|
1679
1754
|
ok: !1,
|
|
1680
1755
|
error: {
|
|
@@ -1686,9 +1761,9 @@ class Rt {
|
|
|
1686
1761
|
} : t;
|
|
1687
1762
|
}
|
|
1688
1763
|
}
|
|
1689
|
-
class
|
|
1764
|
+
class Gt {
|
|
1690
1765
|
constructor(e) {
|
|
1691
|
-
|
|
1766
|
+
c(this, "client");
|
|
1692
1767
|
this.client = e;
|
|
1693
1768
|
}
|
|
1694
1769
|
async latestBetRecords() {
|
|
@@ -1698,10 +1773,17 @@ class Nt {
|
|
|
1698
1773
|
data: e.data.latestBetRecords
|
|
1699
1774
|
} : e;
|
|
1700
1775
|
}
|
|
1776
|
+
async platform() {
|
|
1777
|
+
const e = await this.client.request(wt);
|
|
1778
|
+
return e.ok ? {
|
|
1779
|
+
ok: !0,
|
|
1780
|
+
data: e.data
|
|
1781
|
+
} : e;
|
|
1782
|
+
}
|
|
1701
1783
|
}
|
|
1702
|
-
class
|
|
1784
|
+
class Pt {
|
|
1703
1785
|
constructor(e) {
|
|
1704
|
-
|
|
1786
|
+
c(this, "client");
|
|
1705
1787
|
this.client = e;
|
|
1706
1788
|
}
|
|
1707
1789
|
async betRecords(e) {
|
|
@@ -1717,7 +1799,7 @@ class It {
|
|
|
1717
1799
|
}
|
|
1718
1800
|
async withdrawalRecords(e) {
|
|
1719
1801
|
const t = await this.client.request(
|
|
1720
|
-
|
|
1802
|
+
Pe,
|
|
1721
1803
|
e
|
|
1722
1804
|
);
|
|
1723
1805
|
return t.ok ? { ok: t.ok, data: t.data.member.withdrawalRecords } : t;
|
|
@@ -1734,45 +1816,45 @@ class It {
|
|
|
1734
1816
|
return e.ok ? { ok: e.ok, data: e.data.member.depositsCount } : e;
|
|
1735
1817
|
}
|
|
1736
1818
|
async pointsWalletTransactions(e) {
|
|
1737
|
-
const t = await this.client.request(
|
|
1819
|
+
const t = await this.client.request(Ie, e);
|
|
1738
1820
|
return t.ok ? { ok: t.ok, data: t.data.member.pointsWalletTransactions } : t;
|
|
1739
1821
|
}
|
|
1740
1822
|
async activityRecords(e) {
|
|
1741
1823
|
const t = await this.client.request(
|
|
1742
|
-
|
|
1824
|
+
Et,
|
|
1743
1825
|
e
|
|
1744
1826
|
);
|
|
1745
1827
|
return t.ok ? { ok: t.ok, data: t.data.member.activityRecords } : t;
|
|
1746
1828
|
}
|
|
1747
1829
|
async referrals(e) {
|
|
1748
1830
|
const t = await this.client.request(
|
|
1749
|
-
|
|
1831
|
+
Ct,
|
|
1750
1832
|
e
|
|
1751
1833
|
);
|
|
1752
1834
|
return t.ok ? { ok: t.ok, data: t.data.member.referrals } : t;
|
|
1753
1835
|
}
|
|
1754
1836
|
async referralCommission() {
|
|
1755
|
-
const e = await this.client.request(
|
|
1837
|
+
const e = await this.client.request(Tt);
|
|
1756
1838
|
return e.ok ? { ok: e.ok, data: e.data.member.referralCommission } : e;
|
|
1757
1839
|
}
|
|
1758
1840
|
async uplinesByName(e) {
|
|
1759
1841
|
const t = await this.client.request(
|
|
1760
|
-
|
|
1842
|
+
kt,
|
|
1761
1843
|
e
|
|
1762
1844
|
);
|
|
1763
1845
|
return t.ok ? { ok: t.ok, data: t.data.uplinesByName } : t;
|
|
1764
1846
|
}
|
|
1765
1847
|
async downlinesByName(e) {
|
|
1766
1848
|
const t = await this.client.request(
|
|
1767
|
-
|
|
1849
|
+
_t,
|
|
1768
1850
|
e
|
|
1769
1851
|
);
|
|
1770
1852
|
return t.ok ? { ok: t.ok, data: t.data.downlinesByName } : t;
|
|
1771
1853
|
}
|
|
1772
1854
|
}
|
|
1773
|
-
class
|
|
1855
|
+
class Wt {
|
|
1774
1856
|
constructor(e) {
|
|
1775
|
-
|
|
1857
|
+
c(this, "url");
|
|
1776
1858
|
this.url = e.url;
|
|
1777
1859
|
}
|
|
1778
1860
|
gameThumbnails(e) {
|
|
@@ -1782,9 +1864,9 @@ class Dt {
|
|
|
1782
1864
|
];
|
|
1783
1865
|
}
|
|
1784
1866
|
}
|
|
1785
|
-
class
|
|
1867
|
+
class xt {
|
|
1786
1868
|
constructor(e) {
|
|
1787
|
-
|
|
1869
|
+
c(this, "client");
|
|
1788
1870
|
this.client = e;
|
|
1789
1871
|
}
|
|
1790
1872
|
async promos() {
|
|
@@ -1861,7 +1943,7 @@ class Pt {
|
|
|
1861
1943
|
} : t;
|
|
1862
1944
|
}
|
|
1863
1945
|
async createGCashWithdrawal(e) {
|
|
1864
|
-
const t = await this.client.request(
|
|
1946
|
+
const t = await this.client.request(We, e);
|
|
1865
1947
|
return t.ok ? t.data.createGCashWithdrawal ? {
|
|
1866
1948
|
ok: !1,
|
|
1867
1949
|
error: d(t.data.createGCashWithdrawal.__typename)
|
|
@@ -1870,7 +1952,7 @@ class Pt {
|
|
|
1870
1952
|
} : t;
|
|
1871
1953
|
}
|
|
1872
1954
|
async createMayaWithdrawal(e) {
|
|
1873
|
-
const t = await this.client.request(
|
|
1955
|
+
const t = await this.client.request(xe, e);
|
|
1874
1956
|
return t.ok ? t.data.createMayaWithdrawal ? {
|
|
1875
1957
|
ok: !1,
|
|
1876
1958
|
error: d(t.data.createMayaWithdrawal.__typename)
|
|
@@ -1879,7 +1961,7 @@ class Pt {
|
|
|
1879
1961
|
} : t;
|
|
1880
1962
|
}
|
|
1881
1963
|
async createMayaAppWithdrawal(e) {
|
|
1882
|
-
const t = await this.client.request(
|
|
1964
|
+
const t = await this.client.request($e, e);
|
|
1883
1965
|
return t.ok ? t.data.createMayaAppWithdrawal ? {
|
|
1884
1966
|
ok: !1,
|
|
1885
1967
|
error: d(t.data.createMayaAppWithdrawal.__typename)
|
|
@@ -1888,7 +1970,7 @@ class Pt {
|
|
|
1888
1970
|
} : t;
|
|
1889
1971
|
}
|
|
1890
1972
|
async createBankWithdrawal(e) {
|
|
1891
|
-
const t = await this.client.request(
|
|
1973
|
+
const t = await this.client.request(Ue, e);
|
|
1892
1974
|
return t.ok ? t.data.createBankWithdrawal ? {
|
|
1893
1975
|
ok: !1,
|
|
1894
1976
|
error: d(t.data.createBankWithdrawal.__typename)
|
|
@@ -1898,7 +1980,7 @@ class Pt {
|
|
|
1898
1980
|
}
|
|
1899
1981
|
async remainingDailyWithdrawalsCount() {
|
|
1900
1982
|
const e = await this.client.request(
|
|
1901
|
-
|
|
1983
|
+
Oe
|
|
1902
1984
|
);
|
|
1903
1985
|
return e.ok ? { ok: e.ok, data: e.data.remainingDailyWithdrawalsCount } : e;
|
|
1904
1986
|
}
|
|
@@ -1907,7 +1989,7 @@ class Pt {
|
|
|
1907
1989
|
return e.ok ? { ok: e.ok, data: e.data.pointsWallet } : e;
|
|
1908
1990
|
}
|
|
1909
1991
|
async redeemPointsToCash(e) {
|
|
1910
|
-
const t = await this.client.request(
|
|
1992
|
+
const t = await this.client.request(De, e);
|
|
1911
1993
|
return t.ok ? t.data.redeemPointsToCash ? {
|
|
1912
1994
|
ok: !1,
|
|
1913
1995
|
error: d(t.data.redeemPointsToCash.__typename)
|
|
@@ -1917,20 +1999,20 @@ class Pt {
|
|
|
1917
1999
|
}
|
|
1918
2000
|
async mayaSession(e) {
|
|
1919
2001
|
const t = await this.client.request(
|
|
1920
|
-
|
|
2002
|
+
gt,
|
|
1921
2003
|
e
|
|
1922
2004
|
);
|
|
1923
2005
|
return t.ok ? { ok: t.ok, data: t.data.mayaSession } : t;
|
|
1924
2006
|
}
|
|
1925
2007
|
async gameSession(e) {
|
|
1926
2008
|
const t = await this.client.request(
|
|
1927
|
-
|
|
2009
|
+
be.current,
|
|
1928
2010
|
e
|
|
1929
2011
|
);
|
|
1930
2012
|
return t.ok ? { ok: !0, data: t.data.node } : t;
|
|
1931
2013
|
}
|
|
1932
2014
|
async createGameSession(e) {
|
|
1933
|
-
const t = await this.client.request(
|
|
2015
|
+
const t = await this.client.request(Ee, e);
|
|
1934
2016
|
return t.ok ? t.data.createGameSession ? {
|
|
1935
2017
|
ok: !1,
|
|
1936
2018
|
error: d(t.data.createGameSession.__typename)
|
|
@@ -1940,7 +2022,7 @@ class Pt {
|
|
|
1940
2022
|
}
|
|
1941
2023
|
async endGameSession(e) {
|
|
1942
2024
|
const t = await this.client.request(
|
|
1943
|
-
|
|
2025
|
+
Se.current,
|
|
1944
2026
|
e
|
|
1945
2027
|
);
|
|
1946
2028
|
return t.ok ? t.data.endGameSession ? {
|
|
@@ -1955,7 +2037,7 @@ class Pt {
|
|
|
1955
2037
|
}
|
|
1956
2038
|
async validateMayaSession() {
|
|
1957
2039
|
const e = await this.client.request(
|
|
1958
|
-
|
|
2040
|
+
bt
|
|
1959
2041
|
);
|
|
1960
2042
|
return e.ok ? e.data.validateMayaSession ? {
|
|
1961
2043
|
ok: !0
|
|
@@ -1968,33 +2050,64 @@ class Pt {
|
|
|
1968
2050
|
} : e;
|
|
1969
2051
|
}
|
|
1970
2052
|
}
|
|
1971
|
-
function
|
|
1972
|
-
return
|
|
2053
|
+
function we(n) {
|
|
2054
|
+
return new Date(n.getTime());
|
|
2055
|
+
}
|
|
2056
|
+
function B(n, e) {
|
|
2057
|
+
const t = we(n);
|
|
2058
|
+
return t.setMinutes(t.getMinutes() + e), t;
|
|
2059
|
+
}
|
|
2060
|
+
function le(n, e) {
|
|
2061
|
+
return n.getTime() > e.getTime();
|
|
2062
|
+
}
|
|
2063
|
+
class $t {
|
|
2064
|
+
constructor(e) {
|
|
2065
|
+
c(this, "config");
|
|
2066
|
+
c(this, "cache");
|
|
2067
|
+
this.cache = {}, this.config = {
|
|
2068
|
+
cacheTime: 5,
|
|
2069
|
+
...e
|
|
2070
|
+
};
|
|
2071
|
+
}
|
|
2072
|
+
set(e, t) {
|
|
2073
|
+
const r = B(/* @__PURE__ */ new Date(), this.config.cacheTime);
|
|
2074
|
+
this.cache[e] = {
|
|
2075
|
+
value: t,
|
|
2076
|
+
validUntil: r
|
|
2077
|
+
};
|
|
2078
|
+
}
|
|
2079
|
+
get(e) {
|
|
2080
|
+
const t = this.cache[e];
|
|
2081
|
+
return !t || le(/* @__PURE__ */ new Date(), t.validUntil) ? null : t.value;
|
|
2082
|
+
}
|
|
2083
|
+
}
|
|
2084
|
+
function Ut(n, e, t) {
|
|
2085
|
+
return n < e ? e : n > t ? t : n;
|
|
1973
2086
|
}
|
|
1974
|
-
function
|
|
1975
|
-
return Object.prototype.toString.call(
|
|
2087
|
+
function pe(n) {
|
|
2088
|
+
return Object.prototype.toString.call(n) === "[object Object]" && Object(n) === n;
|
|
1976
2089
|
}
|
|
1977
|
-
function
|
|
2090
|
+
function Ot(n) {
|
|
1978
2091
|
const e = [];
|
|
1979
2092
|
function t(r, a = []) {
|
|
1980
2093
|
for (const s in r) {
|
|
1981
|
-
const
|
|
1982
|
-
|
|
2094
|
+
const m = r[s];
|
|
2095
|
+
pe(m) ? t(m, [...a, s]) : Array.isArray(m) ? t(Bt(m), [...a, s]) : e.push({
|
|
1983
2096
|
key: [...a, s],
|
|
1984
|
-
value:
|
|
2097
|
+
value: m
|
|
1985
2098
|
});
|
|
1986
2099
|
}
|
|
1987
2100
|
}
|
|
1988
|
-
return t(
|
|
2101
|
+
return t(n), e;
|
|
1989
2102
|
}
|
|
1990
|
-
function
|
|
1991
|
-
return
|
|
2103
|
+
function Bt(n) {
|
|
2104
|
+
return n.reduce((e, t, r) => (e[r] = t, e), {});
|
|
1992
2105
|
}
|
|
1993
|
-
class
|
|
2106
|
+
class O {
|
|
1994
2107
|
constructor(e, t) {
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
2108
|
+
c(this, "url");
|
|
2109
|
+
c(this, "options");
|
|
2110
|
+
c(this, "middlewares");
|
|
1998
2111
|
var a;
|
|
1999
2112
|
const r = new Headers((a = t == null ? void 0 : t.fetchOptions) == null ? void 0 : a.headers);
|
|
2000
2113
|
this.url = e, this.options = { ...t == null ? void 0 : t.fetchOptions, headers: r }, this.middlewares = (t == null ? void 0 : t.middlewares) ?? [];
|
|
@@ -2027,23 +2140,23 @@ class G {
|
|
|
2027
2140
|
return await this.exec(s);
|
|
2028
2141
|
}
|
|
2029
2142
|
async exec(e) {
|
|
2030
|
-
var t, r, a, s,
|
|
2143
|
+
var t, r, a, s, m, u;
|
|
2031
2144
|
try {
|
|
2032
2145
|
const p = await fetch(e);
|
|
2033
2146
|
if (!p.ok)
|
|
2034
|
-
return { ok: !1, error:
|
|
2035
|
-
const f = await p.json(),
|
|
2036
|
-
return l ? ((r = l.extensions) == null ? void 0 : r.code) === "FORBIDDEN" || ((a = l.extensions) == null ? void 0 : a.code) === "ACCESS_TOKEN_EXPIRED" ? { ok: !1, error:
|
|
2147
|
+
return { ok: !1, error: w(p.status) };
|
|
2148
|
+
const f = await p.json(), h = f.data, l = (t = f.errors) == null ? void 0 : t.at(0);
|
|
2149
|
+
return l ? ((r = l.extensions) == null ? void 0 : r.code) === "FORBIDDEN" || ((a = l.extensions) == null ? void 0 : a.code) === "ACCESS_TOKEN_EXPIRED" ? { ok: !1, error: w(403, l.message) } : ((s = l.extensions) == null ? void 0 : s.code) === "UNAUTHORIZED" ? { ok: !1, error: w(401, l.message) } : ((m = l.extensions) == null ? void 0 : m.code) === "BAD_USER_INPUT" || ((u = l.extensions) == null ? void 0 : u.code) === "BAD_REQUEST" ? { ok: !1, error: w(400, l.message) } : {
|
|
2037
2150
|
ok: !1,
|
|
2038
|
-
error:
|
|
2151
|
+
error: w(500, l.message)
|
|
2039
2152
|
} : {
|
|
2040
2153
|
ok: !0,
|
|
2041
|
-
data:
|
|
2154
|
+
data: h
|
|
2042
2155
|
};
|
|
2043
2156
|
} catch {
|
|
2044
2157
|
return {
|
|
2045
2158
|
ok: !1,
|
|
2046
|
-
error:
|
|
2159
|
+
error: w(500)
|
|
2047
2160
|
};
|
|
2048
2161
|
}
|
|
2049
2162
|
}
|
|
@@ -2054,8 +2167,8 @@ class G {
|
|
|
2054
2167
|
return t;
|
|
2055
2168
|
}
|
|
2056
2169
|
createUploadBody(e, t) {
|
|
2057
|
-
const r =
|
|
2058
|
-
(
|
|
2170
|
+
const r = Ot(t).filter(
|
|
2171
|
+
(m) => m.value instanceof File || m.value instanceof Blob
|
|
2059
2172
|
), a = new FormData();
|
|
2060
2173
|
a.append(
|
|
2061
2174
|
"operations",
|
|
@@ -2065,20 +2178,30 @@ class G {
|
|
|
2065
2178
|
})
|
|
2066
2179
|
);
|
|
2067
2180
|
const s = {};
|
|
2068
|
-
return r.forEach((
|
|
2069
|
-
s[u.toString()] = [`variables.${
|
|
2070
|
-
}), a.append("map", JSON.stringify(s)), r.forEach((
|
|
2071
|
-
a.append(u.toString(),
|
|
2181
|
+
return r.forEach((m, u) => {
|
|
2182
|
+
s[u.toString()] = [`variables.${m.key.join(".")}`];
|
|
2183
|
+
}), a.append("map", JSON.stringify(s)), r.forEach((m, u) => {
|
|
2184
|
+
a.append(u.toString(), m.value);
|
|
2072
2185
|
}), a;
|
|
2073
2186
|
}
|
|
2074
2187
|
}
|
|
2075
|
-
|
|
2076
|
-
|
|
2188
|
+
function qt(n) {
|
|
2189
|
+
return n === "INR" ? "en-IN" : n === "MYR" ? "en-MY" : n === "IDR" ? "en-ID" : n === "USD" ? "en-US" : "en-PH";
|
|
2190
|
+
}
|
|
2191
|
+
function Ft(n) {
|
|
2192
|
+
return n === "en-IN" ? "+91" : n === "en-MY" ? "+60" : n === "en-ID" ? "+62" : n === "en-US" ? "+1" : "+63";
|
|
2193
|
+
}
|
|
2194
|
+
function P(n, e) {
|
|
2195
|
+
const t = Ft(e);
|
|
2196
|
+
return n.startsWith(t) ? n : n.startsWith(t.substring(1)) ? `+${n}` : n.startsWith("0") ? `${t}${n.substring(1)}` : `${t}${n}`;
|
|
2197
|
+
}
|
|
2198
|
+
async function g(n) {
|
|
2199
|
+
const e = new TextEncoder().encode(n), t = await crypto.subtle.digest("SHA-256", e);
|
|
2077
2200
|
return Array.from(new Uint8Array(t)).map((s) => s.toString(16).padStart(2, "0")).join("");
|
|
2078
2201
|
}
|
|
2079
2202
|
class Ce {
|
|
2080
2203
|
constructor(e) {
|
|
2081
|
-
|
|
2204
|
+
c(this, "enabled");
|
|
2082
2205
|
this.enabled = (e == null ? void 0 : e.enabled) ?? !0;
|
|
2083
2206
|
}
|
|
2084
2207
|
info(e) {
|
|
@@ -2094,49 +2217,39 @@ class Ce {
|
|
|
2094
2217
|
this.enabled && console.log(`\x1B[32m[success] ${e}`);
|
|
2095
2218
|
}
|
|
2096
2219
|
}
|
|
2097
|
-
function
|
|
2098
|
-
|
|
2099
|
-
}
|
|
2100
|
-
function B(o, e) {
|
|
2101
|
-
const t = Q(o);
|
|
2220
|
+
function me(n, e) {
|
|
2221
|
+
const t = we(n);
|
|
2102
2222
|
return t.setDate(t.getDate() + e), t;
|
|
2103
2223
|
}
|
|
2104
|
-
function
|
|
2105
|
-
const t = Q(o);
|
|
2106
|
-
return t.setMinutes(t.getMinutes() + e), t;
|
|
2107
|
-
}
|
|
2108
|
-
function we(o, e) {
|
|
2109
|
-
return o.getTime() > e.getTime();
|
|
2110
|
-
}
|
|
2111
|
-
function ke(o) {
|
|
2224
|
+
function ke(n) {
|
|
2112
2225
|
return new Promise((e) => {
|
|
2113
|
-
setTimeout(e,
|
|
2226
|
+
setTimeout(e, n);
|
|
2114
2227
|
});
|
|
2115
2228
|
}
|
|
2116
|
-
function ge(
|
|
2229
|
+
function ge(n, e) {
|
|
2117
2230
|
const {
|
|
2118
2231
|
until: t,
|
|
2119
2232
|
interval: r = 1e3,
|
|
2120
2233
|
maxAttempt: a = 3
|
|
2121
2234
|
/**/
|
|
2122
2235
|
} = e;
|
|
2123
|
-
async function s(
|
|
2124
|
-
const p = u ?? a, f = await
|
|
2125
|
-
return t(f) ? f : p > 1 ? (await ke(r * ((a - p) / 2)), s(
|
|
2236
|
+
async function s(m, u) {
|
|
2237
|
+
const p = u ?? a, f = await n(...m);
|
|
2238
|
+
return t(f) ? f : p > 1 ? (await ke(r * ((a - p) / 2)), s(m, p - 1)) : f;
|
|
2126
2239
|
}
|
|
2127
|
-
return async (...
|
|
2240
|
+
return async (...m) => await s(m);
|
|
2128
2241
|
}
|
|
2129
|
-
function
|
|
2130
|
-
const t =
|
|
2242
|
+
function ce(n, e) {
|
|
2243
|
+
const t = we(n);
|
|
2131
2244
|
return t.setMinutes(t.getMinutes() - e), t;
|
|
2132
2245
|
}
|
|
2133
|
-
class
|
|
2246
|
+
class Lt {
|
|
2134
2247
|
constructor(e) {
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2248
|
+
c(this, "logger");
|
|
2249
|
+
c(this, "storageKey", "session");
|
|
2250
|
+
c(this, "authService");
|
|
2251
|
+
c(this, "walletService");
|
|
2252
|
+
c(this, "_refreshing", !1);
|
|
2140
2253
|
this.authService = e.authService, this.walletService = e.walletService, this.logger = new Ce({
|
|
2141
2254
|
enabled: e.logs ?? !1
|
|
2142
2255
|
});
|
|
@@ -2158,16 +2271,16 @@ class Gt {
|
|
|
2158
2271
|
}
|
|
2159
2272
|
};
|
|
2160
2273
|
if (e.type === "MAYA") {
|
|
2161
|
-
const
|
|
2162
|
-
until: (
|
|
2274
|
+
const m = await ge(() => this.walletService.mayaSession({ id: e.sessionId }), {
|
|
2275
|
+
until: (h) => {
|
|
2163
2276
|
var l;
|
|
2164
|
-
return
|
|
2277
|
+
return h.ok && ((l = h.data) == null ? void 0 : l.member) != null;
|
|
2165
2278
|
},
|
|
2166
2279
|
interval: 1e3,
|
|
2167
2280
|
maxAttempt: 5
|
|
2168
2281
|
})();
|
|
2169
|
-
if (!
|
|
2170
|
-
if (!((a =
|
|
2282
|
+
if (!m.ok) return m;
|
|
2283
|
+
if (!((a = m.data) != null && a.member))
|
|
2171
2284
|
return {
|
|
2172
2285
|
ok: !1,
|
|
2173
2286
|
error: {
|
|
@@ -2176,7 +2289,7 @@ class Gt {
|
|
|
2176
2289
|
}
|
|
2177
2290
|
};
|
|
2178
2291
|
const p = await ge(() => this.authService.createSession(e), {
|
|
2179
|
-
until: (
|
|
2292
|
+
until: (h) => h.ok,
|
|
2180
2293
|
interval: 1e3,
|
|
2181
2294
|
maxAttempt: 5
|
|
2182
2295
|
})();
|
|
@@ -2186,8 +2299,8 @@ class Gt {
|
|
|
2186
2299
|
this.storageKey,
|
|
2187
2300
|
JSON.stringify({
|
|
2188
2301
|
...p.data,
|
|
2189
|
-
accessTokenExpiresAt:
|
|
2190
|
-
refreshTokenExpiresAt:
|
|
2302
|
+
accessTokenExpiresAt: B(f, 8).getTime(),
|
|
2303
|
+
refreshTokenExpiresAt: ce(me(f, 30), 2).getTime()
|
|
2191
2304
|
})
|
|
2192
2305
|
), {
|
|
2193
2306
|
ok: !0,
|
|
@@ -2197,13 +2310,13 @@ class Gt {
|
|
|
2197
2310
|
if (e.type === "MOBILE_NUMBER") {
|
|
2198
2311
|
const s = await this.authService.createSession(e);
|
|
2199
2312
|
if (s.ok) {
|
|
2200
|
-
const
|
|
2313
|
+
const m = /* @__PURE__ */ new Date();
|
|
2201
2314
|
return window.localStorage.setItem(
|
|
2202
2315
|
this.storageKey,
|
|
2203
2316
|
JSON.stringify({
|
|
2204
2317
|
...s.data,
|
|
2205
|
-
accessTokenExpiresAt:
|
|
2206
|
-
refreshTokenExpiresAt:
|
|
2318
|
+
accessTokenExpiresAt: B(m, 8).getTime(),
|
|
2319
|
+
refreshTokenExpiresAt: ce(me(m, 30), 2).getTime()
|
|
2207
2320
|
})
|
|
2208
2321
|
), {
|
|
2209
2322
|
ok: !0,
|
|
@@ -2226,8 +2339,8 @@ class Gt {
|
|
|
2226
2339
|
this.storageKey,
|
|
2227
2340
|
JSON.stringify({
|
|
2228
2341
|
...t.data,
|
|
2229
|
-
accessTokenExpiresAt:
|
|
2230
|
-
refreshTokenExpiresAt:
|
|
2342
|
+
accessTokenExpiresAt: B(r, 8).getTime(),
|
|
2343
|
+
refreshTokenExpiresAt: ce(me(r, 30), 2).getTime()
|
|
2231
2344
|
})
|
|
2232
2345
|
), {
|
|
2233
2346
|
ok: !0,
|
|
@@ -2242,8 +2355,8 @@ class Gt {
|
|
|
2242
2355
|
this.storageKey,
|
|
2243
2356
|
JSON.stringify({
|
|
2244
2357
|
...t.data,
|
|
2245
|
-
accessTokenExpiresAt:
|
|
2246
|
-
refreshTokenExpiresAt:
|
|
2358
|
+
accessTokenExpiresAt: B(r, 8).getTime(),
|
|
2359
|
+
refreshTokenExpiresAt: ce(me(r, 30), 2).getTime()
|
|
2247
2360
|
})
|
|
2248
2361
|
), { ok: !0 };
|
|
2249
2362
|
} else
|
|
@@ -2266,7 +2379,7 @@ class Gt {
|
|
|
2266
2379
|
try {
|
|
2267
2380
|
let t = JSON.parse(e), r = /* @__PURE__ */ new Date();
|
|
2268
2381
|
const a = new Date(t.accessTokenExpiresAt), s = new Date(t.refreshTokenExpiresAt);
|
|
2269
|
-
if (
|
|
2382
|
+
if (le(r, s))
|
|
2270
2383
|
return this.logger.warn("Session expired. Logging out.."), window.localStorage.removeItem(this.storageKey), {
|
|
2271
2384
|
ok: !1,
|
|
2272
2385
|
error: {
|
|
@@ -2274,22 +2387,22 @@ class Gt {
|
|
|
2274
2387
|
message: "Session expired."
|
|
2275
2388
|
}
|
|
2276
2389
|
};
|
|
2277
|
-
if (
|
|
2390
|
+
if (le(r, a)) {
|
|
2278
2391
|
this.logger.info("Refreshing session..."), this.refreshing = !0;
|
|
2279
|
-
const
|
|
2280
|
-
if (this.refreshing = !1, !
|
|
2281
|
-
return this.logger.error(`Failed to refresh session: ${
|
|
2392
|
+
const m = await this.authService.refreshSession(t.refreshToken);
|
|
2393
|
+
if (this.refreshing = !1, !m.ok)
|
|
2394
|
+
return this.logger.error(`Failed to refresh session: ${m.error.message}`), m.error.name === "InvalidTokenError" || m.error.name === "AccountBlacklistedError" ? (window.localStorage.removeItem(this.storageKey), {
|
|
2282
2395
|
ok: !1,
|
|
2283
|
-
error:
|
|
2396
|
+
error: m.error
|
|
2284
2397
|
}) : (this.logger.warn("Old session returned."), {
|
|
2285
2398
|
ok: !0,
|
|
2286
2399
|
data: t
|
|
2287
2400
|
});
|
|
2288
2401
|
this.logger.success("Session refreshed!"), r = /* @__PURE__ */ new Date(), t = {
|
|
2289
2402
|
...t,
|
|
2290
|
-
...
|
|
2291
|
-
accessTokenExpiresAt:
|
|
2292
|
-
refreshTokenExpiresAt:
|
|
2403
|
+
...m.data,
|
|
2404
|
+
accessTokenExpiresAt: B(r, 8).getTime(),
|
|
2405
|
+
refreshTokenExpiresAt: ce(me(r, 30), 2).getTime()
|
|
2293
2406
|
}, window.localStorage.setItem(this.storageKey, JSON.stringify(t));
|
|
2294
2407
|
}
|
|
2295
2408
|
return {
|
|
@@ -2329,17 +2442,17 @@ class Gt {
|
|
|
2329
2442
|
return typeof window > "u";
|
|
2330
2443
|
}
|
|
2331
2444
|
}
|
|
2332
|
-
function
|
|
2445
|
+
function b(n) {
|
|
2333
2446
|
const e = {};
|
|
2334
|
-
for (const t in
|
|
2335
|
-
const r =
|
|
2447
|
+
for (const t in n) {
|
|
2448
|
+
const r = n[t];
|
|
2336
2449
|
if (r !== null && r !== void 0) {
|
|
2337
|
-
if (
|
|
2338
|
-
e[t] =
|
|
2450
|
+
if (pe(r)) {
|
|
2451
|
+
e[t] = b(r);
|
|
2339
2452
|
continue;
|
|
2340
2453
|
}
|
|
2341
2454
|
if (Array.isArray(r)) {
|
|
2342
|
-
e[t] = r.map((a) =>
|
|
2455
|
+
e[t] = r.map((a) => pe(a) ? b(a) : a);
|
|
2343
2456
|
continue;
|
|
2344
2457
|
}
|
|
2345
2458
|
e[t] = r;
|
|
@@ -2347,21 +2460,21 @@ function g(o) {
|
|
|
2347
2460
|
}
|
|
2348
2461
|
return e;
|
|
2349
2462
|
}
|
|
2350
|
-
function n
|
|
2351
|
-
if (typeof
|
|
2352
|
-
return
|
|
2353
|
-
if (typeof
|
|
2354
|
-
const t = Number.parseFloat(
|
|
2463
|
+
function i(n, e) {
|
|
2464
|
+
if (typeof n == "number" && !Number.isNaN(n))
|
|
2465
|
+
return n;
|
|
2466
|
+
if (typeof n == "string") {
|
|
2467
|
+
const t = Number.parseFloat(n);
|
|
2355
2468
|
if (!Number.isNaN(t))
|
|
2356
2469
|
return t;
|
|
2357
2470
|
}
|
|
2358
2471
|
return e;
|
|
2359
2472
|
}
|
|
2360
|
-
class
|
|
2473
|
+
class Vt {
|
|
2361
2474
|
constructor(e) {
|
|
2362
|
-
|
|
2475
|
+
c(this, "staticService");
|
|
2363
2476
|
const t = (e == null ? void 0 : e.environment) === "development";
|
|
2364
|
-
this.staticService = new
|
|
2477
|
+
this.staticService = new Wt({
|
|
2365
2478
|
url: t ? "https://static.development.opexa.io" : "https://static.opexa.io"
|
|
2366
2479
|
});
|
|
2367
2480
|
}
|
|
@@ -2391,7 +2504,10 @@ class Ot {
|
|
|
2391
2504
|
pointsWalletTransaction: this.pointsWalletTransaction.bind(this),
|
|
2392
2505
|
activityRecord: this.activityRecord.bind(this),
|
|
2393
2506
|
referral: this.referral.bind(this),
|
|
2394
|
-
referralCommission: this.referralCommission.bind(this)
|
|
2507
|
+
referralCommission: this.referralCommission.bind(this),
|
|
2508
|
+
platform__next: this.platform__next.bind(this),
|
|
2509
|
+
pointsClubSettings: this.pointsClubSettings.bind(this),
|
|
2510
|
+
paymentSettings: this.paymentSettings.bind(this)
|
|
2395
2511
|
};
|
|
2396
2512
|
}
|
|
2397
2513
|
site(e) {
|
|
@@ -2401,15 +2517,16 @@ class Ot {
|
|
|
2401
2517
|
logo: e.logo ?? void 0,
|
|
2402
2518
|
fields: e.config.fields
|
|
2403
2519
|
};
|
|
2404
|
-
return
|
|
2520
|
+
return b(t);
|
|
2405
2521
|
}
|
|
2522
|
+
/** @deprecated */
|
|
2406
2523
|
platform(e) {
|
|
2407
|
-
var t, r, a, s,
|
|
2524
|
+
var t, r, a, s, m, u, p, f, h, l, C, k, _, T, v, y, M, R, S, N, D, I, A, G, W, x, E, q, F, L, V, H, Y, j, Q, K, z, J, X, Z, ee, te, re, ae, ne, ie, oe, se, ye;
|
|
2408
2525
|
return {
|
|
2409
2526
|
timezone: e.timezone,
|
|
2410
2527
|
currency: e.currency,
|
|
2411
2528
|
paymentSettings: {
|
|
2412
|
-
minimumFirstDepositAmount:
|
|
2529
|
+
minimumFirstDepositAmount: i(e.minimumFirstDepositAmount),
|
|
2413
2530
|
restrictWithdrawalsToVerifiedMembers: e.restrictWithdrawalsToVerifiedMembers,
|
|
2414
2531
|
depositGateway: {
|
|
2415
2532
|
bank: {
|
|
@@ -2417,77 +2534,167 @@ class Ot {
|
|
|
2417
2534
|
iosEnabled: ((r = e.bankDepositGatewaySettings) == null ? void 0 : r.iosEnabled) ?? !1,
|
|
2418
2535
|
webEnabled: ((a = e.bankDepositGatewaySettings) == null ? void 0 : a.webEnabled) ?? !1,
|
|
2419
2536
|
mobileWebEnabled: ((s = e.bankDepositGatewaySettings) == null ? void 0 : s.mobileWebEnabled) ?? !1,
|
|
2420
|
-
minimumAmount:
|
|
2421
|
-
maximumAmount:
|
|
2537
|
+
minimumAmount: i((m = e.bankDepositGatewaySettings) == null ? void 0 : m.minimumAmount),
|
|
2538
|
+
maximumAmount: i((u = e.bankDepositGatewaySettings) == null ? void 0 : u.maximumAmount)
|
|
2422
2539
|
},
|
|
2423
2540
|
gcash: {
|
|
2424
2541
|
androidEnabled: ((p = e.gcashDepositGatewaySettings) == null ? void 0 : p.androidEnabled) ?? !1,
|
|
2425
2542
|
iosEnabled: ((f = e.gcashDepositGatewaySettings) == null ? void 0 : f.iosEnabled) ?? !1,
|
|
2426
|
-
webEnabled: ((
|
|
2543
|
+
webEnabled: ((h = e.gcashDepositGatewaySettings) == null ? void 0 : h.webEnabled) ?? !1,
|
|
2427
2544
|
mobileWebEnabled: ((l = e.gcashDepositGatewaySettings) == null ? void 0 : l.mobileWebEnabled) ?? !1,
|
|
2428
|
-
minimumAmount:
|
|
2429
|
-
maximumAmount:
|
|
2545
|
+
minimumAmount: i((C = e.gcashDepositGatewaySettings) == null ? void 0 : C.minimumAmount),
|
|
2546
|
+
maximumAmount: i((k = e.gcashDepositGatewaySettings) == null ? void 0 : k.maximumAmount)
|
|
2430
2547
|
},
|
|
2431
2548
|
maya: {
|
|
2432
|
-
androidEnabled: ((
|
|
2433
|
-
iosEnabled: ((
|
|
2434
|
-
webEnabled: ((
|
|
2435
|
-
mobileWebEnabled: ((
|
|
2436
|
-
minimumAmount:
|
|
2437
|
-
maximumAmount:
|
|
2549
|
+
androidEnabled: ((_ = e.mayaDepositGatewaySettings) == null ? void 0 : _.androidEnabled) ?? !1,
|
|
2550
|
+
iosEnabled: ((T = e.mayaDepositGatewaySettings) == null ? void 0 : T.iosEnabled) ?? !1,
|
|
2551
|
+
webEnabled: ((v = e.mayaDepositGatewaySettings) == null ? void 0 : v.webEnabled) ?? !1,
|
|
2552
|
+
mobileWebEnabled: ((y = e.mayaDepositGatewaySettings) == null ? void 0 : y.mobileWebEnabled) ?? !1,
|
|
2553
|
+
minimumAmount: i((M = e.mayaDepositGatewaySettings) == null ? void 0 : M.minimumAmount),
|
|
2554
|
+
maximumAmount: i((R = e.mayaDepositGatewaySettings) == null ? void 0 : R.maximumAmount)
|
|
2438
2555
|
},
|
|
2439
2556
|
mayaApp: {
|
|
2440
2557
|
androidEnabled: ((S = e.mayaAppDepositGatewaySettings) == null ? void 0 : S.androidEnabled) ?? !1,
|
|
2441
|
-
iosEnabled: ((
|
|
2442
|
-
webEnabled: ((
|
|
2443
|
-
mobileWebEnabled: ((
|
|
2444
|
-
minimumAmount:
|
|
2445
|
-
maximumAmount:
|
|
2558
|
+
iosEnabled: ((N = e.mayaAppDepositGatewaySettings) == null ? void 0 : N.iosEnabled) ?? !1,
|
|
2559
|
+
webEnabled: ((D = e.mayaAppDepositGatewaySettings) == null ? void 0 : D.webEnabled) ?? !1,
|
|
2560
|
+
mobileWebEnabled: ((I = e.mayaAppDepositGatewaySettings) == null ? void 0 : I.mobileWebEnabled) ?? !1,
|
|
2561
|
+
minimumAmount: i((A = e.mayaAppDepositGatewaySettings) == null ? void 0 : A.minimumAmount),
|
|
2562
|
+
maximumAmount: i((G = e.mayaAppDepositGatewaySettings) == null ? void 0 : G.maximumAmount)
|
|
2446
2563
|
}
|
|
2447
2564
|
},
|
|
2448
2565
|
withdrawalGateway: {
|
|
2449
2566
|
bank: {
|
|
2450
|
-
androidEnabled: ((
|
|
2451
|
-
iosEnabled: ((
|
|
2452
|
-
webEnabled: ((
|
|
2453
|
-
mobileWebEnabled: ((
|
|
2454
|
-
minimumAmount:
|
|
2455
|
-
maximumAmount:
|
|
2567
|
+
androidEnabled: ((W = e.bankWithdrawalGatewaySettings) == null ? void 0 : W.androidEnabled) ?? !1,
|
|
2568
|
+
iosEnabled: ((x = e.bankWithdrawalGatewaySettings) == null ? void 0 : x.iosEnabled) ?? !1,
|
|
2569
|
+
webEnabled: ((E = e.bankWithdrawalGatewaySettings) == null ? void 0 : E.webEnabled) ?? !1,
|
|
2570
|
+
mobileWebEnabled: ((q = e.bankWithdrawalGatewaySettings) == null ? void 0 : q.mobileWebEnabled) ?? !1,
|
|
2571
|
+
minimumAmount: i((F = e.bankWithdrawalGatewaySettings) == null ? void 0 : F.minimumAmount),
|
|
2572
|
+
maximumAmount: i((L = e.bankWithdrawalGatewaySettings) == null ? void 0 : L.maximumAmount)
|
|
2456
2573
|
},
|
|
2457
2574
|
gcash: {
|
|
2458
|
-
androidEnabled: ((
|
|
2459
|
-
iosEnabled: ((
|
|
2460
|
-
webEnabled: ((
|
|
2461
|
-
mobileWebEnabled: ((
|
|
2462
|
-
minimumAmount:
|
|
2463
|
-
maximumAmount:
|
|
2464
|
-
(
|
|
2575
|
+
androidEnabled: ((V = e.gcashWithdrawalGatewaySettings) == null ? void 0 : V.androidEnabled) ?? !1,
|
|
2576
|
+
iosEnabled: ((H = e.gcashWithdrawalGatewaySettings) == null ? void 0 : H.iosEnabled) ?? !1,
|
|
2577
|
+
webEnabled: ((Y = e.gcashWithdrawalGatewaySettings) == null ? void 0 : Y.webEnabled) ?? !1,
|
|
2578
|
+
mobileWebEnabled: ((j = e.gcashWithdrawalGatewaySettings) == null ? void 0 : j.mobileWebEnabled) ?? !1,
|
|
2579
|
+
minimumAmount: i((Q = e.gcashWithdrawalGatewaySettings) == null ? void 0 : Q.minimumAmount),
|
|
2580
|
+
maximumAmount: i(
|
|
2581
|
+
(K = e.gcashWithdrawalGatewaySettings) == null ? void 0 : K.maximumAmount,
|
|
2465
2582
|
1e6
|
|
2466
2583
|
)
|
|
2467
2584
|
},
|
|
2468
2585
|
maya: {
|
|
2469
|
-
androidEnabled: ((
|
|
2470
|
-
iosEnabled: ((
|
|
2471
|
-
webEnabled: ((
|
|
2472
|
-
mobileWebEnabled: ((
|
|
2473
|
-
minimumAmount:
|
|
2474
|
-
maximumAmount:
|
|
2586
|
+
androidEnabled: ((z = e.mayaWithdrawalGatewaySettings) == null ? void 0 : z.androidEnabled) ?? !1,
|
|
2587
|
+
iosEnabled: ((J = e.mayaWithdrawalGatewaySettings) == null ? void 0 : J.iosEnabled) ?? !1,
|
|
2588
|
+
webEnabled: ((X = e.mayaWithdrawalGatewaySettings) == null ? void 0 : X.webEnabled) ?? !1,
|
|
2589
|
+
mobileWebEnabled: ((Z = e.mayaWithdrawalGatewaySettings) == null ? void 0 : Z.mobileWebEnabled) ?? !1,
|
|
2590
|
+
minimumAmount: i((ee = e.mayaWithdrawalGatewaySettings) == null ? void 0 : ee.minimumAmount),
|
|
2591
|
+
maximumAmount: i((te = e.mayaWithdrawalGatewaySettings) == null ? void 0 : te.maximumAmount)
|
|
2475
2592
|
},
|
|
2476
2593
|
mayaApp: {
|
|
2477
|
-
androidEnabled: ((
|
|
2478
|
-
iosEnabled: ((
|
|
2479
|
-
webEnabled: ((
|
|
2480
|
-
mobileWebEnabled: ((
|
|
2481
|
-
minimumAmount:
|
|
2482
|
-
maximumAmount:
|
|
2483
|
-
(
|
|
2594
|
+
androidEnabled: ((re = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : re.androidEnabled) ?? !1,
|
|
2595
|
+
iosEnabled: ((ae = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ae.iosEnabled) ?? !1,
|
|
2596
|
+
webEnabled: ((ne = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ne.webEnabled) ?? !1,
|
|
2597
|
+
mobileWebEnabled: ((ie = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ie.mobileWebEnabled) ?? !1,
|
|
2598
|
+
minimumAmount: i((oe = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : oe.minimumAmount),
|
|
2599
|
+
maximumAmount: i(
|
|
2600
|
+
(se = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : se.maximumAmount,
|
|
2484
2601
|
1e6
|
|
2485
2602
|
)
|
|
2486
2603
|
}
|
|
2487
2604
|
}
|
|
2488
2605
|
},
|
|
2489
2606
|
pointsClubSettings: {
|
|
2490
|
-
multiplier:
|
|
2607
|
+
multiplier: i((ye = e.pointsClubSettings) == null ? void 0 : ye.multiplier, 0)
|
|
2608
|
+
}
|
|
2609
|
+
};
|
|
2610
|
+
}
|
|
2611
|
+
platform__next(e) {
|
|
2612
|
+
return {
|
|
2613
|
+
currency: e.currency,
|
|
2614
|
+
timezone: e.timezone,
|
|
2615
|
+
locale: qt(e.currency)
|
|
2616
|
+
};
|
|
2617
|
+
}
|
|
2618
|
+
pointsClubSettings(e) {
|
|
2619
|
+
return {
|
|
2620
|
+
multiplier: i(e.multiplier, 0)
|
|
2621
|
+
};
|
|
2622
|
+
}
|
|
2623
|
+
paymentSettings(e) {
|
|
2624
|
+
var t, r, a, s, m, u, p, f, h, l, C, k, _, T, v, y, M, R, S, N, D, I, A, G, W, x, E, q, F, L, V, H, Y, j, Q, K, z, J, X, Z, ee, te, re, ae, ne, ie, oe, se;
|
|
2625
|
+
return {
|
|
2626
|
+
minimumFirstDepositAmount: i(e.minimumFirstDepositAmount),
|
|
2627
|
+
restrictWithdrawalsToVerifiedMembers: e.restrictWithdrawalsToVerifiedMembers,
|
|
2628
|
+
depositGateway: {
|
|
2629
|
+
bank: {
|
|
2630
|
+
androidEnabled: ((t = e.bankDepositGatewaySettings) == null ? void 0 : t.androidEnabled) ?? !1,
|
|
2631
|
+
iosEnabled: ((r = e.bankDepositGatewaySettings) == null ? void 0 : r.iosEnabled) ?? !1,
|
|
2632
|
+
webEnabled: ((a = e.bankDepositGatewaySettings) == null ? void 0 : a.webEnabled) ?? !1,
|
|
2633
|
+
mobileWebEnabled: ((s = e.bankDepositGatewaySettings) == null ? void 0 : s.mobileWebEnabled) ?? !1,
|
|
2634
|
+
minimumAmount: i((m = e.bankDepositGatewaySettings) == null ? void 0 : m.minimumAmount),
|
|
2635
|
+
maximumAmount: i((u = e.bankDepositGatewaySettings) == null ? void 0 : u.maximumAmount)
|
|
2636
|
+
},
|
|
2637
|
+
gcash: {
|
|
2638
|
+
androidEnabled: ((p = e.gcashDepositGatewaySettings) == null ? void 0 : p.androidEnabled) ?? !1,
|
|
2639
|
+
iosEnabled: ((f = e.gcashDepositGatewaySettings) == null ? void 0 : f.iosEnabled) ?? !1,
|
|
2640
|
+
webEnabled: ((h = e.gcashDepositGatewaySettings) == null ? void 0 : h.webEnabled) ?? !1,
|
|
2641
|
+
mobileWebEnabled: ((l = e.gcashDepositGatewaySettings) == null ? void 0 : l.mobileWebEnabled) ?? !1,
|
|
2642
|
+
minimumAmount: i((C = e.gcashDepositGatewaySettings) == null ? void 0 : C.minimumAmount),
|
|
2643
|
+
maximumAmount: i((k = e.gcashDepositGatewaySettings) == null ? void 0 : k.maximumAmount)
|
|
2644
|
+
},
|
|
2645
|
+
maya: {
|
|
2646
|
+
androidEnabled: ((_ = e.mayaDepositGatewaySettings) == null ? void 0 : _.androidEnabled) ?? !1,
|
|
2647
|
+
iosEnabled: ((T = e.mayaDepositGatewaySettings) == null ? void 0 : T.iosEnabled) ?? !1,
|
|
2648
|
+
webEnabled: ((v = e.mayaDepositGatewaySettings) == null ? void 0 : v.webEnabled) ?? !1,
|
|
2649
|
+
mobileWebEnabled: ((y = e.mayaDepositGatewaySettings) == null ? void 0 : y.mobileWebEnabled) ?? !1,
|
|
2650
|
+
minimumAmount: i((M = e.mayaDepositGatewaySettings) == null ? void 0 : M.minimumAmount),
|
|
2651
|
+
maximumAmount: i((R = e.mayaDepositGatewaySettings) == null ? void 0 : R.maximumAmount)
|
|
2652
|
+
},
|
|
2653
|
+
mayaApp: {
|
|
2654
|
+
androidEnabled: ((S = e.mayaAppDepositGatewaySettings) == null ? void 0 : S.androidEnabled) ?? !1,
|
|
2655
|
+
iosEnabled: ((N = e.mayaAppDepositGatewaySettings) == null ? void 0 : N.iosEnabled) ?? !1,
|
|
2656
|
+
webEnabled: ((D = e.mayaAppDepositGatewaySettings) == null ? void 0 : D.webEnabled) ?? !1,
|
|
2657
|
+
mobileWebEnabled: ((I = e.mayaAppDepositGatewaySettings) == null ? void 0 : I.mobileWebEnabled) ?? !1,
|
|
2658
|
+
minimumAmount: i((A = e.mayaAppDepositGatewaySettings) == null ? void 0 : A.minimumAmount),
|
|
2659
|
+
maximumAmount: i((G = e.mayaAppDepositGatewaySettings) == null ? void 0 : G.maximumAmount)
|
|
2660
|
+
}
|
|
2661
|
+
},
|
|
2662
|
+
withdrawalGateway: {
|
|
2663
|
+
bank: {
|
|
2664
|
+
androidEnabled: ((W = e.bankWithdrawalGatewaySettings) == null ? void 0 : W.androidEnabled) ?? !1,
|
|
2665
|
+
iosEnabled: ((x = e.bankWithdrawalGatewaySettings) == null ? void 0 : x.iosEnabled) ?? !1,
|
|
2666
|
+
webEnabled: ((E = e.bankWithdrawalGatewaySettings) == null ? void 0 : E.webEnabled) ?? !1,
|
|
2667
|
+
mobileWebEnabled: ((q = e.bankWithdrawalGatewaySettings) == null ? void 0 : q.mobileWebEnabled) ?? !1,
|
|
2668
|
+
minimumAmount: i((F = e.bankWithdrawalGatewaySettings) == null ? void 0 : F.minimumAmount),
|
|
2669
|
+
maximumAmount: i((L = e.bankWithdrawalGatewaySettings) == null ? void 0 : L.maximumAmount)
|
|
2670
|
+
},
|
|
2671
|
+
gcash: {
|
|
2672
|
+
androidEnabled: ((V = e.gcashWithdrawalGatewaySettings) == null ? void 0 : V.androidEnabled) ?? !1,
|
|
2673
|
+
iosEnabled: ((H = e.gcashWithdrawalGatewaySettings) == null ? void 0 : H.iosEnabled) ?? !1,
|
|
2674
|
+
webEnabled: ((Y = e.gcashWithdrawalGatewaySettings) == null ? void 0 : Y.webEnabled) ?? !1,
|
|
2675
|
+
mobileWebEnabled: ((j = e.gcashWithdrawalGatewaySettings) == null ? void 0 : j.mobileWebEnabled) ?? !1,
|
|
2676
|
+
minimumAmount: i((Q = e.gcashWithdrawalGatewaySettings) == null ? void 0 : Q.minimumAmount),
|
|
2677
|
+
maximumAmount: i((K = e.gcashWithdrawalGatewaySettings) == null ? void 0 : K.maximumAmount, 1e6)
|
|
2678
|
+
},
|
|
2679
|
+
maya: {
|
|
2680
|
+
androidEnabled: ((z = e.mayaWithdrawalGatewaySettings) == null ? void 0 : z.androidEnabled) ?? !1,
|
|
2681
|
+
iosEnabled: ((J = e.mayaWithdrawalGatewaySettings) == null ? void 0 : J.iosEnabled) ?? !1,
|
|
2682
|
+
webEnabled: ((X = e.mayaWithdrawalGatewaySettings) == null ? void 0 : X.webEnabled) ?? !1,
|
|
2683
|
+
mobileWebEnabled: ((Z = e.mayaWithdrawalGatewaySettings) == null ? void 0 : Z.mobileWebEnabled) ?? !1,
|
|
2684
|
+
minimumAmount: i((ee = e.mayaWithdrawalGatewaySettings) == null ? void 0 : ee.minimumAmount),
|
|
2685
|
+
maximumAmount: i((te = e.mayaWithdrawalGatewaySettings) == null ? void 0 : te.maximumAmount)
|
|
2686
|
+
},
|
|
2687
|
+
mayaApp: {
|
|
2688
|
+
androidEnabled: ((re = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : re.androidEnabled) ?? !1,
|
|
2689
|
+
iosEnabled: ((ae = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ae.iosEnabled) ?? !1,
|
|
2690
|
+
webEnabled: ((ne = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ne.webEnabled) ?? !1,
|
|
2691
|
+
mobileWebEnabled: ((ie = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : ie.mobileWebEnabled) ?? !1,
|
|
2692
|
+
minimumAmount: i((oe = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : oe.minimumAmount),
|
|
2693
|
+
maximumAmount: i(
|
|
2694
|
+
(se = e.mayaAppWithdrawalGatewaySettings) == null ? void 0 : se.maximumAmount,
|
|
2695
|
+
1e6
|
|
2696
|
+
)
|
|
2697
|
+
}
|
|
2491
2698
|
}
|
|
2492
2699
|
};
|
|
2493
2700
|
}
|
|
@@ -2511,12 +2718,12 @@ class Ot {
|
|
|
2511
2718
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2512
2719
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
2513
2720
|
};
|
|
2514
|
-
return
|
|
2721
|
+
return b(t);
|
|
2515
2722
|
}
|
|
2516
2723
|
wallet(e) {
|
|
2517
2724
|
return {
|
|
2518
2725
|
id: e.id,
|
|
2519
|
-
balance:
|
|
2726
|
+
balance: i(e.balance, 0),
|
|
2520
2727
|
currency: e.currency,
|
|
2521
2728
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2522
2729
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
@@ -2543,7 +2750,7 @@ class Ot {
|
|
|
2543
2750
|
mobileNumberVerification: e.mobileNumberVerification ?? !1,
|
|
2544
2751
|
personalInformation: e.personalInformation ?? !1,
|
|
2545
2752
|
transactionPassword: e.transactionPassword ?? !1,
|
|
2546
|
-
completionPercentage:
|
|
2753
|
+
completionPercentage: i(e.completionPercentage, 0)
|
|
2547
2754
|
};
|
|
2548
2755
|
}
|
|
2549
2756
|
announcement(e) {
|
|
@@ -2565,9 +2772,9 @@ class Ot {
|
|
|
2565
2772
|
type: e.type,
|
|
2566
2773
|
bank: e.bank,
|
|
2567
2774
|
status: e.status,
|
|
2568
|
-
amount:
|
|
2569
|
-
netAmount:
|
|
2570
|
-
fee:
|
|
2775
|
+
amount: i(e.amount, 0),
|
|
2776
|
+
netAmount: i(e.netAmount, 0),
|
|
2777
|
+
fee: i(e.fee, 0),
|
|
2571
2778
|
reference: e.reference ?? void 0,
|
|
2572
2779
|
withdrawalNumber: e.withdrawalNumber,
|
|
2573
2780
|
recipientMobileNumber: e.recipientMobileNumber ?? void 0,
|
|
@@ -2575,7 +2782,7 @@ class Ot {
|
|
|
2575
2782
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2576
2783
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
2577
2784
|
};
|
|
2578
|
-
return
|
|
2785
|
+
return b(t);
|
|
2579
2786
|
}
|
|
2580
2787
|
deposit(e) {
|
|
2581
2788
|
const t = {
|
|
@@ -2584,34 +2791,34 @@ class Ot {
|
|
|
2584
2791
|
status: e.status,
|
|
2585
2792
|
checkoutUrl: e.checkoutUrl ?? void 0
|
|
2586
2793
|
};
|
|
2587
|
-
return
|
|
2794
|
+
return b(t);
|
|
2588
2795
|
}
|
|
2589
2796
|
depositRecord(e) {
|
|
2590
2797
|
const t = {
|
|
2591
2798
|
id: e.id,
|
|
2592
2799
|
type: e.type,
|
|
2593
2800
|
status: e.status,
|
|
2594
|
-
amount:
|
|
2595
|
-
fee:
|
|
2596
|
-
netAmount:
|
|
2801
|
+
amount: i(e.amount, 0),
|
|
2802
|
+
fee: i(e.fee, 0),
|
|
2803
|
+
netAmount: i(e.netAmount, 0),
|
|
2597
2804
|
reference: e.reference ?? void 0,
|
|
2598
2805
|
depositNumber: e.depositNumber,
|
|
2599
2806
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2600
2807
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
2601
2808
|
};
|
|
2602
|
-
return
|
|
2809
|
+
return b(t);
|
|
2603
2810
|
}
|
|
2604
2811
|
betRecord(e) {
|
|
2605
2812
|
var r;
|
|
2606
2813
|
const t = {
|
|
2607
2814
|
id: e.id,
|
|
2608
|
-
bet:
|
|
2609
|
-
payout:
|
|
2815
|
+
bet: i(e.bet, 0),
|
|
2816
|
+
payout: i(e.payout, 0),
|
|
2610
2817
|
status: e.status,
|
|
2611
|
-
jackpotContribution:
|
|
2612
|
-
jackpotPayout:
|
|
2613
|
-
winloss:
|
|
2614
|
-
validBet:
|
|
2818
|
+
jackpotContribution: i(e.jackpotContribution, 0),
|
|
2819
|
+
jackpotPayout: i(e.jackpotPayout, 0),
|
|
2820
|
+
winloss: i(e.winloss),
|
|
2821
|
+
validBet: i(e.validBet, 0),
|
|
2615
2822
|
vendorRoundId: e.vendorRoundId ?? void 0,
|
|
2616
2823
|
game: {
|
|
2617
2824
|
name: e.game.name,
|
|
@@ -2630,7 +2837,7 @@ class Ot {
|
|
|
2630
2837
|
odds: ((r = e.metadata) == null ? void 0 : r.odds) ?? void 0
|
|
2631
2838
|
}
|
|
2632
2839
|
};
|
|
2633
|
-
return
|
|
2840
|
+
return b(t);
|
|
2634
2841
|
}
|
|
2635
2842
|
latestBetRecord(e) {
|
|
2636
2843
|
return {
|
|
@@ -2642,9 +2849,9 @@ class Ot {
|
|
|
2642
2849
|
images: this.staticService.gameThumbnails(e.game),
|
|
2643
2850
|
provider: e.game.provider
|
|
2644
2851
|
},
|
|
2645
|
-
bet:
|
|
2646
|
-
payout:
|
|
2647
|
-
validBet:
|
|
2852
|
+
bet: i(e.bet, 0),
|
|
2853
|
+
payout: i(e.payout, 0),
|
|
2854
|
+
validBet: i(e.validBet, 0),
|
|
2648
2855
|
dateTimeSettled: new Date(e.dateTimeSettled),
|
|
2649
2856
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2650
2857
|
};
|
|
@@ -2653,13 +2860,13 @@ class Ot {
|
|
|
2653
2860
|
const t = {
|
|
2654
2861
|
id: e.id,
|
|
2655
2862
|
type: e.type,
|
|
2656
|
-
amount:
|
|
2863
|
+
amount: i(e.amount, 0),
|
|
2657
2864
|
content: e.content ?? void 0,
|
|
2658
|
-
currentBalance:
|
|
2865
|
+
currentBalance: i(e.currentBalance, 0),
|
|
2659
2866
|
referenceNumber: e.referenceNumber,
|
|
2660
2867
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2661
2868
|
};
|
|
2662
|
-
return
|
|
2869
|
+
return b(t);
|
|
2663
2870
|
}
|
|
2664
2871
|
game(e) {
|
|
2665
2872
|
return {
|
|
@@ -2680,7 +2887,7 @@ class Ot {
|
|
|
2680
2887
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2681
2888
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
2682
2889
|
};
|
|
2683
|
-
return
|
|
2890
|
+
return b(t);
|
|
2684
2891
|
}
|
|
2685
2892
|
promo(e) {
|
|
2686
2893
|
return {
|
|
@@ -2690,8 +2897,8 @@ class Ot {
|
|
|
2690
2897
|
status: e.status,
|
|
2691
2898
|
description: e.description,
|
|
2692
2899
|
banner: this.file(e.banner),
|
|
2693
|
-
maximumBonusAmount:
|
|
2694
|
-
minimumBonusAmount:
|
|
2900
|
+
maximumBonusAmount: i(e.maximumBonusAmount),
|
|
2901
|
+
minimumBonusAmount: i(e.minimumBonusAmount),
|
|
2695
2902
|
activationEndDateTime: new Date(e.activationEndDateTime),
|
|
2696
2903
|
activationStartDateTime: new Date(e.activationStartDateTime),
|
|
2697
2904
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
@@ -2704,8 +2911,8 @@ class Ot {
|
|
|
2704
2911
|
name: e.name,
|
|
2705
2912
|
description: e.description,
|
|
2706
2913
|
status: e.status,
|
|
2707
|
-
minimumCashback:
|
|
2708
|
-
maximumMonthlyCashback:
|
|
2914
|
+
minimumCashback: i(e.minimumCashback, 0),
|
|
2915
|
+
maximumMonthlyCashback: i(e.maximumMonthlyCashback),
|
|
2709
2916
|
banner: this.file(e.banner),
|
|
2710
2917
|
activationEndDateTime: new Date(e.activationEndDateTime),
|
|
2711
2918
|
activationStartDateTime: new Date(e.activationStartDateTime),
|
|
@@ -2713,7 +2920,7 @@ class Ot {
|
|
|
2713
2920
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated),
|
|
2714
2921
|
turnoverContributionPercentagePerGameProvider: Object.entries(
|
|
2715
2922
|
e.turnoverContributionPercentagePerGameProvider
|
|
2716
|
-
).reduce((r, [a, s]) => (r[a] =
|
|
2923
|
+
).reduce((r, [a, s]) => (r[a] = i(s, 0), r), {})
|
|
2717
2924
|
};
|
|
2718
2925
|
}
|
|
2719
2926
|
bonus(e) {
|
|
@@ -2723,35 +2930,35 @@ class Ot {
|
|
|
2723
2930
|
deposit: e.deposit ? {
|
|
2724
2931
|
type: e.deposit.type,
|
|
2725
2932
|
status: e.deposit.status,
|
|
2726
|
-
fee:
|
|
2727
|
-
amount:
|
|
2728
|
-
netAmount:
|
|
2933
|
+
fee: i(e.deposit.fee, 0),
|
|
2934
|
+
amount: i(e.deposit.amount, 0),
|
|
2935
|
+
netAmount: i(e.deposit.netAmount, 0),
|
|
2729
2936
|
reference: e.deposit.reference ?? void 0,
|
|
2730
2937
|
dateTimeCreated: new Date(e.deposit.dateTimeCreated),
|
|
2731
2938
|
dateTimeLastUpdated: new Date(e.deposit.dateTimeLastUpdated)
|
|
2732
2939
|
} : void 0,
|
|
2733
|
-
balance:
|
|
2734
|
-
amount:
|
|
2940
|
+
balance: i(e.balance, 0),
|
|
2941
|
+
amount: i(e.amount, 0),
|
|
2735
2942
|
expiration: new Date(e.expiration),
|
|
2736
|
-
turnoverRequirement:
|
|
2737
|
-
currentTurnoverRequirementContribution:
|
|
2943
|
+
turnoverRequirement: i(e.turnoverRequirement, 0),
|
|
2944
|
+
currentTurnoverRequirementContribution: i(
|
|
2738
2945
|
e.currentTurnoverRequirementContribution,
|
|
2739
2946
|
0
|
|
2740
2947
|
),
|
|
2741
|
-
currentTurnoverRequirementContributionPercentage:
|
|
2948
|
+
currentTurnoverRequirementContributionPercentage: i(
|
|
2742
2949
|
e.currentTurnoverRequirementContributionPercentage,
|
|
2743
2950
|
0
|
|
2744
2951
|
),
|
|
2745
2952
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2746
2953
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
2747
2954
|
};
|
|
2748
|
-
return
|
|
2955
|
+
return b(t);
|
|
2749
2956
|
}
|
|
2750
2957
|
cashbackBonus(e) {
|
|
2751
2958
|
return {
|
|
2752
2959
|
id: e.id,
|
|
2753
|
-
total:
|
|
2754
|
-
balance:
|
|
2960
|
+
total: i(e.total, 0),
|
|
2961
|
+
balance: i(e.balance, 0),
|
|
2755
2962
|
cashback: this.cashback(e.cashback),
|
|
2756
2963
|
dateTimeCreated: new Date(e.dateTimeCreated),
|
|
2757
2964
|
dateTimeLastUpdated: new Date(e.dateTimeLastUpdated)
|
|
@@ -2764,12 +2971,12 @@ class Ot {
|
|
|
2764
2971
|
status: e.status,
|
|
2765
2972
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2766
2973
|
};
|
|
2767
|
-
return
|
|
2974
|
+
return b(t);
|
|
2768
2975
|
}
|
|
2769
2976
|
pointsWallet(e) {
|
|
2770
2977
|
return {
|
|
2771
2978
|
id: e.id,
|
|
2772
|
-
points:
|
|
2979
|
+
points: i(e.points, 0),
|
|
2773
2980
|
account: e.account,
|
|
2774
2981
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2775
2982
|
};
|
|
@@ -2778,8 +2985,8 @@ class Ot {
|
|
|
2778
2985
|
return {
|
|
2779
2986
|
id: e.id,
|
|
2780
2987
|
type: e.type,
|
|
2781
|
-
amount:
|
|
2782
|
-
balance:
|
|
2988
|
+
amount: i(e.amount, 0),
|
|
2989
|
+
balance: i(e.balance, 0),
|
|
2783
2990
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2784
2991
|
};
|
|
2785
2992
|
}
|
|
@@ -2787,12 +2994,12 @@ class Ot {
|
|
|
2787
2994
|
const t = {
|
|
2788
2995
|
id: e.id,
|
|
2789
2996
|
type: e.type,
|
|
2790
|
-
amount: e.amount ?
|
|
2997
|
+
amount: e.amount ? i(e.amount, 0) : void 0,
|
|
2791
2998
|
domain: e.domain ?? void 0,
|
|
2792
2999
|
details: e.details,
|
|
2793
3000
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2794
3001
|
};
|
|
2795
|
-
return
|
|
3002
|
+
return b(t);
|
|
2796
3003
|
}
|
|
2797
3004
|
referral(e) {
|
|
2798
3005
|
return {
|
|
@@ -2800,18 +3007,18 @@ class Ot {
|
|
|
2800
3007
|
level: e.level,
|
|
2801
3008
|
upline: e.upline,
|
|
2802
3009
|
downline: e.downline,
|
|
2803
|
-
turnover:
|
|
2804
|
-
|
|
3010
|
+
turnover: i(e.turnover, 0),
|
|
3011
|
+
commission: i(e.commission, 0),
|
|
2805
3012
|
dateTimeCreated: new Date(e.dateTimeCreated)
|
|
2806
3013
|
};
|
|
2807
3014
|
}
|
|
2808
3015
|
referralCommission(e) {
|
|
2809
3016
|
return {
|
|
2810
3017
|
id: e.id,
|
|
2811
|
-
commission:
|
|
2812
|
-
level1Commission:
|
|
2813
|
-
level2Commission:
|
|
2814
|
-
level3Commission:
|
|
3018
|
+
commission: i(e.commission, 0),
|
|
3019
|
+
level1Commission: i(e.level1Commission, 0),
|
|
3020
|
+
level2Commission: i(e.level2Commission, 0),
|
|
3021
|
+
level3Commission: i(e.level3Commission, 0),
|
|
2815
3022
|
referralsCount: e.referralsCount,
|
|
2816
3023
|
level1ReferralsCount: e.level1ReferralsCount,
|
|
2817
3024
|
level2ReferralsCount: e.level2ReferralsCount,
|
|
@@ -2822,37 +3029,38 @@ class Ot {
|
|
|
2822
3029
|
};
|
|
2823
3030
|
}
|
|
2824
3031
|
}
|
|
2825
|
-
class
|
|
3032
|
+
class jt {
|
|
2826
3033
|
constructor(e) {
|
|
2827
|
-
|
|
2828
|
-
|
|
2829
|
-
|
|
2830
|
-
|
|
2831
|
-
|
|
2832
|
-
|
|
2833
|
-
|
|
2834
|
-
|
|
2835
|
-
|
|
2836
|
-
|
|
2837
|
-
|
|
3034
|
+
c(this, "cmsPortalService");
|
|
3035
|
+
c(this, "authService");
|
|
3036
|
+
c(this, "gameService");
|
|
3037
|
+
c(this, "fileService");
|
|
3038
|
+
c(this, "walletService");
|
|
3039
|
+
c(this, "accountService");
|
|
3040
|
+
c(this, "reportService");
|
|
3041
|
+
c(this, "portalService");
|
|
3042
|
+
c(this, "sessionManager");
|
|
3043
|
+
c(this, "transformer");
|
|
3044
|
+
c(this, "logger");
|
|
3045
|
+
c(this, "cache");
|
|
2838
3046
|
const {
|
|
2839
3047
|
/**/
|
|
2840
3048
|
site: t,
|
|
2841
3049
|
sitePlatform: r,
|
|
2842
3050
|
platform: a,
|
|
2843
3051
|
environment: s,
|
|
2844
|
-
logs:
|
|
3052
|
+
logs: m
|
|
2845
3053
|
} = e, u = s === "production";
|
|
2846
|
-
this.transformer = new
|
|
3054
|
+
this.transformer = new Vt({
|
|
2847
3055
|
environment: s
|
|
2848
3056
|
}), this.logger = new Ce({
|
|
2849
|
-
enabled:
|
|
3057
|
+
enabled: m ?? !1
|
|
2850
3058
|
});
|
|
2851
|
-
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",
|
|
2852
|
-
url:
|
|
3059
|
+
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", h = u ? "https://report.opexa.io/graphql" : "https://report.development.opexa.io/graphql", l = u ? "https://account.opexa.io/graphql" : "https://account.development.opexa.io/graphql", C = u ? "https://portal.opexa.io/graphql" : "https://portal.development.opexa.io/graphql", k = 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 = "https://portal-api.opexacms.io/v1", v = new Nt({
|
|
3060
|
+
url: T,
|
|
2853
3061
|
site: t,
|
|
2854
3062
|
platform: r
|
|
2855
|
-
}),
|
|
3063
|
+
}), y = {
|
|
2856
3064
|
middlewares: [this.authMiddleware],
|
|
2857
3065
|
fetchOptions: {
|
|
2858
3066
|
headers: {
|
|
@@ -2860,15 +3068,15 @@ class qt {
|
|
|
2860
3068
|
"Platform-Code": a
|
|
2861
3069
|
}
|
|
2862
3070
|
}
|
|
2863
|
-
},
|
|
3071
|
+
}, M = new It(new O(_, y)), R = new Dt(new O(k, y)), S = new xt(new O(f, y)), N = new Mt(new O(l, y)), D = new Pt(new O(h, y)), I = new Gt(new O(C, y)), A = new Rt({
|
|
2864
3072
|
url: p,
|
|
2865
3073
|
platform: a
|
|
2866
|
-
}),
|
|
2867
|
-
logs:
|
|
2868
|
-
authService:
|
|
3074
|
+
}), G = new Lt({
|
|
3075
|
+
logs: m,
|
|
3076
|
+
authService: A,
|
|
2869
3077
|
walletService: S
|
|
2870
3078
|
});
|
|
2871
|
-
this.authService =
|
|
3079
|
+
this.authService = A, this.gameService = M, this.fileService = R, this.walletService = S, this.accountService = N, this.reportService = D, this.portalService = I, this.sessionManager = G, this.cmsPortalService = v, this.cache = new $t();
|
|
2872
3080
|
}
|
|
2873
3081
|
get authMiddleware() {
|
|
2874
3082
|
return async (e) => {
|
|
@@ -2877,12 +3085,21 @@ class qt {
|
|
|
2877
3085
|
return t.data ? (e.headers.append("Authorization", `Bearer ${t.data.accessToken}`), this.logger.info("Session found"), this.logger.success("Added 'Authorization' header")) : this.logger.info("No session found"), e;
|
|
2878
3086
|
};
|
|
2879
3087
|
}
|
|
3088
|
+
get locale() {
|
|
3089
|
+
return new Promise((e) => {
|
|
3090
|
+
const t = "locale", r = this.cache.get(t);
|
|
3091
|
+
if (r) return e(r);
|
|
3092
|
+
this.platform__next().then((a) => {
|
|
3093
|
+
a.ok ? (this.cache.set(t, a.data.locale), e(a.data.locale)) : (this.logger.warn("Failed to fetch currency. Using 'PH' as fallback"), e("en-PH"));
|
|
3094
|
+
});
|
|
3095
|
+
});
|
|
3096
|
+
}
|
|
2880
3097
|
async signIn(e) {
|
|
2881
3098
|
switch (e.type) {
|
|
2882
3099
|
case "NAME_AND_PASSWORD": {
|
|
2883
3100
|
const t = await this.sessionManager.create({
|
|
2884
3101
|
...e,
|
|
2885
|
-
password: await
|
|
3102
|
+
password: await g(e.password)
|
|
2886
3103
|
});
|
|
2887
3104
|
return t.ok ? t.data ? {
|
|
2888
3105
|
ok: !0,
|
|
@@ -2897,6 +3114,14 @@ class qt {
|
|
|
2897
3114
|
}
|
|
2898
3115
|
} : t;
|
|
2899
3116
|
}
|
|
3117
|
+
case "MOBILE_NUMBER": {
|
|
3118
|
+
const t = await this.sessionManager.create({
|
|
3119
|
+
type: "MOBILE_NUMBER",
|
|
3120
|
+
mobileNumber: P(e.mobileNumber, await this.locale),
|
|
3121
|
+
verificationCode: e.verificationCode
|
|
3122
|
+
});
|
|
3123
|
+
return t.ok ? { ok: !0 } : t;
|
|
3124
|
+
}
|
|
2900
3125
|
default: {
|
|
2901
3126
|
const t = await this.sessionManager.create(e);
|
|
2902
3127
|
return t.ok ? { ok: !0 } : t;
|
|
@@ -2909,7 +3134,7 @@ class qt {
|
|
|
2909
3134
|
return await this.sessionManager.createFromAuthenticator({
|
|
2910
3135
|
type: "SECURITY_QUESTION",
|
|
2911
3136
|
token: e.token,
|
|
2912
|
-
secretAnswer: await
|
|
3137
|
+
secretAnswer: await g(e.secretAnswer)
|
|
2913
3138
|
});
|
|
2914
3139
|
default:
|
|
2915
3140
|
return {
|
|
@@ -2925,7 +3150,7 @@ class qt {
|
|
|
2925
3150
|
await this.sessionManager.destroy();
|
|
2926
3151
|
}
|
|
2927
3152
|
watchSession(e) {
|
|
2928
|
-
const t =
|
|
3153
|
+
const t = Ut(e.interval ?? 3e4, 3e4, 6e4);
|
|
2929
3154
|
let r = null;
|
|
2930
3155
|
const a = () => setTimeout(async () => {
|
|
2931
3156
|
await this.sessionManager.verify() || await e.onInvalid(), r = a();
|
|
@@ -2964,6 +3189,7 @@ class qt {
|
|
|
2964
3189
|
/*+ PLATFORM +*/
|
|
2965
3190
|
/*+----------------------------------------+*/
|
|
2966
3191
|
/**/
|
|
3192
|
+
/** @deprecated */
|
|
2967
3193
|
async platform() {
|
|
2968
3194
|
const e = await this.accountService.platform();
|
|
2969
3195
|
return e.ok ? {
|
|
@@ -2971,6 +3197,20 @@ class qt {
|
|
|
2971
3197
|
data: this.transformer.transform.platform(e.data)
|
|
2972
3198
|
} : e;
|
|
2973
3199
|
}
|
|
3200
|
+
async platform__next() {
|
|
3201
|
+
const e = await this.portalService.platform();
|
|
3202
|
+
return e.ok ? {
|
|
3203
|
+
ok: !0,
|
|
3204
|
+
data: this.transformer.transform.platform__next(e.data)
|
|
3205
|
+
} : e;
|
|
3206
|
+
}
|
|
3207
|
+
async paymentSettings() {
|
|
3208
|
+
const e = await this.accountService.paymentSettings();
|
|
3209
|
+
return e.ok ? {
|
|
3210
|
+
ok: !0,
|
|
3211
|
+
data: this.transformer.transform.paymentSettings(e.data)
|
|
3212
|
+
} : e;
|
|
3213
|
+
}
|
|
2974
3214
|
/**/
|
|
2975
3215
|
/*+----------------------------------------+*/
|
|
2976
3216
|
/*+ ACCOUNT +*/
|
|
@@ -2987,15 +3227,15 @@ class qt {
|
|
|
2987
3227
|
* @deprecated use `createAccount__next`
|
|
2988
3228
|
*/
|
|
2989
3229
|
async createAccount(e) {
|
|
2990
|
-
const t = e.id ??
|
|
3230
|
+
const t = e.id ?? $.generate(U.Account).toString(), r = await this.accountService.registerMemberAccount({
|
|
2991
3231
|
input: {
|
|
2992
3232
|
id: t,
|
|
2993
3233
|
btag: e.btag,
|
|
2994
3234
|
name: e.name,
|
|
2995
3235
|
domain: e.domain,
|
|
2996
3236
|
birthDay: typeof e.dateOfBirth == "string" ? e.dateOfBirth : e.dateOfBirth.toISOString(),
|
|
2997
|
-
password: await
|
|
2998
|
-
mobileNumber:
|
|
3237
|
+
password: await g(e.password),
|
|
3238
|
+
mobileNumber: P(e.mobileNumber, await this.locale)
|
|
2999
3239
|
},
|
|
3000
3240
|
referralCode: e.referralCode,
|
|
3001
3241
|
verificationCode: e.verificationCode,
|
|
@@ -3004,12 +3244,12 @@ class qt {
|
|
|
3004
3244
|
return r.ok ? { ok: !0, data: { id: t } } : r;
|
|
3005
3245
|
}
|
|
3006
3246
|
async createAccount__next(e) {
|
|
3007
|
-
const t = e.id ??
|
|
3247
|
+
const t = e.id ?? $.generate(U.Account).toString();
|
|
3008
3248
|
if (e.type === "MOBILE_NUMBER") {
|
|
3009
3249
|
const a = await this.accountService.registerMemberAccountViaMobile({
|
|
3010
3250
|
input: {
|
|
3011
3251
|
id: t,
|
|
3012
|
-
mobileNumber:
|
|
3252
|
+
mobileNumber: P(e.mobileNumber, await this.locale)
|
|
3013
3253
|
},
|
|
3014
3254
|
referralCode: e.referralCode,
|
|
3015
3255
|
reCAPTCHAResponse: e.reCAPTCHAResponse,
|
|
@@ -3021,8 +3261,8 @@ class qt {
|
|
|
3021
3261
|
input: {
|
|
3022
3262
|
id: t,
|
|
3023
3263
|
name: e.name,
|
|
3024
|
-
password: await
|
|
3025
|
-
mobileNumber: e.mobileNumber ?
|
|
3264
|
+
password: await g(e.password),
|
|
3265
|
+
mobileNumber: e.mobileNumber ? P(e.mobileNumber, await this.locale) : void 0
|
|
3026
3266
|
},
|
|
3027
3267
|
reCAPTCHAResponse: e.reCAPTCHAResponse
|
|
3028
3268
|
});
|
|
@@ -3032,7 +3272,7 @@ class qt {
|
|
|
3032
3272
|
return await this.accountService.registerMayaMemberAccount({
|
|
3033
3273
|
input: {
|
|
3034
3274
|
name: e.name,
|
|
3035
|
-
password: await
|
|
3275
|
+
password: await g(e.password),
|
|
3036
3276
|
domain: e.domain
|
|
3037
3277
|
}
|
|
3038
3278
|
});
|
|
@@ -3043,12 +3283,12 @@ class qt {
|
|
|
3043
3283
|
id: e,
|
|
3044
3284
|
data: {
|
|
3045
3285
|
...t,
|
|
3046
|
-
password: t.password ? await
|
|
3047
|
-
transactionPassword: t.transactionPassword ? await
|
|
3286
|
+
password: t.password ? await g(t.password) : void 0,
|
|
3287
|
+
transactionPassword: t.transactionPassword ? await g(t.transactionPassword) : void 0,
|
|
3048
3288
|
...t.mobileNumber && {
|
|
3049
|
-
mobileNumber:
|
|
3289
|
+
mobileNumber: P(t.mobileNumber, await this.locale)
|
|
3050
3290
|
},
|
|
3051
|
-
secretAnswer: t.secretAnswer ? await
|
|
3291
|
+
secretAnswer: t.secretAnswer ? await g(t.secretAnswer) : void 0
|
|
3052
3292
|
}
|
|
3053
3293
|
}
|
|
3054
3294
|
});
|
|
@@ -3068,7 +3308,7 @@ class qt {
|
|
|
3068
3308
|
} : e;
|
|
3069
3309
|
}
|
|
3070
3310
|
async submitVerificationDetails(e) {
|
|
3071
|
-
const t = e.id ??
|
|
3311
|
+
const t = e.id ?? $.generate(U.Verification).toString(), r = await this.accountService.createMemberVerification({
|
|
3072
3312
|
input: {
|
|
3073
3313
|
id: t,
|
|
3074
3314
|
...e
|
|
@@ -3089,8 +3329,8 @@ class qt {
|
|
|
3089
3329
|
async resetPassword(e) {
|
|
3090
3330
|
return await this.accountService.resetPassword({
|
|
3091
3331
|
input: {
|
|
3092
|
-
mobileNumber:
|
|
3093
|
-
newPassword: await
|
|
3332
|
+
mobileNumber: P(e.mobileNumber, await this.locale),
|
|
3333
|
+
newPassword: await g(e.newPassword)
|
|
3094
3334
|
},
|
|
3095
3335
|
verificationCode: e.verificationCode
|
|
3096
3336
|
});
|
|
@@ -3116,7 +3356,7 @@ class qt {
|
|
|
3116
3356
|
return await this.accountService.sendVerificationCode({
|
|
3117
3357
|
input: {
|
|
3118
3358
|
channel: "SMS",
|
|
3119
|
-
recipient:
|
|
3359
|
+
recipient: P(e, await this.locale)
|
|
3120
3360
|
}
|
|
3121
3361
|
});
|
|
3122
3362
|
}
|
|
@@ -3124,7 +3364,7 @@ class qt {
|
|
|
3124
3364
|
if (e.type === "SMS")
|
|
3125
3365
|
return this.authService.sendVerificationCode({
|
|
3126
3366
|
channel: "SMS",
|
|
3127
|
-
recipient:
|
|
3367
|
+
recipient: P(e.mobileNumber, await this.locale),
|
|
3128
3368
|
...e.strict && {
|
|
3129
3369
|
verificationType: "MEMBER"
|
|
3130
3370
|
}
|
|
@@ -3174,13 +3414,13 @@ class qt {
|
|
|
3174
3414
|
/*+----------------------------------------+*/
|
|
3175
3415
|
/**/
|
|
3176
3416
|
async createWithdrawal(e) {
|
|
3177
|
-
const t = e.id ??
|
|
3417
|
+
const t = e.id ?? $.generate(U.Withdrawal).toString();
|
|
3178
3418
|
if (e.type === "BANK") {
|
|
3179
3419
|
const r = await this.walletService.createBankWithdrawal({
|
|
3180
3420
|
input: {
|
|
3181
3421
|
id: t,
|
|
3182
3422
|
amount: e.amount.toString(),
|
|
3183
|
-
transactionPassword: await
|
|
3423
|
+
transactionPassword: await g(e.transactionPassword)
|
|
3184
3424
|
}
|
|
3185
3425
|
});
|
|
3186
3426
|
if (!r.ok) return r;
|
|
@@ -3190,8 +3430,8 @@ class qt {
|
|
|
3190
3430
|
input: {
|
|
3191
3431
|
id: t,
|
|
3192
3432
|
amount: e.amount.toString(),
|
|
3193
|
-
transactionPassword: await
|
|
3194
|
-
recipientMobileNumber:
|
|
3433
|
+
transactionPassword: await g(e.transactionPassword),
|
|
3434
|
+
recipientMobileNumber: P(e.recipientMobileNumber, await this.locale)
|
|
3195
3435
|
}
|
|
3196
3436
|
});
|
|
3197
3437
|
if (!r.ok) return r;
|
|
@@ -3201,8 +3441,8 @@ class qt {
|
|
|
3201
3441
|
input: {
|
|
3202
3442
|
id: t,
|
|
3203
3443
|
amount: e.amount.toString(),
|
|
3204
|
-
transactionPassword: await
|
|
3205
|
-
recipientMobileNumber:
|
|
3444
|
+
transactionPassword: await g(e.transactionPassword),
|
|
3445
|
+
recipientMobileNumber: P(e.recipientMobileNumber, await this.locale)
|
|
3206
3446
|
}
|
|
3207
3447
|
});
|
|
3208
3448
|
if (!r.ok) return r;
|
|
@@ -3212,7 +3452,7 @@ class qt {
|
|
|
3212
3452
|
input: {
|
|
3213
3453
|
id: t,
|
|
3214
3454
|
amount: e.amount.toString(),
|
|
3215
|
-
transactionPassword: await
|
|
3455
|
+
transactionPassword: await g(e.transactionPassword)
|
|
3216
3456
|
}
|
|
3217
3457
|
});
|
|
3218
3458
|
if (!r.ok) return r;
|
|
@@ -3243,7 +3483,7 @@ class qt {
|
|
|
3243
3483
|
/*+----------------------------------------+*/
|
|
3244
3484
|
/**/
|
|
3245
3485
|
async createDeposit(e) {
|
|
3246
|
-
const t = e.id ??
|
|
3486
|
+
const t = e.id ?? $.generate(U.Deposit).toString();
|
|
3247
3487
|
if (e.type === "MAYA") {
|
|
3248
3488
|
const r = await this.walletService.createMayaDeposit({
|
|
3249
3489
|
input: {
|
|
@@ -3457,17 +3697,17 @@ class qt {
|
|
|
3457
3697
|
} : r;
|
|
3458
3698
|
}
|
|
3459
3699
|
async createGameSession(e) {
|
|
3460
|
-
const t = e.id ??
|
|
3700
|
+
const t = e.id ?? $.generate(U.GameSession).toString();
|
|
3461
3701
|
if (e.game.startsWith("SPORTS:")) {
|
|
3462
|
-
const f = await
|
|
3702
|
+
const f = await $.generateFromKey(U.Game, e.game).then(
|
|
3463
3703
|
(l) => l.toString()
|
|
3464
|
-
),
|
|
3704
|
+
), h = await this.gameService.createGameSession({
|
|
3465
3705
|
input: {
|
|
3466
3706
|
id: t,
|
|
3467
3707
|
game: f
|
|
3468
3708
|
}
|
|
3469
3709
|
});
|
|
3470
|
-
return
|
|
3710
|
+
return h.ok ? { ok: !0, data: { id: t } } : h;
|
|
3471
3711
|
}
|
|
3472
3712
|
const a = await this.game(e.game);
|
|
3473
3713
|
if (!a.data)
|
|
@@ -3478,7 +3718,7 @@ class qt {
|
|
|
3478
3718
|
message: "Game does not exist"
|
|
3479
3719
|
}
|
|
3480
3720
|
};
|
|
3481
|
-
const { provider: s, reference:
|
|
3721
|
+
const { provider: s, reference: m } = a.data, p = [
|
|
3482
3722
|
/**/
|
|
3483
3723
|
"RTG",
|
|
3484
3724
|
"DARWIN",
|
|
@@ -3487,7 +3727,7 @@ class qt {
|
|
|
3487
3727
|
"EVOLUTION",
|
|
3488
3728
|
"EVOLUTION_NETENT",
|
|
3489
3729
|
"EVOLUTION_REDTIGER"
|
|
3490
|
-
].includes(s) ? await this.walletService.createGameSession({ input: { id: t, game:
|
|
3730
|
+
].includes(s) ? await this.walletService.createGameSession({ input: { id: t, game: m } }) : await this.gameService.createGameSession({ input: { id: t, game: m } });
|
|
3491
3731
|
return p.ok ? { ok: !0, data: { id: t } } : p;
|
|
3492
3732
|
}
|
|
3493
3733
|
async endGameSession(e) {
|
|
@@ -3507,7 +3747,7 @@ class qt {
|
|
|
3507
3747
|
} : t;
|
|
3508
3748
|
}
|
|
3509
3749
|
async uploadImageFile(e) {
|
|
3510
|
-
const t = e.id ??
|
|
3750
|
+
const t = e.id ?? $.generate(U.File).toString(), r = await this.fileService.uploadPrivateImageFile({
|
|
3511
3751
|
input: {
|
|
3512
3752
|
id: t,
|
|
3513
3753
|
file: e.file
|
|
@@ -3620,10 +3860,17 @@ class qt {
|
|
|
3620
3860
|
data: t.data.map(this.transformer.transform.referral)
|
|
3621
3861
|
} : t;
|
|
3622
3862
|
}
|
|
3863
|
+
async pointsClubSettings() {
|
|
3864
|
+
const e = await this.accountService.pointsClubSettings();
|
|
3865
|
+
return e.ok ? {
|
|
3866
|
+
ok: !0,
|
|
3867
|
+
data: e.data ? this.transformer.transform.pointsClubSettings(e.data) : null
|
|
3868
|
+
} : e;
|
|
3869
|
+
}
|
|
3623
3870
|
}
|
|
3624
3871
|
export {
|
|
3625
|
-
|
|
3626
|
-
|
|
3627
|
-
|
|
3872
|
+
zt as ObjectId,
|
|
3873
|
+
U as ObjectType,
|
|
3874
|
+
jt as Sdk
|
|
3628
3875
|
};
|
|
3629
3876
|
//# sourceMappingURL=index.mjs.map
|