wynn/ts/src/bot/index.ts

48 lines
1.4 KiB
TypeScript
Raw Normal View History

2025-02-27 03:56:30 +00:00
import { config } from "#/config";
import {createBot, Intents} from "discordeno"
const intents = [
Intents.GuildModeration ,
Intents.GuildWebhooks ,
Intents.GuildExpressions ,
Intents.GuildScheduledEvents ,
Intents.GuildMessagePolls ,
Intents.GuildIntegrations ,
Intents.GuildInvites ,
Intents.GuildMessageReactions ,
Intents.GuildPresences ,
Intents.DirectMessages ,
Intents.DirectMessageReactions ,
Intents.GuildMembers ,
Intents.Guilds ,
Intents.GuildInvites ,
Intents.GuildMessages,
]
export const bot = createBot({
intents: intents.reduce((acc, curr) => acc | curr, Intents.Guilds),
token: config.DISCORD_TOKEN,
desiredProperties: {
interaction: {
id: true,
data: true,
type: true,
token: true,
message: true,
channelId: true,
channel: true,
guildId: true,
guild: true,
user: true,
member: true,
},
message: {
id: true,
member: true,
guildId: true,
},
}
})