@smartico/public-api 0.0.427 → 0.0.429

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.
@@ -1169,7 +1169,7 @@ const StoreItemPurchasedTransform = items => {
1169
1169
  purchased_today: purchasedToday,
1170
1170
  purchased_this_week: purchasedThisWeek,
1171
1171
  purchased_this_month: purchasedThisMonth,
1172
- custom_data: r.itemPublicMeta.custom_data,
1172
+ custom_data: IntUtils.JsonOrText(r.itemPublicMeta.custom_data),
1173
1173
  show_timer: r.itemPublicMeta.show_timer,
1174
1174
  related_games: (((_r$relatedGames = r.relatedGames) == null ? void 0 : _r$relatedGames.filter(g => g.game_public_meta.enabled)) || []).map((g, i) => ({
1175
1175
  ext_game_id: g.ext_game_id,
@@ -10711,12 +10711,16 @@ class SmarticoAPI {
10711
10711
  return await this.send(message, ClassId.MARK_INBOX_DELETED_RESPONSE);
10712
10712
  }
10713
10713
  buildGamesApiParams() {
10714
- var _this$tracker$userPub2, _this$tracker$userPub3;
10714
+ var _this$tracker$userPub2, _this$tracker$userPub3, _this$tracker$getHash, _this$tracker;
10715
10715
  const params = Object.assign({}, this.baseRgApiParams, {
10716
10716
  ext_user_id: (_this$tracker$userPub2 = this.tracker.userPublicProps) == null ? void 0 : _this$tracker$userPub2.user_id,
10717
10717
  smartico_ext_user_id: this.tracker.getExtUserId(),
10718
10718
  lang: (_this$tracker$userPub3 = this.tracker.userPublicProps) == null ? void 0 : _this$tracker$userPub3.core_user_language
10719
10719
  });
10720
+ const user_hash = (_this$tracker$getHash = (_this$tracker = this.tracker).getHash) == null ? void 0 : _this$tracker$getHash.call(_this$tracker);
10721
+ if (user_hash) {
10722
+ params.user_hash = user_hash;
10723
+ }
10720
10724
  return params;
10721
10725
  }
10722
10726
  async sendGamesApi({
@@ -10896,15 +10900,15 @@ class SmarticoAPI {
10896
10900
  return await this.send(message, ClassId.CLIENT_SET_AVATAR_RESPONSE);
10897
10901
  }
10898
10902
  async avatarsCustomize(params) {
10899
- var _this$tracker, _this$tracker2;
10903
+ var _this$tracker2, _this$tracker3;
10900
10904
  return this.sendAvatarApi({
10901
10905
  method: 'avatar-customize',
10902
10906
  body: {
10903
10907
  // The server resolves label_id from label_api_key.
10904
10908
  label_api_key: this.label_api_key,
10905
10909
  user_id: params.user_id,
10906
- user_ext_id: (_this$tracker = this.tracker) == null ? void 0 : _this$tracker.getExtUserId(),
10907
- brand_key: this.brand_api_key || ((_this$tracker2 = this.tracker) == null || (_this$tracker2 = _this$tracker2.params) == null ? void 0 : _this$tracker2.brand_key),
10910
+ user_ext_id: (_this$tracker2 = this.tracker) == null ? void 0 : _this$tracker2.getExtUserId(),
10911
+ brand_key: this.brand_api_key || ((_this$tracker3 = this.tracker) == null || (_this$tracker3 = _this$tracker3.params) == null ? void 0 : _this$tracker3.brand_key),
10908
10912
  prompt_id: params.prompt_id,
10909
10913
  avatar_url: params.avatar_url,
10910
10914
  avatar_real_id: params.avatar_real_id