Skip to content

Setting up

Lasse Støjier Pedersen edited this page May 3, 2023 · 4 revisions

Setting up

Here is a step by step, how to get starting whit the setup.

Quick start guide

Just run npm install in the root folder. ( make sure to not use the audit fix, it will break everything )

Add your account(s) into the config.js file.

Edit main.js, by setting up the modules to run in order. And how the settings should be.

And if needed change the module file.

And then run node main

set up accounts

To set up account you just have to add each account to the config list in the config.js file.

The object must have the following properties: steam_user and steam_pass

If you are using 2fa or mail login read the sub section. You can also giv the object other naming, by change the settings Read the sub section

Here is a example where we have added 2 accounts:

var config = [];
config.push({
	steam_user: "**",
	steam_pass: "**"
});
config.push({
	steam_user: "**",
	steam_pass: "**"
});
module.exports = config;

You can also give each account a name, that will be showen in the console, when it running.

That can be done by adding the specialAccountText into the config account object.

Example:

var config = [];
config.push({
	steam_user: "**",
	steam_pass: "**",
	specialAccountText: "Account 1"
});
module.exports = config;

That will log like:

[Sat, 25 Jun 2022 23:15:04 GMT][Account 1 - steamID - steam_user][salequeue] at c:\nodejs\the-steam-awards\modules\events\salequeue.js:61:21 new items: 0

You can custom the console, read more in the setting wiki page

Account whit 2fa

If a account is using 2fa, you will need the sharedSecret to be able to use that account.

Then you just have to set the sharedSecret on the config account, then them it shoud be able to just run the project.

Example:

var config = [];
config.push({
	steam_user: "**",
	steam_pass: "**",
	sharedSecret: "**"
});
module.exports = config;

Account whit mail code

If a account is using mail code, then you have to do a 2 step flow. As we need the sentry file, to be able to just login in at each run, whitout having to set the mail code each time. As this can be a big problem, if you have a lot of accounts, that are unsing this.

If you allready have the sentry file, then you just have to create a folder named sentry, in the root folder. and place the sentry file, whit the steam_user as the name of the file.

so at step 1. you need to just call the login once whit only Username and Password. as that will make you get a mail whit a code. You have to add a module to be able to run the code, so here you just add the testing/test module (Read more in the Module wiki page). And then only make it run that account ( this can also be done whit more then one account at once ). Read more in the Running section

Code Example:

Config.js Main.js
var config = [];
config.push({
	steam_user: "**",
	steam_pass: "**"
});
module.exports = config;
...
modules.push('testing/test');
...
core.RunIndexSpecificBot([Index of the account], modules) 
...

Then once it have runned, you shoud get the mail. Then you have to set the mail code into the config file, in the mailAuth property.

Example:

var config = [];
config.push({
	steam_user: "**",
	steam_pass: "**",
	mailAuth: "**"
});
module.exports = config;

Then just run the project. Now it shoud login, and run that module. Now there shoud be a file in the sentrys folder, whit the account name. That means that you, shoud be able to just run this account agirn, whit out having to get the code from the mail agirn. You can also remove the mailAuth proppery. it doent have to be there any more.

Account whit parental control

What parental control you have to enter a PIN, to account the hole account. There is build way, to use the pin. If a account is using parental control, you will need the Pin to be able to access the hole account.

Then you just have to set the PIN on the config account, then it shoud be able to just run the project.

Example:

var config = [];
config.push({
	steam_user: "**",
	steam_pass: "**",
	PIN: "parental PIN!"
});
module.exports = config;

From Line Format

If you have used a other system, where you have all the accounts in a line format, like username:password:sharedsecret There made a convert that can use used, to create the config.js from that file.

By using npm run ConvertFromLineFormat [FilePath], will add account(s) from a text file has the format username:password:sharedsecret:SpecialAccountText (only username and password is mandatory) on each line.

Other object keys

so if you eks are using a other system, where you allready have the login as a list, but where example the username property, is named somefing else. Then there is a way to, tell the project that it is somefing else.

Each propperty in the account config, have been added to the settings. so it can just be overridden whit that.

Read more in the settings wiki

Running mode

There is a few ways to run this.

  • RunAllBots - core.RunAllBots(modules) - will run all account in config.js
  • RunIndexSpecificBot - core.RunIndexSpecificBot([0, 1], modules) - will run the specifig index in the config.js only
  • RunAllButIndexSpecificBot - core.RunAllButIndexSpecificBot([0, 1], modules) - will run all but the specifig index in the config.js
  • DoRunBots - core.DoRunBots(auths, modules) - will run the given accounts in the auths list. ( Ignoring the config.js )

The modules parameter: you need to push at least one module before running. Read the next section.

Clone this wiki locally