Code Monkey home page Code Monkey logo

node-steam-bot-manager's Introduction

About

A bot management wrapper tool for Steam Community built with NodeJS. Allows users to customize bot actions to the needs of their websites. Whether you are looking for bots to message users when an in-game report occurs, or invite users to your group when they join your server, this tool offers a powerful & easy API.

npm version

forthebadge forthebadge

Features:

  • GUI-Based Bot Control
  • GUI-Based Messaging
  • GUI-Based Trading
  • 2-Factor Authentication Support + Setup
  • Enable API-Key*
  • Generate authentication codes on demand (for manual login)
  • Manage multiple bots simultaneously
  • Login using email/2-factor authentication
  • API Support for third-party systems (Betting, Trading, and so on..)
  • Event based interactions of a single bot or multiple
  • Ability to upvote/downvote attachments on Steam Community
  • Ability to import accounts into tool
  • Create new Steam accounts easily

Requirements

  • NodeJS (V6 is minimum)

WIKI

Visit the wiki for set-up, registration.

For Docs, please visit our docs

If you need further help with setting up the tool, please contact me on Steam, and I will try my best to help you.

Examples:

You can check examples of bots you can build by navigating to the 'examples' folder in the root of the project.

TODO:

  • Expand API access

Updates:

The update policy of this tool is that I will try to post an update every week to few weeks. In the event of large changes, there will be an announcement on ETA. Furthermore, if you happen to use the tool with a certain version of the API, and newer releases do not have the functionality you need, simply rollback using npm package manager. Versions are organized in such manner as of 1.0.50:

  • X.0.0 (Complete release)
  • 1.X.0 (Major release)
  • 1.0.X (Bug fixes)

Libraries used:

How to contribute:

git clone https://github.com/Undeadkillz/node-steam-bot-manager # Clone project files locally
node install # To install the tool and dependancies

The project is still in early stages, and any feedback or contribution is appreciated.

To contribute:

Simply make your desired changes and submit your pull request. At this point, there is no specific format you have to follow, just make sure the code is easily readable, and if possible comment where possible so that the pull request could be approved faster.

To help:

Install the tool, and try out the different examples or even build your own, and try to break the tool. Once you break it, just make sure to inform us via the ISSUES pages, about the issue.

Make sure to atleast include a log of the error message and if possible inform us about the steps to reproduce the issue.

Testing Policy

forthebadge

I will ensure everything works, however I won't be building any unit-tests at this time.


Stable versions via npm (incase your version contains certain bugs, try these builds):

  • 1.0.46
  • 1.0.56

Git Version

Frequently the Github source will not be the same version as the latest npm version. This is because the npm versions are often the stable ones. Github will contain the developmental and possibly even broken versions at times (official versions will be stated in the commit)

Credits:

  • Undeadkillz | Add me on: Steam
  • All authors and helpers of the libraries listed above (with their respective library urls)

forthebadge forthebadge

Tracking

This tool has statistics built-in to allow only the main developer to track usage of the tool. This tracking is anonmous and if need be, can be disabled at will using the configuration. I may use the tracking to ensure certain functionality is working as intended, and also to ensure this tool is used (low usage, may mean that I do not need to keep updating).

Sponsors

The following sponsors help promote further development of this tool.

Techie.Guru

Techie.Guru

* Using this feature means you agree to Steam's API terms found at: Steam API Terms

node-steam-bot-manager's People

Contributors

sameralsayegh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

node-steam-bot-manager's Issues

I cant use the arrow keys @ the registration options

Hi,

I cant use the arrow keys @ the registration options shown below.
Any idea's?

? Choose how you would like to register?: (Use arrow keys)

create new steam account
──────────────
import account

features from node-steam-user

hello, I just wonder if this is possible to re-write my idler feature to your bot

I have something like this in other nodejs bot

	bot.on('accountLimitations', function(limited, communityBanned, locked, canInviteFriends) {
		var limitations = [];
 
		if(limited) {
			limitations.push('LIMITED');
		}
 
		if(communityBanned) {
			limitations.push('COMMUNITY BANNED');
		}
 
		if(locked) {
			limitations.push('LOCKED');
		}
 
		if(limitations.length !== 0) {
			console.log("[" + this.username + "] Limitations: " + limitations.join(', ') + ".");
		}
	});

https://github.com/DoctorMcKay/node-steam-user#accountlimitations
is it possible to use it with your code?

should I use something like this?

botsManager.on('accountLimitations', function (botAccount) {

I think is doesn't work

oAuthToken

Hello, looks like oAuthToken expiring after 1 year (365 days) after add.
is there any method to prevent it?

I need to re-add accounts, because getting 401 error exactly after 1 year after add account.

adding accounts from .txt

Hello, I want to add accounts from .txt file to script.

Usually I'm running nodejs onlyGUI and registering accounts one by one, but now I want to add accounts from txt file.
I'm have in .txt a few accounts, they look like this:

login:password
login2:password2
login3:password3
login4:password4

enter after every line and ':' between login and password, how can I automaticly add them to gui handler?

I think I can deal with array maybe, something like this to read .txt file


var fs = require("fs");
var array = fs.readFileSync('accounts.txt').toString().split("\n");

but how can I add them to account list in script, can you please guide me?
Greetings

Getting error when sentOfferChanged event emits

When sentOfferChanged event emits I'm getting this type of error: ''error: Error: No API-Key set (yet)", that's why I can't get new state of the tradeoffer. I am using callback similar to one provided in examples.
Can you help me to solve this problem?

TradeScript - sending all items to TRADE URL

Hello, is there any chance to create tradescript who can send all tradable steam items and game items (from all games from inventory) to 'Trade URL - You can share this unique URL with other Steam users to allow them to send you a trade offer even if they aren't on your friends list. You can share this URL anywhere, including on third-party trading sites and Steam Community groups.' (example: https://steamcommunity.com/tradeoffer/new/?partner=2222222222&token=tve3-neX)

showing games with drops remaining

Hello again ;)

I have small question, is there some easy method to push console.log with appID with available drop cards?

something like this: [info] {accountname}: you can drop cards in games: {appID}, {appID}.

I know there is some standalone nodeJS scripts to idle Steam games, but I want to do this on this base script, only show appID without actually idle.

Cannot read property 'addEndpoint' of undefined?

Getting this error when I try to run the APITradeBot.js example!

error: Failed to load "data/xxxxxxxx.dat" due to {"Error":"Failed to parse due toTypeError: Cannot read property 'addEndpoint' of undefined"}

(xxxxxxxxx is the name of my bot account)

Any help would be appreciated!

more features (fav, comments, follow, join group)

I hope you can add more features to do all popular things in steamcommunity like:

  • favorite/unfavorite screenshots
  • comment profiles
  • follow/unfollow person
  • join/leave steam group

It would be great if you could do it in the future updates ;)
Greetings

screenshots

Hi, can I link like 10-20 Steam accounts with this tool and like screenshots?

Do I need extra code, or I can do this with existing code.

steam has concurrent limit when one andorid device does secondConfirmation?

hello,should this question be here? if not just delete it. when i use async method to send 50 tradeoffers at the same time,20 tradeoffers make it(STEAM's limit is 5 tradeoffers with the same partner),but when i do androidSecondConfirm using async method,just 1 or 2 secondConfirms make it,the others return "{"success":false}" from steamcommunity.com.
this is my webRequestUrl:
string allowp = SteamGuardAccount.GenerateConfirmationQueryParams("allow");
string allowUrl = $"https://steamcommunity.com/mobileconf/ajaxop?op=allow&{allowp}&cid={data_confid}&ck={data_key}";
does steam have concurrent limit when one andorid device does secondConfirmation? if so,I have to control the concurrent in my code? appropriate for any reply

weird question about executing nodejs script

Hello, I have really weird question, is it possible to execute other nodejs script

something like that:

                        botAccount.Community.followPublisher(profileId, function (err) {
                            if (err)
                                botsManager.errorDebug("Failed to follow user. User might already be followed. Error: " + err);
                            else
                                "node FavouriteBot.js";
                                botsManager.infoDebug("Successfully followed user with  " + botAccount.getAccountName());
});

I mean, executing new script "node FavouriteBot.js"; when follow is done.
I know I can copy paste code to favbot, but I want to know if I can execute external script with new nodejs console

Issue with mobile confirmation

Hey there,
im trying to figure out since over a week now how to setup up successfully the mobile authentification.

When im selecting a bot and using 'Manage' im getting the following output:

? Choose the authentication option you would like to activate. [OFF] Two Factor Authentication
Error encountered while trying to enable two-factor-authentication, error code: undefined

As next part, how would an automated trading bot would look like, im not that familair yet with nodejs, is it still bound to a gui? Or can i wrote a full application handling automatic trades and so on?

Greetings

Ps: added you on steam, feel free to answere me there for faster interactions.

Not working :(

e:\node_modules\node-steam-bot-manager\lib\index.js:119
if (self.config.hasOwnProperty("api_port") && self.config.api_port != null) {
^

TypeError: Cannot read property 'hasOwnProperty' of undefined
at BotManager.startWebserver (e:\node_modules\node-steam-bot-manager\lib\index.js:119:21)
at BotManager.startManager (e:\node_modules\node-steam-bot-manager\lib\index.js:173:10)
at new VoteBot (e:\VoteBot.js:73:17)
at Object. (e:\VoteBot.js:79:1)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)
at Function.Module._load (internal/modules/cjs/loader.js:769:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
at internal/main/run_main_module.js:17:47

Duping Interface.

I Want to just say that i'm using CMD (Windows 10) to use this
and the interface is horrible.

For starters it keeps duping the text and removing options.
This may just be me but its annoying.
Any suggestions?

useragent during login

Hello, I noticed DoctorKay creator of Steam lib for nodejs started using

+const USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36"; +

in his code for steam-store: DoctorMcKay/node-steamstore@bd9bdde

how can I send this useragent during login to Steam with your script and with every task (like follow etc.)

if I want to add this during login to Steam, should I edit your script or steam-user lib?

Greetings :D

Empty Config File

Hi, I just installed the package using npm and wanted to test one of the example files... when i run it, it creates a config folder containing config.json and a data folder. but both of them are empty and i get this error from node:
2019-01-18T12:40:09.962Z - error: Failed to validate - Error=Failed to parse due toSyntaxError: Unexpected end of JSON input
2019-01-18T12:40:09.967Z - error: Failed to load config

how can I count accounts added to script?

I want to count all accounts added to script and show them during script start, something like this

    botsManager.startManager(function (err) {
        setTimeout(unfavourite, 1000 * 10);
        console.log("Starting script with " + accounts.length + " accounts.");
    });

// FIXED //

a few questions

  1. is there chance to auto-login after register account action?
  2. how can I set all my accounts to offline (steam friends) - currently show logged - website
  3. how can I move down first console log - 2017-06-28T11:26:27.029Z - info: Successfully... in case of:
  ──────────────
  register
(Move up and down to reveal more choices)2017-06-28T11:26:27.029Z - info: Successfully...
2017-06-28T11:26:27.098Z - info: Successfully...
  1. how can I remove "2017-06-28T11:26:27.098Z" or at least make it like: 2017-06-28 - 11:26:27 / solved: timestamp: false;
  2. is it possible to do 'Unique Visitors' in VoteBot?

disconnecting from Steam

I want to close connection after action, like after group join etc, only for 1 bot instance

I tried to use:

botAccount.Auth.logoutAccount();
botAccount.logoutAccount();
botAccount.client.logOff();
botAccount.client.disconnect();

looks like 'netstat -b' still shows established connection for node.exe.

example of code:

botAccount.Community.joinGroup(groupID, function (err) {
        if (err)
            botsManager.errorDebug("Failed to join group. " + err);
        else
           botAccount.Auth.logoutAccount();
           botAccount.client.logOff();
           botAccount.client.disconnect();
           botsManager.infoDebug("Successfully joined group with  " + botAccount.getAccountName());
});

I just want to cut connection when finished (only per account).

Can you please help me? 😃

btw. I'm using version before 'heavy update'.

create new accounts

Hey,

Saw you added the ability to create new accounts in a recent update, but can't seem to get it to work.

Can you please provide some more info on what I will need to do?

When creating the accounts it never seems to actually make an account or save any files.

card checker

Hello, I'm trying to do card idle checker, if some account have some cards to idle.
I'm too dumb for this ^^

Source: https://github.com/DoctorMcKay/Steam-Card-Farmer/blob/old-cli/farmer.js

I'm trying to check if any account have some games to idle, if {YES} how many games.
Can you help me?

my code returning: null

var BotManager = require('node-steam-bot-manager');
var request = require('request');
var Cheerio = require('cheerio');
var botsManager = new BotManager();

function cardChecker() {

    var checkCards = function () {

        for (var botAccountIndex in botsManager.getAccounts()) {

            (function () {
                var botAccount = botsManager.getAccounts()[botAccountIndex];

		var g_Jar = request.jar();
		request = request.defaults({"jar": g_Jar});
		request("https://steamcommunity.com/my/badges/?p=1", function(err, response, body) {
			
			botsManager.infoDebug("request sent! " + botAccount.getAccountName());
			
			var $ = Cheerio.load(body);
				var row = $(this);
				var drops = row.find('.progress_info_bold').text().match(/(\d+)/);
				botsManager.infoDebug("games to idle: " + drops + " - " + botAccount.getAccountName());

			});
            })();
        }
};
    botsManager.startManager(function (err) {
        setTimeout(checkCards, 5000);
    });
}

new cardChecker();

module.exports = cardChecker;

2 questions

  1. How can I loop account who has error during example: unfollow
                botAccount.Community.unfollowPublisher(profileId, function (err) {
                    if (err)
                        botsManager.errorDebug("Failed to un-follow user. User might already be un-followed. Error: " + err);


----- what I should to put here to loop account until he will do that without error? -----

                    else
                        botsManager.infoDebug("Successfully un-followed user with  " + botAccount.getAccountName());
                });
            })();

  1. is there a some simple method to keep accounts logged on all the time and do favs/likes or follows without logging them every time with GUI?
    can I just add case in GUIhandler with value of 'node votebot.js' or something?

sorry for stupid questions, my coding skills are at low lvl ^^

Problem with Start API.

Hello, I have problem when I try to start APITradebot.js. It's my log:
2017-04-25T13:51:42.030Z - debug: Starting Bot Manager 2017-04-25T13:51:42.033Z - debug: Loaded config 2017-04-25T13:51:42.083Z - error: Failed to read account data - check file for any malformation using a JSON parser 2017-04-25T13:51:42.105Z - error: TypeError: botsManager.addEndpoint is not a function at D:\bot\examples\InventoryBot.js:54:21 at D:\bot\node_modules\node-steam-bot-manager\index.js:73:17 at D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:76:21 at D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:147:13 at DataControl.getFile (D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:113:9) at DataControl.loadAccounts (D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:138:10) at D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:71:18 at DataControl.validateConfig (D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:105:5) at D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:159:18 at DataControl.getFile (D:\bot\node_modules\node-steam-bot-manager\components\DataControl.js:113:9) 2017-04-25T13:51:42.109Z - error: Error initializing data - TypeError: botsManager.addEndpoint is not a function 2017-04-25T13:51:42.112Z - error: Failed to start Bot Manager 2017-04-25T13:51:42.693Z - debug: Logged on to chat on "12_98" 2017-04-25T13:51:42.695Z - debug: Logged into "12_98"

Steam Market sell listing

Hello again :)

I have a few accounts where I idle steam games for cards and 1 storage account.
I transferred all steam trading cards (for 1 game) to storage account, and I have ~1000 cards to sell (they are all from one game).
I want to put them on Steam market (I know I can use SIH chrome extension or something different but I prefer nodejs method).

I found something: https://dev.doctormckay.com/topic/287-automatic-market-seller/#entry746
but I really don't know how to use it, do you know how to implement this? like I want to put all steam items to steam market for fixed price?

I will confirm market listings on phone.
Greetings.

EDIT: I even found something like this: https://github.com/Z8pn/node-steam-market
but how can I use it in your script? to loop all cards and put them on market?

TypeError: Cannot read property 'createOffer' of undefined

Getting the following error!

botAccount.TradeManager.createOffer(partnerSid, function (err, currentOffer) {

TypeError: Cannot read property 'createOffer' of undefined
at C:\Users\LolCoolKat\Documents\node-steam-bot-manager\APITradeBot.js:80:52

Any help would be appreciated!

getting nicknames from accounts

I trying to do simple script to grab Steam nickname of current account, but even with it I'm failing.
Works good in my idler script

	bot.on("accountInfo", function(name) {
		console.log("Your Online Name: " + name);
	});

but this doesn't work,

var BotManager = require('node-steam-bot-manager');

function myNick() {
    var botsManager = new BotManager();

    botsManager.on("accountInfo", function(name) {
		botsManager.infoDebug(botAccount.getAccountName()+ ": your nickname ->" + name);
    });
    botsManager.infoDebug("Starting...");
    botsManager.startManager(function (err) {
        if (err)
            botsManager.errorDebug("Failed to start.");
    });
}

new myNick();

module.exports = myNick;

I found this: https://github.com/DoctorMcKay/node-steam-user#accountinfo
but I don't really get it, where I should put this to grab current nickname?

logging with web browser

Hello, I wonder if I can login with web browser (firefox/chrome) to Steam with informations from .dat (username, oauth, steamguard), or its not possible?

subscribe workshop item

Hello, can you add feature to subscribing workshop item with script?
I can't find anywhere this, even on steam-user, steam-community packages.

problem

image
I met this problem
I met this problem
What should I do
thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.