Jump to content
McKay Development

Search the Community

Showing results for tags 'node-steam-tradeoffer-manager'.

  • 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. How to create multi-bot on the same ip address? When you run two accounts I get the error: "Can't check confirmations: HTTP error 429"How to fix it?
  2. At this point in my code, I just want to accept the offer, until its accepted for real. I'm aware that errors can happen, for example when steam is beeing slow or laggy. In this case I just wanna keep trying until the offer is either accepted or expired. offer.accept(true, function (err){ if(err){ while(offer.state!=3 || offer.state!=8){ offer.accept(); } } }); Could this work, how would it be done better?
  3. Hey, I've played around a little with the library you're offering us. However, my little application just gets stuck at some point, and I don't really get why. Code: manager.on('newOffer', function (offer) { var itemsToReceive = offer.itemsToReceive; var itemsToGive = offer.itemsToGive; if (itemsToGive.length >0) {} }else{ offer.accept(function (err) { if(err){ console.log("Unable to accept offer: "); } console.log("offer accepted "+itemsToReceive.length+" Keys received"); }); } } ); I'm loging in, setting cookie etc. following your examples. However this should accept any offer that it gets as long as its empty on my bots side. But after some time it just gets stuck and doesn't accept anymore. I can also press control + c in my terminal then, to exit the code where it got stuck at. And another question: How can I make a callback to do the offer.accept over and over again, until its done / gone? (steam has issues too often). Thank you for reading & thanks for your great work
  4. hi how can write steam trade offer manager i pay for this
  5. Lately, I've been having this error when i try to send a trade, but it doesnt happend always, only one or twice a day for example. Why does this happen? A piece of my code: var trade = offers.createOffer(steamid); trade.addTheirItems(pooluser); trade.setToken(token); trade.send(function (err, status){ if (err) { console.log(err); } else { console.log("Offer sent"); console.log(status); } });
  6. Hi all! How do i track 15 days delay to user trade offer? (if because of user current trade will be hold for 15 days)
  7. I have a code to obtain cookies: community.login({ ... login data ... }, function(err, sessionID, cookies, steamguard){ fs.writeFileSync("cookies.json", JSON.stringify(cookies)); }) (Sorry for this format of code, writing post from phone. And to be clear i am receiving any login error) Then i take cookies file and proceed to the main app. manager.setCookies(cookies, function(err){ if(err){ throw err; // getting Not Logged In } ... }); (manager object is being set at the start of the code) why manager.setCookies requires to be logged in, when i am providing valid cookies?
  8. PROBLEM (WATCH VIDEO): <iframe width="560" height="315" src="https://www.youtube.com/embed/c-5_hREIQPs" frameborder="0" allowfullscreen></iframe> Please help me guys
  9. Error: Cannot load new trade data: Data temporarily unavailable at update (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:677:14) at manager.getOffer (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:697:4) at _apiCall (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:49:4) at SteamCommunity._community.httpRequest (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\webapi.js:54:3) at Request._callback (C:\xampp\htdocs\js\node_modules\steamcommunity\components\http.js:67:15) at Request.self.callback (C:\xampp\htdocs\js\node_modules\request\request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (C:\xampp\htdocs\js\node_modules\request\request.js:1081:10) at emitOne (events.js:96:13) Can you tell me why this error comes and what it mean? or this { Error: There was an error sending your trade offer. Please try again later. (26) at Object.exports.makeAnError (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\helpers.js:10:12) at SteamCommunity.manager._community.httpRequestPost (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:507:12) at Request._callback (C:\xampp\htdocs\js\node_modules\steamcommunity\components\http.js:67:15) at Request.self.callback (C:\xampp\htdocs\js\node_modules\request\request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (C:\xampp\htdocs\js\node_modules\request\request.js:1081:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (C:\xampp\htdocs\js\node_modules\request\request.js:1001:12) eresult: 26 }
  10. When i sent item as gift steam need verify in steam mobile app. How steam bot can this ? Thanks !
  11. Hello. Sending a trade offer from bot is the last part before my site is ready but I can't get it work. var newOffer = manager.createOffer("https://steamcommunity.com/tradeoffer/new/?partner=240789497&token=ORC28YoI"); newOffer.addMyItems(currentGame); newOffer.send("You just won a bet", function(err, status) { console.log(newOffer); if(pending > 0) { handleOffers(); } }); C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\helpers.js:29 callback(error); ^ TypeError: callback is not a function at Object.exports.makeAnError (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\helpers.js:29:4) at SteamCommunity.manager._community.httpRequestPost (C:\xampp\htdocs\js\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:507:12) at Request._callback (C:\xampp\htdocs\js\node_modules\steamcommunity\components\http.js:67:15) at Request.self.callback (C:\xampp\htdocs\js\node_modules\request\request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (C:\xampp\htdocs\js\node_modules\request\request.js:1081:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (C:\xampp\htdocs\js\node_modules\request\request.js:1001:12)
  12. When my site has a > 150 people, then get this error when multiple all trades Code [36m[2017-01-07 15:42:04.768] [DEBUG] [default] - [39m{ Error: Busy at SteamCommunity._community.httpRequest (/bot/node_modules/steam-tradeoffer-manager/lib/webapi.js:43:16) at Request._callback (/bot/node_modules/steamcommunity/components/http.js:67:15) at Request.self.callback (/bot/node_modules/request/request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (/bot/node_modules/request/request.js:1081:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at Gunzip.<anonymous> (/bot/node_modules/request/request.js:1001:12) at Gunzip.g (events.js:291:16) eresult: '10' } And the second question: I can not understand why, even without a large load is constantly pops up an error connection timeout and HTTP 500: [36m[2017-01-07 15:36:03.946] [DEBUG] [default] - [39m{ Error: Timeout at SteamCommunity._community.httpRequest (/bot/node_modules/steam-tradeoffer-manager/lib/webapi.js:43:16) at Request._callback (/bot/node_modules/steamcommunity/components/http.js:67:15) at Request.self.callback (/bot/node_modules/request/request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (/bot/node_modules/request/request.js:1081:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at Gunzip.<anonymous> (/bot/node_modules/request/request.js:1001:12) at Gunzip.g (events.js:291:16) eresult: '16' } [36m[2017-01-07 15:35:18.625] [DEBUG] [default] - [39m{ Error: HTTP error 500 at SteamCommunity._checkHttpError (/bot/node_modules/steamcommunity/components/http.js:108:9) at Request._callback (/bot/node_modules/steamcommunity/components/http.js:50:61) at Request.self.callback (/bot/node_modules/request/request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (/bot/node_modules/request/request.js:1081:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (/bot/node_modules/request/request.js:1001:12) at IncomingMessage.g (events.js:291:16) code: 500 } At this point, "STEAM" is in excellent condition I will be very grateful to you for the answer. In advance, thank you very much! (Sorry for my bad english).
  13. Hello, im trying to get the history of trades of one account, but i allways got error, this is my code: offers.getOffers(2, function(err, sent, recived){ if (err) { console.log(err); process.exit(1); } else { console.log(sent); process.exit(1); } }); Is something wrong? And how i use data filter (historialCutof)?
  14. I have my site up and running and bots are working correctly the only issue i'm having is when the jackpot ends and the winner is selected the bot holds the items and asks for a mobile confirm before it will send.. Ive been reading around and can't find much help. Any idea on how to fix this? Thanks in advance.
  15. Hi I have little problem with errors (28 actually) (I know - 28 means already redeem). It always shutdown script Code console.log("acceptOffer"); if(again == 0) return; offer.accept(function(error, status) { if(error){ console.log("acceptOffer error"); console.log(error); return; } }); Console acceptOffer acceptOffer error { Error: There was an error accepting this trade offer. Please try again later. (28) at Object.exports.makeAnError (/root/app/node_modules/steam-tradeoffer-manager/lib/helpers.js:10:12) at SteamCommunity.manager._community.httpRequestPost (/root/app/node_modules/steam-tradeoffer-manager/lib/classes/TradeOffer.js:643:13) at Request._callback (/root/app/node_modules/steamcommunity/components/http.js:67:15) at Request.self.callback (/root/app/node_modules/request/request.js:186:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (/root/app/node_modules/request/request.js:1081:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (/root/app/node_modules/request/request.js:1001:12) eresult: 28 } And manager.on('receivedOfferChanged', function(offer, oldState) { console.log("receivedOfferChanged"); }); isn't called What I should do? Cheers
  16. Bot logged, sending me message, online, after 4-5 seconds it's stopping with error tradebot.js:181. Can it work on win10.14393?
  17. For some reason it's returning value as [object Object] Anyone know why?
  18. Hi. I have little problem with my code. It says "DeprecationWarning: Calling an asynchronous function without callback is deprecated." function SteamBot(name, autodecline) { var self = this; // all data this.accountData = data; console.log(data.steamid); this.steamid = data.steamid; this.login = data.name; this.password = data.password; this.shared = data.shared_secret; this.identity = data.identity_secret; this.autodecline = (typeof autodecline == 'undefined' ? true : autodecline); console.log(this.autodecline); this.cachedir = "private/bot/"; this.pollPath = this.cachedir + 'polldata.json'; this.loggedIn = false; this.gotApiKey = false; this.error = false; this.inventory = []; this.client = new SteamUser(); this.community = new SteamCommunity(); this.client.setOption('promptSteamGuardCode', false); var managerConfig = { steam : this.client, community : this.community, domain : "localhost", language : "en", // pollInterval : 3000, // cancelTime : 600000, // pendingCancelTime : 30000 }; this.client.on('loggedOn', () => { this.loggedIn = true; this.client.setPersona(SteamUser.EPersonaState.Online) }) this.manager = new TradeOfferManager(managerConfig); if (fs.existsSync(this.cachedir + 'polldata.json')) { this.manager.pollData = JSON.parse(fs.readFileSync(this.cachedir + 'polldata.json')); } this.manager.on('pollData', function(pollData) { console.log("pollData > " + self.cachedir); fs.writeFile(self.cachedir + 'polldata.json', JSON.stringify(pollData)); }); this.manager.on('newOffer', function(offer) { console.log("newOffer"); offer.decline(function(err) { if (err) { console.log("[SteamBotsHandler] BOT " + self.name + " unable to decline offer: " + err.message); } }); }); } Here is log... newOffer newOffer pollData > private/bots_cache/csgocloudbot2/ (node:24579) DeprecationWarning: Calling an asynchronous function without callback is deprecated. pollData > private/bots_cache/csgocloudbot2/ (node:24579) DeprecationWarning: Calling an asynchronous function without callback is deprecated. I have latest version of tradeoffer manager. What to do? Cheers
  19. When loading items from offer not all the items in one language and What is the problem and where did I go wrong? PS Happy new year)
  20. Hey, my tradeBot (only sometimes) crashes right after receiving an offer. I tried to fix it with a friend who is more into coding SteamBots than me, but we weren't able to figure out what is going wrong here. I want to keep the script more or less private since someone made it for me and he doesn't want me to share the full code for it, but this should be enough. Will provide more if needed! var config = require('./config.js'); var SteamUser = require('steam-user'); var client = new SteamUser(); var SteamCommunity = require("steamcommunity"); var community = new SteamCommunity(); var SteamTotp = require('steam-totp'); var mobilecode = SteamTotp.getAuthCode(config.sharedsecret); var TradeOfferManager = require('steam-tradeoffer-manager'); var manager = new TradeOfferManager({ "steam": client, "domain": "http://localhost", "language": "en", "cancelTime": "600000", // 10 minutes "pollInterval": "5000" }); var login = { accountName: config.username, password: config.password, twoFactorCode: mobilecode }; client.logOn(login); client.on('loggedOn', function(details) { client.getPersonas([client.steamID], function(personas) { console.log("============ Logged in ===============================") console.log('== Name: ' + personas[client.steamID]["player_name"]); console.log('== ID64: ' + client.steamID); console.log("======================================================"); console.log(""); }); console.log(); client.setPersona(1); // Shows the status as online. 0 = offline (It will still work though!) 1 = online setInterval(function() { client.webLogOn(); }, 1000 * 60); // Refreshes session every 10 minutes }); client.on('webSession', function(sessionID, cookies) { manager.setCookies(cookies, function(err) { if (err) { console.log("Couldn\'t set cookies! Error: " + err); } }); community.setCookies(cookies); community.startConfirmationChecker(10000, config.identitysecret); }); client.on('error', function(e) { console.log(e); process.exit(1); }); community.on("sessionExpired", function(err) { console.log("## Session Expired, relogging."); client.webLogOn(); }); manager.on('newOffer', function(offer) { // When a new offer is received do the stuff below offer.getUserDetails(function(err, me, them) { // Get errors, an object containing the escrow days left and the inventory of the bot and the partner console.log("============ New Offer ==============================="); console.log("== Partner: " + them.personaName); //This is where the error happened! console.log("============ My items ================================")The error is happening in line 78. (The second-last starting with console.log("== Partner: ...)) TypeError: Cannot read property 'personaName' of undefined at C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\index.js:78:43 at Object.exports.makeAnError (C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\node_modules\steam-tradeoffer-manager\lib\helpers.js:33:4) at C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:818:12 at SteamCommunity._checkTradeError (C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\node_modules\steamcommunity\components\http.js:145:3) at Request._callback (C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\node_modules\steamcommunity\components\http.js:52:80) at Request.self.callback (C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\node_modules\steamcommunity\node_modules\request\request.js:186:22) at emitTwo (events.js:87:13) at Request.emit (events.js:172:7) at Request.<anonymous> (C:\Users\Thomas\Desktop\Coding\Steam Trading\moneyBot\node_modules\steamcommunity\node_modules\request\request.js:1081:10) at emitOne (events.js:77:13) I feel like this error is really weird. Why would personaName be undefined right after receiving the trade? It also handles a lot of trades without any problems, but then suddenly crashes. steam-tradeoffer-manager is running on 2.5.0 and I also reinstalled all modules. Any help is appreciated!
  21. So i am building a steambot to interact with a website! Is there a specific variable in the item array that i could use to identify the item once the item is given to the bot? I heard that people use assetid but that it can change after making a trade. manager.on('sentOfferChanged', function(offer, oldState) { if(TradeOfferManager.ETradeOfferState[offer.state] == "Declined") { console.log("Declined"); } else if (TradeOfferManager.ETradeOfferState[offer.state] == "Active") { } else if (TradeOfferManager.ETradeOfferState[offer.state] == "Accepted") { offer.itemsToReceive.forEach(function(entry) { console.log(entry.id); }); } else { console.log("Changed?"); console.log(TradeOfferManager.ETradeOfferState[offer.state]); } }); Also, where does the bot get the item data from? I dont see assetid for the items in http://api.steampowered.com/IEconItems_440/GetPlayerItems/v0001/
  22. Hello. I have a bot which buying some items on side marketplace, and then marketplace bot sends offer to my bot with items. I want to save price of each item (price for each assetid). I know assetid in marketplacebot inventory, but when my bot accepting trade offer, assetid changes, and i cant get old assetid to compare it and save price. Any ideas of solution? ty
  23. have a question... 1. So i have made a donation bot. I can accept any incoming offers instantly i can do that fine. 2. (What i want to do but can't) I want to make the bot accept offers automatically if the items a user gives the bot is worth more than what they want. For example, i put 2 $1 skins up for trade with the bot and i want something from the bot which is $5 i want it to decline that, but say if i wanted an item that was $1.50 it would accept it. I can sort out the confirmations easily. Just the code for calculating the items and making the bot decide whether it is a good trade. Here is what i have! (trade code) client.on("tradeRequest", function(steamID, respond) { console.log("Incoming trade request from " + steamID.getSteam3RenderedID() + ", Accepting"); respond(true); }); client.on("tradeStarted", function(steamID){ steamTrade.open(steamID); }); steamTrade.on("ready", function(){ steamTrade.ready(function(){ steamTrade.confirm(); console.log("Trade Confirmed! New items in inventory!") }); })
  24. How to use proxy then bot login. I use multibot and to don't get a limit of users login from same ip , i need to use proxy every time then bot login.
  25. Hi. I got a problem like this and i don't know how to fix it. log.verbose("polldata.json is corrupt"); ^ ReferenceError: log is not defined at Object.<anonymous> (C:\Users\kingwang\Desktop\Trade Offer Bot\bot2.js:55:3) at Module._compile (module.js:409:26) at Object.Module._extensions..js (module.js:416:10) at Module.load (module.js:343:32) at Function.Module._load (module.js:300:12) at Function.Module.runMain (module.js:441:10) at startup (node.js:139:18) at node.js:974:3 And here is my code if(fs.existsSync(POLLDATA_FILENAME)) { try { manager.pollData = JSON.parse(fs.readFileSync(POLLDATA_FILENAME)); } catch(e) { log.verbose("polldata.json is corrupt"); } } manager.on('pollData', function(pollData) { fs.writeFile(POLLDATA_FILENAME, JSON.stringify(pollData)); }); var logger = new (Winston.Logger)({ transports: [ new (Winston.transports.Console)({ colorize: true, level: 'debug' }), new (Winston.transports.File)({ level: 'info', timestamp: true, filename: 'cratedump.log', json: false }) ] }); var client = new SteamUser(); var offers = new TradeOfferManager({ steam: client, domain: config2.domain, language: "en", pollInterval: 10000, cancelTime: 50000 }); fs.readFile('polldata.json', function (err, data) { if (err) { logger.warn('Error reading polldata.json. If this is the first run, this is expected behavior: '+err); } else { console.log('Welcome back my master.'.green); console.log("Found previous trade offer poll data. Importing it to keep things running smoothly.".info); offers.pollData = JSON.parse(data); } }); client.logOn({ accountName: config2.username, password: config2.password, }); client.on('loggedOn', function (details) { console.log(timestamp("[hh:mm:ss] Logged into Steam as " + config2.username.green)); // If you wanted to go in-game after logging in (for crafting or whatever), you can do the following client.gamesPlayed(440); }); client.on('webSession', function (sessionID, cookies) { console.log("Got web session".info); client.setPersona(1) offers.setCookies(cookies, function (err){ if (err) { logger.error('Unable to set trade offer cookies: '+err); process.exit(1); } logger.info("Trade offer cookies set."); manager.loadInventory(440, 2, true, function(err, inventory) { if (err) { console.log(err); return; } if (inventory.length == 0) { // Inventory empty console.log("TF2 inventory is empty"); return; } console.log("Found " + inventory.length + " TF2 items"); var ref = inventory.filter(function (item) { return item.name == 'Refined Metal' }); var rec = inventory.filter(function (item) { return item.name == 'Reclaimed Metal' }); var scrap = inventory.filter(function (item) { return item.name == 'Scrap Metal' }); console.log("Found " + ref.length + " Refined Metal"); console.log("Found " + rec.length + " Reclaimed Metal"); console.log("Found " + scrap.length + " Scrap Metal"); var inventory = inventory.filter(function (item) { return item.name == 'Refined Metal' }); var trade = offers.createOffer(admin); trade.addMyItems(inventory); trade.setMessage("Here, have some items!"); trade.send(function(err, status) { if (err) { console.log(err); } else { console.log("Success. Offer was sent to admin.") } }); }); }); }); Any ideas how to fix this problem? Also, my bot is working fine before
×
×
  • Create New...