3JS Games
Browse documentation

Guide

Add cloud saves

A minimal integration path for existing save and load flows.

  1. Inspect and preserve the existing game save model.
  2. Vendor the unchanged official SDK at 3jsgames-sdk/v1/storage.js.
  3. Check isAvailable(), then call get, set, or delete.
  4. Handle AUTH_REQUIRED and other stable error codes.
  5. Test both standalone and embedded behavior.
await ThreeJSGames.storage.set("savegame", {
  level: 4,
  coins: 120
});

See the complete Cloud Storage contract before shipping.