Jump to content
McKay Development

Dr. McKay

Administrator
  • Posts

    3544
  • Joined

  • Last visited

Everything posted by Dr. McKay

  1. Please read the documentation. You need to call setCookies and wait for the callback before you try to do anything else, and that is invalid input for getOffer.
  2. Your err and offer parameters are switched.
  3. You can't perform authenticated requests before you're logged in. You aren't logged in until the loggedOn event is emitted. What your code is doing is starting the login process, then immediately before it completes you're trying to send an offer. Obviously, that's not gonna work.
  4. Your timeout should be for calling the callback, not for calling LogOn again.
  5. https://github.com/DoctorMcKay/node-steamcommunity/wiki/SteamCommunity#uploadavatarimage-format-callback
  6. You should probably wait for the sentOfferChanged event to be emitted with the offer's state being Active before you add it to your database.
  7. You need a code every time you login if you're using TOTP/mobile authenticator.
  8. You should add a delay before you attempt to relog if your code was wrong. A wrong code will continue to be wrong for up to 30 seconds. What happened there was that your code was already used when you tried to login, so Steam failed your login and told you that your last code was wrong. Then you tried to login 15 more times with the same incorrect code. For obvious reasons, Steam blacklisted your IP for a short time.
  9. You can't. You can add a friend via steamcommunity, however.
  10. Read the documentation please. There are events for everything you just described.
  11. You should make it stop restarting the script a lot of times.
  12. Use steamID.toString() instead of JSON.stringify.
  13. https://github.com/DoctorMcKay/node-steam-tradeoffer-manager/wiki/TradeOffer#getreceiveditemsgetactions-callback
  14. The steamID property will be null if you aren't connected. It'll be a SteamID object if you are.
  15. Assuming all items are CS:GO items... var offer = manager.createOffer("https://steamcommunity.com/tradeoffer/new/?partner=123456&token=xxxxxx"); offer.addMyItems([ { "appid": 730, "contextid": 2, "assetid": "6908727870" }, { "appid": 730, "contextid": 2, "assetid": "6901768067" } ]); offer.addTheirItems([ { "appid": 730, "contextid": 2, "assetid": "847548541" }, { "appid": 730, "contextid": 2, "assetid": "325415748" } ]); offer.send(function(err, status) { if (err) { throw err; } console.log("Offer #" + offer.id + " is now " + status); });
  16. Just call getReceivedItems after the offer is accepted.
  17. Just keep trying to accept it. As far as I can tell, error 28 just means Steam is being bad.
  18. The API isn't going anywhere.
  19. Yeah it only happens when an HTTP request fails. If you aren't making requests then it won't be emitted.
×
×
  • Create New...