11 মিনিট

Identity, profile, run ও claim flow

Scoped identity ও replay-resistant result ব্যবহার করুন।

Identity ও privacy

  1. 1.Player ID একটি game ও environment-এ scoped।
  2. 2.Token email বা global account ID দেয় না।
  3. 3.Player intent-এর পরে identity.login ব্যবহার করুন।
  4. 4.Private profile অন্য game-এ কপি করবেন না।

Run flow

const run = await D3Games.runs.start({ gameVersion: "1.0.0", scoringVersion: "v2" });
await D3Games.runs.submit({ ...run, gameVersion: "1.0.0", scoringVersion: "v2", metrics: { score: 1200 } }, crypto.randomUUID());
Browser run continuity প্রমাণ করে, honest score নয়। Authoritative outcome-এ server-verified submission ব্যবহার করুন।

Guest claim

Claim token memory বা protected session storage-এ রাখুন। Login-এর পরে একবার claim করুন; consumed token replay করা যায় না।