@smartico/public-api 0.0.421 → 0.0.424

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@smartico/public-api",
3
- "version": "0.0.421",
3
+ "version": "0.0.424",
4
4
  "description": "Smartico public API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -47,6 +47,7 @@ export const SAWTemplatesTransform = (items: SAWTemplate[]): TMiniGameTemplate[]
47
47
  earliest_expiration_dt: r.earliest_expiration_dt,
48
48
  latest_expiration_dt: r.latest_expiration_dt,
49
49
  steps_to_finish_game: r.saw_template_ui_definition.steps_to_finish_game,
50
+ min_steps_to_finish_game: r.saw_template_ui_definition.min_steps_to_finish_game,
50
51
  custom_section_id: r.saw_template_ui_definition.custom_section_id,
51
52
  saw_template_ui_definition: r.saw_template_ui_definition,
52
53
  ...(r.saw_game_type_id === SAWGameType.LootboxCalendarDays || r.saw_game_type_id === SAWGameType.LootboxWeekdays
@@ -469,6 +469,23 @@ export interface SAWTemplateUI {
469
469
  */
470
470
  custom_game_url?: string;
471
471
 
472
+ /**
473
+ * Whether this template is played as a custom mini-game.
474
+ *
475
+ * A template of any regular game type (wheel, scratch card, treasure hunt,
476
+ * …) can be switched over to a custom game while keeping its own type,
477
+ * prizes and buy-in settings — only the way it is played changes: the
478
+ * widget loads `custom_game_url` in an iframe instead of rendering the
479
+ * built-in game. `saw_game_type_id` still reports the original type, so
480
+ * treat this flag — not the type — as the answer to "is this played as a
481
+ * custom game", together with `SAWGameType.CustomMinigame`, which is always
482
+ * played that way.
483
+ *
484
+ * When `false` or omitted, the template is played as its own game type.
485
+ * Back-Office label: _"Use Custom Game"_.
486
+ */
487
+ use_custom?: boolean;
488
+
472
489
  /**
473
490
  * Minutes for the Voyager seed window.
474
491
  * The seed window is the range of seeds that can be used to generate the map.
@@ -222,6 +222,8 @@ export interface TMiniGameTemplate {
222
222
  activeTillDate?: number;
223
223
  /** Number of steps to complete the game and collect the prize (step games — Voyager / Treasure Hunt) */
224
224
  steps_to_finish_game?: number;
225
+ /** Minimum number of path steps / collectible prizes a session must include before the game can finish (step games — Voyager / Treasure Hunt). `>= 1` and `<= steps_to_finish_game`; when omitted, no minimum is enforced */
226
+ min_steps_to_finish_game?: number;
225
227
  /** ID of the operator-defined custom section (widget menu grouping) the mini-game is assigned to */
226
228
  custom_section_id?: number;
227
229