@smartico/public-api 0.0.362 → 0.0.364

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.
@@ -1,5 +1,7 @@
1
+ import { TAvatarPrompt } from '../WSAPI/WSAPITypes';
1
2
  import { ProtocolResponse } from '../Base/ProtocolResponse';
2
3
  import { AvatarPrompt } from './AvatarPrompt';
3
4
  export interface GetAvatarPromptsResponse extends ProtocolResponse {
4
5
  prompts: AvatarPrompt[];
5
6
  }
7
+ export declare const avatarPromptTransform: (items: AvatarPrompt[], avatarDomain: string) => TAvatarPrompt[];
@@ -1,5 +1,7 @@
1
+ import { TAvatarCustomized } from '../WSAPI/WSAPITypes';
1
2
  import { ProtocolResponse } from '../Base/ProtocolResponse';
2
3
  import { AvatarCustomized } from './AvatarCustomized';
3
4
  export interface GetAvatarsCustomizedResponse extends ProtocolResponse {
4
5
  avatars: AvatarCustomized[];
5
6
  }
7
+ export declare const avatarCustomizedTransform: (items: AvatarCustomized[], avatarDomain: string) => TAvatarCustomized[];
@@ -1,5 +1,7 @@
1
+ import { TAvatarDefinition } from '../WSAPI/WSAPITypes';
1
2
  import { ProtocolResponse } from '../Base/ProtocolResponse';
2
3
  import { AvatarDefinition } from './AvatarDefinition';
3
4
  export interface GetAvatarsListResponse extends ProtocolResponse {
4
5
  avatars: AvatarDefinition[];
5
6
  }
7
+ export declare const avatarDefinitionTransform: (items: AvatarDefinition[], avatarDomain: string) => TAvatarDefinition[];
@@ -11,7 +11,7 @@ import { GetTournamentInfoResponse, GetTournamentsResponse, TournamentRegisterRe
11
11
  import { LeaderBoardDetails, LeaderBoardPeriodType } from './Leaderboard';
12
12
  import { GetLevelMapResponse } from './Level';
13
13
  import { WSAPI } from './WSAPI/WSAPI';
14
- import { TInboxMessage, TInboxMessageBody, TLevel, TMiniGameTemplate, TMissionOrBadge, TStoreCategory, TAchCategory, TStoreItem, TTournament, TTournamentDetailed, LeaderBoardDetailsT, UserLevelExtraCountersT, TSegmentCheckResult, TUICustomSection, TBonus, TRaffle, TLevelCurrent, TActivityLog, TRaffleDraw } from './WSAPI/WSAPITypes';
14
+ import { TInboxMessage, TInboxMessageBody, TLevel, TMiniGameTemplate, TMissionOrBadge, TStoreCategory, TAchCategory, TStoreItem, TTournament, TTournamentDetailed, LeaderBoardDetailsT, UserLevelExtraCountersT, TSegmentCheckResult, TUICustomSection, TBonus, TRaffle, TLevelCurrent, TActivityLog, TRaffleDraw, TAvatarDefinition, TAvatarCustomized, TAvatarPrompt } from './WSAPI/WSAPITypes';
15
15
  import { GetAchievementsUserInfoResponse } from './Core/GetAchievementsUserInfoResponse';
16
16
  import { GetJackpotsPotsResponse, GetJackpotsResponse, JackpotsOptinResponse, JackpotsOptoutResponse } from './Jackpots';
17
17
  import { GetCustomSectionsResponse } from './CustomSections';
@@ -23,7 +23,10 @@ import { GetRafflesResponse } from './Raffle/GetRafflesResponse';
23
23
  import { GetActivityLogResponse } from './ActivityLog';
24
24
  import { InboxCategories } from './Inbox/InboxCategories';
25
25
  import { GetDrawRunResponse, GetRaffleDrawRunsHistoryResponse, RaffleClaimPrizeResponse, RaffleOptinResponse } from './Raffle';
26
- import { GetAvatarsListResponse, GetAvatarsCustomizedResponse, GetAvatarPromptsResponse, SetAvatarResponse } from './Avatars';
26
+ import { GetAvatarsListResponse } from './Avatars/GetAvatarsListResponse';
27
+ import { GetAvatarsCustomizedResponse } from './Avatars/GetAvatarsCustomizedResponse';
28
+ import { GetAvatarPromptsResponse } from './Avatars/GetAvatarPromptsResponse';
29
+ import { SetAvatarResponse } from './Avatars';
27
30
  import { GetJackpotWinnersResponse, JackpotWinnerHistory } from './Jackpots/GetJackpotWinnersResponse';
28
31
  import { GetJackpotEligibleGamesResponse, TGetJackpotEligibleGamesResponse } from './Jackpots/GetJackpotEligibleGamesResponse';
29
32
  import { GamesApiResponse, GamePickRound, GamePickRoundBoard, GamePickUserInfo, GamePickGameInfo } from './WSAPI/WSAPITypes';
@@ -178,6 +181,9 @@ declare class SmarticoAPI {
178
181
  avatarsGetCustomized(user_ext_id: string): Promise<GetAvatarsCustomizedResponse>;
179
182
  avatarsGetPrompts(user_ext_id: string): Promise<GetAvatarPromptsResponse>;
180
183
  avatarSetAvatar(user_ext_id: string, avatar_id: string, avatar_real_id: number): Promise<SetAvatarResponse>;
184
+ avatarsGetListT(user_ext_id: string): Promise<TAvatarDefinition[]>;
185
+ avatarsGetCustomizedT(user_ext_id: string): Promise<TAvatarCustomized[]>;
186
+ avatarsGetPromptsT(user_ext_id: string): Promise<TAvatarPrompt[]>;
181
187
  getWSCalls(): WSAPI;
182
188
  getRelatedItemsForGame(user_ext_id: string, related_game_id: string): Promise<GetRelatedAchTourResponse>;
183
189
  getRafflesT(user_ext_id: string): Promise<TRaffle[]>;
@@ -934,7 +934,7 @@ export declare class WSAPI {
934
934
  getAvatarPrompts(): Promise<TAvatarPrompt[]>;
935
935
  /**
936
936
  * Sets the specified avatar as the active avatar for the current user.
937
- * Pass `avatar_url` (the image path from `TAvatarDefinition.public_meta.url` or a CDN URL for AI-customized avatars)
937
+ * Pass `avatar_url` (the `TAvatarDefinition.url` path or a CDN URL for AI-customized avatars)
938
938
  * and `avatar_real_id` from the avatar catalog.
939
939
  * After a successful call, the avatar list cache is cleared so the next `getAvatarsList()` call reflects `is_in_use`.
940
940
  *
@@ -944,7 +944,7 @@ export declare class WSAPI {
944
944
  * const avatar = avatars.find((a) => !a.hide_until_achieved || a.is_given);
945
945
  * if (avatar) {
946
946
  * _smartico.api.setAvatar({
947
- * avatar_url: avatar.public_meta.url,
947
+ * avatar_url: avatar.url,
948
948
  * avatar_real_id: avatar.avatar_real_id,
949
949
  * }).then((result) => {
950
950
  * console.log(result);
@@ -1753,7 +1753,8 @@ export interface GamePickRoundRequestParams extends GamePickRequestParams {
1753
1753
  round_id: number;
1754
1754
  }
1755
1755
  /**
1756
- * TAvatarDefinition describes a single avatar available in the avatar catalog
1756
+ * TAvatarDefinition describes a single avatar available in the avatar catalog.
1757
+ * Fields from the raw `public_meta` object are flattened to the top level.
1757
1758
  */
1758
1759
  export interface TAvatarDefinition {
1759
1760
  /** Unique identifier of the avatar */
@@ -1764,13 +1765,12 @@ export interface TAvatarDefinition {
1764
1765
  hide_until_achieved: boolean;
1765
1766
  /** Display priority — lower value means higher position in the grid */
1766
1767
  priority: number;
1767
- /** Public metadata containing the avatar image URL and optional description */
1768
- public_meta: {
1769
- /** Optional description of the avatar */
1770
- description?: string;
1771
- /** Image path/URL of the avatar */
1772
- url: string;
1773
- };
1768
+ /** Optional description of the avatar (from public_meta) */
1769
+ description?: string;
1770
+ /** Raw image path/URL of the avatar as returned by the server (from public_meta) */
1771
+ url: string;
1772
+ /** Full CDN URL of the avatar image, built from avatar_domain + url */
1773
+ avatar_url: string;
1774
1774
  /**
1775
1775
  * Source type of the avatar.
1776
1776
  * 0 = free (always available to all users), other values = earned/purchased
@@ -1784,8 +1784,6 @@ export interface TAvatarDefinition {
1784
1784
  is_given: boolean;
1785
1785
  /** Whether this avatar is currently in use by the user */
1786
1786
  is_in_use?: boolean;
1787
- /** Full CDN URL of the avatar image, built from avatar_domain + public_meta.url */
1788
- avatar_url: string;
1789
1787
  }
1790
1788
  /**
1791
1789
  * TAvatarCustomized describes an AI-customized version of a base avatar
@@ -1799,18 +1797,16 @@ export interface TAvatarCustomized {
1799
1797
  dt_created: string;
1800
1798
  }
1801
1799
  /**
1802
- * TAvatarPrompt describes an AI style prompt available for avatar customization
1800
+ * TAvatarPrompt describes an AI style prompt available for avatar customization.
1801
+ * Fields from the raw `public_meta` object are flattened to the top level.
1803
1802
  */
1804
1803
  export interface TAvatarPrompt {
1805
1804
  /** Unique identifier of the AI customization prompt */
1806
1805
  prompt_id: number;
1807
- /** Public metadata for the prompt */
1808
- public_meta: {
1809
- /** Display name of the prompt style (e.g. "Cartoon", "Watercolor") */
1810
- name: string;
1811
- /** URL of the prompt style icon image */
1812
- icon_url: string;
1813
- };
1806
+ /** Display name of the prompt style, e.g. "Cartoon", "Watercolor" (from public_meta) */
1807
+ name: string;
1808
+ /** Full CDN URL of the prompt style icon image (from public_meta) */
1809
+ icon_url: string;
1814
1810
  /** Currency type used to pay for this customization (0=points, 1=gems, 2=diamonds) */
1815
1811
  cost_currency_type_id: number;
1816
1812
  /** Cost amount in the given currency */
package/dist/index.js CHANGED
@@ -1248,6 +1248,26 @@ exports.BadgesTimeLimitStates = void 0;
1248
1248
  var _MissionUtils;
1249
1249
  var USER_STATE_PARAMS_KEYS_GAMES = ['core_fav_game_top3', 'core_fav_game_type_top3', 'core_fav_game_provider_top3'];
1250
1250
  var USER_STATE_PARAMS_KEYS_BET_AMOUNT = ['core_recommended_deposit_amount', 'core_recommended_casino_bet_amount', 'casino_last_bet_amount', 'casino_last_bet_amount_real', 'casino_last_bet_amount_bonus', 'acc_last_deposit_amount'];
1251
+ var MINOR_WORDS = new Set(['of', 'at', 'in', 'on', 'to', 'up', 'as', 'by', 'for', 'from', 'into', 'onto', 'with', 'upon', 'via', 'and', 'but', 'or', 'nor', 'so', 'yet', 'vs', 'v', 'a', 'an', 'the']);
1252
+ function toGameTitleCase(raw) {
1253
+ if (!raw) return raw;
1254
+ var tokens = raw.toLowerCase().split(/(\b\w+\b)/);
1255
+ var wordTokens = tokens.filter(function (t) {
1256
+ return /^\w+$/.test(t);
1257
+ });
1258
+ var lastWordIdx = wordTokens.length - 1;
1259
+ var wordIndex = 0;
1260
+ return tokens.map(function (token) {
1261
+ if (!/^\w+$/.test(token)) return token;
1262
+ var isFirst = wordIndex === 0;
1263
+ var isLast = wordIndex === lastWordIdx;
1264
+ wordIndex++;
1265
+ if (isFirst || isLast || !MINOR_WORDS.has(token)) {
1266
+ return token.charAt(0).toUpperCase() + token.slice(1);
1267
+ }
1268
+ return token;
1269
+ }).join('');
1270
+ }
1251
1271
  var MissionUtils = function MissionUtils() {};
1252
1272
  _MissionUtils = MissionUtils;
1253
1273
  MissionUtils.getAvailabilityStatus = function (mission) {
@@ -1424,8 +1444,8 @@ MissionUtils.replaceTagsFavMissionTask = function (_ref) {
1424
1444
  });
1425
1445
  if (value && value.length > 0) {
1426
1446
  suggestedGames = value.map(function (v) {
1427
- var cleaned = v.replace(/_/g, ' ').toLowerCase();
1428
- return cleaned.charAt(0).toUpperCase() + cleaned.slice(1);
1447
+ var cleaned = v.replace(/_/g, ' ');
1448
+ return toGameTitleCase(cleaned);
1429
1449
  }).join(', ');
1430
1450
  }
1431
1451
  }
@@ -1435,8 +1455,7 @@ MissionUtils.replaceTagsFavMissionTask = function (_ref) {
1435
1455
  if (IntUtils.isNotNull(pos) && _value && _value[pos]) {
1436
1456
  suggestedGames = _value[pos];
1437
1457
  if (suggestedGames) {
1438
- suggestedGames = suggestedGames.replace('_', ' ').toLowerCase();
1439
- suggestedGames = suggestedGames.charAt(0).toUpperCase() + suggestedGames.slice(1);
1458
+ suggestedGames = toGameTitleCase(suggestedGames.replace(/_/g, ' '));
1440
1459
  }
1441
1460
  }
1442
1461
  }
@@ -3784,18 +3803,7 @@ var WSAPI = /*#__PURE__*/function () {
3784
3803
  try {
3785
3804
  var _this45 = this;
3786
3805
  return Promise.resolve(OCache.use(onUpdateContextKey.AvatarsList, exports.ECacheContext.WSAPI, function () {
3787
- try {
3788
- return Promise.resolve(_this45.api.avatarsGetList(_this45.userExtId)).then(function (response) {
3789
- return (response.avatars || []).map(function (a) {
3790
- var _a$public_meta, _a$public_meta2;
3791
- return _extends({}, a, {
3792
- avatar_url: _this45.api.avatarDomain && (_a$public_meta = a.public_meta) != null && _a$public_meta.url ? a.public_meta.url.startsWith('http') ? a.public_meta.url : "" + _this45.api.avatarDomain + a.public_meta.url : ((_a$public_meta2 = a.public_meta) == null ? void 0 : _a$public_meta2.url) || ''
3793
- });
3794
- });
3795
- });
3796
- } catch (e) {
3797
- return Promise.reject(e);
3798
- }
3806
+ return _this45.api.avatarsGetListT(_this45.userExtId);
3799
3807
  }, CACHE_DATA_SEC));
3800
3808
  } catch (e) {
3801
3809
  return Promise.reject(e);
@@ -3820,13 +3828,7 @@ var WSAPI = /*#__PURE__*/function () {
3820
3828
  try {
3821
3829
  var _this46 = this;
3822
3830
  return Promise.resolve(OCache.use(onUpdateContextKey.AvatarsCustomized, exports.ECacheContext.WSAPI, function () {
3823
- try {
3824
- return Promise.resolve(_this46.api.avatarsGetCustomized(_this46.userExtId)).then(function (response) {
3825
- return response.avatars || [];
3826
- });
3827
- } catch (e) {
3828
- return Promise.reject(e);
3829
- }
3831
+ return _this46.api.avatarsGetCustomizedT(_this46.userExtId);
3830
3832
  }, CACHE_DATA_SEC));
3831
3833
  } catch (e) {
3832
3834
  return Promise.reject(e);
@@ -3851,13 +3853,7 @@ var WSAPI = /*#__PURE__*/function () {
3851
3853
  try {
3852
3854
  var _this47 = this;
3853
3855
  return Promise.resolve(OCache.use(onUpdateContextKey.AvatarPrompts, exports.ECacheContext.WSAPI, function () {
3854
- try {
3855
- return Promise.resolve(_this47.api.avatarsGetPrompts(_this47.userExtId)).then(function (response) {
3856
- return response.prompts || [];
3857
- });
3858
- } catch (e) {
3859
- return Promise.reject(e);
3860
- }
3856
+ return _this47.api.avatarsGetPromptsT(_this47.userExtId);
3861
3857
  }, CACHE_DATA_SEC));
3862
3858
  } catch (e) {
3863
3859
  return Promise.reject(e);
@@ -3865,7 +3861,7 @@ var WSAPI = /*#__PURE__*/function () {
3865
3861
  }
3866
3862
  /**
3867
3863
  * Sets the specified avatar as the active avatar for the current user.
3868
- * Pass `avatar_url` (the image path from `TAvatarDefinition.public_meta.url` or a CDN URL for AI-customized avatars)
3864
+ * Pass `avatar_url` (the `TAvatarDefinition.url` path or a CDN URL for AI-customized avatars)
3869
3865
  * and `avatar_real_id` from the avatar catalog.
3870
3866
  * After a successful call, the avatar list cache is cleared so the next `getAvatarsList()` call reflects `is_in_use`.
3871
3867
  *
@@ -3875,7 +3871,7 @@ var WSAPI = /*#__PURE__*/function () {
3875
3871
  * const avatar = avatars.find((a) => !a.hide_until_achieved || a.is_given);
3876
3872
  * if (avatar) {
3877
3873
  * _smartico.api.setAvatar({
3878
- * avatar_url: avatar.public_meta.url,
3874
+ * avatar_url: avatar.url,
3879
3875
  * avatar_real_id: avatar.avatar_real_id,
3880
3876
  * }).then((result) => {
3881
3877
  * console.log(result);
@@ -4623,6 +4619,47 @@ exports.PointChangeSourceType = void 0;
4623
4619
  PointChangeSourceType[PointChangeSourceType["Avatars"] = 22] = "Avatars";
4624
4620
  })(exports.PointChangeSourceType || (exports.PointChangeSourceType = {}));
4625
4621
 
4622
+ var avatarDefinitionTransform = function avatarDefinitionTransform(items, avatarDomain) {
4623
+ return items.map(function (item) {
4624
+ return {
4625
+ avatar_real_id: item.avatar_real_id,
4626
+ is_default: item.is_default,
4627
+ hide_until_achieved: item.hide_until_achieved,
4628
+ priority: item.priority,
4629
+ description: item.public_meta.description,
4630
+ url: item.public_meta.url,
4631
+ avatar_url: item.public_meta.url && !item.public_meta.url.startsWith('http') ? "" + avatarDomain + item.public_meta.url : item.public_meta.url,
4632
+ avatar_source_type_id: item.avatar_source_type_id,
4633
+ active_from_date: item.active_from_date,
4634
+ active_till_date: item.active_till_date,
4635
+ is_given: item.is_given,
4636
+ is_in_use: item.is_in_use
4637
+ };
4638
+ });
4639
+ };
4640
+
4641
+ var avatarCustomizedTransform = function avatarCustomizedTransform(items, avatarDomain) {
4642
+ return items.map(function (item) {
4643
+ return {
4644
+ avatar_real_id: item.avatar_real_id,
4645
+ url: item.url && !item.url.startsWith('http') ? "" + avatarDomain + item.url : item.url,
4646
+ dt_created: item.dt_created
4647
+ };
4648
+ });
4649
+ };
4650
+
4651
+ var avatarPromptTransform = function avatarPromptTransform(items, avatarDomain) {
4652
+ return items.map(function (item) {
4653
+ return {
4654
+ prompt_id: item.prompt_id,
4655
+ name: item.public_meta.name,
4656
+ icon_url: item.public_meta.icon_url && !item.public_meta.icon_url.startsWith('http') ? "" + avatarDomain + item.public_meta.icon_url : item.public_meta.icon_url,
4657
+ cost_currency_type_id: item.cost_currency_type_id,
4658
+ cost_value: item.cost_value
4659
+ };
4660
+ });
4661
+ };
4662
+
4626
4663
  /**
4627
4664
  * @ignore
4628
4665
  */
@@ -6108,25 +6145,58 @@ var SmarticoAPI = /*#__PURE__*/function () {
6108
6145
  return Promise.reject(e);
6109
6146
  }
6110
6147
  };
6148
+ _proto.avatarsGetListT = function avatarsGetListT(user_ext_id) {
6149
+ try {
6150
+ var _this80 = this;
6151
+ return Promise.resolve(_this80.avatarsGetList(user_ext_id)).then(function (_this80$avatarsGetLis) {
6152
+ var _this80$avatarsGetLis2;
6153
+ return avatarDefinitionTransform((_this80$avatarsGetLis2 = _this80$avatarsGetLis.avatars) != null ? _this80$avatarsGetLis2 : [], _this80.avatarDomain);
6154
+ });
6155
+ } catch (e) {
6156
+ return Promise.reject(e);
6157
+ }
6158
+ };
6159
+ _proto.avatarsGetCustomizedT = function avatarsGetCustomizedT(user_ext_id) {
6160
+ try {
6161
+ var _this81 = this;
6162
+ return Promise.resolve(_this81.avatarsGetCustomized(user_ext_id)).then(function (_this81$avatarsGetCus) {
6163
+ var _this81$avatarsGetCus2;
6164
+ return avatarCustomizedTransform((_this81$avatarsGetCus2 = _this81$avatarsGetCus.avatars) != null ? _this81$avatarsGetCus2 : [], _this81.avatarDomain);
6165
+ });
6166
+ } catch (e) {
6167
+ return Promise.reject(e);
6168
+ }
6169
+ };
6170
+ _proto.avatarsGetPromptsT = function avatarsGetPromptsT(user_ext_id) {
6171
+ try {
6172
+ var _this82 = this;
6173
+ return Promise.resolve(_this82.avatarsGetPrompts(user_ext_id)).then(function (_this82$avatarsGetPro) {
6174
+ var _this82$avatarsGetPro2;
6175
+ return avatarPromptTransform((_this82$avatarsGetPro2 = _this82$avatarsGetPro.prompts) != null ? _this82$avatarsGetPro2 : [], _this82.avatarDomain);
6176
+ });
6177
+ } catch (e) {
6178
+ return Promise.reject(e);
6179
+ }
6180
+ };
6111
6181
  _proto.getWSCalls = function getWSCalls() {
6112
6182
  return new WSAPI(this);
6113
6183
  };
6114
6184
  _proto.getRelatedItemsForGame = function getRelatedItemsForGame(user_ext_id, related_game_id) {
6115
6185
  try {
6116
- var _this80 = this;
6117
- var message = _this80.buildMessage(user_ext_id, exports.ClassId.GET_RELATED_ACH_N_TOURNAMENTS_REQUEST, {
6186
+ var _this83 = this;
6187
+ var message = _this83.buildMessage(user_ext_id, exports.ClassId.GET_RELATED_ACH_N_TOURNAMENTS_REQUEST, {
6118
6188
  related_game_id: related_game_id
6119
6189
  });
6120
- return Promise.resolve(_this80.send(message, exports.ClassId.GET_RELATED_ACH_N_TOURNAMENTS_RESPONSE));
6190
+ return Promise.resolve(_this83.send(message, exports.ClassId.GET_RELATED_ACH_N_TOURNAMENTS_RESPONSE));
6121
6191
  } catch (e) {
6122
6192
  return Promise.reject(e);
6123
6193
  }
6124
6194
  };
6125
6195
  _proto.getRafflesT = function getRafflesT(user_ext_id) {
6126
6196
  try {
6127
- var _this81 = this;
6128
- return Promise.resolve(_this81.getRaffles(user_ext_id)).then(function (_this81$getRaffles) {
6129
- return raffleTransform(_this81$getRaffles.items);
6197
+ var _this84 = this;
6198
+ return Promise.resolve(_this84.getRaffles(user_ext_id)).then(function (_this84$getRaffles) {
6199
+ return raffleTransform(_this84$getRaffles.items);
6130
6200
  });
6131
6201
  } catch (e) {
6132
6202
  return Promise.reject(e);
@@ -6134,18 +6204,18 @@ var SmarticoAPI = /*#__PURE__*/function () {
6134
6204
  };
6135
6205
  _proto.getRaffles = function getRaffles(user_ext_id) {
6136
6206
  try {
6137
- var _this82 = this;
6138
- var message = _this82.buildMessage(user_ext_id, exports.ClassId.RAF_GET_RAFFLES_REQUEST);
6139
- return Promise.resolve(_this82.send(message, exports.ClassId.RAF_GET_RAFFLES_RESPONSE));
6207
+ var _this85 = this;
6208
+ var message = _this85.buildMessage(user_ext_id, exports.ClassId.RAF_GET_RAFFLES_REQUEST);
6209
+ return Promise.resolve(_this85.send(message, exports.ClassId.RAF_GET_RAFFLES_RESPONSE));
6140
6210
  } catch (e) {
6141
6211
  return Promise.reject(e);
6142
6212
  }
6143
6213
  };
6144
6214
  _proto.getRaffleDrawRun = function getRaffleDrawRun(user_ext_id, payload) {
6145
6215
  try {
6146
- var _this83 = this;
6147
- var message = _this83.buildMessage(user_ext_id, exports.ClassId.RAF_GET_DRAW_RUN_REQUEST, payload);
6148
- return Promise.resolve(_this83.send(message, exports.ClassId.RAF_GET_DRAW_RUN_RESPONSE));
6216
+ var _this86 = this;
6217
+ var message = _this86.buildMessage(user_ext_id, exports.ClassId.RAF_GET_DRAW_RUN_REQUEST, payload);
6218
+ return Promise.resolve(_this86.send(message, exports.ClassId.RAF_GET_DRAW_RUN_RESPONSE));
6149
6219
  } catch (e) {
6150
6220
  return Promise.reject(e);
6151
6221
  }
@@ -6158,10 +6228,10 @@ var SmarticoAPI = /*#__PURE__*/function () {
6158
6228
  winners_to = 20;
6159
6229
  }
6160
6230
  try {
6161
- var _this84 = this;
6231
+ var _this87 = this;
6162
6232
  var winners_limit = winners_to - winners_from > 50 ? 50 : winners_to - winners_from;
6163
6233
  var winners_offset = winners_from;
6164
- return Promise.resolve(_this84.getRaffleDrawRun(user_ext_id, {
6234
+ return Promise.resolve(_this87.getRaffleDrawRun(user_ext_id, {
6165
6235
  raffle_id: raffle_id,
6166
6236
  run_id: run_id,
6167
6237
  winners_limit: winners_limit,
@@ -6173,41 +6243,41 @@ var SmarticoAPI = /*#__PURE__*/function () {
6173
6243
  };
6174
6244
  _proto.getRaffleDrawRunsHistory = function getRaffleDrawRunsHistory(user_ext_id, props) {
6175
6245
  try {
6176
- var _this85 = this;
6177
- var message = _this85.buildMessage(user_ext_id, exports.ClassId.RAF_GET_DRAW_HISTORY_REQUEST, props);
6178
- return Promise.resolve(_this85.send(message, exports.ClassId.RAF_GET_DRAW_HISTORY_RESPONSE));
6246
+ var _this88 = this;
6247
+ var message = _this88.buildMessage(user_ext_id, exports.ClassId.RAF_GET_DRAW_HISTORY_REQUEST, props);
6248
+ return Promise.resolve(_this88.send(message, exports.ClassId.RAF_GET_DRAW_HISTORY_RESPONSE));
6179
6249
  } catch (e) {
6180
6250
  return Promise.reject(e);
6181
6251
  }
6182
6252
  };
6183
6253
  _proto.claimRafflePrize = function claimRafflePrize(user_ext_id, props) {
6184
6254
  try {
6185
- var _this86 = this;
6186
- var message = _this86.buildMessage(user_ext_id, exports.ClassId.RAF_CLAIM_PRIZE_REQUEST, props);
6187
- return Promise.resolve(_this86.send(message, exports.ClassId.RAF_CLAIM_PRIZE_RESPONSE));
6255
+ var _this89 = this;
6256
+ var message = _this89.buildMessage(user_ext_id, exports.ClassId.RAF_CLAIM_PRIZE_REQUEST, props);
6257
+ return Promise.resolve(_this89.send(message, exports.ClassId.RAF_CLAIM_PRIZE_RESPONSE));
6188
6258
  } catch (e) {
6189
6259
  return Promise.reject(e);
6190
6260
  }
6191
6261
  };
6192
6262
  _proto.raffleOptin = function raffleOptin(user_ext_id, props) {
6193
6263
  try {
6194
- var _this87 = this;
6195
- var message = _this87.buildMessage(user_ext_id, exports.ClassId.RAF_OPTIN_REQUEST, props);
6196
- return Promise.resolve(_this87.send(message, exports.ClassId.RAF_OPTIN_RESPONSE));
6264
+ var _this90 = this;
6265
+ var message = _this90.buildMessage(user_ext_id, exports.ClassId.RAF_OPTIN_REQUEST, props);
6266
+ return Promise.resolve(_this90.send(message, exports.ClassId.RAF_OPTIN_RESPONSE));
6197
6267
  } catch (e) {
6198
6268
  return Promise.reject(e);
6199
6269
  }
6200
6270
  };
6201
6271
  _proto.getActivityLog = function getActivityLog(user_ext_id, startTimeSeconds, endTimeSeconds, limit, offset) {
6202
6272
  try {
6203
- var _this88 = this;
6204
- var message = _this88.buildMessage(user_ext_id, exports.ClassId.GET_POINT_HISTORY_REQUEST, {
6273
+ var _this91 = this;
6274
+ var message = _this91.buildMessage(user_ext_id, exports.ClassId.GET_POINT_HISTORY_REQUEST, {
6205
6275
  startTimeSeconds: Math.floor(startTimeSeconds),
6206
6276
  endTimeSeconds: Math.floor(endTimeSeconds),
6207
6277
  limit: limit,
6208
6278
  offset: offset
6209
6279
  });
6210
- return Promise.resolve(_this88.send(message, exports.ClassId.GET_POINT_HISTORY_RESPONSE));
6280
+ return Promise.resolve(_this91.send(message, exports.ClassId.GET_POINT_HISTORY_RESPONSE));
6211
6281
  } catch (e) {
6212
6282
  return Promise.reject(e);
6213
6283
  }
@@ -6220,11 +6290,11 @@ var SmarticoAPI = /*#__PURE__*/function () {
6220
6290
  to = 50;
6221
6291
  }
6222
6292
  try {
6223
- var _this89 = this;
6293
+ var _this92 = this;
6224
6294
  var limit = to - from > 50 ? 50 : to - from;
6225
6295
  var offset = from;
6226
- return Promise.resolve(_this89.getActivityLog(user_ext_id, startTimeSeconds, endTimeSeconds, limit, offset)).then(function (_this89$getActivityLo) {
6227
- return ActivityLogTransform(_this89$getActivityLo.logHistory);
6296
+ return Promise.resolve(_this92.getActivityLog(user_ext_id, startTimeSeconds, endTimeSeconds, limit, offset)).then(function (_this92$getActivityLo) {
6297
+ return ActivityLogTransform(_this92$getActivityLo.logHistory);
6228
6298
  });
6229
6299
  } catch (e) {
6230
6300
  return Promise.reject(e);
@@ -6738,6 +6808,9 @@ exports.TournamentUtils = TournamentUtils;
6738
6808
  exports.UICustomSectionTransform = UICustomSectionTransform;
6739
6809
  exports.UserAchievementTransform = UserAchievementTransform;
6740
6810
  exports.WSAPI = WSAPI;
6811
+ exports.avatarCustomizedTransform = avatarCustomizedTransform;
6812
+ exports.avatarDefinitionTransform = avatarDefinitionTransform;
6813
+ exports.avatarPromptTransform = avatarPromptTransform;
6741
6814
  exports.drawRunHistoryTransform = drawRunHistoryTransform;
6742
6815
  exports.drawRunTransform = drawRunTransform;
6743
6816
  exports.drawTransform = drawTransform;