Jump to content
McKay Development

Search the Community

Showing results for tags 'Question'.

  • 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. const manager = new TradeOfferManager({ steam: client, community: community, language: "en"}); manager.on("sentOfferChanged ", function (offer,oldState) { console.log(`Sent offer changed:` + offer.state);}); sentOfferChanged doesnt emit, the only time it emits something is when I send an offer that needs to be confirmed (ETradeOfferState = 9). Do I have to call doPoll() manually or Iam missing something?
  2. How do i check if a group is joinable or invite only?
  3. Hi, I have a little question: Where can i get shared_secret? After the first run steam.login(), I got "steamguard". Which passed to the function generateAuthCode.What am I doing wrong? Thank you. var SteamCommunity = require('steamcommunity'); var steam = new SteamCommunity(); var logOnOptions = { accountName: 'user1', password: 'passsssssssword',// twoFactorCode: '72N37', twoFactorCode: SteamTotp.generateAuthCode('76561198035130610||snip') }; console.log(logOnOptions) //logs in via browser steam.login(logOnOptions, function(err, sessionID, cookies, steamguard) { console.log(steamguard) // '76561198035130610||snip' if (err) { console.log("There was an error logging in! Error details: " + err.message); process.exit(1); //terminates program } else { console.log("Successfully logged in as " + logOnOptions.accountName); } });
  4. I wanna make a bot wich responds randomly when the user typer !random, i have created a array with the example: var random = ["random","blabla","bla"] So i added the function: function random_sentences(random) { return random[Math.floor(Math.random()*random.length)];} and if anyones type !random: else if(message == "!random") { client.chatMessage(random_sentences(random)) } this error appears: throw new Error("Unknown SteamID input format \"" + input + "\""); ^ Error: Unknown SteamID input format I did like to know how the bot can reponse randomly.Thanks
  5. If I recall it correctly, node-steamcommunity and other web clients of Steam used the old chat system to get the online status to a account. To achieve this with the new chat we would have to implement a whole layer just to handle the connections with CM servers (I guess). I noticed that whenever I open the Steam app, my account get an online status, although I don't know if it also connects to CM servers or something as I haven't success trying to use debugging proxies and stuff. Anyone knows what would be the "cheapest" way to get online status on a account? Also, what's your setup to analyze the calls that Android apps make? I tried to use fiddler and mitmproxy, but my Android had some issues with CA certificates. Thanks in advance
  6. I have this problem: My bot: bot.js Config.js Help pls
  7. I have been having this trouble on my Steam Trading Bot, when i try to run the bot, it always return Error 401 Any of you have any idea how this turns out, or how i can solve this problem Thank you so much for your time and your help Here is my full source code https://drive.google.com/open?id=110RbCiAqAY0_PvoGDyKfeKrW341GQQXZ
  8. client.on("friendMessage", function(steamID, message) {if (message == "!test") {client.chatMessage(steamID, "test")}if (message == "") {client.chatMessage(steamID, "")}if (message == "") {client.chatMessage(steamID, "" )} if (message == "!mystery") {client.chatMessage(steamID, "" )}}}); Script That I'm Using Anyone Can Help Me? I Want to add Unknown Command , but , dont know how
  9. Hello i use this code community.postGroupAnnouncement("103582791463279214", title, msg, (err) => { if (err) { console.log("Error while posting announcement. Error " + err); } console.log("Posted announcement!"); console.log(" - Title: " + title); console.log(" - Message: " + msg); client.chatMessage(steamID, "hadi kapı orda yürü."); }); i not get any error or warn. But not sended announcement please help me
  10. Solution for getting appOwnershipChached apps' name instead of appid. I got config.default_apps by using an empty Steam account to get the numerical list of apps each account has by default and on that line I compare that default list to the list of the fetched user account which might have some games and then filter to remove the default apps. //get GAME LIST client.on('appOwnershipCached', async() => { try { const appIDs = await client.getOwnedApps() let gameList = appIDs.filter((game) => { // remove default apps from list return !config.default_apps.includes(game) }) const appDetails = await client.getProductInfo(gameList, []) let appData = appDetails.apps let arr = await Object.keys(appData).map(key => { // convert list to array return appData[key] }) let cleanGameList = [] await arr.forEach(app => { // push only app names into array if (app.appinfo.common !== undefined) { // necessary only .common since .common.name gives TypeError cleanGameList.push(app.appinfo.common.name) } }) log(cleanGameList) } catch(err) { log(err) } }) Well, I've been trying/searching different things for hours now without any sufficient results. I am trying to get the name of the app/game instead of the appid number via appOwnershipCached. I am actually trying to get the games in the users account instead of also apps and default apps that come with a Steam account. I managed to get the names with an npm package called appid, but it takes a while until it converts all of them since it's fetching it from Steam API, so unfortunately it's not an option and I've run out. So I have two questions: Is there a way to get an apps' name instead of appid? Is there a way to get only the games without apps and default apps? Edit: I actually managed to filter it to the point until I get only the games in my library. I basically filter default apps from the appOwnershipCached fetch of appIDs and then if the appID has a name, it puts it into the gameList array. But the problem is, some games seem not to have names, why is that? For example: Rocket League only has { appid: '252590', public_only: '1' } on .appinfo... OLD NOT WORKING //get GAME LIST client.on('appOwnershipCached', async() => { try { const appIDs = await client.getOwnedApps() log(appIDs) let gameList = appIDs.filter((game) => { return !config.default_apps.includes(game) }) log(gameList) accountData.games = await gameList // log("my games: " + accountData.games) const appDetails = await client.getProductInfo(gameList, []) // ROCKET LEAGUE TEST const rl = await client.getProductInfo([252590], []) log(rl.apps[252590].appinfo) // let appData = appDetails.apps // log(appData) let arr = await Object.keys(appData).map(key => { return appData[key] }) // log(arr) let cleanGameList = [] await arr.forEach(app => { if (app.appinfo.common.name != null) { // log(app.appinfo.common.name) console.log("list: ", cleanGameList) return cleanGameList.push(app.appinfo.common.name) } }) } catch(err) { log(err) } })
  11. Hello. I make an account manager for Steam, and when I reboot the server, I constantly have to log in again from all my accounts. How can I save a session without shared secret? Is it possible?
  12. Hey there, I'm such a newbie in steambot coding. The main objective of the code would be that the bot should request a cs:go / tf2 key from a user who sends the command "!order" via trade offers. My current state is that the bot creates the offer but there's always an error because I get the error: "Cannot send an empty trade offer." Is there anything which I'm too blind to see? Thanks in advance! My code: function checkKeys(steamID) { var theirKeys = []; var amountOfKeysToAdd = 1; manager.getUserInventoryContents(steamID, config.keysFromCSGO && config.keysFromTF2, 2, true, function(err, inventory) { if (err) { console.log('Error getting user inventory.'.red); } else { console.log('Checking if user has CS:GO or TF2 keys.'.green); for (var n = 0; n < inventory.length; n++) { if(theirKeys.length < amountOfKeysToAdd && config.acceptedKeys.indexOf(inventory[n].market_hash_name) >= 0) { theirKeys.push(inventory[n]); console.log(inventory[n].market_hash_name); } } console.log('User has' + theirKeys.length + 'key(s).'); } }); } function sendOffer(sender) { let theirKeys = []; var offer = (manager.createOffer(sender.getSteamID64())); offer.addTheirItems(theirKeys); offer.send ((err, status) => { if (err) { console.log('There was an error sending the offer.'.red + err); } else { console.log('An offer has been sent.'.green); console.log(status); } }); } client.on('friendMessage', (sender, message) => { if (message === "!start") { client.chatMessage(sender, config.startMessage); } else if (message === "!owner") { client.chatMessage(sender, config.ownerMessage); } else if (message === "!help") { client.chatMessage(sender, config.helpMessage); } else if (message === "!order") { client.chatMessage(sender, config.orderMessage); client.chatMessage(sender, 'Processing your request....'); checkKeys(sender); console.log('Creating offer...'.cyan); sendOffer(sender); } else if (message === "!proof") { client.chatMessage(sender, config.proofMessage); } });
  13. Hello Error: Must be logged in before trying to do anything with confirmations I get this error when executing code in BAS (Browser Automation Studio) [[IDENTITY_SECRET]] = JSON.parse([[FILE_CONTENT]]).identity_secret var SteamTotp = require('steam-totp'); [[code2]] = SteamTotp.generateConfirmationKey([[IDENTITY_SECRET]]); [[code3]] = SteamTotp.getConfirmationKey([[code2]]); [[TIME]] = SteamTotp.time([[timeOffset]]); var SteamCommunity = require('steamcommunity'); var community = new SteamCommunity(); var Steam = require('steam-client'); var client = new Steam.CMClient(Steam.EConnectionProtocol.TCP); var TradeOfferManager = require('steam-tradeoffer-manager'); var manager = new TradeOfferManager(); client.on('webSession', (sessionID, cookies) => { manager.setCookies(cookies, function (err) { if (err) { logger.error(err) //игнор.прав process.exit(1); } }); community.setCookies(cookies); community.startConfirmationChecker(10000, [[code3]]); }); var time = [[TIME]]; var confKey = [[code3]]; var allowKey = [[code3]]; community.acceptAllConfirmations(time, confKey, allowKey, function(err, confs){ if(err){ res.sendError(err); return; } if(confs == null) confs = []; res.sendSuccess(confs); });
  14. I want to create bot with automatic sending spesific trading card with spesific input //the conversation A: !badges 570 2 BOT: Sending 2sets of Dota 2 A: !badges 440 5 BOT: Sending 5sets of Team Fortress 2 //my spesific input ... client.on("friendMessage", function(steamID, message) { var msg; if (steamID == account.owner){ ... else if (msg = message.match(/^!badges(\d+) (\d+))) { var appID = msg[1]; var count = msg[2]; client.chatMessage(steamID, "..."); } } else{ ... } ... Can anyone help me to get the code?
  15. Hi, I have a bot problem. I can not idolize a few games at once, I can only go to Tf2, if I want another free game and I can not do it, why? My code: client.logOn(logOnOptions); client.on('loggedOn', () => { console.log('Zalogowano!'); client.setPersona(SteamUser.EPersonaState.Online); client.gamesPlayed(["Siezek To Kozak!"],440); });
  16. Siezek1

    Autobuy

    Hi, I will send someone a line to my autobuos, so that the bot will buy me the item as it will be at a given price on steam
  17. Hi, if someone can help me out with this i dont rl know how to build this and i created such a mess here with all of this code... I tryed to search up everywhere and i cant find similar problem... I have prices database in database.json file witch bot loads and then u can acces to !prices <item name>, similar to that i created !buy <item name> command witch is triggered when user insert name of item witch exist in database.json and in bots inventory(inventory.json)... After that bot needs to create offer with this items witch are selected...There i start having some issues. Down is my messed code if someone can explain what im doing wrong, and how i can make trade offer with selected items for price thats inside of database by chat command ? } else if (command === "!buy" && itemName) { const database = JSON.parse(fs.readFileSync('./database.json', 'utf8')); if(database[itemName]) { const buyPrice = database[itemName].sell; const sellPrice = database[itemName].sell.metal let offer = manager.createOffer("https://steamcommunity.com/tradeoffer/new/?partner=12345678&token=xxxxxxxx"); let t = manager.createOffer(steamID.getSteamID64()); t.getUserDetails((ERR, ME, THEM) => { if (ERR) { console.log("## An error occurred while getting trade holds: " + ERR); client.chatMessage(steamID, "An error occurred while getting your trade holds. Please try again"); } else if (ME.escrowDays == 0 && THEM.escrowDays == 0) { client.chatMessage(steamID, "Processing your request."); manager.getUserInventoryContents(steamID.getSteamID64(), 440, 2, true, (ERR, INV, CURR) => { offer.addTheirItems(INV); offer.addMyItems(INV); var MyItems = require(`./Inventory.JSON`); offer.send(function(err, status) { }, client.chatMessage(steamID, "Prepairing offer...")); if (ETradeOfferState == 12) { console.log(`Offer #${offer.id} sent, but requires confirmation`); community.acceptConfirmationForObject("identitySecret", offer.id, function(err) { if (err) { console.log(err); } else { console.log("Offer confirmed"); } }); } else { console.log(`Offer #${offer.id} sent successfully`); client.chatMessage(steamID, `Trade offer created ! [ offer ID: ${offer.id} ]`); } if (ERR) { console.log("## An error occurred while getting inventory: " + ERR); client.chatMessage(steamID, "An error occurred while loading your inventory. Please try later, or check if your inventory isnt on private ! \n If is that not case error is caused by Steam servers witch seems to be offline... \n Try to sent offer with up given price at link:\n https://steamcommunity.com/tradeoffer/new/?partner=xxxxxxxx "); } }); } });
  18. Hi, give me a line of code to let my bot write a comment to friends for adding it to a friend? And if it's possible, it's a line of code with an option, like a bot friend writing a command to him, for example! Rep bot writes him in the comment "+ rep" Thank You EDIT: Repaired
  19. Hello there, I'm new to this forum and I have several question regarding the topic title. Currently, I have a project in mind on developing somewhat similar to other competitive platform like Faceit or ESEA but I don't know where to start. Perhaps any users in this forum could brief me on what I need to learn or do? I've done some research and learn some basic about angular, node, rcon and stuffs, as well as read some of the steam web documentation but yet I still does not understand how to implement it. Its just that I'm just curious on how do I get my web based application to interact with steam such as assigning servers to match room and others. I'm sorry if this topic in general and my explanation is not clear, but I'm determined to build one. Thanks!
  20. I have application on node it has steam-bots and socket.io server, during initialization bots they receive an instance socket.io and send to the admin panel requests about the status of trades When I need to update the server's socket.io code, I have to restart the application completely. How to make the bots not reboot when changing the server's socket.io code? Or - how can I organize data exchange between two nodejs applications?
  21. Hello, for some reason I can't login on any Steam accounts. — Node.js version: 12.4.0 / 8.16.0 node-steam-user version: 4.12.2 — Debug log (first part, then it repeat immediately inf. amount of times): Connecting to TCP CM: 155.133.230.34:27019 TCP connection established Handled message: ChannelEncryptRequest Channel encrypt request: protocol 1, universe 1, nonce 2c1378e10fb52fd105a21685874390d8, 0 remaining bytes Sending message: ChannelEncryptResponse Handled message: ChannelEncryptResult Sending message: ClientLogon Handled message: ClientLogOnResponse Log on response: TryAnotherCM Code: console.log('> Loading, please wait.') const SteamUser = require('steam-user') const client = new SteamUser() const logOnOptions = { accountName: '***', password: '***', } console.log('> Loaded, logging in.') client.logOn(logOnOptions) client.on('loggedOn', () => { console.log('> Logged into Steam.') client.setPersona(SteamUser.Steam.EPersonaState.Online, 'aeonix.space') client.gamesPlayed('Idling', 730) }) client.on('debug', console.log)
  22. Hello guys i began to create a programm and i want to send messages any friend through api. I found https://api.steampowered.com/ISteamWebUserPresenceOAuth/Logon/v0001 and pass access_token - https://steamcommunity.com/dev/managegameservers and dev api key and i get an answer UnauthorizedAccess is denied. Retrying will not help. Please verify yourkey=parameter. What is that problem? How i can fix that? Help pls!
  23. I am new in node js, i start 2 days ago. Is that possible to create multiple specific input message? steam chat a: hello bot: !mymoney, !checkname [gameid] a: !checkname 440 bot: Team Fortress 2 a: !checkname 570 bot: Dota 2 node.js code ..... client.on("friendMessage", function(steamID, message) { if (message == "!mymoney") { client.chatMessage(steamID, duitgw) } else if (message == "!checkname"){ if (message.line2 == "440"){ //like this ..... } else if (message.line2 == notnumber){ //another condition .... } else if (message.line2 == isnt set){ //another condition .... } } else{ client.chatMessage(steamID, "!mymoney, !checkgame [gameid]") } }); ..... edit: i use comment for highlight
  24. When working with your library there was a difficulty... How can i promise example here: botInfo = {}; client.logOn(logOnOptions); client.on('wallet', function(hasWallet, currency, balance) { botInfo.balance = balance; }); client.on('emailInfo', function(address, validated) { botInfo.emailAddress = address; botInfo.emailValidated = validated; }); console.log(botInfo); // i want to log data after fill info no one promise don't work....
×
×
  • Create New...