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. Helloes people and Dr. McKay, Calling loadUserInventory with an instance of TradeOfferManager throws this error (running on a nodejs vs 4 cartridge at openshift): This error appears when I both instantiate tradeoffer-manager and login with another instance of steam-user, although the same error is shown when I use steamcommunity (although I guess slightly different so that the references to SteamUser are references to SteamCommunity?)...wait what? Here is the related code; var SteamUser = require('steam-user'); var SteamTotp = require('steam-totp'); var TradeOfferManager = require('steam-tradeoffer-manager'); var SU = new SteamUser(); var offers = new TradeOfferManager({ steam: SU, domain: config.domain, language: "en", pollInterval: 10000, cancelTime: 300000 }); SteamTotp.getAuthCode(my_shared_secret, function(err, code) { if (err) logger.debug(err.message); logger.debug(code); SU.logOn({ "accountName": config.username, "password": config.password, "twoFactorCode": code }); }); SU.on('loggedOn', function (details) { logger.debug("Login successful as: " + SU.steamID.getSteam3RenderedID()); offers.loadUserInventory(my_steamID64, 570, true, function(inventory) { logger.debug(inventory);}); }); (again, same happens if I use node-steamcommunity and try to call loadUserInventory from it's own login function's callback.) I have been able to enable two-factor authentication and login with steam-totp ever since, so I've no idea where the problem could lie anymore. Any ideas? Many thanks regardless.
  2. I am having an issue with the recieved trades, here is the log: 2016-08-28T21:20:18.417Z - info: -------------------------------------------------------------------- 2016-08-28T21:20:18.418Z - info: [bOT] New offer #1483101417 from STEAMID64: 765611981081644772016-08-28T21:20:18.455Z - info: [bOT] Partner: 76561198108164477 has a balance of: 0$.2016-08-28T21:20:18.456Z - info: MAG-7 | Metallic DDPAT (Factory New)2016-08-28T21:20:18.457Z - info: Sawed-Off | Yorick (Minimal Wear)2016-08-28T21:20:18.457Z - info: Falchion Case2016-08-28T21:20:18.458Z - info: Operation Breakout Weapon Case2016-08-28T21:20:18.504Z - info: 0.042016-08-28T21:20:18.504Z - info: [bOT] [D] The trade costs: 0.042016-08-28T21:20:18.541Z - info: 0.152016-08-28T21:20:18.541Z - info: [bOT] [D] The trade costs: 0.192016-08-28T21:20:18.583Z - info: 0.032016-08-28T21:20:18.583Z - info: [bOT] [D] The trade costs: 0.222016-08-28T21:20:18.620Z - info: 0.032016-08-28T21:20:18.620Z - info: [bOT] [D] The trade costs: 0.252016-08-28T21:20:18.706Z - info: [bOT] [D] User STEAMID64: 76561198108164477 offered a deposit trade. Look for everything is ok with the trade.2016-08-28T21:20:22.452Z - error: [bOT] [D] Unable to accept offer 1483101417: Cannot load new trade data: Data temporarily unavailable2016-08-28T21:20:22.672Z - info: --------------------------------------------------------------------Whats that?When this happens if its a deposit it doesnt send data to the mysql db so the player doesnt get the money on their balance but the trade is accepted...
  3. Hello guys, im currently getting TradingPartners Inventory from Steams Json Api like this: http://steamcommunity.com/profiles/STEAMID/inventory/json/730/2 In gernal, there seems to be no AssetId which i need to add the Item to the trade offer. Some items contain the assetID in the "view Ingame" link so i could parse it. It looks like that: steam://rungame/730/SteamID/+csgo_econ_action_preview%20S%owner_steamid%A%assetid%D7116476999790771279 So there is a assetId i could use but im not even sure if its the real Items Asset Id of my TradePartners Inventory or just from an Steam CSGO Item to display it. Anyways, for Items like CSGO Cases, there is not even a a link which contains a assetId. How should i provide the Item Informations which TradeOffersManager need? Is there acually any way to use this Steam Api for the trades? Thanks!
  4. 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?
  5. 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.
  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. 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)
  8. 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.
  9. 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?
  10. 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
  11. 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
  12. 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
  13. I have an error accepting trade offer: Unable to accept offer: There was an error accepting this trade offer. Please try again later. (42)
  14. 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}`); } }); });
  15. 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.
  16. 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)
  17. http://pastebin.com/sDi8gSc0 This is my code right now, when I send trades with only my items/my items added it says An error occured whilst sending trade offer: Error: HTTP error 401 but when I send a trade offer where I don't add any of my items (only their items) it works fine, so may I ask how do I stop this error? Here's my code for sending a trade with my items if(type == "withdraw") { offer.setMessage("By acceppting this offer you will lose " + value + " Gems"); for (var a = 0; a < itemsToGive.length; a++) { offer.addMyItem({"assetid": itemsToGive[a], "appid": 730, "contextid":2}); console.log(itemsToGive[a]); } } offer.send(function(err, status) { if (err) { console.log("An error occured whilst sending trade offer: " + err); } if(status == "pending") { console.log("Trade offer Pending. Offer #" + offer.id + " Regardless, adding to database with the offer state: 9"); tradeData = { tradeofferid: offer.id, steamid: partner, type: type, amount: value, paid: 0, offerState: 9 }; connection.query('INSERT INTO csgotrades SET ?', tradeData); } if (status == "sent") { console.log("Trade offer succesfully sent. Offer #" + offer.id); tradeData = { tradeofferid: offer.id, steamid: partner, type: type, amount: value, paid: 0, offerState: offer.state }; connection.query('INSERT INTO csgotrades SET ?', tradeData); } }); I can send trades with their items fine but with mine I just get the error if(type == "withdraw") { offer.setMessage("By acceppting this offer you will lose " + value + " Gems"); for (var a = 0; a < itemsToGive.length; a++) { offer.addMyItem({"assetid": itemsToGive[a], "appid": 730, "contextid":2}); console.log(itemsToGive[a]); } }
  18. Hello ! How should i properly handle this error ? I wrapped offer.accept into Promise and when i catch error then i get errCode and if errCode === 28 what way to re-accept this offer properly ? should i return false and then try to accept offer again ? or update somehow ?
  19. Hi! I'm trying to send an offer from one account to another. I'm relative new to programming. Here is the code: var TradeOfferManager = require('steam-tradeoffer-manager'); var SteamID = TradeOfferManager.SteamID; var sid = new SteamID('[MY_STEAM_ID]'); sid.type = SteamID.Type.INDIVIDUAL; sid.instance = SteamID.Instance.DESKTOP; var SteamCommunity = require('steamcommunity'); var SteamTotp = require('steam-totp'); var SteamUser = require('steam-user'); var client = new SteamUser(); var community = new SteamCommunity(); var manager = new TradeOfferManager({ "steam": client, "domain": "MY_DOMAIN", "language": "en" }); // Steam logon options var logOnOptions = { "accountName": "MY_STEAM_USERNAME", "password": "MY_STEAM_PASSWORD", }; client.logOn(logOnOptions); client.on('loggedOn', function() { console.log("Logged into Steam as " + client.steamID.getSteam3RenderedID()); }); // Send offer var offer = manager.createOffer("https://steamcommunity.com/tradeoffer/new/?partner=MY_STEAM_PARTNER&token=MY_STEAM_TOKEN"); manager.loadUserInventory(sid, 730, 2, true, function(err, myItems) { if(err) { console.error(err); return; } console.log(myItems[3]); offer.addMyItem(myItems[3]); offer.setToken("MY_STEAM_TOKEN"); offer.setMessage("Transferring my stuff"); offer.send(function(err) { console.log(err); }); });The output is the following: Logged into Steam as [U:1:MY_STEAM_ID] CEconItem { id: '6763577968', classid: '310778073', instanceid: '302028390', amount: 1, pos: 3, assetid: '6763577968', contextid: '2', appid: '730', icon_url: '-9a81dlWLwJ2UUGcVs_nsVtzdOEdtWwKGZZLQHTxDZ7I56KU0Zwwo4NUX4oFJZEHLbXH5ApeO4YmlhxYQknCRvCo04DEVlxkKgpovrG1eVcwg8zAaAJF_t24nZSOqPrxN7LEmyUB6pwl2r2U84-h2VG1-hA6MWimJ4GRIAU2NAmC-QLvkLjsjJftup3L1zI97T2fu0Hu', icon_url_large: '-9a81dlWLwJ2UUGcVs_nsVtzdOEdtWwKGZZLQHTxDZ7I56KU0Zwwo4NUX4oFJZEHLbXH5ApeO4YmlhxYQknCRvCo04DEVlxkKgpovrG1eVcwg8zAaAJF_t24nZSOqPrxN7LEm1Rd6dd2j6eR99Wh2ADhrRBoYjyiJdXDIAdrYl_UqFK2lL-9hsXt7cvKwHMyvCAg-z-DyIQOpr_N', icon_drag_url: '', name: 'P2000 | Granite Marbleized', market_hash_name: 'P2000 | Granite Marbleized (Field-Tested)', market_name: 'P2000 | Granite Marbleized (Field-Tested)', name_color: 'D2D2D2', background_color: '', type: 'Industrial Grade Pistol', tradable: true, marketable: true, commodity: false, market_tradable_restriction: 7, descriptions: [ { type: 'html', value: 'Exterior: Field-Tested' }, { type: 'html', value: ' ' }, { type: 'html', value: 'Accurate and controllable, the German-made P2000 is a serviceable first-round pistol that works best against unarmored opponents. It has been painted in a marbleized pattern.' }, { type: 'html', value: ' ' }, { type: 'html', value: 'The Italy Collection', color: '9da1a9', app_data: [Object] }, { type: 'html', value: ' ' } ], actions: [ { name: 'Inspect in Game...', link: 'steam://rungame/730/76561202255233023/+csgo_econ_action_preview%20S%owner_steamid%A%assetid%D14285500353088769102' } ], market_actions: [ { name: 'Inspect in Game...', link: 'steam://rungame/730/76561202255233023/+csgo_econ_action_preview%20M%listingid%A%assetid%D14285500353088769102' } ], tags: [ { internal_name: 'CSGO_Type_Pistol', name: 'Pistol', category: 'Type', category_name: 'Type' }, { internal_name: 'weapon_hkp2000', name: 'P2000', category: 'Weapon', category_name: 'Weapon' }, { internal_name: 'set_italy', name: 'The Italy Collection', category: 'ItemSet', category_name: 'Collection' }, { internal_name: 'normal', name: 'Normal', category: 'Quality', category_name: 'Category' }, { internal_name: 'Rarity_Uncommon_Weapon', name: 'Industrial Grade', category: 'Rarity', color: '5e98d9', category_name: 'Quality' }, { internal_name: 'WearCategory2', name: 'Field-Tested', category: 'Exterior', category_name: 'Exterior' } ], is_currency: false, market_marketable_restriction: 0, fraudwarnings: [] } Error: HTTP error 401 at SteamCommunity.manager._community.httpRequestPost (/srv/SteamTrade/node_modules/steam-tradeoffer-manager/lib/classes/TradeOffer.js:477:31) at Request._callback (/srv/SteamTrade/node_modules/steamcommunity/components/http.js:62:14) at Request.self.callback (/srv/SteamTrade/node_modules/request/request.js:187:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (/srv/SteamTrade/node_modules/request/request.js:1044:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (/srv/SteamTrade/node_modules/request/request.js:965:12) at emitNone (events.js:91:20)I couldn't get steam-totp to work (getAuthCode() that is), could this be the issue - that the account isn't logged in correctly? Why I suspect this might be the issue is because manager.loadInventory(730, 2, true, function(err, myItems)didn't work, while manager.loadUserInventory(sid, 730, 2, true, function(err, myItems)works. If not, what else could be the issue? Thankful for answers, Andreas
  20. Here's a bit of my code, which works I've removed the callback as it didn't need to be there, so I can check when an offer is pending confirmation, then it gets added to the database, but when it gets added if for some reason the bot doesn't auto acceppt it (I have .checkconfirmations on but still if there's an error) so this code wouldn't be the best, so how would I check upon when the bot confirms a trade? Here's the little bit of code offer.Send(callback etc { if(status == "pending") { console.log("Trade offer Pending. Offer #" + offer.id + " Regardless, adding to database with the offer state: 9"); tradeData = { tradeofferid: offer.id, steamid: partner, type: type, amount: value, paid: 0, offerState: 7 }; connection.query('INSERT INTO csgotrades SET ?', tradeData); } });
  21. hello, im trying to make a steam trade bot (and im not so good with coding). i found this code to send trade offer but i don"t know how to add items var offer = manager.createOffer("https://steamcommunity.com/tradeoffer/new/?partner=0000000&token=xxxxxxx"); manager.loadInventory(730, 2, true, function(err, myItems) { if(err) { console.error(err); return; } offer.loadPartnerInventory(730, 2, function(err, theirItems) { if(err) { console.error(err); return; } offer.addMyItem(myItems[0]); offer.addTheirItem(theirItems[0]); offer.send(""); }); }); }); let's say i want to : send 2 items with id 6908727870 and id 6901768067 and recieve 2 items with id 847548541 and id 325415748 please just help me filling these ids in the code above to serve like an example for me. thank you so much
  22. After an exchange asset_id changes. But how opskins or bitskins gets new asset_id? By original_id (GetPlayerItems) or how? They need to know what exactly this thing from this man they got...
  23. I know that getReceivedItems working with accepted offers but what I need that get the Items in the sent trade offers "not in the received trade offers" after accepted. Can I do that?how?
×
×
  • Create New...