SDK methods

Item 1.19 of the Game Requirements

The initialization of the Yandex Games SDK and the use of its methods are carried out in strict accordance with the documentation and game requirements:

  1. The SDK is initialized exactly as described on the Connection and usage page.

  2. At the moment when the user can start playing the game, the LoadingAPI.ready() method from Game Ready must be called.

  3. The use of gameplay markup is optional; however, if the GameplayAPI.start() and GameplayAPI.stop() methods are used in the game, the timing of event dispatches must strictly correspond to those described in section Gameplay.

  4. Tracking game_api_pause and game_api_resume events is optional. However, if ysdk.on() and ysdk.off() methods are used in the game, the event handling logic must strictly follow the description in section Pause and Resume Events.

SDK Initialization

1.19.1. The SDK is initialized exactly as specified on the Connection and usage page. For the requirement to be considered fulfilled, the current loader must be used.

Loader Version Check

  1. Start the game with the debug panel.

    1. Open the Yandex Games console.
    2. Select the game you need.
    3. In the top left corner, click on Open with debug panel.
    1. Open the required game.

    2. Add &debug-mode=16 to the end of the browser's address bar.

      Example link: https://yandex.com/games/app/XXXX?debug-mode=16, where XXXX is the unique game ID.

  2. On the debug panel to the left of the Game Ready indicator, find two letters:

    • IF (init false) — the game supports the old loader. Hovering over IF will display Is loader: false.

    • IT (init true) — the game supports the new loader. Hovering over IT will display Is loader: true.

Examples

Loader

Comment

Game screenshot: the debug panel shows IF, and the tooltip below reads: "SDK was initialized Version: v2. Is loader: false."

Old loader. Displayed on the debug panel IF.

Game screenshot: the debug panel shows IF, and the tooltip below reads: "SDK was initialized Version: v2. Is loader: false."

Old loader. Displayed on the debug panel IF.

Game screenshot: the debug panel shows IT, and the tooltip below reads: "SDK was initialized Version: v2. Is loader: true."

New loader. Displayed on the debug panel IT.

Game screenshot: the debug panel shows IT, and the tooltip below reads: "SDK was initialized Version: v2. Is loader: true."

New loader. Displayed on the debug panel IT.

Game Ready

1.19.2. When the user is ready to start the game, call the LoadingAPI.ready() method from Game Ready.

To fulfill the requirement, the LoadingAPI.ready() method must be called at the correct moment.

Loading screen

During the game's loading, the Yandex Games platform first shows its own loading screen — a pulsing game icon with the "Loading" caption. It can be dismissed manually by tapping the screen.

What the Yandex Games loading screen looks like

Yandex Games loading screen: a pulsing game icon with the "Loading" caption

Moderation checks the game's own loading screen. If it contains prohibited content — third-party links, unauthorized logos, elements that infringe copyright — this will be grounds for rejection.

Preparation

  1. Start the game with the debug panel.

    1. Open the Yandex Games console.
    2. Select the game you need.
    3. In the top left corner, click on Open with debug panel.
    1. Open the required game.

    2. Add &debug-mode=16 to the end of the browser's address bar.

      Example link: https://yandex.com/games/app/XXXX?debug-mode=16, where XXXX is the unique game ID.

  2. On the debug panel, find the Game Ready indicator .

Game Ready check logic

  1. Verify that the purple indicator changes to green within 90 seconds.
  2. Reload the game.
  3. Recheck at what moment the indicator changes color.

Scenarios that moderation considers during the check:

Scenario

Example

The Yandex Games loading screen is dismissed manually — tap the screen to dismiss it, then check when the indicator changes.

Game loading video: the Yandex Games loading screen is dismissed by tapping, then the game's own loading screen is shown, after which the game becomes available for interaction.

The Yandex Games loading screen disappears automatically — wait for the screen to hide itself, then check when the indicator changes.

Game loading video: the Yandex Games loading screen disappears automatically, then the game's own loading screen is briefly shown, after which the game becomes available for interaction.

Note

Game Ready must work correctly in both scenarios. If the LoadingAPI.ready() call is tied to a specific point in time rather than the game's actual readiness, this will be noticeable when the Yandex Games loading screen is manually dismissed, and moderation will flag this as a violation.

Game Ready works correctly

The purple indicator changes to green at the moment:

  • when the menu is available;
  • when the game is playable (including the initial animation).

Game Ready

Comment

Game loading video: the debug panel indicator blinks blue during loading; when the menu appears, the indicator turns green.

The green indicator appears at the moment when the menu becomes available.

Game loading video: the debug panel indicator blinks blue during loading; when the menu appears, the indicator turns green.

The green indicator appears at the moment when the menu becomes available.

Game loading video: the debug panel indicator blinks blue during loading; when the menu appears, the indicator turns green.

The green indicator appears at the moment when the menu becomes available.

Game loading video: the debug panel indicator blinks blue during loading; when the game becomes available for interaction, the indicator turns green.

The green indicator appears at the moment when the game is available for interaction.

Game loading video: the debug panel indicator blinks blue during loading; when the game becomes available for interaction, the indicator turns green.

The green indicator appears at the moment when the game is available for interaction.

Game loading video: the debug panel indicator blinks blue during loading; when the game becomes available for interaction, the indicator turns green.

The green indicator appears at the moment when the game is available for interaction.

Game Ready is not working correctly

The purple indicator changed to green :

  • before the game became available for interaction (there are progress bars, spinners, black screen, etc.);
  • a few seconds after the game became available for interaction.

Game Ready

Comment

Game loading video: during loading, the debug panel indicator is green even though the game cannot yet be interacted with.

The green indicator appears before the game becomes available for interaction.

Game loading video: during loading, the debug panel indicator first blinks blue, then turns green even though the game cannot yet be interacted with.

The green indicator appears before the game becomes available for interaction.

Game loading video: during loading and the ad, the debug panel indicator is green even though the game cannot yet be interacted with.

The green indicator appears before the game becomes available for interaction.

Gameplay video: the game is already available for interaction, but the debug panel indicator continues to blink blue for a few more seconds.

The green indicator appeared only a few seconds after the game became available for interaction.

Gameplay video: the game is already available for interaction, but the debug panel indicator continues to blink blue for a few more seconds.

The green indicator appeared only a few seconds after the game became available for interaction.

Game Ready is not integrated

The indicator turned red after 90 seconds.

Game Ready

Comment

Quiz game video: while the game is in progress, the debug panel indicator blinks blue, then turns red.

The indicator turned red — Game Ready is not integrated.

Gameplay Markup

1.19.3. The methods GameplayAPI.start() and GameplayAPI.stop() allow marking the start and stop of the gameplay. If they are used in the game, then the moments of event sending strictly correspond to the descriptions in the section Gameplay.

Preparation

  1. Start the game with the debug panel.

    1. Open the Yandex Games console.
    2. Select the game you need.
    3. In the top left corner, click on Open with debug panel.
    1. Open the required game.

    2. Add &debug-mode=16 to the end of the browser's address bar.

      Example link: https://yandex.com/games/app/XXXX?debug-mode=16, where XXXX is the unique game ID.

  2. On the debug panel, find the gamepad button 🎮.

Checking gameplay markup

Track the status of the gameplay indicator depending on actions:

  • When a player starts the gameplay or resumes it after a pause, the method GameplayAPI.start() must be called. The gameplay indicator should turn green — gameplay is in progress.

  • When a player finishes the gameplay or pauses it, the method GameplayAPI.stop() must be called. The gameplay indicator should turn red — gameplay is paused.

Scenarios that moderation considers during the check:

  • Starting and finishing a level.
  • Opening and closing the game menu.
  • Opening and closing the purchase menu.
  • Starting and closing advertisements.
  • Losing focus on the game and returning to it (switching to another browser tab or a different window).

Tip

To find out where the focus is (on the game or on another window), track the events game_api_resume and game_api_pause.

Gameplay correctly marked

The indicator color changes depending on the scenario.

Game

Comment

Level selection and start video: when the level appears, the gameplay indicator (gamepad icon) turns green.

At the start of a new level, the indicator is green.

Gameplay video: when the level is completed, the gameplay indicator (gamepad icon) changes from green to red.

Level completed, the indicator turns red.

Gameplay video: during a level, the gameplay indicator (gamepad icon) is green; when the menu opens, it turns red; after closing the menu, it turns green again.

When navigating to the menu and then returning to the gameplay, the indicator changes.

Gameplay video: during a level, the gameplay indicator (gamepad icon) is green; when the menu opens, it turns red; after closing the menu, it turns green again.

When navigating to the menu and then returning to the gameplay, the indicator changes.

Gameplay video: when navigating from the game to the in-app purchase store, the gameplay indicator (gamepad icon) changes from green to red. When returning to the game, the indicator turns green.

When navigating to the purchase menu and then returning to the gameplay, the indicator changes.

Gameplay video: when an ad starts, the gameplay indicator (gamepad icon) changes from green to red. When returning to the game, the indicator turns green.

The ad is closed, the indicator color changes from red to green.

Gameplay video: during the game, the gameplay indicator (gamepad icon) is green. When another application (File Explorer) is opened, the indicator turns red. After switching back to the browser tab with the game, the indicator turns green.

When shifting focus from the browser tab to another window and then returning to the gameplay, the indicator color changes.

Gameplay marked incorrectly

The indicator color does not change depending on the scenario.

Game

Comment

Gameplay video: after the level ends, the gameplay indicator (gamepad icon) is still green.

Level completed, the indicator color did not change from green to red.

Gameplay video: after the menu opens, the gameplay indicator (gamepad icon) is still green.

When navigating to the menu, the indicator color did not change from green to red.

Gameplay video: when an ad starts, the gameplay indicator (gamepad icon) changes from green to red. After returning to the game, the indicator remains red.

The ad is closed, the indicator color did not change from red to green.

Gameplay video: during the game, the gameplay indicator (gamepad icon) is green. When another application (File Explorer) is opened, the indicator remains green.

When shifting focus from the browser tab to another window, the indicator color does not change.

Contact Moderation

If you believe you are using the SDK methods correctly and your game was incorrectly unpublished or denied, please fill out the form below.

The quality control service of moderation will recheck the decision and return the game if it was unfairly blocked.

Open the form