Build/project structure #142

Merged
BlackAngelTV merged 80 commits from build/project-structure into main 2026-09-23 14:31:21 +02:00
Showing only changes of commit baf8db059b - Show all commits
+24
View File
@@ -0,0 +1,24 @@
import { Client, Collection, GatewayIntentBits, Partials } from 'discord.js';
/**
* Only the intents required by the bot (M2-T02):
* - Guilds: slash commands, channels, roles
* - GuildMembers (privileged): welcome, departures, role assignment
* - GuildModeration: ban/kick audit events
* - GuildMessages: /clear and ticket channels
* MessageContent is intentionally not requested.
*/
export function createClient() {
const client = new Client({
intents: [
GatewayIntentBits.Guilds,
GatewayIntentBits.GuildMembers,
GatewayIntentBits.GuildModeration,
GatewayIntentBits.GuildMessages,
],
partials: [Partials.GuildMember],
});
client.commands = new Collection();
return client;
}