Hi!
I’m building an automated Steam account manager and need to reliably fetch all possible account status flags for a given account, including:
VAC bans (vacBanned)
Trade bans and restrictions (tradeBanState, “red warning” banners)
Market restrictions (e.g. “not allowed to use the Community Market”, cooldowns, etc.)
Limited account status (isLimitedAccount)
Any “red warning”/security flags shown on the profile (e.g. “This account has been restricted”, “Community banned”, etc.)
I’m currently using node-steamcommunity and my code looks like this
const SteamCommunity = require('steamcommunity');
const community = new SteamCommunity();
community.setCookies(cookies); // cookies from steam-session (WebBrowser)
community.getSteamUser(steamId, (err, user) => {
if (err) {
// Often get: 'The specified profile could not be found.'
// Sometimes get HTTP 302 redirect to /id/<customURL>
// Sometimes get empty user object
console.warn('getSteamUser error', err);
return;
}
// Trying to read:
// user.vacBanned, user.tradeBanState, user.isLimitedAccount
// But sometimes these fields are missing or user is undefined
console.log('User status:', {
vacBanned: user.vacBanned,
tradeBanState: user.tradeBanState,
isLimitedAccount: user.isLimitedAccount,
// ...other fields?
});
});
Questions:
What is the most reliable way to get all these status flags for any account (including limited, banned, restricted, etc.)?
Is there a better method or recommended workflow to avoid “profile not found” errors and reliably get all status fields?
How do I detect “red warning” banners (community ban, trade ban, market ban) if getSteamUser fails or returns incomplete data?
Any best practices for cookies/session setup to maximize success rate?
Thanks for any advice or code examples! 💙