@moneypot/hub 1.1.1 → 1.2.0-dev.2
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/src/__generated__/gql.d.ts +10 -2
- package/dist/src/__generated__/gql.js +5 -1
- package/dist/src/__generated__/graphql.d.ts +552 -138
- package/dist/src/__generated__/graphql.js +62 -23
- package/dist/src/db/index.d.ts +4 -1
- package/dist/src/db/index.js +1 -0
- package/dist/src/db/types.d.ts +36 -0
- package/dist/src/graphql-queries.d.ts +1 -0
- package/dist/src/graphql-queries.js +13 -0
- package/dist/src/pg-advisory-lock.d.ts +8 -0
- package/dist/src/pg-advisory-lock.js +27 -0
- package/dist/src/pg-versions/002-balance-id.sql +11 -0
- package/dist/src/pg-versions/003-take-request.sql +107 -0
- package/dist/src/plugins/hub-withdraw.js +2 -2
- package/dist/src/process-transfers.js +23 -2
- package/dist/src/process-withdrawal-request.js +16 -0
- package/dist/src/take-request/process-take-request.d.ts +7 -0
- package/dist/src/take-request/process-take-request.js +783 -0
- package/package.json +3 -3
|
@@ -136,6 +136,8 @@ export var ExperienceTransferOrderBy;
|
|
|
136
136
|
ExperienceTransferOrderBy["Natural"] = "NATURAL";
|
|
137
137
|
ExperienceTransferOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
138
138
|
ExperienceTransferOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
139
|
+
ExperienceTransferOrderBy["TakeRequestIdAsc"] = "TAKE_REQUEST_ID_ASC";
|
|
140
|
+
ExperienceTransferOrderBy["TakeRequestIdDesc"] = "TAKE_REQUEST_ID_DESC";
|
|
139
141
|
ExperienceTransferOrderBy["ToAccountIdAsc"] = "TO_ACCOUNT_ID_ASC";
|
|
140
142
|
ExperienceTransferOrderBy["ToAccountIdDesc"] = "TO_ACCOUNT_ID_DESC";
|
|
141
143
|
ExperienceTransferOrderBy["ToHolderIdAsc"] = "TO_HOLDER_ID_ASC";
|
|
@@ -155,26 +157,6 @@ export var FaucetClaimOrderBy;
|
|
|
155
157
|
FaucetClaimOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
156
158
|
FaucetClaimOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
157
159
|
})(FaucetClaimOrderBy || (FaucetClaimOrderBy = {}));
|
|
158
|
-
export var GeneralTransferOrderBy;
|
|
159
|
-
(function (GeneralTransferOrderBy) {
|
|
160
|
-
GeneralTransferOrderBy["CurrencyAsc"] = "CURRENCY_ASC";
|
|
161
|
-
GeneralTransferOrderBy["CurrencyDesc"] = "CURRENCY_DESC";
|
|
162
|
-
GeneralTransferOrderBy["FromAccountIdAsc"] = "FROM_ACCOUNT_ID_ASC";
|
|
163
|
-
GeneralTransferOrderBy["FromAccountIdDesc"] = "FROM_ACCOUNT_ID_DESC";
|
|
164
|
-
GeneralTransferOrderBy["FromHolderIdAsc"] = "FROM_HOLDER_ID_ASC";
|
|
165
|
-
GeneralTransferOrderBy["FromHolderIdDesc"] = "FROM_HOLDER_ID_DESC";
|
|
166
|
-
GeneralTransferOrderBy["IdAsc"] = "ID_ASC";
|
|
167
|
-
GeneralTransferOrderBy["IdDesc"] = "ID_DESC";
|
|
168
|
-
GeneralTransferOrderBy["Natural"] = "NATURAL";
|
|
169
|
-
GeneralTransferOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
170
|
-
GeneralTransferOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
171
|
-
GeneralTransferOrderBy["ToAccountIdAsc"] = "TO_ACCOUNT_ID_ASC";
|
|
172
|
-
GeneralTransferOrderBy["ToAccountIdDesc"] = "TO_ACCOUNT_ID_DESC";
|
|
173
|
-
GeneralTransferOrderBy["ToHolderIdAsc"] = "TO_HOLDER_ID_ASC";
|
|
174
|
-
GeneralTransferOrderBy["ToHolderIdDesc"] = "TO_HOLDER_ID_DESC";
|
|
175
|
-
GeneralTransferOrderBy["TypeAsc"] = "TYPE_ASC";
|
|
176
|
-
GeneralTransferOrderBy["TypeDesc"] = "TYPE_DESC";
|
|
177
|
-
})(GeneralTransferOrderBy || (GeneralTransferOrderBy = {}));
|
|
178
160
|
export var HolderKind;
|
|
179
161
|
(function (HolderKind) {
|
|
180
162
|
HolderKind["Controller"] = "CONTROLLER";
|
|
@@ -259,6 +241,16 @@ export var PayoutStatus;
|
|
|
259
241
|
PayoutStatus["Rejected"] = "rejected";
|
|
260
242
|
PayoutStatus["Unconfirmed"] = "unconfirmed";
|
|
261
243
|
})(PayoutStatus || (PayoutStatus = {}));
|
|
244
|
+
export var PayoutStatusChangeOrderBy;
|
|
245
|
+
(function (PayoutStatusChangeOrderBy) {
|
|
246
|
+
PayoutStatusChangeOrderBy["IdAsc"] = "ID_ASC";
|
|
247
|
+
PayoutStatusChangeOrderBy["IdDesc"] = "ID_DESC";
|
|
248
|
+
PayoutStatusChangeOrderBy["Natural"] = "NATURAL";
|
|
249
|
+
PayoutStatusChangeOrderBy["PayoutIdAsc"] = "PAYOUT_ID_ASC";
|
|
250
|
+
PayoutStatusChangeOrderBy["PayoutIdDesc"] = "PAYOUT_ID_DESC";
|
|
251
|
+
PayoutStatusChangeOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
252
|
+
PayoutStatusChangeOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
253
|
+
})(PayoutStatusChangeOrderBy || (PayoutStatusChangeOrderBy = {}));
|
|
262
254
|
export var PendingPayoutAttemptOrderBy;
|
|
263
255
|
(function (PendingPayoutAttemptOrderBy) {
|
|
264
256
|
PendingPayoutAttemptOrderBy["IdAsc"] = "ID_ASC";
|
|
@@ -276,17 +268,27 @@ export var PendingPayoutOrderBy;
|
|
|
276
268
|
PendingPayoutOrderBy["Natural"] = "NATURAL";
|
|
277
269
|
PendingPayoutOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
278
270
|
PendingPayoutOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
279
|
-
PendingPayoutOrderBy["StatusAsc"] = "STATUS_ASC";
|
|
280
|
-
PendingPayoutOrderBy["StatusDesc"] = "STATUS_DESC";
|
|
281
271
|
PendingPayoutOrderBy["UserIdAsc"] = "USER_ID_ASC";
|
|
282
272
|
PendingPayoutOrderBy["UserIdDesc"] = "USER_ID_DESC";
|
|
283
273
|
})(PendingPayoutOrderBy || (PendingPayoutOrderBy = {}));
|
|
284
274
|
export var PendingPayoutStatus;
|
|
285
275
|
(function (PendingPayoutStatus) {
|
|
276
|
+
PendingPayoutStatus["Canceled"] = "canceled";
|
|
286
277
|
PendingPayoutStatus["Error"] = "error";
|
|
287
278
|
PendingPayoutStatus["PayoutCreated"] = "payout_created";
|
|
288
279
|
PendingPayoutStatus["Pending"] = "pending";
|
|
280
|
+
PendingPayoutStatus["Retry"] = "retry";
|
|
289
281
|
})(PendingPayoutStatus || (PendingPayoutStatus = {}));
|
|
282
|
+
export var PendingPayoutStatusChangeOrderBy;
|
|
283
|
+
(function (PendingPayoutStatusChangeOrderBy) {
|
|
284
|
+
PendingPayoutStatusChangeOrderBy["IdAsc"] = "ID_ASC";
|
|
285
|
+
PendingPayoutStatusChangeOrderBy["IdDesc"] = "ID_DESC";
|
|
286
|
+
PendingPayoutStatusChangeOrderBy["Natural"] = "NATURAL";
|
|
287
|
+
PendingPayoutStatusChangeOrderBy["PendingPayoutIdAsc"] = "PENDING_PAYOUT_ID_ASC";
|
|
288
|
+
PendingPayoutStatusChangeOrderBy["PendingPayoutIdDesc"] = "PENDING_PAYOUT_ID_DESC";
|
|
289
|
+
PendingPayoutStatusChangeOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
290
|
+
PendingPayoutStatusChangeOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
291
|
+
})(PendingPayoutStatusChangeOrderBy || (PendingPayoutStatusChangeOrderBy = {}));
|
|
290
292
|
export var ResendEmailResult;
|
|
291
293
|
(function (ResendEmailResult) {
|
|
292
294
|
ResendEmailResult["AlreadyDone"] = "ALREADY_DONE";
|
|
@@ -305,6 +307,29 @@ export var SessionOrderBy;
|
|
|
305
307
|
SessionOrderBy["UserIdAsc"] = "USER_ID_ASC";
|
|
306
308
|
SessionOrderBy["UserIdDesc"] = "USER_ID_DESC";
|
|
307
309
|
})(SessionOrderBy || (SessionOrderBy = {}));
|
|
310
|
+
export var TakeRequestOrderBy;
|
|
311
|
+
(function (TakeRequestOrderBy) {
|
|
312
|
+
TakeRequestOrderBy["CurrencyKeyAsc"] = "CURRENCY_KEY_ASC";
|
|
313
|
+
TakeRequestOrderBy["CurrencyKeyDesc"] = "CURRENCY_KEY_DESC";
|
|
314
|
+
TakeRequestOrderBy["ExperienceIdAsc"] = "EXPERIENCE_ID_ASC";
|
|
315
|
+
TakeRequestOrderBy["ExperienceIdDesc"] = "EXPERIENCE_ID_DESC";
|
|
316
|
+
TakeRequestOrderBy["IdAsc"] = "ID_ASC";
|
|
317
|
+
TakeRequestOrderBy["IdDesc"] = "ID_DESC";
|
|
318
|
+
TakeRequestOrderBy["Natural"] = "NATURAL";
|
|
319
|
+
TakeRequestOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
320
|
+
TakeRequestOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
321
|
+
TakeRequestOrderBy["StatusAsc"] = "STATUS_ASC";
|
|
322
|
+
TakeRequestOrderBy["StatusDesc"] = "STATUS_DESC";
|
|
323
|
+
TakeRequestOrderBy["UserIdAsc"] = "USER_ID_ASC";
|
|
324
|
+
TakeRequestOrderBy["UserIdDesc"] = "USER_ID_DESC";
|
|
325
|
+
})(TakeRequestOrderBy || (TakeRequestOrderBy = {}));
|
|
326
|
+
export var TakeRequestStatus;
|
|
327
|
+
(function (TakeRequestStatus) {
|
|
328
|
+
TakeRequestStatus["ControllerRejected"] = "CONTROLLER_REJECTED";
|
|
329
|
+
TakeRequestStatus["Pending"] = "PENDING";
|
|
330
|
+
TakeRequestStatus["Transferred"] = "TRANSFERRED";
|
|
331
|
+
TakeRequestStatus["UserCanceled"] = "USER_CANCELED";
|
|
332
|
+
})(TakeRequestStatus || (TakeRequestStatus = {}));
|
|
308
333
|
export var TransactionOrderBy;
|
|
309
334
|
(function (TransactionOrderBy) {
|
|
310
335
|
TransactionOrderBy["ChillIdAsc"] = "CHILL_ID_ASC";
|
|
@@ -326,6 +351,16 @@ export var TransactionStatus;
|
|
|
326
351
|
TransactionStatus["Replaced"] = "replaced";
|
|
327
352
|
TransactionStatus["Unconfirmed"] = "unconfirmed";
|
|
328
353
|
})(TransactionStatus || (TransactionStatus = {}));
|
|
354
|
+
export var TransactionStatusChangeOrderBy;
|
|
355
|
+
(function (TransactionStatusChangeOrderBy) {
|
|
356
|
+
TransactionStatusChangeOrderBy["IdAsc"] = "ID_ASC";
|
|
357
|
+
TransactionStatusChangeOrderBy["IdDesc"] = "ID_DESC";
|
|
358
|
+
TransactionStatusChangeOrderBy["Natural"] = "NATURAL";
|
|
359
|
+
TransactionStatusChangeOrderBy["PrimaryKeyAsc"] = "PRIMARY_KEY_ASC";
|
|
360
|
+
TransactionStatusChangeOrderBy["PrimaryKeyDesc"] = "PRIMARY_KEY_DESC";
|
|
361
|
+
TransactionStatusChangeOrderBy["TransactionIdAsc"] = "TRANSACTION_ID_ASC";
|
|
362
|
+
TransactionStatusChangeOrderBy["TransactionIdDesc"] = "TRANSACTION_ID_DESC";
|
|
363
|
+
})(TransactionStatusChangeOrderBy || (TransactionStatusChangeOrderBy = {}));
|
|
329
364
|
export var TransferDirection;
|
|
330
365
|
(function (TransferDirection) {
|
|
331
366
|
TransferDirection["Incoming"] = "INCOMING";
|
|
@@ -445,10 +480,14 @@ export var WithdrawalOrderBy;
|
|
|
445
480
|
})(WithdrawalOrderBy || (WithdrawalOrderBy = {}));
|
|
446
481
|
export const AddCasino_GetCurrentControllerDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "query", "name": { "kind": "Name", "value": "AddCasino_GetCurrentController" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "currentController" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }] } }] } }] };
|
|
447
482
|
export const GetUserFromUserTokenDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "GetUserFromUserToken" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "token" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "userFromUserToken" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "token" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "token" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "user" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "uname" } }] } }, { "kind": "Field", "name": { "kind": "Name", "value": "experience" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "name" } }] } }] } }] } }] };
|
|
448
|
-
export const StartPendingExperienceTransferDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "StartPendingExperienceTransfer" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpUserId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpExperienceId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "amount" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "Int" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "currency" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "String" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "metadata" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "JSON" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "transferCurrencyExperienceToUser" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "userId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpUserId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "experienceId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpExperienceId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "amount" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "amount" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "currency" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "currency" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "metadata" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "metadata" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TransferCurrencyExperienceToUserSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TransferMetadataIdExists" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }] } }] } }] };
|
|
483
|
+
export const StartPendingExperienceTransferDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "StartPendingExperienceTransfer" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpUserId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpExperienceId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTakeRequestId" } }, "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "amount" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "Int" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "currency" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "String" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "metadata" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "JSON" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "transferCurrencyExperienceToUser" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "userId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpUserId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "experienceId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpExperienceId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "amount" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "amount" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "currency" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "currency" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "metadata" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "metadata" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "takeRequestId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTakeRequestId" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TransferCurrencyExperienceToUserSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TransferMetadataIdExists" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TakeRequestAlreadyTerminal" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "takeRequest" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }, { "kind": "Field", "name": { "kind": "Name", "value": "experienceTransfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }] } }] } }] } }] };
|
|
449
484
|
export const PaginateTransfersDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "query", "name": { "kind": "Name", "value": "PaginateTransfers" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "controllerId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "after" } }, "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "Cursor" } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "limit" } }, "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "Int" } }, "defaultValue": { "kind": "IntValue", "value": "10" } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "transfersByHolder" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "holderId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "controllerId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "after" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "after" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "first" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "limit" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "orderBy" }, "value": { "kind": "EnumValue", "value": "ID_ASC" } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "type" }, "value": { "kind": "EnumValue", "value": "EXPERIENCE" } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "pageInfo" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "endCursor" } }, { "kind": "Field", "name": { "kind": "Name", "value": "hasNextPage" } }] } }, { "kind": "Field", "name": { "kind": "Name", "value": "edges" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "cursor" } }, { "kind": "Field", "name": { "kind": "Name", "value": "node" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "amount" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }, { "kind": "Field", "name": { "kind": "Name", "value": "statusAt" } }, { "kind": "Field", "name": { "kind": "Name", "value": "currencyByCurrency" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "displayUnitName" } }, { "kind": "Field", "name": { "kind": "Name", "value": "displayUnitScale" } }] } }, { "kind": "Field", "name": { "kind": "Name", "value": "fromHolderId" } }, { "kind": "Field", "name": { "kind": "Name", "value": "holderByFromHolderId" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "User" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "uname" } }] } }] } }, { "kind": "Field", "name": { "kind": "Name", "value": "toHolderId" } }, { "kind": "Field", "name": { "kind": "Name", "value": "holderByToHolderId" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "User" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "uname" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "ExperienceTransfer" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "experienceId" } }, { "kind": "Field", "name": { "kind": "Name", "value": "experienceByExperienceId" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "name" } }] } }] } }] } }] } }] } }] } }] };
|
|
450
485
|
export const GetCurrenciesDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "query", "name": { "kind": "Name", "value": "GetCurrencies" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "allCurrencies" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "nodes" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "displayUnitName" } }, { "kind": "Field", "name": { "kind": "Name", "value": "displayUnitScale" } }] } }] } }] } }] };
|
|
451
486
|
export const GetCurrentControllerDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "query", "name": { "kind": "Name", "value": "GetCurrentController" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "currentController" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }] } }, { "kind": "Field", "name": { "kind": "Name", "value": "allCurrencies" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "nodes" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "displayUnitName" } }, { "kind": "Field", "name": { "kind": "Name", "value": "displayUnitScale" } }] } }] } }] } }] };
|
|
452
487
|
export const CompleteTransferDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "CompleteTransfer" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTransferId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "completeTransfer" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "id" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTransferId" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "CompleteTransferSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "ExperienceTransfer" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "InvalidTransferStatus" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "currentStatus" } }, { "kind": "Field", "name": { "kind": "Name", "value": "message" } }] } }] } }] } }] } }] };
|
|
453
488
|
export const ClaimTransferDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "ClaimTransfer" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTransferId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "claimTransfer" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "id" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTransferId" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "ClaimTransferSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "ExperienceTransfer" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "InvalidTransferStatus" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "currentStatus" } }, { "kind": "Field", "name": { "kind": "Name", "value": "message" } }] } }] } }] } }] } }] };
|
|
454
489
|
export const GetCasinoJwksDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "query", "name": { "kind": "Name", "value": "GetCasinoJWKS" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "jwks" } }] } }] };
|
|
490
|
+
export const MpPaginatedPendingTakeRequestsDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "query", "name": { "kind": "Name", "value": "MpPaginatedPendingTakeRequests" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "controllerId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "after" } }, "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "Cursor" } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "allTakeRequests" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "condition" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "controllerId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "controllerId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "status" }, "value": { "kind": "EnumValue", "value": "PENDING" } }] } }, { "kind": "Argument", "name": { "kind": "Name", "value": "after" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "after" } } }, { "kind": "Argument", "name": { "kind": "Name", "value": "orderBy" }, "value": { "kind": "EnumValue", "value": "ID_ASC" } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "pageInfo" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "endCursor" } }, { "kind": "Field", "name": { "kind": "Name", "value": "hasNextPage" } }] } }, { "kind": "Field", "name": { "kind": "Name", "value": "edges" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "cursor" } }, { "kind": "Field", "name": { "kind": "Name", "value": "node" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }, { "kind": "Field", "name": { "kind": "Name", "value": "amount" } }, { "kind": "Field", "name": { "kind": "Name", "value": "currencyKey" } }, { "kind": "Field", "name": { "kind": "Name", "value": "userId" } }, { "kind": "Field", "name": { "kind": "Name", "value": "experienceId" } }, { "kind": "Field", "name": { "kind": "Name", "value": "experienceTransfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "amount" } }] } }] } }] } }] } }] } }] };
|
|
491
|
+
export const MpRejectTakeRequestDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "MpRejectTakeRequest" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTakeRequestId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "rejectTakeRequest" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "id" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTakeRequestId" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "RejectTakeRequestSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "takeRequest" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TakeRequestAlreadyTerminal" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "takeRequest" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }] } }] } }] };
|
|
492
|
+
export const MpTransferTakeRequestDocument = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "MpTransferTakeRequest" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTakeRequestId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpExperienceId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpUserId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "amount" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "Int" } } } }, { "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "currencyKey" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "String" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "transferCurrencyExperienceToUser" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "takeRequestId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTakeRequestId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "experienceId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpExperienceId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "userId" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpUserId" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "amount" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "amount" } } }, { "kind": "ObjectField", "name": { "kind": "Name", "value": "currency" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "currencyKey" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TransferCurrencyExperienceToUserSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TransferMetadataIdExists" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "TakeRequestAlreadyTerminal" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "takeRequest" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }, { "kind": "Field", "name": { "kind": "Name", "value": "experienceTransfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }] } }] } }] } }] };
|
|
493
|
+
export const CompleteTransfer2Document = { "kind": "Document", "definitions": [{ "kind": "OperationDefinition", "operation": "mutation", "name": { "kind": "Name", "value": "CompleteTransfer2" }, "variableDefinitions": [{ "kind": "VariableDefinition", "variable": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTransferId" } }, "type": { "kind": "NonNullType", "type": { "kind": "NamedType", "name": { "kind": "Name", "value": "UUID" } } } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "completeTransfer" }, "arguments": [{ "kind": "Argument", "name": { "kind": "Name", "value": "input" }, "value": { "kind": "ObjectValue", "fields": [{ "kind": "ObjectField", "name": { "kind": "Name", "value": "id" }, "value": { "kind": "Variable", "name": { "kind": "Name", "value": "mpTransferId" } } }] } }], "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "result" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "CompleteTransferSuccess" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "ExperienceTransfer" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "takeRequest" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }] } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "InvalidTransferStatus" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "Field", "name": { "kind": "Name", "value": "currentStatus" } }, { "kind": "Field", "name": { "kind": "Name", "value": "message" } }, { "kind": "Field", "name": { "kind": "Name", "value": "transfer" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "__typename" } }, { "kind": "InlineFragment", "typeCondition": { "kind": "NamedType", "name": { "kind": "Name", "value": "ExperienceTransfer" } }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "takeRequest" }, "selectionSet": { "kind": "SelectionSet", "selections": [{ "kind": "Field", "name": { "kind": "Name", "value": "id" } }, { "kind": "Field", "name": { "kind": "Name", "value": "status" } }] } }] } }] } }] } }] } }] } }] } }] };
|
package/dist/src/db/index.d.ts
CHANGED
|
@@ -14,7 +14,10 @@ interface QueryExecutor {
|
|
|
14
14
|
export declare class UserFriendlyError extends Error {
|
|
15
15
|
constructor(userFriendlyMessage: string);
|
|
16
16
|
}
|
|
17
|
-
export
|
|
17
|
+
export type PgClientInTransaction = pg.PoolClient & {
|
|
18
|
+
_inTransaction: true;
|
|
19
|
+
};
|
|
20
|
+
export declare function withPgPoolTransaction<T>(pool: pg.Pool, callback: (_client: PgClientInTransaction) => Promise<T>, retryCount?: number, maxRetries?: number): Promise<T>;
|
|
18
21
|
export declare function userFromActiveSessionKey(pool: pg.Pool, sessionKey: string): Promise<{
|
|
19
22
|
user: DbUser;
|
|
20
23
|
sessionId: DbSession["id"];
|
package/dist/src/db/index.js
CHANGED
|
@@ -35,6 +35,7 @@ export async function withPgPoolTransaction(pool, callback, retryCount = 0, maxR
|
|
|
35
35
|
try {
|
|
36
36
|
client = await pool.connect();
|
|
37
37
|
await client.query("begin isolation level serializable");
|
|
38
|
+
client._inTransaction = true;
|
|
38
39
|
const result = await callback(client);
|
|
39
40
|
await client.query("commit");
|
|
40
41
|
return result;
|
package/dist/src/db/types.d.ts
CHANGED
|
@@ -25,6 +25,7 @@ export type DbWithdrawal = {
|
|
|
25
25
|
currency_key: string;
|
|
26
26
|
status: DbTransferStatusKind;
|
|
27
27
|
status_at: Date;
|
|
28
|
+
withdrawal_request_id: string;
|
|
28
29
|
};
|
|
29
30
|
export type DbWithdrawalRequest = {
|
|
30
31
|
id: string;
|
|
@@ -78,3 +79,38 @@ export type DbBankroll = {
|
|
|
78
79
|
currency_key: string;
|
|
79
80
|
amount: number;
|
|
80
81
|
};
|
|
82
|
+
export type DbProcessedTakeRequest = {
|
|
83
|
+
id: string;
|
|
84
|
+
mp_take_request_id: string;
|
|
85
|
+
user_id: string;
|
|
86
|
+
experience_id: string;
|
|
87
|
+
casino_id: string;
|
|
88
|
+
currency_key: string;
|
|
89
|
+
requested_amount: number | null;
|
|
90
|
+
transferred_amount: number;
|
|
91
|
+
};
|
|
92
|
+
export type DbBalance = {
|
|
93
|
+
id: string;
|
|
94
|
+
casino_id: string;
|
|
95
|
+
user_id: string;
|
|
96
|
+
experience_id: string;
|
|
97
|
+
currency_key: string;
|
|
98
|
+
amount: number;
|
|
99
|
+
};
|
|
100
|
+
export type DbTakeRequestStatus = "PENDING" | "PROCESSING" | "COMPLETED" | "FAILED" | "REJECTED";
|
|
101
|
+
export type DbTakeRequest = {
|
|
102
|
+
id: string;
|
|
103
|
+
mp_take_request_id: string;
|
|
104
|
+
user_id: string;
|
|
105
|
+
experience_id: string;
|
|
106
|
+
casino_id: string;
|
|
107
|
+
currency_key: string;
|
|
108
|
+
amount: number | null;
|
|
109
|
+
status: DbTakeRequestStatus;
|
|
110
|
+
reserved_amount: number;
|
|
111
|
+
mp_transfer_id: string | null;
|
|
112
|
+
mp_transfer_status: DbTransferStatusKind | null;
|
|
113
|
+
transfer_needs_completion: boolean;
|
|
114
|
+
transfer_completion_attempted_at: Date | null;
|
|
115
|
+
updated_at: Date;
|
|
116
|
+
};
|
|
@@ -4,6 +4,7 @@ export declare const GET_USER_FROM_USER_TOKEN: import("@graphql-typed-document-n
|
|
|
4
4
|
export declare const START_PENDING_EXPERIENCE_TRANSFER: import("@graphql-typed-document-node/core").TypedDocumentNode<import("./__generated__/graphql.js").StartPendingExperienceTransferMutation, import("./__generated__/graphql.js").Exact<{
|
|
5
5
|
mpUserId: import("./__generated__/graphql.js").Scalars["UUID"]["input"];
|
|
6
6
|
mpExperienceId: import("./__generated__/graphql.js").Scalars["UUID"]["input"];
|
|
7
|
+
mpTakeRequestId?: import("./__generated__/graphql.js").InputMaybe<import("./__generated__/graphql.js").Scalars["UUID"]["input"]>;
|
|
7
8
|
amount: import("./__generated__/graphql.js").Scalars["Int"]["input"];
|
|
8
9
|
currency: import("./__generated__/graphql.js").Scalars["String"]["input"];
|
|
9
10
|
metadata: import("./__generated__/graphql.js").Scalars["JSON"]["input"];
|
|
@@ -17,6 +17,7 @@ export const START_PENDING_EXPERIENCE_TRANSFER = gql(`
|
|
|
17
17
|
mutation StartPendingExperienceTransfer(
|
|
18
18
|
$mpUserId: UUID!
|
|
19
19
|
$mpExperienceId: UUID!
|
|
20
|
+
$mpTakeRequestId: UUID
|
|
20
21
|
$amount: Int!
|
|
21
22
|
$currency: String!
|
|
22
23
|
$metadata: JSON!
|
|
@@ -28,6 +29,7 @@ export const START_PENDING_EXPERIENCE_TRANSFER = gql(`
|
|
|
28
29
|
amount: $amount
|
|
29
30
|
currency: $currency
|
|
30
31
|
metadata: $metadata
|
|
32
|
+
takeRequestId: $mpTakeRequestId
|
|
31
33
|
}
|
|
32
34
|
) {
|
|
33
35
|
result {
|
|
@@ -45,6 +47,17 @@ export const START_PENDING_EXPERIENCE_TRANSFER = gql(`
|
|
|
45
47
|
status
|
|
46
48
|
}
|
|
47
49
|
}
|
|
50
|
+
... on TakeRequestAlreadyTerminal {
|
|
51
|
+
__typename
|
|
52
|
+
takeRequest {
|
|
53
|
+
id
|
|
54
|
+
status
|
|
55
|
+
experienceTransfer {
|
|
56
|
+
id
|
|
57
|
+
status
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
48
61
|
}
|
|
49
62
|
}
|
|
50
63
|
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { PoolClient } from "pg";
|
|
2
|
+
import { DbCasino, DbProcessedTakeRequest } from "./db/types.js";
|
|
3
|
+
export declare const pgAdvisoryLock: {
|
|
4
|
+
forMpTakeRequestProcessing: (pgClient: PoolClient, params: {
|
|
5
|
+
mpTakeRequestId: DbProcessedTakeRequest["mp_take_request_id"];
|
|
6
|
+
casinoId: DbCasino["id"];
|
|
7
|
+
}) => Promise<void>;
|
|
8
|
+
};
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
var LockNamespace;
|
|
2
|
+
(function (LockNamespace) {
|
|
3
|
+
LockNamespace[LockNamespace["MP_TAKE_REQUEST"] = 1] = "MP_TAKE_REQUEST";
|
|
4
|
+
})(LockNamespace || (LockNamespace = {}));
|
|
5
|
+
function simpleHash32(text) {
|
|
6
|
+
let hash = 0;
|
|
7
|
+
for (let i = 0; i < text.length; i++) {
|
|
8
|
+
hash = hash * 31 + text.charCodeAt(i);
|
|
9
|
+
hash = hash | 0;
|
|
10
|
+
}
|
|
11
|
+
return hash;
|
|
12
|
+
}
|
|
13
|
+
function createHashKey(input1, ...rest) {
|
|
14
|
+
const combinedString = [input1, ...rest].join("|");
|
|
15
|
+
return simpleHash32(combinedString);
|
|
16
|
+
}
|
|
17
|
+
async function acquireAdvisoryLock(pgClient, namespace, hash) {
|
|
18
|
+
await pgClient.query({
|
|
19
|
+
text: `SELECT pg_advisory_xact_lock($1, $2)`,
|
|
20
|
+
values: [namespace, hash],
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
export const pgAdvisoryLock = {
|
|
24
|
+
forMpTakeRequestProcessing: async (pgClient, params) => {
|
|
25
|
+
await acquireAdvisoryLock(pgClient, LockNamespace.MP_TAKE_REQUEST, createHashKey(params.mpTakeRequestId, params.casinoId));
|
|
26
|
+
},
|
|
27
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
-- Add balance.id UUID PK column
|
|
2
|
+
-- Migrate the existing surrogate PK to a unique index.
|
|
3
|
+
|
|
4
|
+
ALTER TABLE hub.balance ADD COLUMN id uuid default hub_hidden.uuid_generate_v7();
|
|
5
|
+
UPDATE hub.balance SET id = hub_hidden.uuid_generate_v7();
|
|
6
|
+
ALTER TABLE hub.balance ALTER COLUMN id SET NOT NULL;
|
|
7
|
+
|
|
8
|
+
-- Migrate old PK to unique index
|
|
9
|
+
ALTER TABLE hub.balance DROP CONSTRAINT balance_pkey;
|
|
10
|
+
ALTER TABLE hub.balance ADD CONSTRAINT balance_pkey PRIMARY KEY (id);
|
|
11
|
+
CREATE UNIQUE INDEX balance_casino_id_user_id_experience_id_currency_key_key ON hub.balance(casino_id, user_id, experience_id, currency_key);
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
-- Create a simplified take request system with a single table state machine
|
|
2
|
+
|
|
3
|
+
-- UNDO
|
|
4
|
+
|
|
5
|
+
-- DROP TABLE IF EXISTS hub.take_transfer;
|
|
6
|
+
-- DROP TABLE IF EXISTS hub.take_request;
|
|
7
|
+
-- DROP TYPE IF EXISTS hub.mp_take_request_status;
|
|
8
|
+
-- DROP TYPE IF EXISTS hub.mp_transfer_status;
|
|
9
|
+
|
|
10
|
+
-- Local take request status that doesn't map to MP's take_request_status kind
|
|
11
|
+
CREATE TYPE hub.take_request_status AS ENUM (
|
|
12
|
+
'PENDING', -- Initial state
|
|
13
|
+
'PROCESSING', -- Funds reserved, transfer in progress
|
|
14
|
+
'COMPLETED', -- Transfer completed successfully
|
|
15
|
+
'FAILED', -- Transfer failed, needs investigation
|
|
16
|
+
'REJECTED' -- Request rejected (insufficient funds, etc)
|
|
17
|
+
);
|
|
18
|
+
|
|
19
|
+
-- Maps to MP's app_public.take_request_status enum
|
|
20
|
+
CREATE TYPE hub.mp_take_request_status AS ENUM (
|
|
21
|
+
'PENDING', -- Initial state
|
|
22
|
+
'TRANSFERRED', -- Experience controller successfully transferred to player
|
|
23
|
+
'CONTROLLER_REJECTED', -- Hub controller rejected the take request (player had zero balance)
|
|
24
|
+
'USER_CANCELED' -- Player canceled the take request
|
|
25
|
+
);
|
|
26
|
+
|
|
27
|
+
-- Maps to MP's app_public.transfer_status_kind enum
|
|
28
|
+
CREATE TYPE hub.mp_transfer_status AS ENUM (
|
|
29
|
+
'PENDING', -- Initial state
|
|
30
|
+
'COMPLETED', -- Balance transfer completed
|
|
31
|
+
'CANCELED', -- Player canceled
|
|
32
|
+
'UNCLAIMED', -- Controller hasn't claimed
|
|
33
|
+
'EXPIRED' -- Transfer expired
|
|
34
|
+
);
|
|
35
|
+
|
|
36
|
+
-- Create the simplified take request table
|
|
37
|
+
CREATE TABLE hub.take_request (
|
|
38
|
+
id UUID PRIMARY KEY DEFAULT hub_hidden.uuid_generate_v7(),
|
|
39
|
+
mp_take_request_id UUID UNIQUE NOT NULL, -- MP take request ID
|
|
40
|
+
user_id UUID NOT NULL REFERENCES hub.user(id),
|
|
41
|
+
experience_id UUID NOT NULL REFERENCES hub.experience(id),
|
|
42
|
+
casino_id UUID NOT NULL REFERENCES hub.casino(id),
|
|
43
|
+
currency_key TEXT NOT NULL,
|
|
44
|
+
amount FLOAT NULL, -- NULL means "take all"
|
|
45
|
+
status hub.take_request_status NOT NULL DEFAULT 'PENDING',
|
|
46
|
+
mp_status hub.mp_take_request_status NOT NULL DEFAULT 'PENDING', -- MP's take request status
|
|
47
|
+
status_changed_at TIMESTAMPTZ NOT NULL DEFAULT now(), -- When our status was last changed
|
|
48
|
+
reserved_amount FLOAT NOT NULL,
|
|
49
|
+
mp_transfer_id UUID NULL, -- ID of the transfer
|
|
50
|
+
-- mp_transfer_status is just informational
|
|
51
|
+
mp_transfer_status hub.mp_transfer_status NULL,
|
|
52
|
+
-- Whether we need to call completeTransfer
|
|
53
|
+
transfer_needs_completion BOOLEAN NOT NULL DEFAULT TRUE,
|
|
54
|
+
-- When we last attempted to complete the transfer
|
|
55
|
+
transfer_completion_attempted_at TIMESTAMPTZ NULL,
|
|
56
|
+
updated_at TIMESTAMPTZ NOT NULL DEFAULT now(),
|
|
57
|
+
|
|
58
|
+
FOREIGN KEY (currency_key, casino_id) REFERENCES hub.currency(key, casino_id)
|
|
59
|
+
);
|
|
60
|
+
|
|
61
|
+
-- Create indexes for queries we'll run frequently
|
|
62
|
+
CREATE INDEX take_request_casino_id_idx ON hub.take_request(casino_id);
|
|
63
|
+
CREATE INDEX take_request_user_id_idx ON hub.take_request(user_id);
|
|
64
|
+
CREATE INDEX take_request_experience_id_idx ON hub.take_request(experience_id);
|
|
65
|
+
CREATE INDEX take_request_status_idx ON hub.take_request(status);
|
|
66
|
+
CREATE INDEX take_request_updated_at_idx ON hub.take_request(updated_at);
|
|
67
|
+
-- A mp_take_request_id is unique per casino
|
|
68
|
+
CREATE UNIQUE INDEX take_request_casino_id_mp_take_request_id_key ON hub.take_request(casino_id, mp_take_request_id);
|
|
69
|
+
-- A mp_transfer_id is unique per casino
|
|
70
|
+
CREATE UNIQUE INDEX take_request_casino_id_mp_transfer_id_key ON hub.take_request(casino_id, mp_transfer_id) WHERE mp_transfer_id IS NOT NULL;
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
-- Create a function to automatically update timestamps
|
|
74
|
+
CREATE OR REPLACE FUNCTION hub.update_take_request_timestamps()
|
|
75
|
+
RETURNS TRIGGER AS $$
|
|
76
|
+
BEGIN
|
|
77
|
+
NEW.updated_at = NOW();
|
|
78
|
+
|
|
79
|
+
-- Update status_changed_at if status is changing
|
|
80
|
+
IF OLD.status IS DISTINCT FROM NEW.status THEN
|
|
81
|
+
NEW.status_changed_at = NOW();
|
|
82
|
+
END IF;
|
|
83
|
+
|
|
84
|
+
RETURN NEW;
|
|
85
|
+
END;
|
|
86
|
+
$$ LANGUAGE plpgsql;
|
|
87
|
+
|
|
88
|
+
-- Create trigger to call the function
|
|
89
|
+
CREATE TRIGGER update_take_request_timestamps
|
|
90
|
+
BEFORE UPDATE ON hub.take_request
|
|
91
|
+
FOR EACH ROW
|
|
92
|
+
EXECUTE FUNCTION hub.update_take_request_timestamps();
|
|
93
|
+
|
|
94
|
+
-- GRANTS
|
|
95
|
+
|
|
96
|
+
GRANT SELECT ON hub.take_request TO app_postgraphile;
|
|
97
|
+
|
|
98
|
+
-- RLS
|
|
99
|
+
|
|
100
|
+
ALTER TABLE hub.take_request ENABLE ROW LEVEL SECURITY;
|
|
101
|
+
|
|
102
|
+
CREATE POLICY select_take_request ON hub.take_request FOR SELECT USING (
|
|
103
|
+
hub_hidden.is_operator() OR (
|
|
104
|
+
-- Users can only see their own records
|
|
105
|
+
user_id = hub_hidden.current_user_id()
|
|
106
|
+
)
|
|
107
|
+
);
|
|
@@ -32,8 +32,8 @@ export const HubWithdrawPlugin = makeExtendSchemaPlugin((build) => {
|
|
|
32
32
|
const { session } = identity;
|
|
33
33
|
return withPgPoolTransaction(superuserPool, async (pgClient) => {
|
|
34
34
|
const { amount, currency } = input;
|
|
35
|
-
if (amount
|
|
36
|
-
throw new GraphQLError("Withdraw amount must be
|
|
35
|
+
if (amount < 1) {
|
|
36
|
+
throw new GraphQLError("Withdraw amount must be at least 1");
|
|
37
37
|
}
|
|
38
38
|
if (!Number.isInteger(amount)) {
|
|
39
39
|
throw new GraphQLError("Withdraw amount must be an integer");
|
|
@@ -14,6 +14,7 @@ import { assert } from "tsafe";
|
|
|
14
14
|
import { isUuid } from "./util.js";
|
|
15
15
|
import { processWithdrawalRequests } from "./process-withdrawal-request.js";
|
|
16
16
|
import * as jwtService from "./services/jwt-service.js";
|
|
17
|
+
import { processTakeRequests } from "./take-request/process-take-request.js";
|
|
17
18
|
const MP_COMPLETE_TRANSFER = gql(`
|
|
18
19
|
mutation CompleteTransfer($mpTransferId: UUID!) {
|
|
19
20
|
completeTransfer(input: { id: $mpTransferId }) {
|
|
@@ -252,7 +253,10 @@ async function processTransfersUntilEmpty({ afterCursor, graphqlClient, casinoIn
|
|
|
252
253
|
}
|
|
253
254
|
return afterCursor;
|
|
254
255
|
}
|
|
255
|
-
async function processWithdrawals({ casinoId, graphqlClient, }) {
|
|
256
|
+
async function processWithdrawals({ abortSignal, casinoId, graphqlClient, }) {
|
|
257
|
+
if (abortSignal.aborted) {
|
|
258
|
+
return;
|
|
259
|
+
}
|
|
256
260
|
const withdrawals = await db.getPendingWithdrawals(superuserPool, {
|
|
257
261
|
casinoId,
|
|
258
262
|
limit: 10,
|
|
@@ -261,6 +265,9 @@ async function processWithdrawals({ casinoId, graphqlClient, }) {
|
|
|
261
265
|
logger.debug(`[sendWithdrawalLoop] withdrawals:`, withdrawals);
|
|
262
266
|
}
|
|
263
267
|
for (const withdrawal of withdrawals) {
|
|
268
|
+
if (abortSignal.aborted) {
|
|
269
|
+
break;
|
|
270
|
+
}
|
|
264
271
|
const response = await graphqlClient.request(MP_COMPLETE_TRANSFER, {
|
|
265
272
|
mpTransferId: withdrawal.mp_transfer_id,
|
|
266
273
|
});
|
|
@@ -404,7 +411,21 @@ export function startTransferProcessor({ casinoId, signal, }) {
|
|
|
404
411
|
logger.info(`[startTransferProcessor] Aborted by graceful shutdown.`);
|
|
405
412
|
break;
|
|
406
413
|
}
|
|
407
|
-
await processWithdrawals({
|
|
414
|
+
await processWithdrawals({
|
|
415
|
+
abortSignal: signal,
|
|
416
|
+
casinoId: casino.id,
|
|
417
|
+
graphqlClient,
|
|
418
|
+
});
|
|
419
|
+
if (signal.aborted) {
|
|
420
|
+
logger.info(`[startTransferProcessor] Aborted by graceful shutdown.`);
|
|
421
|
+
break;
|
|
422
|
+
}
|
|
423
|
+
await processTakeRequests({
|
|
424
|
+
abortSignal: signal,
|
|
425
|
+
controllerId: casinoSecret.controller_id,
|
|
426
|
+
casinoId: casino.id,
|
|
427
|
+
graphqlClient,
|
|
428
|
+
});
|
|
408
429
|
processorState.backoffTime = MIN_BACKOFF_TIME;
|
|
409
430
|
}
|
|
410
431
|
catch (e) {
|