├── config.json ├── LICENSE ├── README.md └── index.js /config.json: -------------------------------------------------------------------------------- 1 | { 2 | "bots": { 3 | "firstaccount": { 4 | "shared_secret": "", 5 | "username": "", 6 | "password": "" 7 | } 8 | } 9 | } -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Aga 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # steam-rep-bot 2 | ## +REP BOT 3 | Auto comment you steam profile 4 | 5 | # Getting Started 6 | For you to get started you need the following 7 | ``` 8 | NODEJS 9 | NPM Package Installer 10 | Your Shared Secret 11 | ``` 12 | ### Installing 13 | 14 | First off get your Identity Secret, and Shared Secret. Read this Thread here (https://forums.backpack.tf/index.php?/topic/46354-guide-how-to-find-the-steam-identity_secret-on-an-android-phone/) 15 | 16 | Or use SteamDesktopAuthenticator (https://github.com/Jessecar96/SteamDesktopAuthenticator.git) 17 | Enter the SDA folder in the maFiles folder open the file that has your SteamID name and look for Identity Secret and Shared Secret code. 18 | 19 | 20 | Fill in config.json 21 | 22 | After this open console, and write the following. 23 | ``` 24 | mkdir steam-rep-bot 25 | npm install steam-user 26 | npm install steam-tradeoffer-manager 27 | npm install steamcommunity 28 | npm install steam-totp 29 | npm install fs 30 | npm i --save lodash.merge 31 | 32 | ``` 33 | After this make way to this directory, and drop in the code. 34 | Once this is complete type the following into Command Prompt. 35 | 36 | ``` 37 | cd steam-rep-bot 38 | node index.js 39 | ``` 40 | Or make a batch file where you put the following command 41 | ``` 42 | @echo off 43 | color 2 44 | node index.js 45 | pause 46 | ``` 47 | And save as start.bat in steam-rep-bot folder. 48 | 49 | HOW TO USE 50 | 51 | Send !comment or !help to write +rep on you profile 52 | 53 | To use another signature change this 54 | 55 | firstCommunity.postUserComment(steamID, "+REP") 56 | 57 | firstCommunity.postUserComment(steamID, "+REP Signed by .......you steam name") 58 | -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | var SteamUser = require('steam-user'); 2 | var SteamCommunity = require('steamcommunity'); 3 | var SteamTotp = require('steam-totp'); 4 | var TradeOfferManager = require('steam-tradeoffer-manager'); 5 | var fs = require('fs'); 6 | 7 | var firstClient = new SteamUser(); 8 | 9 | // Managers 10 | var firstManager = new TradeOfferManager({ 11 | "steam": firstClient, 12 | "domain": "example.com", 13 | "language": "en" 14 | }); 15 | 16 | // Communities 17 | var firstCommunity = new SteamCommunity(); 18 | 19 | // Config 20 | var config = JSON.parse(fs.readFileSync('./config.json')); 21 | 22 | var firstLogonOptions = { 23 | "accountName": config.bots.firstaccount.username, 24 | "password": config.bots.firstaccount.password, 25 | "twoFactorCode": SteamTotp.getAuthCode(config.bots.firstaccount.shared_secret) 26 | }; 27 | 28 | // Logging in... 29 | firstClient.logOn(firstLogonOptions); 30 | 31 | firstClient.on('loggedOn', () => { 32 | console.log('Logged In!'); 33 | firstClient.setPersona(SteamUser.Steam.EPersonaState.Online); 34 | firstClient.gamesPlayed(["Testing +REP BOT",440,570]); 35 | }); 36 | 37 | firstClient.on('webSession', (sessionid, cookies) => { 38 | firstManager.setCookies(cookies); 39 | firstCommunity.setCookies(cookies); 40 | }); 41 | 42 | 43 | firstClient.on('friendRelationship', function(steamID, relationship) { 44 | 45 | if (relationship == SteamUser.Steam.EFriendRelationship.RequestRecipient) { 46 | firstClient.addFriend(steamID); 47 | console.log(" "); 48 | console.log("Accepted friend request from: " + steamID); 49 | firstClient.chatMessage(steamID, "Welcome To My +REP Bot, type !help to get started!"); 50 | } 51 | }); 52 | 53 | 54 | 55 | firstClient.on("friendMessage", function(steamID, message) { 56 | if (message == "!help") { 57 | firstClient.chatMessage(steamID, "Type !comment for +rep on your profile"); 58 | } 59 | }); 60 | 61 | 62 | firstClient.on("friendMessage", function(steamID, message) { 63 | if (message == "!comment") { 64 | firstClient.chatMessage(steamID, "OK i comment you profile !") 65 | firstCommunity.postUserComment(steamID, "+REP") 66 | } 67 | }); 68 | --------------------------------------------------------------------------------