Class · inherits GlobalDataStore
DataStore
A GlobalDataStore that also supports versioning, key metadata, and
enumerating keys.
About DataStore
See Data stores for an in-depth guide on data structure, management, error handling, limits, and more.
Methods 4
GetVersionAsync
(key: string, version: string) → TupleYieldsRetrieves the specified key version.This function retrieves the specified key version as well as a
DataStoreKeyInfoinstance. A version identifier can be found throughDataStore.ListVersionsAsyncor alternatively be the identifier returned byGlobalDataStore.SetAsync.GetVersionAtTimeAsync
(key: string, timestamp: int64) → TupleYieldsRetrieves the key version that was current at a given time.This function retrieves the key version that was current at a given time as well as a
DataStoreKeyInfoinstance.ListKeysAsync
(prefix: string, pageSize: int = 0, cursor: string, excludeDeleted: boolean = false) → DataStoreKeyPagesYieldsReturns aDataStoreKeyPagesobject for enumerating through keys of a data store.This function returns a
DataStoreKeyPagesobject for enumerating through keys of a data store. It accepts an optionalprefixparameter to only locate keys whose names start with the provided prefix.If
DataStoreOptions.AllScopeswas set to true when accessing the data store throughDataStoreService.GetDataStore, keys will be returned with all scopes as prefixes.ListVersionsAsync
(key: string, sortDirection: SortDirection = Ascending, minDate: int64 = 0, maxDate: int64 = 0, pageSize: int = 0) → DataStoreVersionPagesYieldsEnumerates all versions of a key.This function enumerates versions of the specified key in either ascending or descending order specified by a
SortDirectionparameter. It can optionally filter the returned versions by minimum and maximum timestamp.
DataStore also has every member of GlobalDataStore. Deprecated and Roblox-only members are hidden.
Reference text from the Roblox Creator Documentation, licensed CC BY 4.0, reorganized by rbxtoolshub.com · Studio 0.743.0.7431133.