-
-
Notifications
You must be signed in to change notification settings - Fork 29
/
client.d.ts
141 lines (138 loc) · 4.68 KB
/
client.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
import * as Discord from "discord.js"
export * from "discord.js"
export class LimitedCollection<K, V> extends Discord.LimitedCollection<K, V> {
forceSet(key: any, value: any): this
}
export class Collection<K, V> extends Discord.Collection<K, V> {
forceSet(key: any, value: any): this
}
declare module "discord.js-light" {
interface Caches {
ChannelManager: [manager: typeof Discord.ChannelManager, holds: typeof Discord.Channel];
GuildChannelManager: [manager: typeof Discord.GuildChannelManager, holds: typeof Discord.GuildChannel];
GuildManager: [manager: typeof Discord.GuildManager, holds: typeof Discord.Guild];
PermissionOverwriteManager: [manager: typeof Discord.PermissionOverwriteManager, holds: typeof Discord.PermissionOverwrites];
RoleManager: [manager: typeof Discord.RoleManager, holds: typeof Discord.Role];
}
interface ClientOptions {
disabledEvents?: Array<string>
}
interface ClientEvents {
rest: [
{
path: string,
method: string,
responseHeaders: object,
responseBody: string
}
];
shardConnect: [
number,
Discord.Collection<Discord.Snowflake, Discord.Guild>
];
guildEmojisUpdate: [
Discord.Collection<Discord.Snowflake, Discord.GuildEmoji>
];
guildStickersUpdate: [
Discord.Collection<Discord.Snowflake, Discord.Sticker>
];
}
interface Guild {
partial: boolean
}
interface Role {
partial: boolean
}
interface Invite {
partial: boolean
}
interface Presence {
partial: boolean
}
interface StageInstance {
partial: boolean
}
interface ThreadMember {
partial: boolean
}
interface ApplicationCommand {
partial: boolean
}
interface GuildScheduledEvent {
partial: boolean
}
interface GuildChannel {
fetchOverwrites(): Promise<Discord.Collection<Discord.Snowflake, Discord.PermissionOverwrites>>
}
interface UserManager {
forge(user_id: Discord.Snowflake): Discord.User
}
interface GuildManager {
forge(guild_id: Discord.Snowflake): Discord.Guild
}
interface ChannelManager {
forge(id: Discord.Snowflake, type?: "DM"): Discord.DMChannel
forge(id: Discord.Snowflake, type: "GUILD_TEXT"): Discord.TextChannel
forge(id: Discord.Snowflake, type: "GUILD_VOICE"): Discord.VoiceChannel
forge(id: Discord.Snowflake, type: "GUILD_CATEGORY"): Discord.CategoryChannel
forge(id: Discord.Snowflake, type: "GUILD_NEWS"): Discord.NewsChannel
forge(id: Discord.Snowflake, type: "GUILD_STORE"): Discord.StoreChannel
forge(id: Discord.Snowflake, type: "GUILD_STAGE_VOICE"): Discord.StageChannel
forge(id: Discord.Snowflake, type: "GUILD_PUBLIC_THREAD" | "GUILD_PRIVATE_THREAD" | "GUILD_NEWS_THREAD"): Discord.ThreadChannel
}
interface GuildChannelManager {
forge(id: Discord.Snowflake, type: "GUILD_TEXT"): Discord.TextChannel
forge(id: Discord.Snowflake, type: "GUILD_VOICE"): Discord.VoiceChannel
forge(id: Discord.Snowflake, type: "GUILD_CATEGORY"): Discord.CategoryChannel
forge(id: Discord.Snowflake, type: "GUILD_NEWS"): Discord.NewsChannel
forge(id: Discord.Snowflake, type: "GUILD_STORE"): Discord.StoreChannel
forge(id: Discord.Snowflake, type: "GUILD_STAGE_VOICE"): Discord.StageChannel
forge(id: Discord.Snowflake, type: "GUILD_PUBLIC_THREAD" | "GUILD_PRIVATE_THREAD" | "GUILD_NEWS_THREAD"): Discord.ThreadChannel
}
interface GuildMemberManager {
forge(user_id: Discord.Snowflake): Discord.GuildMember
}
interface GuildEmojiManager {
forge(emoji_id: Discord.Snowflake): Discord.GuildEmojiManager
}
interface RoleManager {
forge(role_id: Discord.Snowflake): Discord.Role
}
interface MessageManager {
forge(message_id: Discord.Snowflake): Discord.Message
}
interface PresenceManager {
forge(user_id: Discord.Snowflake): Discord.Presence
}
interface ReactionManager {
forge(emoji_id: Discord.Snowflake): Discord.MessageReaction
forge(unicode_emoji: string): Discord.MessageReaction
}
interface GuildBanManager {
forge(user_id: Discord.Snowflake): Discord.GuildBan
}
interface ApplicationCommandManager {
forge(application_id: Discord.Snowflake): Discord.ApplicationCommand
}
interface GuildInviteManager {
forge(code: string, channel_id: Discord.Snowflake): Discord.Invite
}
interface GuildStickerManager {
forge(sticker_id: Discord.Snowflake): Discord.Sticker
}
interface GuildScheduledEventManager {
forge(sticker_id: Discord.Snowflake): Discord.GuildScheduledEvent
}
interface StageInstanceManager {
forge(stage_id: Discord.Snowflake): Discord.StageInstance
}
interface VoiceStateManager {
forge(user_id: Discord.Snowflake): Discord.VoiceState
}
interface PermissionOverwriteManager {
forge(user_id: Discord.Snowflake, type: Discord.OverwriteType): Discord.PermissionOverwrites
}
interface ThreadMemberManager {
forge(user_id: Discord.Snowflake): Discord.ThreadMember
}
}