SDK
Analytics events
Smaz Games measures plays of every game and shows the totals on your dashboard. With the SDK you can add your own gameplay events. Games must not include analytics or tracking scripts of their own, including Google Analytics (gtag.js) and Google Tag Manager.
What the site measures for you
Open Stats on a game in the developer dashboard. Figures are totals for your own games only, over 7, 30 or 90 days, and refresh every few minutes.
| Figure | How it is counted |
|---|---|
| Page views | Visits to the game page |
| Plays | Each time the game is started in the player |
| Players | Distinct browsers, not verified people |
| Play time | Seconds while the game is visible, not paused, in a supported orientation and, for SDK games, between gameplayStart and gameplayStop |
| Gameplay starts | Plays where the SDK reported gameplayStart |
| Devices | Desktop or mobile, from the player's pointer type |
| Countries | From the network request. IP addresses are not stored |
| Session lengths | Plays grouped by length: under 1, 1–5, 5–15, 15–30 and over 30 minutes |
| New and returning players | Whether the browser had played the game before |
| Day 1 and day 7 return | Share of new players who came back one and seven days later |
You never receive player names, emails or individual play records.
Custom events
OpenArcade.track('level_complete', { level: 3, seconds: 74, stars: 2 });
OpenArcade.track('tutorial_skipped');
OpenArcade.track('shop_opened', { from: 'pause_menu' });| Rule | Limit |
|---|---|
| Event name | 1 to 40 characters: lowercase letters, numbers, _, starting with a letter |
| Parameters | Up to 10 per event |
| Parameter names | Same rule as event names. game_id is reserved and added by the site |
| Parameter values | Numbers, true/false, or strings up to 100 characters. Anything else is dropped |
| Rate | 60 events per minute per game frame. Extra events are rejected with status 429 |
Events are sent to the site's Google Analytics property with your game's ID. They are not sent from private previews or the SDK test game, and in local test mode they are only logged to the console in debug mode.
Events the site sends
| Event | When |
|---|---|
game_launch | The player started the game |
game_loaded | Your game called loadingStop(). Includes load_ms |
happy_moment | Your game called happyMoment() |
Your own Google Analytics property
If you want your game's events in your own Google Analytics 4 property, send its measurement ID (G-XXXXXXXXXX) through developer support. Once it is attached, your game's events and a page view for its game page are also sent to your property. Your property receives nothing else from the site.
What not to send
- No personal data: no names, usernames, emails, player IDs, chat text, locations or device identifiers.
- No free text typed by players.
- No events that duplicate the site's own, such as a launch event.
Name events after what happened (level_failed, boss_defeated), and put details in parameters rather than in the name (level_complete with { level: 3 }, not level_3_complete).
Younger players
For signed-in players under 18, Google signals and ad personalisation are turned off for all events.