2023-06-06 18:22:36 +02:00
|
|
|
import { Document, Types } from 'mongoose'
|
2023-06-06 13:49:27 +02:00
|
|
|
|
2023-06-04 22:06:28 +02:00
|
|
|
export {}
|
|
|
|
|
|
|
|
declare global {
|
2023-06-06 13:49:27 +02:00
|
|
|
interface IUser extends Document {
|
2023-06-06 18:22:36 +02:00
|
|
|
_id: Types.ObjectId,
|
2023-06-04 22:06:28 +02:00
|
|
|
username: string,
|
2023-06-06 13:49:27 +02:00
|
|
|
usernameType: string,
|
2023-06-04 22:06:28 +02:00
|
|
|
discord: {
|
|
|
|
id: string,
|
|
|
|
username: string,
|
|
|
|
avatarHash: string
|
|
|
|
},
|
|
|
|
minecraft?: {
|
|
|
|
uuid: string,
|
|
|
|
username: string
|
|
|
|
},
|
2023-06-06 22:28:26 +02:00
|
|
|
teamInvites: Types.ObjectId[],
|
2023-06-04 22:06:28 +02:00
|
|
|
role: {
|
|
|
|
admin: boolean,
|
|
|
|
moderator: boolean,
|
|
|
|
},
|
2023-06-06 18:22:36 +02:00
|
|
|
team?: ITeam,
|
2023-06-05 10:17:35 +02:00
|
|
|
accessToken?: string
|
2023-06-04 22:06:28 +02:00
|
|
|
}
|
2023-06-05 16:05:03 +02:00
|
|
|
|
|
|
|
interface IWhitelist {
|
2023-06-06 18:22:36 +02:00
|
|
|
_id: types.ObjectId,
|
2023-06-05 16:05:03 +02:00
|
|
|
uuid: string,
|
|
|
|
connected: boolean,
|
|
|
|
code: string
|
|
|
|
}
|
2023-06-06 14:29:05 +02:00
|
|
|
|
|
|
|
interface ITeam {
|
2023-06-06 18:22:36 +02:00
|
|
|
_id: types.ObjectId,
|
2023-06-06 14:29:05 +02:00
|
|
|
name: string,
|
|
|
|
color: string,
|
2023-06-24 13:27:33 +02:00
|
|
|
members: IUser[],
|
2023-06-06 14:29:05 +02:00
|
|
|
textChannelId: string,
|
|
|
|
voiceChannelId: string
|
|
|
|
}
|
2023-06-15 16:55:23 +02:00
|
|
|
|
|
|
|
type DiscordUser = {
|
|
|
|
id: string,
|
|
|
|
username: string,
|
|
|
|
discriminator: string,
|
|
|
|
global_name: string,
|
|
|
|
avatar: string,
|
|
|
|
bot?: boolean,
|
|
|
|
system?: boolean,
|
|
|
|
mfa_enabled?: boolean,
|
|
|
|
banner?: string,
|
|
|
|
accent_color?: number,
|
|
|
|
locale?: string,
|
|
|
|
verified?: boolean,
|
|
|
|
email?: string,
|
|
|
|
flags?: number,
|
|
|
|
premium_type?: number,
|
|
|
|
public_flags?: number
|
|
|
|
}
|
2023-06-04 22:06:28 +02:00
|
|
|
}
|