Jump to content
McKay Development

Error using ".getActiveFriendMessageSessions()" methood


Recommended Posts

Been having this problem with the ".getActiveFriendMessageSessions()" methood for days

This is my code:

const SteamUser = require('steam-user');
const SteamTotp = require('steam-totp');

const clientTiftoo = new SteamUser();
const logOnParmsTiftoo = {
    accountName: "account",
    password: "password",
    twoFactorCode: SteamTotp.generateAuthCode('authcode')

console.log("logged in successfully")

const hi = clientTiftoo.chat.getActiveFriendMessageSessions({}, (err, res) => {console.log(err)})

This is the error that comes up:

C:\Users\mosta\Desktop>node bot2.js

Logged in successfully
Promise { <pending> }
Error: Request timed out
    at Timeout._onTimeout (C:\Users\mosta\node_modules\@doctormckay\stdlib\components\promises.js:17:12)
    at listOnTimeout (node:internal/timers:559:17)
    at processTimers (node:internal/timers:502:7)

While i'm at it, i'm trying to make my bot log in, read and respond to all unread messages, then log out and close the script. is this method the best way to iterate through unread messages and respond to them?

Thanks alot in advance!

Note: the code runs for about 10 seconds before timing out

Link to comment
Share on other sites

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.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...