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
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.
While this works, Roblox .ROBLOSECURITY cookies expire after 30 years of first authenticating them.
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);
}
So I am aware of the bugs it contains, working on fixes now, 2.0.0 will most likely be a stable build, right now clone the github repo and Typescript compile it, as that seems to be stable
30 years? did you make a typo there? second, how does this work under the hood/internally, how does it manipulate the datastores from a Node project? third, the API reference link seems to be broken.
other than that, seems like an interesting project, I’ll be sure to give it a go when I eventually come around to developing a discord bot or anything like that.
It’s based on actual client code, and no I didn’t make a typo, they literally expire after 30 years
Just authenticated, and the max age was: Tue, 13-Dec-2050 22:49:03 GMT
Cookies are session based, when you log out it destroys that session therefore destroys that cookie. What I am saying is, the cookie will expire 30 years from the date you either signed up or logged in, or it will expire when you log out
ah, I misinterpreted the whole discussion, sorry about that. there are cookies as I like to call them, legacy cookies, they are cookies that, technically expire, as you said, after 30 years. new accounts tho, they do not have “legacy cookies”, and they obey the new refresh policy which causes them to reset every now and then, correct me if I’m wrong here.
that’s why I asked how old the account, whose cookie you’re using, is. I was just curious if it was an account with a legacy cookie, feel free to test this theory, by using an old accounts cookie, and a new one’s cookie, and checking how long they both last.
Howdy! We found that the best work around is to simply go into Incognito, get the cookie, and close the browser.
Do not sign out of that session or get a cookie from a non-incognito mode.
Back when I mentioned “legacy cookies” at the time, it’s because I believe during the captcha change a lot of cookies got reset or something. But had you logged into the account session again it would refresh as normal. Every time you log in, Roblox will generate you a new cookie for a session, this is why not doing incognito can cause it to expire. If they detect a cookie, they will expire it early to refresh a new one.
Like @LordMerc I was wondering about limits as well.
Limits per server are clearly described here but limits per game aren’t described as clearly (get limited if requested from “too many servers at once”).
Maybe you could do something with the error codes returned?