Skip to content

RbxDataStoreService is a node module that That allows you to use DataStoreService outside of Roblox. This project was created because people outside ROBLOX always want to use DataStoreService outside ROBLOX.

Notifications You must be signed in to change notification settings

830008/RbxDataStoreService

 
 

Repository files navigation

A Node.js wrapper for interacting with the Roblox DataStore API.


JavaScript Style Guide Roblox API Discord NPM package

AboutInstallationDocsCredits

About

RbxDataStoreService is a node module that That allows you to use DataStoreService outside of Roblox. This project was created because people outside ROBLOX always want to use DataStoreService outside ROBLOX.

RbxDataStoreService allows you to do things you would normally do on the Roblox DataStoreService through a Node.js interface. You can use RbxDataStoreService along with ROBLOX's HttpService feature to create scripts that interact with the DataStoreService externally.

Installation

With node.js installed simply run:

# Run this to install RbxDataStoreService locally to your repository.
$ npm install @mfd/rbxdatastoreservice --save

# Run this instead to install RbxDataStoreService globally so you can use it anywhere.
$ npm install @mfd/rbxdatastoreservice -g

That's it!

Documentation

You can find the current RbxDataStoreService documentation here (Roblox Wiki) or here (API Reference)

Initial setup

  1. Run RbxDataStoreService.InitializeAsync with the parameters of Cookie and PlaceId. This will store your cookie internally and validate it, but will perform no cookie refresh automatically, it also requires that your cookie have the warning and be valid.
  2. While this works, Roblox .ROBLOSECURITY cookies expire after 30 years of first authenticating them.
  3. You need to store this new cookie somewhere - whether it be in a database, or a JSON file.

Note: By default, InitializeAsync will validate the cookie you provide by making a HTTP request.

Example

This example makes use of the new async-await syntax.

const RBX = require('@mfd/rbxdatastoreservice');
async function startApp() {
	await RBX.InitializeAsync(
		'_|WARNING:-DO-NOT-SHARE-THIS.--Sharing-this-will-allow-someone-to-log-in-as-you-and-to-steal-your-ROBUX-and-items.|_...',
		123,
	);
	// Do everything else, calling functions and the like.
	let DataStoreService = RBX.DataStoreService;
	let DataStore = DataStoreService.GetDataStore('Test', 'global');
	let value = await DataStore.GetAsync('SomeKey');
	console.log(value);
}

Credits

About

RbxDataStoreService is a node module that That allows you to use DataStoreService outside of Roblox. This project was created because people outside ROBLOX always want to use DataStoreService outside ROBLOX.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 100.0%