Jump to content
McKay Development


  • Posts

  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Fabro's Achievements

  1. Thanks you for your answer. Is there any reason to that, and is there any way to avoid? Because I have made trades with people, and never had any restriction before. I just had this with the bot, and after that I tried to trade an item with a friend of mine, and did not had the restriction that I had with the bot. He literally accepted the trade and returned the item in less than 2 minutes. I don't completely understand why is that limitation set with the bot, but not with other accounts. Shouldn't the bot behave like a regular account while interacting with steam?
  2. Is there any way of knowing why items are restricted to trade for 7 days after the offer is accepted, but not market restricted? Both accounts (user and bot) have authenticator enabled, none of them has used new devices, both have purchases in the last 6 months and they have been mutual friends for over two months now. On received offer, escrowEnds is null, but there are 2 extra properties that caught my eye. market_marketable_restriction is 0 on every item, but market_tradable_restriction is set to 7 on every item, and when the offer is accepted, in deed, items are not allowed to be traded for 7 days. What should be the reason behind this? I've been searching everywhere, but it seems there is no information about this. I have also asked on Steam Forums, but nothing yet. It seems a bit strange to be limited on one thing but not the other, and I cannot figure out how to properly perform the trade so the restriction is set to 0 on both marketable and tradable. I have also noted that there is an undocumented property, called "market_buy_country_restriction", that is set to 'FR' on all items, regardless of the fact that both accounts are set to AR. Any kind of help would be really appreciated. I'm completely lost on how to proceed from there.
  3. Hello. Thank you for your help. I have moved the offer inside webSession and now the error has gone, nonetheless, I am waiting the 7 days cooldown because of new device, but I think it will work as expected inside webSession. About keeping it logged, the few times I have tested trying to keep the bot logged, it randomly asked for SteamGuard code in the console, but it might be something I messed up because of me not being familiar with the events and the order they are fired, since there are events concerning keeping the bot logged. I have searched the wiki, but I wasn't able to find a "list" of events in order of firing. I will keep digging the source code and look for them and try to understand better the way they work, I am doing that but since I am new to Node.JS it takes me a while to understand the syntax. By they way, can you listen an event, inside an already listened event? For instance, can you listed for a chat message inside the callback of listened to a offer recieved? Or events cannot be nested inside each other? Once again, thank you for your help.
  4. Hello. I am quite new to Node.JS so I need a little help sorting some things out. I am trying to make the bot controlled by POST request by using Express for the URL routing, so the bot only responds to specific requests made from specific domain to specific endpoints. I am able to login to SteamUser, but I am not able to share the cookies to SteamCommunity. I wasn't able to find a way to keep the bot logged in across different endpoints, I am assuming that it comes from the fact that every request is unique and they are not sharing data between them, so, I have to make the bot log in on each request, and that's fine with me. The problem comes when I try to share the cookies from webSession event, and send a trade on the loggedOn event. It appears that when logged on event fires, cookies are not yet configured. What approach should I use to perform the login on the SteamCommunity module? Here is my current code, that rejects my trade offer, because cookies are not yet configured. app.get('/lero', async (req, res) => { res.send('Loaded'); const SteamUser = require('steam-user'); const SteamCommunity = require('steamcommunity'); const SteamTotp = require('steam-totp'); const TradeOfferManager = require('steam-tradeoffer-manager'); const FS = require('fs'); let client = new SteamUser(); let manager = new TradeOfferManager({ "steam": client, "domain": "bot.test", "language": "es" }); let community = new SteamCommunity(); // Steam logon options let logOnOptions = { "accountName": "censored", "password": "censored", "twoFactorCode": SteamTotp.getAuthCode("censored"), }; if (FS.existsSync('polldata.json')) { manager.pollData = JSON.parse(FS.readFileSync('polldata.json').toString('utf8')); } client.logOn(logOnOptions); const { Sequelize, Op, Model, DataType, DataTypes } = require('sequelize'); const sequelize = new Sequelize('cendsored', 'censored', 'censored', { host: 'localhost', dialect: 'mysql', define: { underscored: true, createdAt: 'created_at', updatedAt: 'updated_at' , deletedAt: 'deleted_at', } }); const initModels = require('./models/init-models'); const models = initModels(sequelize); client.on('webSession', (sessionID, cookies) => { community.setCookies(cookies); manager.setCookies(cookies); console.log(cookies); // console logs this after the error, meaning trade is sent before this }); client.on('loggedOn', async () => { console.log("Logged into Steam"); const su = await models.steam_users.findOne({ where: { steam_personaname: 'censored', }, include: [{ model: models.users, as: 'user', }], }).then((r) => { client.chat.sendFriendMessage(r.steam_steamidmodern, "Sending trade in a moment"); let offer = manager.createOffer('censored'); console.log(offer); console.log(community); let item = { assetid: 'censored', appid: '730', contextid: '2', amount: 1, }; if (offer.addTheirItem(item)) { offer.send((err, status) => { if (err) { console.log(err); } else { console.log(status); } }); } }); }); }); I am familiar with events, since in PHP I have worked with OpenCart, Wordpress and Laravel, but I cannot find the right order of events here, to correctly log in both modules. Any help will be very much appreciated.
  • Create New...