Drepic Posted March 15, 2017 Report Posted March 15, 2017 Hi, I currently am working a trading bot. I think it may pertinent that I am running multiple bots. However, I seem to receive the following error when the following code is called and the correct steam64id is the partner to the trade. manager.on('newOffer', function(offer) { console.log("New offer #" + offer.id + " from " + offer.partner.getSteam3RenderedID() + " To bot: " + index); if (offer.partner.getSteamID64() === 'ID IS HERE') { offer.accept((err, status) => { if (err) { console.log(err); } else { console.log(`Accepted offer. Status: ${status}.`); } }); }else{ offer.decline(); } }); I have tried re-sending the trade, but more often than not the error persists. Here is the specific stack trace: { Error: There was an error accepting this trade offer. Please try again later. (42) at Object.exports.makeAnError (D:\Save Locations\Documents\HTML and Web\CStrike.bet\Website\Steambot\node_modules\steam-tradeoffer-manager\lib\helpers.js:12:12) at SteamCommunity.manager._community.httpRequestPost (D:\Save Locations\Documents\HTML and Web\CStrike.bet\Website\Steambot\node_modules\steam-tradeoffer-manager\lib\classes\TradeOffer.js:649:13) at Request._callback (D:\Save Locations\Documents\HTML and Web\CStrike.bet\Website\Steambot\node_modules\steamcommunity\components\http.js:69:15) at Request.self.callback (D:\Save Locations\Documents\HTML and Web\CStrike.bet\Website\Steambot\node_modules\request\request.js:188:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (D:\Save Locations\Documents\HTML and Web\CStrike.bet\Website\Steambot\node_modules\request\request.js:1171:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (D:\Save Locations\Documents\HTML and Web\CStrike.bet\Website\Steambot\node_modules\request\request.js:1091:12) eresult: 42 } Thanks for the help. Quote
Dr. McKay Posted March 15, 2017 Report Posted March 15, 2017 42 = NoMatch Did you perhaps set the apiKey property manually? Quote
Drepic Posted March 15, 2017 Author Report Posted March 15, 2017 (edited) 42 = NoMatch Did you perhaps set the apiKey property manually?No, I just used the domain parameter. Also, while the two bots I'm testing have the same domain, they have different API keys. Neither of which are the API key associated with the domain I registered with steam. Edited March 15, 2017 by Drepic Quote
Drepic Posted March 16, 2017 Author Report Posted March 16, 2017 (edited) 42 = NoMatch Did you perhaps set the apiKey property manually? No, I just used the domain parameter. Also, while the two bots I'm testing have the same domain, they have different API keys. Neither of which are the API key associated with the domain I registered with steam. Actually, they are the correct apiKeys associated with the accounts. I haven't seen this problem anywhere else. I'm wondering if I'm doing anything wrong. Should I be using node-steam-tradeoffer-manager-2 (via npm) instead ? Edited March 16, 2017 by Drepic Quote
Drepic Posted March 16, 2017 Author Report Posted March 16, 2017 I believe I found the issue, for anyone else who stumbles upon this thread. I did not create an individual community instance for each bot instance, doing so resolved the issue I was having. Thanks for the help. Drepic 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.