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. I have some issues where i cant access my sent offers to cancel them is there anyway to get the list of pending sent offers and cancel them?
  2. Hi, I have 2 things I'm not quite sure about: 1) Currently I use getUserInventoryContents(appid,contextid...etc) to load user's inventory as well as mine. Is it possible to select items from 2 different games in the same trade offer? For example: Their items in trade window will have both CSGO + Steam inventory items 2) How do I go about adding a certain amount of Steam Gems from user's / bot's inventory? I read this article: https://dev.doctormckay.com/topic/332-identifying-steam-items/ and know what asseid,contextid stands for, but I just can't figure out how to find a specific item in an inventory and select Steam gems for example Any help is appreciated!
  3. Hi, I want my bot to comment on the user's profile upon a successful trade. I tried looking for it here: https://github.com/DoctorMcKay/node-steam-user#events- But I dont find it anywhere! Thanks!
  4. I created a donation bot for a community and one of the users is unable to donate to the community's bot because the bot thinks that it has a bundle of trade offers with the user. What can I do to fix this issue? { Error: You have sent too many trade offers, or have too many outstanding trade offers with Jumpman652. Please cancel some before sending more. at Object.exports.makeAnError (/var/www/donationbot/node_modules/steam-tradeoffer-manager/lib/helpers.js:17:12) at SteamCommunity.manager._community.httpRequestPost (/var/www/donationbot/node_modules/steam-tradeoffer-manager/lib/classes/TradeOffer.js:349:12) at Request._callback (/var/www/donationbot/node_modules/steamcommunity/components/http.js:67:15) at Request.self.callback (/var/www/donationbot/node_modules/request/request.js:186:22) at Request.emit (events.js:159:13) at Request.<anonymous> (/var/www/donationbot/node_modules/request/request.js:1163:10) at Request.emit (events.js:159:13) at IncomingMessage.<anonymous> (/var/www/donationbot/node_modules/request/request.js:1085:12) at Object.onceWrapper (events.js:254:19) at IncomingMessage.emit (events.js:164:20) at endReadableNT (_stream_readable.js:1054:12) at _combinedTickCallback (internal/process/next_tick.js:138:11) at process._tickDomainCallback (internal/process/next_tick.js:218:9) cause: 'OfferLimitExceeded', eresult: 25 }
  5. I am trying to get my CS:GO inventory with getInventoryContents(appid, contextid, tradableOnly, callback). My full code is: "use strict"; const SteamUser = require('steam-user'); const SteamTotp = require('steam-totp'); const SteamCommunity = require('steamcommunity'); const TradeOfferManager = require('steam-tradeoffer-manager'); const client = new SteamUser(); const community = new SteamCommunity(); const manager = new TradeOfferManager({ steam: client, community: community, language: 'en' }); var steamLogOn = { accountName: 'FancyUsername', password: 'VerySecurePassword', twoFactorCode: SteamTotp.generateAuthCode('Shared_Secret') }; client.logOn(steamLogOn); client.on('loggedOn', () => { console.log('[Steam] Logged in'); }); client.on('webSession', (sessionid, cookies) => { manager.setCookies(cookies); community.setCookies(cookies); }); manager.getInventoryContents(730, 2, true, (err, inventory) => { if (err) { throw err; } else { console.log(inventory); } }); The error i get is: /var/www/bot/node_modules/steamcommunity/components/users.js:374 "uri": "https://steamcommunity.com/inventory/" + userID.getSteamID64() + "/" + appID + "/" + contextID, ^ TypeError: Cannot read property 'getSteamID64' of null at get (/var/www/bot/node_modules/steamcommunity/components/users.js:374:60) at SteamCommunity.getUserInventoryContents (/var/www/bot/node_modules/steamcommunity/components/users.js:370:2) at TradeOfferManager.getUserInventoryContents (/var/www/bot/node_modules/steam-tradeoffer-manager/lib/index.js:293:18) at TradeOfferManager.getInventoryContents (/var/www/bot/node_modules/steam-tradeoffer-manager/lib/index.js:281:7) at Object.<anonymous> (/var/www/bot/test.js:34:9) at Module._compile (module.js:660:30) at Object.Module._extensions..js (module.js:671:10) at Module.load (module.js:573:32) at tryModuleLoad (module.js:513:12) at Function.Module._load (module.js:505:3)
  6. Imagine bot go offline after tradeoffer sent. User will accept offer and presumes that he will get some codes into chat. But whoops bot went offline right before user accepted offer. Bot starts 1 minute later and he dont know about any accepted offer when he was offline. How to solve this?
  7. Hello guys! I want to receive percentage of wear on a skin. http://api.steampowered.com/IEconItems_730/GetPlayerItems/v0001/?key=KEYHERE&SteamID=IDHERE This API doesn't work. If someone knows something I will be very grateful. Thank you!
  8. When i send a few trades to my bot one of them can be confirmed by mobile and displayed in send trades list, but not listed in bot incom trades. Probably its a steam issue, but maybe this is somehow connected with poll frequency.(Poll time 10s). And this bugged trade will only appear if i send one more trade. Sender acc Bot acc in same time
  9. Hey there! I've just done a queue that sends trade offers in my bot. Since I have an option to set a rate limiter for this queue (N jobs processed in X seconds), I ask if anybody knows what are the current steam's limit on sending trades? Thanks regardless and sorry if I posted in a wrong forum.
  10. Hello guys. I've got a problem which i cant decide by myself.. First problem was that my bot was going offline with no reason, but i decided it And now i got the second problem: After few hours (sometimes days) bot asking for steam guard code. In console it looks like: "Steam Guard Code:". Guys, need your help Thanks. Code: const config = require("./config.js"); const Config = require('config-js'); const SteamUser = require('steam-user'); const SteamTotp = require('steam-totp'); const SteamCommunity = require('steamcommunity'); const TradeofferManager = require('steam-tradeoffer-manager'); const client = new SteamUser(); const community = new SteamCommunity(); const manager = new TradeofferManager({ steam: client, community: community, language: 'en' // Может быть любой язык }); // Log in to account with config.js const logOnOptions = { "accountName": config.steam.username, "password": config.steam.password, "twoFactorCode": SteamTotp.generateAuthCode(config.steam.twoFactorCode) }; client.logOn(logOnOptions); // After success login client.on('loggedOn', () => { console.log('Bot succesfully authorized!'); client.setPersona(SteamUser.Steam.EPersonaState.Online, config.steam.botname); console.log('Bot status changed to "Online"'); }); // Thats how i solve problem with going offline community.on('sessionExpired', function(err) { if (err) { console.log('sessionExpired: '+err); } community.stopConfirmationChecker(); if (client.steamID) { client.webLogOn(); } else { client.logOn(logOnOptions); } }); // Thats my way to solve second problem, but it didnt help. client.on("steamGuard", function(domain, callback, lastCodeWrong) { if(lastCodeWrong) { console.log("Last code wrong, try again!"); setTimeout(function() { callback(SteamTotp.getAuthCode(config.steam.twoFactorCode)); }, 30000); } });
  11. Hi, my name is Thanh. Did anybody find the same problems as mine : - I'm using expressjs to run my bot service. - There's a big problem when running the service that the server's memory is increased each time when the bot RECEIVE the items and it is not decreased. So when the memory reach up to 1.4Gbs or a little bit more, the service crashed (Turn Off). - Especially the memory is not increased a lot when SENDING items. How can i solve this problems? Any advice is good for me. Thank you for your time.
  12. I have been working on a tradelog code and i need to get the (offer) from the trade when it processes the trade i dont know the correct way to export the offer from manager.on('newOffer', (offer) => { processOffer(offer); });
  13. Could some assist me in disabling my bot's session from ever timing out?
  14. hi i need to get all active sent offers manager.on('offerList', function(ActiveOnly,sent,received) { resp.send(sent); }); bot this get all sent items
  15. getExchangeDetails wouldnt work because my trade apparently didn't have a tradeID set. I couldn't find tradeID being set anywhere in TradeOffer.js's code, and it probably isn't meant to be TradeOffer.id either because that's also being checked for. Any ideas?
  16. Their descriptions say that Steam uses the larger value between you and the other user - would this mean that if either the bot or the trade partner have a trade cooldown that both of the escrowDays values will be the same amount?
  17. Hello! I'm trying to send automatic offers. I have two functions for doing this: One for the ones I want to send and other to send counter offers. The first one works perfect (Thanks again for helping me with that), then I decided to copy-paste that for the second and change it a little. But here's what is strange: the couner function can send offers, but can't confirm them because the offer id is always null. Here are the 2 offers objects: TradeOffer { partner: censored, id: '2192436500', message: 'Here's your trade', state: 9, itemsToGive: [ ... ], itemsToReceive: [ ... ], isOurOffer: true, created: 2018-01-21T11:03:44.021Z, updated: 2018-01-21T11:03:44.021Z, expires: 2018-02-04T11:03:44.021Z, tradeID: null, fromRealTimeTrade: false, confirmationMethod: 2, escrowEnds: null, rawJson: '' } And this is the wrong one: TradeOffer { partner: censored, id: null, message: 'That was not the correct price. Here's what I wanted.', state: 1, itemsToGive: [ ... ], itemsToReceive: [ ... ], isOurOffer: true, created: null, updated: null, expires: null, tradeID: null, fromRealTimeTrade: false, confirmationMethod: null, escrowEnds: null, rawJson: '' } Here is the working one: var offer = manager.createOffer(item.trade_route); offer.addMyItems(items_to_send); offer.addTheirItem({"appid": 440, "contextid": 2, "assetid": item.currentID}); offer.setMessage("Here's your trade"); offer.send(function(err, status) { if (err) { console.log(err); return; } console.log(offer); //here's the one I posted above if (status == 'pending') { console.log(`Offer #${offer.id} sent, but requires confirmation`); setTimeout( function(){ community.acceptConfirmationForObject(key, offer.id, function(err) { if (err) { console.log(err); } else { console.log("Offer " + offer.id +" confirmed"); } }); }, 2000 ); } else { console.log(`Offer #${offer.id} sent successfully`); } }); Here's the worng one (counter offer): var offer = manager.createOffer(trade_url); manager.loadUserInventory(user_id, 440, 2, false, function (err, inventory, currencies) { if ('code for validating other things') { offer.addMyItem(...); offer.addTheirItems(items_to_send); offer.setMessage("That was not the correct price. Here's what I wanted."); offer.send(function (err, status) { if (err) { console.log(err); } if (status == 'pending') { console.log(offer) // Here's the one I posted above setTimeout(function () { community.acceptConfirmationForObject(key, offer.id, function (err) { if (err) { console.log(err); } else { console.log("Offer " + offer.id + " confirmed"); } }); }, 4000); } else { console.log(`Offer #${offer.id} sent successfully`); } }); } else { console.log("Validation failed") ... non related code } }); }); Why the second one can't have the offer.id? Any kinf of help would be aprreciated Note: I had to remove the non-related code and coments... sorry if you test it and fails.
  18. Hello, I was reading over the documentation for both node-steamcommunity and node-steam-tradeoffer-manager. According to the steam community documentation community, polling is deprecated and may be removed. In the tradeoffer-manager documentation you use polling there. Are these two different types of polling? Would I be able to continue to use tradeoffer-manager polling or should I move over to "acceptAllConfirmations" from the community module?
  19. Here is my code: function sendWithdrawTrade(partner, assetid, callback) { var itemsLength =''; connection.query(`SELECT COUNT(*) AS count FROM trade WHERE tradeurl = '${partner}' `, function(err, rows){ var itemsLength = rows[0].count; console.log(rows[0].count + ' items'); setValue(rows[0].count); }); function setValue(value) { itemsLength = value; } const offer = manager.createOffer(partner); manager.getInventoryContents(730, 2, true, (err, inv) => { if (err) { console.log(err); } else { console.log(itemsLength + ' - items length'); for (var i = 0; i < itemsLength; i++){ var parten = `${partner}`; var items = ""; var loop = [i+1]; console.log(loop); connection.query("SELECT itemid FROM trade WHERE tradeurl = '" + partner + "' AND id = '" + loop + "' ", function(err, rows){ if (err) throw err; for (var i = 0; i < rows.length; i++) { var result = rows[i]; var items = result.itemid; setValue2(items); console.log(items); } }); function setValue2(value) { items = value; } //offer.addMyItem({"appid": 730,"contextid": 2,"assetid": items}); } offer.send((err, status) => { if (err) { console.log(err); } else { console.log(`Sent offer. Status: ${status}.`); } }); }; }); } And thats what I get in console: (node:7284) [DEP0013] DeprecationWarning: Calling an asynchronous function without callback is deprecated. 2 items Got API key: *myapikey* 2 - items length [ 1 ] [ 2 ] Error: Cannot send an empty trade offer at TradeOffer.send (C:\OSPanel\domains\qw.qw\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:282:23) at manager.getInventoryContents (C:\OSPanel\domains\qw.qw\bot.js:179:10) at SteamCommunity.<anonymous> (C:\OSPanel\domains\qw.qw\node_modules\steamcommunity\components\users.js:442:5) at Request._callback (C:\OSPanel\domains\qw.qw\node_modules\steamcommunity\components\http.js:67:15) at Request.self.callback (C:\OSPanel\domains\qw.qw\node_modules\request\request.js:186:22) at emitTwo (events.js:126:13) at Request.emit (events.js:214:7) at Request.<anonymous> (C:\OSPanel\domains\qw.qw\node_modules\request\request.js:1163:10) at emitOne (events.js:116:13) at Request.emit (events.js:211:7) 13335825558 13346525760 I dont understand two things: 1) Why trade send before the "console.log(items);" ? 2) After for loop variable items is empty. How to get this variable from that loop?
  20. Hi, I need to know, how to send in offer items that user selected on website. I found only code that selects all items: for(i=0; i<itemsArray.length; i++){ const item = theirInv.find((item) => item.assetid ==''+itemsArray[i]); console.log("got item number" + i); offer.addTheirItem(item); } Also I don't understand how to make a webpage where user can select items for trade. User just need to click on his (or bot's) items, then press button for trade. Then somehow nodejs bot must to get trade url, items ids and start trade function. I know that I probably need to use ajax and curl, but just don't understand HOW Thanks
  21. Within the past few days, a number of my trading bots have failed to accept mobile confirmations for any of their trades. After some investigating, Jessecar96's SDA reveals a relatively blank screen on the confirmations window (left in attached SS), in contrast to the textually definitive "Nothing to confirm..." (right in attached SS) Trades are able to be sent, received and accepted, however any trades involving items leaving the accounts' inventories, will be left in a ceaseless state of awaiting confirmation. Accounts started receiving this 'Steam Mobile Authentication Blacklist' status a few days ago, when the bots were attempting to confirm multiple large trade offers at once (3x 25,000 item offers). Today, my primary trading bot became blacklisted when attempting to confirm many smaller offers simultaneously. I suspect that Valve implemented a new sensitive rate limiter to users/bots attempting to authenticate their trades. For now, I'm still able to trade perfectly fine on other accounts connected to the same phone number. Clarification on the restricted authentication process would be helpful, or a workaround that won't trigger Valve's discrete blacklisting services. A substantial quantity of items are now locked on these blacklisted accounts. Thanks for you help
  22. I'm using the following code but the 'newOffer' event is never being called and according to the docs this only works if polling is enabled, which should be. What am I doing wrong? var steamuser = require('steam-user'); var steamtotp = require('steam-totp'); var trademanager = require('steam-tradeoffer-manager'); var SteamCommunity = require('steamcommunity'); var data = [ { username:'', password:'', shasec:'/XqviM=', shacon:'++3t4fpJI=' }, { username:'', password:'', shasec:'=', shacon:'+P+kKyvfYk=' } ]; var client = []; var manager = []; var community = []; var initializeClients = function(data) { for (var index in data) { initializeClient(index); }; }; var initializeClient = function(index) { var account = data[index]; community[index] = new SteamCommunity(); client[index] = new steamuser(); manager[index] = new trademanager({ "steam": client[index], "community": community[index], "language": "en" }); console.log('[Account] [', account.username,'] is logging on'); client[index].logOn({ 'accountName': account.username, 'password': account.password, 'twoFactorCode': steamtotp.generateAuthCode(account.shasec) }); client[index].on('loggedOn', function() { console.log('[Account] Success!'); }); client[index].on('webSession', (sessionid, cookies) => { manager[index].setCookies(cookies, function(err){ console.log('API Key retrieved'); }); community[index].setCookies(cookies); community[index].startConfirmationChecker(15000, account.shacon); console.log('webSession ID: ' + sessionid); }); client[index].on('newOffer', function(offer, oldState) { console.log('[Account] [', account.username,'] has a newly received offer!'); }); }; initializeClients(data); Edit: I removed the second setCookies as it was not needed, also added an error check on setCookies but it does not throw any errors.
  23. How to use skipStateUpdate? Can you give one example from "offer.accept" to "offer.skipStateUpdate" please?
  24. Hello, How could I cancel outgoing offers within 5 minutes, and incoming overs in 90 seconds? I know how the sent offers cancel time work but I want them to be different. How can I do this? Thanks.
  25. I am having a weird issue with large offers (100+ keys). It seems that Steam takes progressively longer time to accept or confirm an offer. For example, 4 keys take 3 seconds to confirm, 50 keys take 20 seconds, and 100+ just times out after 30 seconds. If the bot receives keys, the time delay happens in 'https://steamcommunity.com/tradeoffer/offerid/accept'and returns error 500 after 30 seconds. When the bot gives keys, the time delay happens in Community.respondToConfirmation() https://steamcommunity.com/mobileconf/ajaxop and returns "success: false" after 30 seconds. What's even weirder is that the next request to fetch active offers is also delayed by about 20 seconds or times out with error 500 too. This doesn't seem like a rate limit issue, as I added generous delays between requests, for example confirming only after 4 seconds. And the delay also clearly depends on the number of items in the offer. confrimationChecker is not active, and all requests are processed strictly sequentially. Anyone experienced such an issue? What could be the problem here? Any ideas?
×
×
  • Create New...