@smartico/public-api 0.0.242 → 0.0.244

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.
Files changed (72) hide show
  1. package/dist/Jackpots/JackpotPublicMeta.d.ts +5 -1
  2. package/dist/Jackpots/JackpotType.d.ts +1 -1
  3. package/dist/Level/LevelPublicMeta.d.ts +5 -1
  4. package/dist/MiniGames/SAWTemplate.d.ts +1 -0
  5. package/dist/Raffle/Raffle.d.ts +5 -1
  6. package/dist/SmarticoLib/index.d.ts +5 -1
  7. package/dist/WSAPI/WSAPITypes.d.ts +5 -1
  8. package/dist/index.js +5 -2
  9. package/dist/index.js.map +1 -1
  10. package/dist/index.modern.mjs +5 -2
  11. package/dist/index.modern.mjs.map +1 -1
  12. package/docs/enums/JackpotType.md +2 -2
  13. package/docs/interfaces/JackpotPublicMeta.md +3 -1
  14. package/docs/interfaces/TLevel.md +3 -1
  15. package/package.json +1 -1
  16. package/src/IntUtils.ts +1 -1
  17. package/src/Jackpots/JackpotPublicMeta.ts +5 -1
  18. package/src/Jackpots/JackpotType.ts +1 -1
  19. package/src/Level/LevelPublicMeta.ts +5 -1
  20. package/src/MiniGames/SAWTemplate.ts +1 -0
  21. package/src/Raffle/Raffle.ts +5 -1
  22. package/src/SmarticoLib/index.ts +5 -1
  23. package/src/WSAPI/WSAPI.ts +5 -0
  24. package/src/WSAPI/WSAPITypes.ts +5 -1
  25. package/dist/Quiz/MarketsAnswersType.d.ts +0 -22
  26. package/dist/Raffle/GetDrawResponse.d.ts +0 -5
  27. package/dist/SmarticoPublicAPI.d.ts +0 -23
  28. package/dist/Store/BuyShopItemErrorCode.d.ts +0 -10
  29. package/dist/Store/BuyShopItemRequest.d.ts +0 -4
  30. package/dist/Store/BuyShopItemResponse.d.ts +0 -4
  31. package/dist/Store/GetCategoriesShopResponse.d.ts +0 -5
  32. package/dist/Store/GetShopItemsResponse.d.ts +0 -5
  33. package/dist/Store/ShopCategory.d.ts +0 -5
  34. package/dist/Store/ShopCategoryPublicMeta.d.ts +0 -4
  35. package/dist/Store/ShopItem.d.ts +0 -9
  36. package/dist/Store/ShopItemPublicMeta.d.ts +0 -10
  37. package/dist/Store/ShopItemType.d.ts +0 -4
  38. package/dist/Store/StorItemPruchased.d.ts +0 -6
  39. package/dist/service/index.d.ts +0 -5
  40. package/dist/service/types/ErrorCodes.d.ts +0 -13
  41. package/dist/service/types/GRequest.d.ts +0 -16
  42. package/dist/service/types/GResponse.d.ts +0 -10
  43. package/dist/service/types/Game/GameAttemptType.d.ts +0 -6
  44. package/dist/service/types/Game/GameCanPlayType.d.ts +0 -10
  45. package/dist/service/types/Game/GameExternalStatus.d.ts +0 -6
  46. package/dist/service/types/Game/GameInfo.d.ts +0 -9
  47. package/dist/service/types/Game/GamePick.d.ts +0 -90
  48. package/dist/service/types/Game/GameUtil.d.ts +0 -7
  49. package/dist/service/types/SmarticoProto/GetTranslationsRequest.d.ts +0 -7
  50. package/dist/service/types/SmarticoProto/GetTranslationsResponse.d.ts +0 -7
  51. package/dist/service/types/SmarticoProto/ProtocolMessage.d.ts +0 -5
  52. package/dist/service/types/SmarticoProto/ProtocolRequest.d.ts +0 -6
  53. package/dist/service/types/SmarticoProto/ProtocolResponse.d.ts +0 -5
  54. package/dist/service/types/SmarticoProto/PublicLabelInfo.d.ts +0 -34
  55. package/dist/service/types/SmarticoProto/PublicProperties.d.ts +0 -11
  56. package/dist/service/types/SmarticoProto/ResponseIdentify.d.ts +0 -12
  57. package/dist/service/types/SmarticoProto/SAW/SAWAcknowledgeType.d.ts +0 -5
  58. package/dist/service/types/SmarticoProto/SAW/SAWBuyInType.d.ts +0 -5
  59. package/dist/service/types/SmarticoProto/SAW/SAWDoSpinRequest.d.ts +0 -5
  60. package/dist/service/types/SmarticoProto/SAW/SAWDoSpinResponse.d.ts +0 -15
  61. package/dist/service/types/SmarticoProto/SAW/SAWGameType.d.ts +0 -10
  62. package/dist/service/types/SmarticoProto/SAW/SAWGetTemplatesRequest.d.ts +0 -3
  63. package/dist/service/types/SmarticoProto/SAW/SAWGetTemplatesResponse.d.ts +0 -5
  64. package/dist/service/types/SmarticoProto/SAW/SAWPrize.d.ts +0 -11
  65. package/dist/service/types/SmarticoProto/SAW/SAWPrizeType.d.ts +0 -8
  66. package/dist/service/types/SmarticoProto/SAW/SAWPrizeUI.d.ts +0 -13
  67. package/dist/service/types/SmarticoProto/SAW/SAWTemplate.d.ts +0 -21
  68. package/dist/service/types/SmarticoProto/SAW/SAWTemplateUI.d.ts +0 -31
  69. package/dist/service/types/SmarticoProto/SAW/SAWWinSoundType.d.ts +0 -12
  70. package/dist/service/types/SmarticoProto/TranslationArea.d.ts +0 -9
  71. package/dist/service/types/User/UserInfo.d.ts +0 -10
  72. package/dist/util/Util.d.ts +0 -51
@@ -14,7 +14,11 @@ interface JackpotPublicMeta {
14
14
  placeholder1: string;
15
15
  /** custom value of placeholder2 defined by operator and can be used in the HTML templates */
16
16
  placeholder2: string;
17
- /** custom data as string or JSON string that can be used in UIWidget */
17
+ /**
18
+ * Custom data as string or JSON string that can be used in API to build custom UI
19
+ * You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
20
+ * Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
21
+ */
18
22
  custom_data: string;
19
23
  }
20
24
  export { JackpotPublicMeta };
@@ -1,5 +1,5 @@
1
1
  declare enum JackpotType {
2
- Main = 1,
2
+ MultiUser = 1,
3
3
  Personal = 2
4
4
  }
5
5
  export { JackpotType };
@@ -14,6 +14,10 @@ export interface LevelPublicMeta {
14
14
  dx: number;
15
15
  dy: number;
16
16
  };
17
- /**custom data as string or JSON string that can be used in UIWidget */
17
+ /**
18
+ * Custom data as string or JSON string that can be used in API to build custom UI
19
+ * You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
20
+ * Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
21
+ */
18
22
  custom_data: string;
19
23
  }
@@ -25,6 +25,7 @@ export interface SAWTemplate {
25
25
  saw_skin_ui_definition: {
26
26
  skin_folder: string;
27
27
  skin_css: string;
28
+ use_new_popups?: boolean;
28
29
  };
29
30
  expose_game_stat_on_api?: boolean;
30
31
  requires_prize_claim?: boolean;
@@ -8,7 +8,11 @@ interface RafflePublicMeta {
8
8
  custom_section_id: number;
9
9
  /** URL of the image that represents the raffle */
10
10
  image_url: string;
11
- /** Custom data as string or JSON string that can be used in UIWidget */
11
+ /**
12
+ * Custom data as string or JSON string that can be used in API to build custom UI
13
+ * You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
14
+ * Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
15
+ */
12
16
  custom_data: string;
13
17
  }
14
18
  interface Raffle {
@@ -836,7 +836,11 @@ export interface TLevel {
836
836
  *
837
837
  */
838
838
  required_level_counter_2: number;
839
- /** The custom data of the Level defined by operator in the BackOffice. Can be a JSON object, string or number */
839
+ /**
840
+ * Custom data as string or JSON string that can be used in API to build custom UI
841
+ * You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
842
+ * Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
843
+ */
840
844
  custom_data: string;
841
845
  }
842
846
  /**
@@ -220,7 +220,11 @@ export interface TLevel {
220
220
  *
221
221
  */
222
222
  required_level_counter_2: number;
223
- /** The custom data of the Level defined by operator in the BackOffice. Can be a JSON object, string or number */
223
+ /**
224
+ * Custom data as string or JSON string that can be used in API to build custom UI
225
+ * You can request from Smartico to define fields for your specific case that will be managed from Smartico BackOffice
226
+ * Read more here - https://help.smartico.ai/welcome/products/general-concepts/custom-fields-attributes
227
+ */
224
228
  custom_data: string;
225
229
  }
226
230
  /**
package/dist/index.js CHANGED
@@ -232,7 +232,7 @@ IntUtils.JsonOrText = function (str) {
232
232
  return str;
233
233
  }
234
234
  }
235
- return str;
235
+ return str || {};
236
236
  };
237
237
  // public static wsTimeToEpoch = (time: string): number => {
238
238
  // if (time) {
@@ -2622,6 +2622,9 @@ var WSAPI = /*#__PURE__*/function () {
2622
2622
  var _pots = _jackpots.items.map(function (jp) {
2623
2623
  return jp.pot;
2624
2624
  });
2625
+ _jackpots.items.forEach(function (jp) {
2626
+ jp.jp_public_meta.custom_data = IntUtils.JsonOrText(jp.jp_public_meta.custom_data);
2627
+ });
2625
2628
  OCache.set(onUpdateContextKey.Pots, _pots, exports.ECacheContext.WSAPI, JACKPOT_POT_CACHE_SEC);
2626
2629
  return _jackpots.items;
2627
2630
  });
@@ -4417,7 +4420,7 @@ var JackPotTemparature;
4417
4420
 
4418
4421
  exports.JackpotType = void 0;
4419
4422
  (function (JackpotType) {
4420
- JackpotType[JackpotType["Main"] = 1] = "Main";
4423
+ JackpotType[JackpotType["MultiUser"] = 1] = "MultiUser";
4421
4424
  JackpotType[JackpotType["Personal"] = 2] = "Personal";
4422
4425
  })(exports.JackpotType || (exports.JackpotType = {}));
4423
4426