Skip to content
Back to skills

Roblox Data

ASecurity

Roblox player-save persistence: DataStore, ProfileStore, session locks, schemas, migrations, retries, shutdown, version history, RTBF deletion templates and DataStore limits. Use when writing, changing, debugging or auditing save code: data lost, rolled back, duplicated or not saving; adding a field to the save; changing currency or inventory storage; reviewing a save layer.

  • 2 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added October 17, 2026
ai-agentsdebuggingapi

Works with

  • api

Security analysis

A100/100

Pro scans all 4 files and shows the line behind each finding

Scanned October 17, 2026

npx -y skills add rodrigo-guerraa/roblox-hub --skill roblox-data --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Roblox Data?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Roblox Data
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/rodrigo-guerraa-roblox-data/badge)](https://www.skillsdirectory.com/skills/rodrigo-guerraa-roblox-data)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: roblox-data
description: "Roblox player-save persistence: DataStore, ProfileStore, session locks, schemas, migrations, retries, shutdown, version history, RTBF deletion templates and DataStore limits. Use when writing, changing, debugging or auditing save code: data lost, rolled back, duplicated or not saving; adding a field to the save; changing currency or inventory storage; reviewing a save layer."
---

# Roblox data persistence

Where this conflicts with the `roblox-lessons` skill, `roblox-lessons` wins.

## When to use

Player saves, migrations, retries, shutdowns, session ownership. Leaderboard stores: see `roblox-lessons` `references/data.md` (Leaderboards). Open Cloud data-store access: `roblox-lessons` `references/open-cloud.md`.

## Our defaults (from `roblox-lessons` data.md)

- **Use ProfileStore** (MadStudioRoblox, session locking). The raw-DataStore patterns in `references/full.md` explain the mechanics and apply to non-profile stores; do not hand-roll a second lock around ProfileStore.
- **Studio saves to its own store:** `NAME .. "_Studio"` when `RunService:IsStudio()`; suffix leaderboard/ordered stores the same way. With Studio API access off, ProfileStore falls back to its in-memory mock by itself.
- **Never rename the DataStore to change the save format** (a new name is a new, empty store). Store `dataVersion` and migrate step by step: pure `Migrate(data, target)`, `Steps[v]` upgrades v to v+1 on a deep copy, each step in `pcall`, live data replaced only if every step succeeds, then `Reconcile()`. A save newer than the code, or a missing/failed step: end the session, leave the save untouched, kick with "please rejoin".
- Studio conveniences (starting grants, force-owned passes, test runners) are guarded by `RunService:IsStudio()`.

## Quick reference

- Serializable template plus a version field; deep-copy templates so nested defaults are never shared; migrate, then reconcile missing fields.
- `UpdateAsync` for read-modify-write on non-profile stores; bounded retries with backoff; a failed read is not an empty profile.
- ProfileStore: `StartSessionAsync` can return `nil` (never treat as new data); a custom `Cancel` callback disables the built-in timeout, so add your own deadline; `OnSessionEnd` kicks; `EndSession` on leave; no `Steal` in normal joins.
- `PlayerRemoving` alone is not enough; `BindToClose` finishes pending work.
- Store only primitives/arrays/dictionaries. Reject NaN/inf numbers and strings failing `utf8.len`; one bad value fails the whole write.
- RTBF: keep the user ID as a static substring in keys (`player_<UserId>`) so deletion templates can match.
- `GetAsync` serves a 4-second local cache; verify writes with `DataStoreGetOptions.UseCache = false`.
- Poll `GetRequestBudgetForRequestType` for live headroom instead of guessing quotas.
- `Player.User` is the documented identity for new code; `UserId` remains valid. Never mix the two in one key scheme.
- Ack a grant only after it is durably persisted; an unknown outcome is retried with the same idempotent operation, never re-granted.

> Details, code and limits: [references/full.md](references/full.md)

Files in this skill

  • LICENSE1 KB
  • SKILL.md3.1 KB
  • SOURCE.md3.2 KB
  • references/full.md38.3 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.