import { Effect } from "effect";
const SteamUser = require('steam-user');
const client = new SteamUser();
// Listen for the 'loggedOn' event
client.on('loggedOn', async () => {
console.log('Successfully logged in to Steam!');
// Perform additional actions after login
try {
const profileInfo = await client.getPersonas([client.steamID]);
console.log('Profile Info:', profileInfo);
} catch (error) {
console.error('Error fetching profile info:', error);
}
});
// Log in to Steam with credentials
client.logOn({
accountName: 'account_name',
password: 'password',
});
import { Effect } from "effect";
const SteamUser = require('steam-user');
const client = new SteamUser();
// Listen for the 'loggedOn' event
client.on('loggedOn', async () => {
console.log('Successfully logged in to Steam!');
// Perform additional actions after login
try {
const profileInfo = await client.getPersonas([client.steamID]);
console.log('Profile Info:', profileInfo);
} catch (error) {
console.error('Error fetching profile info:', error);
}
});
// Log in to Steam with credentials
client.logOn({
accountName: 'account_name',
password: 'password',
});