@smartico/public-api 0.0.214 → 0.0.216
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/MiniGames/SAWPrizeUI.d.ts +1 -0
- package/dist/SmarticoLib/index.d.ts +1 -0
- package/dist/WSAPI/WSAPI.d.ts +12 -2
- package/dist/index.js +87 -69
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +13 -1
- package/dist/index.modern.mjs.map +1 -1
- package/docs/classes/WSAPI.md +26 -2
- package/docs/interfaces/TMiniGameTemplate.md +6 -0
- package/package.json +1 -1
- package/src/MiniGames/SAWPrizeUI.ts +1 -0
- package/src/SmarticoLib/index.ts +1 -0
- package/src/WSAPI/WSAPI.ts +55 -22
package/dist/WSAPI/WSAPI.d.ts
CHANGED
|
@@ -266,8 +266,8 @@ export declare class WSAPI {
|
|
|
266
266
|
* ```
|
|
267
267
|
*
|
|
268
268
|
* **Visitor mode: not supported**
|
|
269
|
-
|
|
270
|
-
getMiniGamesHistory({ limit, offset, saw_template_id }: {
|
|
269
|
+
*/
|
|
270
|
+
getMiniGamesHistory({ limit, offset, saw_template_id, }: {
|
|
271
271
|
limit?: number;
|
|
272
272
|
offset?: number;
|
|
273
273
|
saw_template_id?: number;
|
|
@@ -289,6 +289,16 @@ export declare class WSAPI {
|
|
|
289
289
|
playMiniGame(template_id: number, { onUpdate }?: {
|
|
290
290
|
onUpdate?: (data: TMiniGameTemplate[]) => void;
|
|
291
291
|
}): Promise<TMiniGamePlayResult>;
|
|
292
|
+
/**
|
|
293
|
+
* Sends the acknowledge request with specific client_request_id from minigame history in order to claim prize
|
|
294
|
+
* **Example**:
|
|
295
|
+
* ```
|
|
296
|
+
* _smartico.api.miniGameWinAcknowledgeRequest('2a189322-31bb-4119-b943-bx7868ff8dc3').then((result) => {
|
|
297
|
+
* console.log(result);
|
|
298
|
+
* });
|
|
299
|
+
* ```
|
|
300
|
+
*/
|
|
301
|
+
miniGameWinAcknowledgeRequest(request_id: string): Promise<import("../MiniGames").SAWDoAknowledgeResponse>;
|
|
292
302
|
/**
|
|
293
303
|
* Plays the specified by template_id mini-game on behalf of user spin_count times and returns array of the prizes
|
|
294
304
|
* After playMiniGameBatch is called, you can call getMiniGames to get the list of mini-games. The returned list of mini-games is cached for 30 seconds. But you can pass the onUpdate callback as a parameter. Note that each time you call playMiniGameBatch with a new onUpdate callback, the old one will be overwritten by the new one.
|
package/dist/index.js
CHANGED
|
@@ -2034,7 +2034,7 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2034
2034
|
* ```
|
|
2035
2035
|
*
|
|
2036
2036
|
* **Visitor mode: not supported**
|
|
2037
|
-
|
|
2037
|
+
*/
|
|
2038
2038
|
;
|
|
2039
2039
|
_proto.getMiniGamesHistory = function getMiniGamesHistory(_ref5) {
|
|
2040
2040
|
var limit = _ref5.limit,
|
|
@@ -2085,6 +2085,24 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2085
2085
|
return Promise.reject(e);
|
|
2086
2086
|
}
|
|
2087
2087
|
}
|
|
2088
|
+
/**
|
|
2089
|
+
* Sends the acknowledge request with specific client_request_id from minigame history in order to claim prize
|
|
2090
|
+
* **Example**:
|
|
2091
|
+
* ```
|
|
2092
|
+
* _smartico.api.miniGameWinAcknowledgeRequest('2a189322-31bb-4119-b943-bx7868ff8dc3').then((result) => {
|
|
2093
|
+
* console.log(result);
|
|
2094
|
+
* });
|
|
2095
|
+
* ```
|
|
2096
|
+
*/
|
|
2097
|
+
;
|
|
2098
|
+
_proto.miniGameWinAcknowledgeRequest = function miniGameWinAcknowledgeRequest(request_id) {
|
|
2099
|
+
try {
|
|
2100
|
+
var _this19 = this;
|
|
2101
|
+
return Promise.resolve(_this19.api.doAcknowledgeRequest(null, request_id));
|
|
2102
|
+
} catch (e) {
|
|
2103
|
+
return Promise.reject(e);
|
|
2104
|
+
}
|
|
2105
|
+
}
|
|
2088
2106
|
/**
|
|
2089
2107
|
* Plays the specified by template_id mini-game on behalf of user spin_count times and returns array of the prizes
|
|
2090
2108
|
* After playMiniGameBatch is called, you can call getMiniGames to get the list of mini-games. The returned list of mini-games is cached for 30 seconds. But you can pass the onUpdate callback as a parameter. Note that each time you call playMiniGameBatch with a new onUpdate callback, the old one will be overwritten by the new one.
|
|
@@ -2103,15 +2121,15 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2103
2121
|
var _ref7 = _temp6 === void 0 ? {} : _temp6,
|
|
2104
2122
|
onUpdate = _ref7.onUpdate;
|
|
2105
2123
|
try {
|
|
2106
|
-
var
|
|
2124
|
+
var _this20 = this;
|
|
2107
2125
|
if (onUpdate) {
|
|
2108
|
-
|
|
2126
|
+
_this20.onUpdateCallback.set(onUpdateContextKey.Saw, onUpdate);
|
|
2109
2127
|
}
|
|
2110
|
-
return Promise.resolve(
|
|
2128
|
+
return Promise.resolve(_this20.api.sawSpinBatchRequest(null, template_id, spin_count)).then(function (response) {
|
|
2111
2129
|
var request_ids = response.results.map(function (result) {
|
|
2112
2130
|
return result.request_id;
|
|
2113
2131
|
});
|
|
2114
|
-
|
|
2132
|
+
_this20.api.doAcknowledgeBatchRequest(null, request_ids);
|
|
2115
2133
|
var o = response.results.map(function (result) {
|
|
2116
2134
|
return {
|
|
2117
2135
|
errCode: result.errCode,
|
|
@@ -2135,8 +2153,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2135
2153
|
;
|
|
2136
2154
|
_proto.requestMissionOptIn = function requestMissionOptIn(mission_id) {
|
|
2137
2155
|
try {
|
|
2138
|
-
var
|
|
2139
|
-
return Promise.resolve(
|
|
2156
|
+
var _this21 = this;
|
|
2157
|
+
return Promise.resolve(_this21.api.missionOptIn(null, mission_id)).then(function (r) {
|
|
2140
2158
|
var o = {
|
|
2141
2159
|
err_code: r.errCode,
|
|
2142
2160
|
err_message: r.errMsg
|
|
@@ -2155,8 +2173,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2155
2173
|
;
|
|
2156
2174
|
_proto.requestMissionClaimReward = function requestMissionClaimReward(mission_id, ach_completed_id) {
|
|
2157
2175
|
try {
|
|
2158
|
-
var
|
|
2159
|
-
return Promise.resolve(
|
|
2176
|
+
var _this22 = this;
|
|
2177
|
+
return Promise.resolve(_this22.api.missionClaimPrize(null, mission_id, ach_completed_id)).then(function (r) {
|
|
2160
2178
|
var o = {
|
|
2161
2179
|
err_code: r.errCode,
|
|
2162
2180
|
err_message: r.errMsg
|
|
@@ -2190,12 +2208,12 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2190
2208
|
var _ref8 = _temp7 === void 0 ? {} : _temp7,
|
|
2191
2209
|
onUpdate = _ref8.onUpdate;
|
|
2192
2210
|
try {
|
|
2193
|
-
var
|
|
2211
|
+
var _this23 = this;
|
|
2194
2212
|
if (onUpdate) {
|
|
2195
|
-
|
|
2213
|
+
_this23.onUpdateCallback.set(onUpdateContextKey.TournamentList, onUpdate);
|
|
2196
2214
|
}
|
|
2197
2215
|
return Promise.resolve(OCache.use(onUpdateContextKey.TournamentList, exports.ECacheContext.WSAPI, function () {
|
|
2198
|
-
return
|
|
2216
|
+
return _this23.api.tournamentsGetLobbyT(null);
|
|
2199
2217
|
}, CACHE_DATA_SEC));
|
|
2200
2218
|
} catch (e) {
|
|
2201
2219
|
return Promise.reject(e);
|
|
@@ -2229,8 +2247,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2229
2247
|
;
|
|
2230
2248
|
_proto.getTournamentInstanceInfo = function getTournamentInstanceInfo(tournamentInstanceId) {
|
|
2231
2249
|
try {
|
|
2232
|
-
var
|
|
2233
|
-
return Promise.resolve(
|
|
2250
|
+
var _this24 = this;
|
|
2251
|
+
return Promise.resolve(_this24.api.tournamentsGetInfoT(null, tournamentInstanceId));
|
|
2234
2252
|
} catch (e) {
|
|
2235
2253
|
return Promise.reject(e);
|
|
2236
2254
|
}
|
|
@@ -2243,8 +2261,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2243
2261
|
;
|
|
2244
2262
|
_proto.registerInTournament = function registerInTournament(tournamentInstanceId) {
|
|
2245
2263
|
try {
|
|
2246
|
-
var
|
|
2247
|
-
return Promise.resolve(
|
|
2264
|
+
var _this25 = this;
|
|
2265
|
+
return Promise.resolve(_this25.api.registerInTournament(null, tournamentInstanceId)).then(function (r) {
|
|
2248
2266
|
var o = {
|
|
2249
2267
|
err_code: r.errCode,
|
|
2250
2268
|
err_message: r.errMsg
|
|
@@ -2276,9 +2294,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2276
2294
|
;
|
|
2277
2295
|
_proto.getLeaderBoard = function getLeaderBoard(periodType, getPreviousPeriod) {
|
|
2278
2296
|
try {
|
|
2279
|
-
var
|
|
2297
|
+
var _this26 = this;
|
|
2280
2298
|
return Promise.resolve(OCache.use(onUpdateContextKey.LeaderBoards, exports.ECacheContext.WSAPI, function () {
|
|
2281
|
-
return
|
|
2299
|
+
return _this26.api.leaderboardsGetT(null, periodType, getPreviousPeriod);
|
|
2282
2300
|
}, CACHE_DATA_SEC));
|
|
2283
2301
|
} catch (e) {
|
|
2284
2302
|
return Promise.reject(e);
|
|
@@ -2304,11 +2322,11 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2304
2322
|
onlyFavorite = _ref9.onlyFavorite,
|
|
2305
2323
|
onUpdate = _ref9.onUpdate;
|
|
2306
2324
|
try {
|
|
2307
|
-
var
|
|
2325
|
+
var _this27 = this;
|
|
2308
2326
|
if (onUpdate) {
|
|
2309
|
-
|
|
2327
|
+
_this27.onUpdateCallback.set(onUpdateContextKey.InboxMessages, onUpdate);
|
|
2310
2328
|
}
|
|
2311
|
-
return Promise.resolve(
|
|
2329
|
+
return Promise.resolve(_this27.api.getInboxMessagesT(null, from, to, onlyFavorite));
|
|
2312
2330
|
} catch (e) {
|
|
2313
2331
|
return Promise.reject(e);
|
|
2314
2332
|
}
|
|
@@ -2321,8 +2339,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2321
2339
|
;
|
|
2322
2340
|
_proto.getInboxMessageBody = function getInboxMessageBody(messageGuid) {
|
|
2323
2341
|
try {
|
|
2324
|
-
var
|
|
2325
|
-
return Promise.resolve(
|
|
2342
|
+
var _this28 = this;
|
|
2343
|
+
return Promise.resolve(_this28.api.getInboxMessageBodyT(messageGuid));
|
|
2326
2344
|
} catch (e) {
|
|
2327
2345
|
return Promise.reject(e);
|
|
2328
2346
|
}
|
|
@@ -2335,8 +2353,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2335
2353
|
;
|
|
2336
2354
|
_proto.markInboxMessageAsRead = function markInboxMessageAsRead(messageGuid) {
|
|
2337
2355
|
try {
|
|
2338
|
-
var
|
|
2339
|
-
return Promise.resolve(
|
|
2356
|
+
var _this29 = this;
|
|
2357
|
+
return Promise.resolve(_this29.api.markInboxMessageRead(null, messageGuid)).then(function (r) {
|
|
2340
2358
|
return {
|
|
2341
2359
|
err_code: r.errCode,
|
|
2342
2360
|
err_message: r.errMsg
|
|
@@ -2354,8 +2372,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2354
2372
|
;
|
|
2355
2373
|
_proto.markAllInboxMessagesAsRead = function markAllInboxMessagesAsRead() {
|
|
2356
2374
|
try {
|
|
2357
|
-
var
|
|
2358
|
-
return Promise.resolve(
|
|
2375
|
+
var _this30 = this;
|
|
2376
|
+
return Promise.resolve(_this30.api.markAllInboxMessageRead(null)).then(function (r) {
|
|
2359
2377
|
return {
|
|
2360
2378
|
err_code: r.errCode,
|
|
2361
2379
|
err_message: r.errMsg
|
|
@@ -2373,8 +2391,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2373
2391
|
;
|
|
2374
2392
|
_proto.markUnmarkInboxMessageAsFavorite = function markUnmarkInboxMessageAsFavorite(messageGuid, mark) {
|
|
2375
2393
|
try {
|
|
2376
|
-
var
|
|
2377
|
-
return Promise.resolve(
|
|
2394
|
+
var _this31 = this;
|
|
2395
|
+
return Promise.resolve(_this31.api.markUnmarkInboxMessageAsFavorite(null, messageGuid, mark)).then(function (r) {
|
|
2378
2396
|
return {
|
|
2379
2397
|
err_code: r.errCode,
|
|
2380
2398
|
err_message: r.errMsg
|
|
@@ -2392,8 +2410,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2392
2410
|
;
|
|
2393
2411
|
_proto.deleteInboxMessage = function deleteInboxMessage(messageGuid) {
|
|
2394
2412
|
try {
|
|
2395
|
-
var
|
|
2396
|
-
return Promise.resolve(
|
|
2413
|
+
var _this32 = this;
|
|
2414
|
+
return Promise.resolve(_this32.api.deleteInboxMessage(null, messageGuid)).then(function (r) {
|
|
2397
2415
|
return {
|
|
2398
2416
|
err_code: r.errCode,
|
|
2399
2417
|
err_message: r.errMsg
|
|
@@ -2411,8 +2429,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2411
2429
|
;
|
|
2412
2430
|
_proto.deleteAllInboxMessages = function deleteAllInboxMessages() {
|
|
2413
2431
|
try {
|
|
2414
|
-
var
|
|
2415
|
-
return Promise.resolve(
|
|
2432
|
+
var _this33 = this;
|
|
2433
|
+
return Promise.resolve(_this33.api.deleteAllInboxMessages(null)).then(function (r) {
|
|
2416
2434
|
return {
|
|
2417
2435
|
err_code: r.errCode,
|
|
2418
2436
|
err_message: r.errMsg
|
|
@@ -2428,8 +2446,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2428
2446
|
;
|
|
2429
2447
|
_proto.getTranslations = function getTranslations(lang_code) {
|
|
2430
2448
|
try {
|
|
2431
|
-
var
|
|
2432
|
-
return Promise.resolve(
|
|
2449
|
+
var _this34 = this;
|
|
2450
|
+
return Promise.resolve(_this34.api.getTranslationsT(null, lang_code, [])).then(function (r) {
|
|
2433
2451
|
return {
|
|
2434
2452
|
translations: r.translations
|
|
2435
2453
|
};
|
|
@@ -2440,15 +2458,15 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2440
2458
|
};
|
|
2441
2459
|
_proto.updateOnSpin = function updateOnSpin(data) {
|
|
2442
2460
|
try {
|
|
2443
|
-
var
|
|
2461
|
+
var _this35 = this;
|
|
2444
2462
|
return Promise.resolve(OCache.use(onUpdateContextKey.Saw, exports.ECacheContext.WSAPI, function () {
|
|
2445
|
-
return
|
|
2463
|
+
return _this35.api.sawGetTemplatesT(null);
|
|
2446
2464
|
}, CACHE_DATA_SEC)).then(function (templates) {
|
|
2447
2465
|
var index = templates.findIndex(function (t) {
|
|
2448
2466
|
return t.id === data.saw_template_id;
|
|
2449
2467
|
});
|
|
2450
2468
|
templates[index].spin_count = data.spin_count;
|
|
2451
|
-
|
|
2469
|
+
_this35.updateEntity(onUpdateContextKey.Saw, templates);
|
|
2452
2470
|
});
|
|
2453
2471
|
} catch (e) {
|
|
2454
2472
|
return Promise.reject(e);
|
|
@@ -2456,9 +2474,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2456
2474
|
};
|
|
2457
2475
|
_proto.reloadMiniGameTemplate = function reloadMiniGameTemplate() {
|
|
2458
2476
|
try {
|
|
2459
|
-
var
|
|
2460
|
-
return Promise.resolve(
|
|
2461
|
-
|
|
2477
|
+
var _this36 = this;
|
|
2478
|
+
return Promise.resolve(_this36.api.sawGetTemplatesT(null)).then(function (updatedTemplates) {
|
|
2479
|
+
_this36.updateEntity(onUpdateContextKey.Saw, updatedTemplates);
|
|
2462
2480
|
});
|
|
2463
2481
|
} catch (e) {
|
|
2464
2482
|
return Promise.reject(e);
|
|
@@ -2466,9 +2484,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2466
2484
|
};
|
|
2467
2485
|
_proto.updateMissions = function updateMissions() {
|
|
2468
2486
|
try {
|
|
2469
|
-
var
|
|
2470
|
-
return Promise.resolve(
|
|
2471
|
-
|
|
2487
|
+
var _this37 = this;
|
|
2488
|
+
return Promise.resolve(_this37.api.missionsGetItemsT(null)).then(function (payload) {
|
|
2489
|
+
_this37.updateEntity(onUpdateContextKey.Missions, payload);
|
|
2472
2490
|
});
|
|
2473
2491
|
} catch (e) {
|
|
2474
2492
|
return Promise.reject(e);
|
|
@@ -2476,9 +2494,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2476
2494
|
};
|
|
2477
2495
|
_proto.updateBonuses = function updateBonuses() {
|
|
2478
2496
|
try {
|
|
2479
|
-
var
|
|
2480
|
-
return Promise.resolve(
|
|
2481
|
-
|
|
2497
|
+
var _this38 = this;
|
|
2498
|
+
return Promise.resolve(_this38.api.bonusesGetItemsT(null)).then(function (payload) {
|
|
2499
|
+
_this38.updateEntity(onUpdateContextKey.Bonuses, payload);
|
|
2482
2500
|
});
|
|
2483
2501
|
} catch (e) {
|
|
2484
2502
|
return Promise.reject(e);
|
|
@@ -2486,9 +2504,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2486
2504
|
};
|
|
2487
2505
|
_proto.updateTournaments = function updateTournaments() {
|
|
2488
2506
|
try {
|
|
2489
|
-
var
|
|
2490
|
-
return Promise.resolve(
|
|
2491
|
-
|
|
2507
|
+
var _this39 = this;
|
|
2508
|
+
return Promise.resolve(_this39.api.tournamentsGetLobbyT(null)).then(function (payload) {
|
|
2509
|
+
_this39.updateEntity(onUpdateContextKey.TournamentList, payload);
|
|
2492
2510
|
});
|
|
2493
2511
|
} catch (e) {
|
|
2494
2512
|
return Promise.reject(e);
|
|
@@ -2496,9 +2514,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2496
2514
|
};
|
|
2497
2515
|
_proto.updateInboxMessages = function updateInboxMessages() {
|
|
2498
2516
|
try {
|
|
2499
|
-
var
|
|
2500
|
-
return Promise.resolve(
|
|
2501
|
-
|
|
2517
|
+
var _this40 = this;
|
|
2518
|
+
return Promise.resolve(_this40.api.getInboxMessagesT(null)).then(function (payload) {
|
|
2519
|
+
_this40.updateEntity(onUpdateContextKey.InboxMessages, payload);
|
|
2502
2520
|
});
|
|
2503
2521
|
} catch (e) {
|
|
2504
2522
|
return Promise.reject(e);
|
|
@@ -2506,9 +2524,9 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2506
2524
|
};
|
|
2507
2525
|
_proto.updateEntity = function updateEntity(contextKey, payload) {
|
|
2508
2526
|
try {
|
|
2509
|
-
var
|
|
2527
|
+
var _this41 = this;
|
|
2510
2528
|
OCache.set(contextKey, payload, exports.ECacheContext.WSAPI);
|
|
2511
|
-
var onUpdate =
|
|
2529
|
+
var onUpdate = _this41.onUpdateCallback.get(contextKey);
|
|
2512
2530
|
if (onUpdate) {
|
|
2513
2531
|
onUpdate(payload);
|
|
2514
2532
|
}
|
|
@@ -2548,17 +2566,17 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2548
2566
|
;
|
|
2549
2567
|
_proto.jackpotGet = function jackpotGet(filter) {
|
|
2550
2568
|
try {
|
|
2551
|
-
var
|
|
2569
|
+
var _this42 = this;
|
|
2552
2570
|
var signature = (filter == null ? void 0 : filter.jp_template_id) + ":" + (filter == null ? void 0 : filter.related_game_id);
|
|
2553
|
-
if (signature !==
|
|
2554
|
-
|
|
2555
|
-
|
|
2571
|
+
if (signature !== _this42.jackpotGetSignature) {
|
|
2572
|
+
_this42.jackpotGetSignature = signature;
|
|
2573
|
+
_this42.jackpotClearCache();
|
|
2556
2574
|
}
|
|
2557
2575
|
var jackpots = [];
|
|
2558
2576
|
var pots = [];
|
|
2559
2577
|
return Promise.resolve(OCache.use(onUpdateContextKey.Jackpots, exports.ECacheContext.WSAPI, function () {
|
|
2560
2578
|
try {
|
|
2561
|
-
return Promise.resolve(
|
|
2579
|
+
return Promise.resolve(_this42.api.jackpotGet(null, filter)).then(function (_jackpots) {
|
|
2562
2580
|
var _pots = _jackpots.items.map(function (jp) {
|
|
2563
2581
|
return jp.pot;
|
|
2564
2582
|
});
|
|
@@ -2587,10 +2605,10 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2587
2605
|
var jp_template_ids = jackpots.map(function (jp) {
|
|
2588
2606
|
return jp.jp_template_id;
|
|
2589
2607
|
});
|
|
2590
|
-
return Promise.resolve(
|
|
2608
|
+
return Promise.resolve(_this42.api.potGet(null, {
|
|
2591
2609
|
jp_template_ids: jp_template_ids
|
|
2592
|
-
})).then(function (
|
|
2593
|
-
return
|
|
2610
|
+
})).then(function (_this42$api$potGet) {
|
|
2611
|
+
return _this42$api$potGet.items;
|
|
2594
2612
|
});
|
|
2595
2613
|
} catch (e) {
|
|
2596
2614
|
return Promise.reject(e);
|
|
@@ -2623,11 +2641,11 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2623
2641
|
;
|
|
2624
2642
|
_proto.jackpotOptIn = function jackpotOptIn(filter) {
|
|
2625
2643
|
try {
|
|
2626
|
-
var
|
|
2644
|
+
var _this43 = this;
|
|
2627
2645
|
if (!filter.jp_template_id) {
|
|
2628
2646
|
throw new Error('jp_template_id is required in jackpotOptIn');
|
|
2629
2647
|
}
|
|
2630
|
-
return Promise.resolve(
|
|
2648
|
+
return Promise.resolve(_this43.api.jackpotOptIn(null, filter));
|
|
2631
2649
|
} catch (e) {
|
|
2632
2650
|
return Promise.reject(e);
|
|
2633
2651
|
}
|
|
@@ -2649,11 +2667,11 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2649
2667
|
;
|
|
2650
2668
|
_proto.jackpotOptOut = function jackpotOptOut(filter) {
|
|
2651
2669
|
try {
|
|
2652
|
-
var
|
|
2670
|
+
var _this44 = this;
|
|
2653
2671
|
if (!filter.jp_template_id) {
|
|
2654
2672
|
throw new Error('jp_template_id is required in jackpotOptOut');
|
|
2655
2673
|
}
|
|
2656
|
-
return Promise.resolve(
|
|
2674
|
+
return Promise.resolve(_this44.api.jackpotOptOut(null, filter));
|
|
2657
2675
|
} catch (e) {
|
|
2658
2676
|
return Promise.reject(e);
|
|
2659
2677
|
}
|
|
@@ -2679,8 +2697,8 @@ var WSAPI = /*#__PURE__*/function () {
|
|
|
2679
2697
|
;
|
|
2680
2698
|
_proto.getRelatedItemsForGame = function getRelatedItemsForGame(related_game_id) {
|
|
2681
2699
|
try {
|
|
2682
|
-
var
|
|
2683
|
-
return Promise.resolve(
|
|
2700
|
+
var _this45 = this;
|
|
2701
|
+
return Promise.resolve(_this45.api.getRelatedItemsForGame(null, related_game_id));
|
|
2684
2702
|
} catch (e) {
|
|
2685
2703
|
return Promise.reject(e);
|
|
2686
2704
|
}
|