@smartico/public-api 0.0.410 → 0.0.411

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.
@@ -23,39 +23,41 @@ type TRibbon = 'sale' | 'hot' | 'new' | 'vip' | string;
23
23
  export interface TMiniGamePrize {
24
24
  /** ID of the prize */
25
25
  id: number;
26
- /** The visual name of the prize */
26
+ /** Display name of the prize, pre-translated; any jackpot placeholder in it arrives resolved to the live jackpot value */
27
27
  name: string;
28
- /** The type of the prize, no-prize, points, bonus, manual, spin, jackpot */
28
+ /** The type of the prize — see {@link MiniGamePrizeTypeName} ('no-prize', 'points', 'gems-and-diamonds', 'spin', 'bonus', 'jackpot', 'raffle-ticket', 'mission', 'change-level', 'manual') */
29
29
  prize_type: MiniGamePrizeTypeName;
30
- /** Numeric value of the prize in case it's 'points' or 'spin' type. For other types of prizes this value is not relevant.
30
+ /** Numeric value of the prize in case it's 'points' or 'spin' type. For other types of prizes this value is not relevant.
31
31
  * For example for prize '100 points' the prize_value will be 100. For '100 free spins' the prize_value will be 100.
32
32
  */
33
33
  prize_value?: number;
34
- /** Custom font size for the prize (desktop) */
34
+ /** Custom font size in px for rendering the prize name on the game surface (e.g. a wheel sector), desktop */
35
35
  font_size?: number;
36
- /** Custom font size for the prize (mobile) */
36
+ /** Custom font size in px for the prize name, mobile; falls back to `font_size` when absent */
37
37
  font_size_mobile?: number;
38
38
  /** The URL of the icon of the prize, aspect ratio 1:1 */
39
39
  icon?: string;
40
- /** for scratch card defines position of prize in the list */
40
+ /** For Scratch Card games — relative order of the prize in the scratch grid (lower first). May be absent for other game types */
41
41
  position: number;
42
- /** List of sectors for the prize */
42
+ /** For Spin-a-Wheel games — wheel sector indices this prize occupies. Absent for non-wheel games */
43
43
  sectors: number[];
44
- /** Type of acknowledge message for users */
44
+ /** Which win modal the prize uses — see {@link SAWAcknowledgeTypeName} (Silent / QuickMessage / FullMessage / ExplicitAcknowledge) */
45
45
  acknowledge_type: SAWAcknowledgeTypeName;
46
46
  /** Message that will be shown to user in modal pop-up */
47
47
  aknowledge_message: string;
48
- /** Deep link that will trigger some action in modal pop-up */
48
+ /** Message shown instead of `aknowledge_message` when the spin is finalised as lost (`lose: true` acknowledge flows — games with a client-decided outcome, e.g. Voyager). Absent unless configured */
49
+ aknowledge_message_lose?: string;
50
+ /** Deep link executed when the user taps the main action button in the win modal (run it via `_smartico.dp()`) */
49
51
  acknowledge_dp: string;
50
- /** The name of the action button in modal pop-up */
52
+ /** Label of the main action button in the win modal */
51
53
  acknowledge_action_title: string;
52
- /** Deep link that will trigger some action in modal pop-up (additional) */
54
+ /** Deep link of the additional action button in the win modal */
53
55
  acknowledge_dp_additional?: string;
54
- /** The name of the action button in modal pop-up (additional) */
56
+ /** Label of the additional action button in the win modal */
55
57
  acknowledge_action_title_additional?: string;
56
- /** Deep link that will trigger some action in modal pop-up (second button) */
58
+ /** Deep link of the secondary button in the win modal */
57
59
  second_btn?: string,
58
- /** The name of the action button in modal pop-up (second button) */
60
+ /** Label of the secondary button in the win modal */
59
61
  second_btn_action_title?: string;
60
62
  /** Message when the prize pool is empty for that specific prize */
61
63
  out_of_stock_message?: string;
@@ -77,17 +79,17 @@ export interface TMiniGamePrize {
77
79
  is_surcharge?: boolean;
78
80
  /** Always `false` in API responses — deleted prizes are excluded server-side */
79
81
  is_deleted?: boolean;
80
- /** The custom data of the mini-game defined by operator in the BackOffice. Can be a JSON object, string or number */
82
+ /** The custom data of the prize defined by the operator. Can be a JSON object, string or number */
81
83
  custom_data?: any;
82
- /** Prize modifiers that will multiply by 2x, 5x or 10x the current total. This will not affect the final Prize Amount that will be awarded. */
84
+ /** Step-modifier tiles for step games (Treasure Hunt / Voyager) — see {@link PrizeModifiers} (2x / 5x / 10x, /2 / /5 / /10, 0, reset) applied to the running total revealed during the game. Presentation only — the awarded amount is still `prize_value` */
83
85
  prize_modifiers?: PrizeModifiers[];
84
- /** When enabled, you can split prize value by decimal values */
86
+ /** Step games (Treasure Hunt / Voyager): when true, the per-step revealed amounts of the prize value may be fractional; when false the split uses whole numbers */
85
87
  allow_split_decimal?: boolean;
86
- /** When enabled, you can hide prize from prize history */
88
+ /** Operator hint to hide this prize when rendering prize-history UIs. Informational only — API responses are not filtered by it */
87
89
  hide_prize_from_history?: boolean;
88
- /** Requirements to claim the prize (lootbox specific)*/
90
+ /** Operator text describing what the user must do to be eligible for this prize (lootbox games); shown when the prize is not yet available to the user */
89
91
  requirements_to_get_prize?: string;
90
- /** The period type for the prize to be given: Time from last attempt, Calendar days UTC, Calendar days user time zone, Lifetime */
92
+ /** Period basis for the prize availability restriction — see {@link AttemptPeriodType}. `CalendarDaysUserTimeZone` evaluates `weekdays` / the active window in the user's timezone; the other types use `relative_period_timezone` */
91
93
  max_give_period_type_id?: AttemptPeriodType;
92
94
  }
93
95
 
@@ -167,11 +169,10 @@ export interface TMiniGameTemplate {
167
169
  /** in case of charging type 'Spin attempts', shows the current number of spin attempts that user has */
168
170
  spin_count?: number;
169
171
 
170
- /**
171
- * if the game is limit to the number of spins that user can do during period of time,
172
- * this property shows the epoch time in UTC when the next attempt will be available.
173
- * Note that you need to enable 'Show time to the next available spin' setting on mini-game template in the backoffice
174
- * Important: this field will not be populated if “Max number of attempts a user can do” is set to value different from 1
172
+ /**
173
+ * If the game limits the number of attempts per period of time, the epoch-ms time (UTC) when the next attempt becomes available.
174
+ * Populated only when the operator enabled the "show time to the next available spin" template setting, and only when the
175
+ * template's maximum attempts per period is 1.
175
176
  * */
176
177
  next_available_spin_ts: number;
177
178
 
@@ -190,7 +191,7 @@ export interface TMiniGameTemplate {
190
191
  /** The message that should be shown to the user when he cannot play the game because he doesn't have spin attempts or points. */
191
192
  no_attempts_message: string;
192
193
 
193
- /** Current jackpont amount, if jackpot is enabled. */
194
+ /** Current jackpot amount, if jackpot is enabled. */
194
195
  jackpot_current: number;
195
196
  /** The amount that will be added to the jackpot every time when somebody plays the game. Note that the contribution amount is abstract, means that no money or points are deducted from the user balance. */
196
197
  jackpot_add_on_attempt: number;
@@ -205,28 +206,28 @@ export interface TMiniGameTemplate {
205
206
  /** The custom data of the mini-game defined by operator in the BackOffice. Can be a JSON object, string or number */
206
207
  custom_data: any;
207
208
 
208
- /** List of prizes for mini-games */
209
+ /** Prizes configured for this game — see {@link TMiniGamePrize} */
209
210
  prizes: TMiniGamePrize[];
210
211
 
211
212
  /** Operator template setting. When enabled, the per-prize stock statistics (`pool`, `wins_count`, `weekdays`, `active_from_ts` / `active_till_ts`) are populated on `prizes` and kept current after every play; when disabled (default) those fields are omitted. See `getMiniGames` "Per-prize statistics" */
212
213
  expose_game_stat_on_api?: boolean;
213
214
 
214
- /** Time zone to ensure each day aligns with your local midnight. */
215
+ /** Timezone offset in minutes used to evaluate the template's period-based rules (UTC minus local, as in JS `Date.getTimezoneOffset()` — e.g. `-180` for UTC+3) */
215
216
  relative_period_timezone?: number;
216
- /** Holds time from which template will become available, for the template that are targeted to be available from specific time (UNIX timestamp) */
217
+ /** Time from which the template becomes available (epoch ms); absent when not restricted */
217
218
  activeFromDate?: number;
218
- /** Holds time till which template will become available, for the templates that are targeted to be available from specific time (UNIX timestamp) */
219
+ /** Time until which the template stays available (epoch ms); absent when not restricted */
219
220
  activeTillDate?: number;
220
- /** The amount of steps to complete the game and gather the prize */
221
+ /** Number of steps to complete the game and collect the prize (step games — Voyager / Treasure Hunt) */
221
222
  steps_to_finish_game?: number;
222
223
  /** ID of the operator-defined custom section (widget menu grouping) the mini-game is assigned to */
223
224
  custom_section_id?: number;
224
225
 
225
- /** The UI definition of the mini-game */
226
+ /** Full raw UI definition of the mini-game (skin, colors, per-game visual settings) — see {@link SAWTemplateUI}. The commonly needed values are already lifted onto this template object */
226
227
  saw_template_ui_definition: SAWTemplateUI;
227
- /** The layout of the game */
228
+ /** Grid layout of the game. Populated only for Lootbox game types (LootboxWeekdays / LootboxCalendarDays) */
228
229
  game_layout?: SAWGameLayoutName;
229
- /** When enabled the prize history icon is visible on a certain template */
230
+ /** Operator setting: show a prize-history entry point (icon / button) on this game's view */
230
231
  show_prize_history?: boolean;
231
232
  /** The maximum number of attempts that user can do during period of time */
232
233
  max_number_of_attempts?: number;