A powerful and extendable Discord bot, with it's own module system :3 thevoid.cafe/projects/voidy
at develop 33 lines 708 B view raw
1import { Schema, model } from "mongoose"; 2 3export interface IGuildConfig { 4 guildId: string; 5 logging: { 6 channelId?: string; 7 }; 8 welcome: { 9 channelId?: string; 10 message?: string; 11 }; 12 autoRoles: { 13 memberRoleId?: string; 14 botRoleId?: string; 15 }; 16} 17 18const GuildConfigSchema = new Schema<IGuildConfig>({ 19 guildId: { type: String, required: true, unique: true, index: true }, 20 logging: { 21 channelId: { type: String }, 22 }, 23 welcome: { 24 channelId: { type: String }, 25 message: { type: String }, 26 }, 27 autoRoles: { 28 memberRoleId: { type: String }, 29 botRoleId: { type: String }, 30 }, 31}); 32 33export const GuildConfig = model<IGuildConfig>("GuildConfig", GuildConfigSchema);