Menu
 

Roblox Cross-Experience Identity Patterns: HttpService + External Backend

Roblox Cross-Experience Identity Patterns: HttpService + External Backend

Roblox's native data stores are consistent within a single experience. The moment a studio publishes a second experience and wants shared progression, currency, or a unified ban list, the native stack stops being enough. The standard 2026 pattern is: server-side HttpService calls from each experience to a single external backend that owns the canonical player identity.

2026 update: Roblox modified HttpService:JSONEncode and JSONDecode starting March 10, 2026, to add explicit encoding for inf, -inf, and NaN. Treat those values as forbidden on your backend JSON contract to stay portable.

Why Native Is Not Enough

  • DataStoreService is per-experience. A second experience cannot read the first's data store.
  • Teleport data is not secure. Roblox docs are explicit: do not put currency or inventory in teleport payloads.
  • Open Cloud rate limits. Checking a ban list across multiple experiences hits rate limits quickly, especially at medium player counts.
  • MessagingService is transient. Great for signals, not for durable shared state.

Pattern: Single External Backend as the Identity Source

Every Roblox experience server calls a shared backend via HttpService. The backend owns player identity, shared progression, shared currency, and a unified ban/admin log. Individual experiences still use DataStoreService for per-experience concerns (chunk/save data, per-place tutorials), but anything that should travel with the player lives on the backend.

local HttpService = game:GetService("HttpService")
local BACKEND = "https://api.supercraft.host/v1"
local SERVER_TOKEN = game:GetService("ServerStorage"):WaitForChild("ServerToken").Value

local function verifyPlayer(userId)
    local res = HttpService:RequestAsync({
        Url = BACKEND .. "/environments/prod/auth/roblox/verify",
        Method = "POST",
        Headers = { ["Authorization"] = "ServerToken " .. SERVER_TOKEN,
                    ["Content-Type"]  = "application/json" },
        Body = HttpService:JSONEncode({ robloxUserId = userId }),
    })
    return HttpService:JSONDecode(res.Body)
end

local function readProgression(playerId)
    local res = HttpService:RequestAsync({
        Url = BACKEND .. "/players/" .. playerId .. "/documents/progression",
        Method = "GET",
        Headers = { ["Authorization"] = "ServerToken " .. SERVER_TOKEN },
    })
    return HttpService:JSONDecode(res.Body)
end

What Lives Where

Concern Home
Place-local tutorial state DataStoreService (per experience)
Short-lived session data between place hops MemoryStoreService or teleport data (non-secure)
Player identity across experiences External backend (player document)
Shared currency / premium items External backend economy with atomic adjust
Unified ban list External backend, audited
Leaderboards across experiences External backend leaderboard with seasons

Security Rules

  1. HttpService only from server scripts. Never expose the backend token to the client.
  2. Store the server token in ServerStorage or environment config. Treat it like a secret.
  3. Rotate tokens. Revoke and reissue periodically, and whenever a staff member leaves.
  4. Verify the Roblox user id server-side. Don't trust a client-supplied id.
  5. Rate-limit server calls. Even with HttpService, runaway loops can DoS your own backend.

Where Supercraft GSB Fits

Supercraft provides a dedicated /auth/roblox/verify endpoint for server-side Roblox verification, plus project-scoped players, documents, economy, and leaderboards that span every experience you publish. Admin endpoints let customer support read and repair any player's documents — the single hardest piece to build yourself.

Design pointer: if you expect more than one Roblox experience, set up the external backend before the second experience ships. Retrofitting shared identity after launch is painful; designing it in on day one is cheap.

Related in This Hub

See the Roblox integration model on the Supercraft Game Server Backend page.

Top