Skip to content

Instantly share code, notes, and snippets.

@JulianVennen
Created August 24, 2021 15:10
Show Gist options
  • Save JulianVennen/b308152ab7c25a6558fc744cc84e7b6f to your computer and use it in GitHub Desktop.
Save JulianVennen/b308152ab7c25a6558fc744cc84e7b6f to your computer and use it in GitHub Desktop.
const {Client} = require("discord.js");
const config = require('../config.json');
(async () => {
const client = new Client({
intents: ['GUILD_PRESENCES'],
});
await client.login(config.auth_token);
console.log('Logged in!');
client.on('presenceUpdate', async (old, presence) => {
console.log(`New status: ${presence.status}, Old Status: ${old?.status}`)
})
})()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment