Jump to content
McKay Development

Search the Community

Showing results for tags 'node.js'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • News & Announcements
    • Releases & Updates
  • Help & Support
    • General
    • Guides
    • node-steam-user
    • node-steamcommunity
    • node-steam-tradeoffer-manager
    • node-steam-session

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Skype


Location


Interests

  1. I have spent some time checking the node-steamcommunity GitHub wiki, and first of all : Dr. McKay, you are a hero for building up such an easy npm interface for the messy Steam API... I came up with some code to make sure I'm logged in almost 24/7 : // Modules are required and secret stuff is ready... function logOnSteam() { console.log("Logging in to Steam..."); steamCommunity.login(logOnOptions, function (e, sessionID, cookies, steamguard) { if (e) { console.log("There was an error logging in ! Error details : " + e.message); setTimeout(logOnSteam, 1000*60*4); // try to reconnect in 4 minutes return; } else { console.log("Successfully logged in as " + logOnOptions.accountName + " !"); steamCommunity.chatLogon(); // to appear online tradeOfferManager.setCookies(cookies, function (err) { if (err) { console.log(err); return; } }); } // automatic confirmation of EVERYTHING every "confirmationPeriod" ms steamCommunity.startConfirmationChecker(confirmationPeriod, identitySecret); }); } function checkSteamLogged() { steamCommunity.loggedIn( function (err, loggedIn, familyView) { if (err) { console.log(err); setTimeout(checkSteamLogged, 1000*60*4); // check again in 4 min } else if ( ! loggedIn ) { console.log("Steam login check : NOT LOGGED IN !"); logOnSteam(); } else { console.log("Steam login check : already logged in !"); } }); } steamCommunity.on('sessionExpired', function (err) { if (err) {console.log(err);} logOnSteam(); }); logOnSteam(); setInterval(checkSteamLogged, 1000*60*30); I guess this is enough to be safe... (unless I made some rookie mistake ?) This code is obviously the starting point for some TradeOfferManager handling, and I was wondering if I didn't go too far : if the 'sessionExpired' event is really triggered whenever we are not logged in, does it mean the 'checkSteamLogged()' function can be safely removed without harm ?'.startConfirmationChecker()' doesn't create a new instance each time it is called ? (I don't want to trigger 10 confirmations checkers leading to 10 times the intended check rate...)Thanks for any input !
  2. Hi guys! I do not know and where to start. I want to make steam bot. On the Internet, many libraries for this, but I settled on (this) because there is someone to ask. What I have in stock: Steam account, which can make and receive exchange Look like that's it. Questions: To begin, I just want to make the authorization, as I realize it is from my computer via a bot. How can I do it? So as for Steam authentication requests from the phone key. Please help experts!
  3. after manager.loadUserInventory(row[y].userid,730, 2, true, function (err, myItems, currencies) { if (err) { reconnect(); logger.info('Ошибка загрузка инвентарÑ: ' + err); return; }err = Error: unable to verify the first certificate what is the problem?
  4. Is there a way that I can make contra offer without trade url or friendship with user. It is possible in steam. Here is the case: 1. User know bot trade url and send him trade offer. 2. Bot receive the offer and user is not in bot friends list. 3. Bot send him contra offer with bot items and user's items without knowing user's trade url.
  5. I might be doing this wrong. This is my code: client.on("chatUserLeft", function(chatID, userID) { if (userID.getSteamID64() !== owner) { client.chatMessage(userID, "I hope your issue has been resolved! Whenever you have another question feel free to open another chat :)"); } client.leaveChat(chatID); }); owner = my steamid64. The error I'm getting: C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-user\components\chat.js:512 delete this.chats[sid64].members[target64]; ^ TypeError: Cannot read property 'members' of undefined at SteamUser._handlers.(anonymous function) (C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-user\components\chat.js:512:28) at SteamUser._handleMessage (C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-user\components\messages.js:198:29) at emitThree (events.js:116:13) at CMClient.emit (events.js:194:7) at CMClient._netMsgReceived (C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-client\lib\cm_client.js:278:8) at CMClient.handlers.(anonymous function) (C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-client\lib\cm_client.js:386:8) at CMClient._netMsgReceived (C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-client\lib\cm_client.js:260:24) at emitOne (events.js:96:13) at TCPConnection.emit (events.js:188:7) at TCPConnection._readPacket (C:\Users\Tim\Desktop\Steam Bots\Assistant\node_modules\steam-client\lib\tcp_connection.js:73:7) [nodemon] app crashed - waiting for file changes before starting... Help is appreciated.
  6. Here is the case 1. First trade offer I am sending from bot to user item 'CS:GO Case Key' but he does not accepting it yet 2. Second trade was requested and bot sending to user2 item 'CS:GO Case Key' but it is in trade offer 1 two. 3. And when some of the users accept trade offer one of offers is in "InvalidItems" state. How can I prevent this? Is there a property in CEconItem which tell us that item is in trade already? Something like this (dummy code): offers[roundBot].loadInventory(730, 2, true, function (err, myItems) { for (var i = 0; i < myItems.lenght; i++) { if (myItems[i].isAvailable == 1) { itemsToSendArray.push(myItems[i]); } } }
  7. Is there a full example of a bot that sends trade offers and then confirms using startconfirmationchecker as i always get this error once the method is called. Am i just missing something? https://gyazo.com/a59aa36fed4a641325a926e41ccb890f steamClient.on('logOnResponse', function(logonResp) { if (logonResp.eresult === Steam.EResult.OK) { console.log('Logged in'); steamFriends.setPersonaState(Steam.EPersonaState.Online); steamWebLogOn.webLogOn(function(sessionID, newCookie) { getSteamAPIKey({ sessionID: sessionID, webCookie: newCookie }, function(err, APIKey) { offers.setup({ sessionID: sessionID, webCookie: newCookie, APIKey: APIKey }); fetchtradeurl(); offerItems(); community.startConfirmationChecker(10000, identity_secret); }); }); } });
  8. For some reason I consistently get this error after receiving a trade offer. steam_bot.js:217 if (them.escrowDays <= 0) { ^ TypeError: Cannot read property 'escrowDays' of undefined at /home/teslim/steam-bot/steam_bot.js:217:17 at Object.exports.makeAnError (/home/teslim/steam-bot/node_modules/steam-tradeoffer-manager/lib/helpers.js:33:4) at manager._community.httpRequestGet (/home/teslim/steam-bot/node_modules/steam-tradeoffer-manager/lib/classes/TradeOffer.js:752:12) at SteamCommunity._checkCommunityError (/home/teslim/steam-bot/node_modules/steamcommunity/components/http.js:129:3) at Request._callback (/home/teslim/steam-bot/node_modules/steamcommunity/components/http.js:51:88) at Request.self.callback (/home/teslim/steam-bot/node_modules/request/request.js:187:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (/home/teslim/steam-bot/node_modules/request/request.js:1044:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7)
  9. Firstly I would like to say that you made amazing job! I have a few questions and suggestions. Questions: 1) createAccount() works great. But If I understand correctly It creates accounts through Steam client. Is it safe to create for example 30 or more accounts at once? Does Steam register my machine ID or just IP when I am using this function? 2) Is it possible to change account store country? (not profile country) 3) Is it possible to change email or password? If not, Is it hard to implement this kind of functionality?
  10. Good afternoon. About 2 weeks ago, there was a problem of melting. Boat started getting 429 error when manager.setCookies (). Every day I tried to run it but the problem does not go away. I changed the IP address is given, the server, and even tried to run it on a PC. All the same. Help solve this problem. Restrictions on the account no. $ 5, too, threw.
  11. I've read posts below but. I have 429 error while retrieving a apiKey (setting it manually doesn't really work (btw why?)). Interesting thing that I did change IP, vps and waited about a week and it seems like this bot still doesn't work. is my account banned or what?
  12. Hi there. My web-app have ATM about 10k users. It is good idea to use only 1 bot for loadUserInventory on my web app or should I make more bots for this? Regards.
  13. Edit: Per the post below, this was backported in from v6.3.0 to v5.12.0 as well. Holy crap I thought there were just two active branches. Hi, so after like 3 months of trying to debug a memory leak (mckay can probably attest to all the posts I've made about this) and indeed even browsing node/v8's code I've finally found out why there's indefinite growth of memory usage even when the asset cache isn't used. A leak which shows up in snapshots as system-level retained objects (i.e. things we *never* control at the interpreter level). As it turns out there is a bug in versions of node prior to 4.4.5 where the handle to a VM context was generated as a global. Meaning no garbage collection. Since v2 made the wise decision of using VM contexts instead of straight evals - this of course triggered that bug. And every time a context was created it was putting every object in that context into a global for all intents and purposes. Here is the relevant change that corrected the issue in later node releases. Hope this PSA can save a few people the hassle and perhaps a few bug reports in the future. The relevant changes are tagged with "contextify": https://github.com/nodejs/node/blob/v4.4.5/CHANGELOG.md
  14. node-steamcommunity version 3.21.2, I checked your code, there is no changes in new version, the same error may occur
  15. Hello I have a couple of questions regarding the tradeOffers event and changes in trade offer states. Is the tradeOffers event only emitted when receiving a new trade offer? Is there an event that is emitted when a trade offer changes state? Is the only way to detect changes in trade offer states to poll Steam API GetTradeOffers? What are the rate limits of Steam API GetTradeOffers, is it based on IP Address or Steam Account, or?Thank you for any support, really loving your libraries.
  16. When bot have new offer request I want to know some details for partner. I got offer object but there I can only get offer.partner which is SteamID object I want to check if he is in my friend list and to check if his steam guard is activate (getSteamGuardDetails). And if not to reject offer. How can I do that? Thanks
  17. Hey, I'm currently rewriting my bots due to all those new goodies which been developed in the last year (shoutouts to McKay and everyone working on these). Currently debugging everything and saw that calling JSON.stringify on pollData returns undefined. Had a look at the original pollData and dug a little into the JSON.stringify manual. The manual's saying, that the method will return undefined if a part of the data is a function. Always thought that it would simply omit the function. (tested pre submitting: yep, everything I tried resulted in omitting the Function when calling stringify on the object). Either way, Im at a loss here. Here's a Screenshot of the pollData (this is pre stringifying and right at the beginning of the pollData): and here's my event handler: prototype._onPollData = function onPollDataCallback(data) { var that = this; try{ var write = JSON.stringify(data); }catch (e){ console.log(e); //pls lemme find some } console.log(util.inspect(data, false, null)); fs.writeFile('./bots/pollData/' + that.botName + '.json', JSON.stringify(data), function(err) { if (err){ console.log(err); } return; }); }; I guess that I simply am screwing up somewhere and am just to tunneled to see it but wanted to make sure, if that [Function] really belongs there. Cheers
  18. I have an error accepting trade offer: Unable to accept offer: There was an error accepting this trade offer. Please try again later. (42)
  19. Sometimes unknownOfferSent event is triggered incorrectly, even if trade offer has been sent correctly and I receive tradeid fron newOffer. bot.manager.on("unknownOfferSent", function(offer){ self.cancelOffer(offer, 20, function(err){ if(err){ log.error(`Can't reject trade offer â„–${offer.id}, user - ${offer.partner.getSteamID64()}`); }else{ log.info(`Success reject trade offer â„–${offer.id}`); } }); });
  20. I've been working on getting a bot that uses multiple accounts to add comments to a profile, it works sort of like the report bots that have been released recently. My only issue is that when you have Steam Guard disabled, you can't make comments through the API. If anyone could show me how to use the cookies correctly so I don't have to repeatedly use Steam Guard codes that would be great. Here is my code: var SteamCommunity = require('steamcommunity'); var ReadLine = require('readline'); var fs = require('fs'); var SteamID = require("steamid"); var banshee = 'steamid64'; var comments = ['a', 'b', 'c', 'd', 'e']; var rand = Math.floor(Math.random() * comments.length); var concat = comments[rand]; var community = new SteamCommunity(); var steamID = new SteamID(banshee); var rl = ReadLine.createInterface({ "input": process.stdin, "output": process.stdout }); rl.question("Username: ", function(accountName) { rl.question("Password: ", function(password) { doLogin(accountName, password); }); }); function doLogin(accountName, password, authCode, captcha) { community.login({ "accountName": accountName, "password": password, "authCode": authCode, "captcha": captcha }, function(err, sessionID, cookies, steamguard) { if(err) { if(err.message == 'SteamGuard') { console.log("An email has been sent to your address at " + err.emaildomain); rl.question("Steam Guard Code: ", function(code) { doLogin(accountName, password, code); }); return; } if(err.message == 'CAPTCHA') { console.log(err.captchaurl); rl.question("CAPTCHA: ", function(captchaInput) { doLogin(accountName, password, null, captchaInput); }); return; } console.log(err); process.exit(); return; } console.log("Logged on!"); community.getSteamUser(steamID, function(err, user) { if(err) console.log(err); else { user.comment(concat, function(err) { if(err) console.log(err); }); console.log("Comment posted!"); setTimeout(function() { process.exit(); }, 2000); } }); }); }
  21. Title, I am trying to use steam-user with csgo, https://github.com/joshuaferrara/node-csgo.
  22. I am trying to provide a tool that allows the app to login a user, find if a game in the user's library is installed locally or not, and find the location of that installation. It is not real clear to me how to go about doing this or even how to get the information about a particular app in general using the steam node based apis. Can anybody help?
  23. Hello Guys, so I started my own Jackpotsite some Days ago, it works but it doesnt works as good as I want it to. Ill try to explain my problem to you guys: The Trading Bot wont accept all offers that are incoming, mostly it does, but sometimes a offer gets "stuck" and another guy has to deposit to get it into the Pot. I think thats because some offers are loading bugged from steam and when the Bot gets another offer all incoming offers are reloading and the bugged offer can be accepted then. So I guess to fix it I need a new part in the bots script which forces the bot to reload all the incoming offers every few seconds. But I suck at scripting so I want to ask you Guys for Help. I am using the bot from CSGoNetwork 1,4 but I think its the same Bot as in 1,31 Link to the sell.js: ->> pastebin.com/acVEc8R4 Im very thankfull for your help in advance. Sry for my bad english If you need any other information feel free to ask PS: please dont tell me that my site wont make it anyway or that valve will shut it down. Im here for coding help.
  24. Hello, im using this code to check the status of my sent offer ! can you help ? manager.getOffer({id:'1413390722'}, function(err, offer){ if(err){throw err;} console.log(offer); }); i get this as err : Error: No API-Key set (yet) at TradeOfferManager._apiCall.callback [as _apiCall] (C:\Bot\node_modules\st eam-tradeoffer-manager\lib\webapi.js:9:12) at TradeOfferManager.getOffer.callback._apiCall [as getOffer] (C:\Bot\node_m odules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:31:7) at SteamUser.<anonymous> (C:\Bot\all.js:124:13) at emitTwo (events.js:87:13) at SteamUser.emit (events.js:172:7) at IncomingMessage.<anonymous> (C:\Bot\node_modules\steam-user\components\we b.js:73:9) at emitOne (events.js:77:13) at IncomingMessage.emit (events.js:169:7) at IncomingMessage.Readable.read (_stream_readable.js:368:10) at flow (_stream_readable.js:759:26)
  25. How to get wear of sticker on a weapon? I found it on this page API GetPlayerItems... But this page does not work very often. Is there a way to get the other way?
×
×
  • Create New...