disgroove 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/class/Client.d.ts +306 -0
- package/dist/class/Client.js +771 -0
- package/dist/class/Client.js.map +1 -0
- package/dist/class/index.d.ts +1 -0
- package/dist/class/index.js +18 -0
- package/dist/class/index.js.map +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +22 -0
- package/dist/index.js.map +1 -0
- package/dist/rest/Endpoints.d.ts +97 -0
- package/dist/rest/Endpoints.js +205 -0
- package/dist/rest/Endpoints.js.map +1 -0
- package/dist/rest/REST.d.ts +16 -0
- package/dist/rest/REST.js +55 -0
- package/dist/rest/REST.js.map +1 -0
- package/dist/rest/index.d.ts +2 -0
- package/dist/rest/index.js +32 -0
- package/dist/rest/index.js.map +1 -0
- package/dist/structures/Application.d.ts +250 -0
- package/dist/structures/Application.js +258 -0
- package/dist/structures/Application.js.map +1 -0
- package/dist/structures/ApplicationCommand.d.ts +68 -0
- package/dist/structures/ApplicationCommand.js +133 -0
- package/dist/structures/ApplicationCommand.js.map +1 -0
- package/dist/structures/AuditLogEntry.d.ts +16 -0
- package/dist/structures/AuditLogEntry.js +54 -0
- package/dist/structures/AuditLogEntry.js.map +1 -0
- package/dist/structures/AutoModerationRule.d.ts +29 -0
- package/dist/structures/AutoModerationRule.js +85 -0
- package/dist/structures/AutoModerationRule.js.map +1 -0
- package/dist/structures/Channel.d.ts +296 -0
- package/dist/structures/Channel.js +579 -0
- package/dist/structures/Channel.js.map +1 -0
- package/dist/structures/Guild.d.ts +452 -0
- package/dist/structures/Guild.js +1161 -0
- package/dist/structures/Guild.js.map +1 -0
- package/dist/structures/GuildMember.d.ts +46 -0
- package/dist/structures/GuildMember.js +126 -0
- package/dist/structures/GuildMember.js.map +1 -0
- package/dist/structures/GuildScheduledEvent.d.ts +45 -0
- package/dist/structures/GuildScheduledEvent.js +115 -0
- package/dist/structures/GuildScheduledEvent.js.map +1 -0
- package/dist/structures/GuildTemplate.d.ts +25 -0
- package/dist/structures/GuildTemplate.js +80 -0
- package/dist/structures/GuildTemplate.js.map +1 -0
- package/dist/structures/Integration.d.ts +28 -0
- package/dist/structures/Integration.js +96 -0
- package/dist/structures/Integration.js.map +1 -0
- package/dist/structures/Interaction.d.ts +204 -0
- package/dist/structures/Interaction.js +368 -0
- package/dist/structures/Interaction.js.map +1 -0
- package/dist/structures/Invite.d.ts +22 -0
- package/dist/structures/Invite.js +108 -0
- package/dist/structures/Invite.js.map +1 -0
- package/dist/structures/Message.d.ts +97 -0
- package/dist/structures/Message.js +327 -0
- package/dist/structures/Message.js.map +1 -0
- package/dist/structures/Role.d.ts +35 -0
- package/dist/structures/Role.js +81 -0
- package/dist/structures/Role.js.map +1 -0
- package/dist/structures/StageInstance.d.ts +20 -0
- package/dist/structures/StageInstance.js +53 -0
- package/dist/structures/StageInstance.js.map +1 -0
- package/dist/structures/User.d.ts +53 -0
- package/dist/structures/User.js +168 -0
- package/dist/structures/User.js.map +1 -0
- package/dist/structures/Webhook.d.ts +133 -0
- package/dist/structures/Webhook.js +189 -0
- package/dist/structures/Webhook.js.map +1 -0
- package/dist/structures/index.d.ts +17 -0
- package/dist/structures/index.js +34 -0
- package/dist/structures/index.js.map +1 -0
- package/dist/types/application-command.d.ts +97 -0
- package/dist/types/application-command.js +3 -0
- package/dist/types/application-command.js.map +1 -0
- package/dist/types/application-role-connection-metadata.d.ts +17 -0
- package/dist/types/application-role-connection-metadata.js +3 -0
- package/dist/types/application-role-connection-metadata.js.map +1 -0
- package/dist/types/application.d.ts +55 -0
- package/dist/types/application.js +3 -0
- package/dist/types/application.js.map +1 -0
- package/dist/types/audit-log.d.ts +77 -0
- package/dist/types/audit-log.js +3 -0
- package/dist/types/audit-log.js.map +1 -0
- package/dist/types/auto-moderation.d.ts +61 -0
- package/dist/types/auto-moderation.js +3 -0
- package/dist/types/auto-moderation.js.map +1 -0
- package/dist/types/channel.d.ts +411 -0
- package/dist/types/channel.js +3 -0
- package/dist/types/channel.js.map +1 -0
- package/dist/types/emoji.d.ts +22 -0
- package/dist/types/emoji.js +3 -0
- package/dist/types/emoji.js.map +1 -0
- package/dist/types/gateway-events.d.ts +53 -0
- package/dist/types/gateway-events.js +3 -0
- package/dist/types/gateway-events.js.map +1 -0
- package/dist/types/guild-scheduled-event.d.ts +55 -0
- package/dist/types/guild-scheduled-event.js +3 -0
- package/dist/types/guild-scheduled-event.js.map +1 -0
- package/dist/types/guild-template.d.ts +28 -0
- package/dist/types/guild-template.js +3 -0
- package/dist/types/guild-template.js.map +1 -0
- package/dist/types/guild.d.ts +305 -0
- package/dist/types/guild.js +3 -0
- package/dist/types/guild.js.map +1 -0
- package/dist/types/index.d.ts +22 -0
- package/dist/types/index.js +39 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/interaction.d.ts +141 -0
- package/dist/types/interaction.js +3 -0
- package/dist/types/interaction.js.map +1 -0
- package/dist/types/invite.d.ts +56 -0
- package/dist/types/invite.js +3 -0
- package/dist/types/invite.js.map +1 -0
- package/dist/types/message-components.d.ts +76 -0
- package/dist/types/message-components.js +3 -0
- package/dist/types/message-components.js.map +1 -0
- package/dist/types/oauth2.d.ts +14 -0
- package/dist/types/oauth2.js +3 -0
- package/dist/types/oauth2.js.map +1 -0
- package/dist/types/role.d.ts +42 -0
- package/dist/types/role.js +3 -0
- package/dist/types/role.js.map +1 -0
- package/dist/types/stage-instance.d.ts +18 -0
- package/dist/types/stage-instance.js +3 -0
- package/dist/types/stage-instance.js.map +1 -0
- package/dist/types/sticker.d.ts +59 -0
- package/dist/types/sticker.js +3 -0
- package/dist/types/sticker.js.map +1 -0
- package/dist/types/team.d.ts +28 -0
- package/dist/types/team.js +3 -0
- package/dist/types/team.js.map +1 -0
- package/dist/types/user.d.ts +73 -0
- package/dist/types/user.js +3 -0
- package/dist/types/user.js.map +1 -0
- package/dist/types/voice.d.ts +46 -0
- package/dist/types/voice.js +3 -0
- package/dist/types/voice.js.map +1 -0
- package/dist/types/webhook.d.ts +31 -0
- package/dist/types/webhook.js +3 -0
- package/dist/types/webhook.js.map +1 -0
- package/dist/utils/constants.d.ts +963 -0
- package/dist/utils/constants.js +1147 -0
- package/dist/utils/constants.js.map +1 -0
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/index.js +19 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/rawers.d.ts +467 -0
- package/dist/utils/rawers.js +295 -0
- package/dist/utils/rawers.js.map +1 -0
- package/package.json +27 -0
|
@@ -0,0 +1,305 @@
|
|
|
1
|
+
import type { VerificationLevel, DefaultMessageNotificationLevel, ExplicitContentFilterLevel, GuildFeatures, MFALevel, PremiumTier, GuildNSFWLevel, GuildMemberFlags, IntegrationExpireBehaviors, OAuth2Scopes, SystemChannelFlags, OnboardingMode, PromptTypes } from "../utils/constants";
|
|
2
|
+
import type { RawChannel, RawEmoji, RawSticker, RawUser, RawRole, JSONEmoji, JSONSticker } from ".";
|
|
3
|
+
import type { Channel, Role, User } from "../structures";
|
|
4
|
+
export interface RawGuild {
|
|
5
|
+
id: string;
|
|
6
|
+
name: string;
|
|
7
|
+
icon: string | null;
|
|
8
|
+
icon_hash?: string | null;
|
|
9
|
+
splash: string | null;
|
|
10
|
+
discovery_splash: string | null;
|
|
11
|
+
owner?: boolean;
|
|
12
|
+
owner_id: string;
|
|
13
|
+
permissions?: string;
|
|
14
|
+
region?: string | null;
|
|
15
|
+
afk_channel_id: string | null;
|
|
16
|
+
afk_timeout: number;
|
|
17
|
+
widget_enabled?: boolean;
|
|
18
|
+
widget_channel_id?: string | null;
|
|
19
|
+
verification_level: VerificationLevel;
|
|
20
|
+
default_message_notifications: DefaultMessageNotificationLevel;
|
|
21
|
+
explicit_content_filter: ExplicitContentFilterLevel;
|
|
22
|
+
roles: Array<RawRole>;
|
|
23
|
+
emojis: Array<RawEmoji>;
|
|
24
|
+
features: Array<GuildFeatures>;
|
|
25
|
+
mfa_level: MFALevel;
|
|
26
|
+
application_id: string | null;
|
|
27
|
+
system_channel_id: string | null;
|
|
28
|
+
system_channel_flags: number;
|
|
29
|
+
rules_channel_id: string | null;
|
|
30
|
+
max_presences?: number | null;
|
|
31
|
+
max_members?: number;
|
|
32
|
+
vanity_url_code: string | null;
|
|
33
|
+
description: string | null;
|
|
34
|
+
banner: string | null;
|
|
35
|
+
premium_tier: PremiumTier;
|
|
36
|
+
premium_subscription_count?: number;
|
|
37
|
+
preferred_locale: string;
|
|
38
|
+
public_updates_channel_id: string | null;
|
|
39
|
+
max_video_channel_users?: number;
|
|
40
|
+
approximate_member_count?: number;
|
|
41
|
+
approximate_presence_count?: number;
|
|
42
|
+
welcome_screen?: RawWelcomeScreen;
|
|
43
|
+
nsfw_level: GuildNSFWLevel;
|
|
44
|
+
stickers?: Array<RawSticker>;
|
|
45
|
+
premium_progress_bar_enabled: boolean;
|
|
46
|
+
safety_alerts_channel_id: string | null;
|
|
47
|
+
}
|
|
48
|
+
export interface RawGuildPreview {
|
|
49
|
+
id: string;
|
|
50
|
+
name: string;
|
|
51
|
+
icon: string | null;
|
|
52
|
+
splash: string | null;
|
|
53
|
+
discovery_splash: string | null;
|
|
54
|
+
emojis: Array<RawEmoji>;
|
|
55
|
+
features: Array<GuildFeatures>;
|
|
56
|
+
approximate_member_count?: number;
|
|
57
|
+
approximate_presence_count?: number;
|
|
58
|
+
description: string | null;
|
|
59
|
+
stickers?: Array<RawSticker>;
|
|
60
|
+
}
|
|
61
|
+
export interface RawGuildWidgetSettings {
|
|
62
|
+
enabled: boolean;
|
|
63
|
+
channel_id: string | null;
|
|
64
|
+
}
|
|
65
|
+
export interface RawGuildWidget {
|
|
66
|
+
id: string;
|
|
67
|
+
name: string;
|
|
68
|
+
instant_invite: string | null;
|
|
69
|
+
channels: Array<RawChannel>;
|
|
70
|
+
members: Array<RawUser>;
|
|
71
|
+
presence_count: number;
|
|
72
|
+
}
|
|
73
|
+
export interface RawGuildMember {
|
|
74
|
+
user?: RawUser;
|
|
75
|
+
nick?: string | null;
|
|
76
|
+
avatar?: string | null;
|
|
77
|
+
roles: Array<string>;
|
|
78
|
+
joined_at: number;
|
|
79
|
+
premium_since?: number | null;
|
|
80
|
+
deaf: boolean;
|
|
81
|
+
mute: boolean;
|
|
82
|
+
flags: GuildMemberFlags;
|
|
83
|
+
pending?: boolean;
|
|
84
|
+
permissions?: string;
|
|
85
|
+
communication_disabled_until?: number | null;
|
|
86
|
+
}
|
|
87
|
+
export interface RawIntegration {
|
|
88
|
+
guild_id: string;
|
|
89
|
+
id: string;
|
|
90
|
+
name: string;
|
|
91
|
+
type: string;
|
|
92
|
+
enabled: boolean;
|
|
93
|
+
syncing?: boolean;
|
|
94
|
+
role_id?: string;
|
|
95
|
+
enable_emoticons?: boolean;
|
|
96
|
+
expire_behavior?: IntegrationExpireBehaviors;
|
|
97
|
+
expire_grace_period?: number;
|
|
98
|
+
user?: RawUser;
|
|
99
|
+
account: RawIntegrationAccount;
|
|
100
|
+
synced_at?: number;
|
|
101
|
+
subscriber_count?: number;
|
|
102
|
+
revoked?: boolean;
|
|
103
|
+
application?: RawIntegrationApplication;
|
|
104
|
+
scopes?: Array<OAuth2Scopes>;
|
|
105
|
+
}
|
|
106
|
+
export interface RawIntegrationAccount {
|
|
107
|
+
id: string;
|
|
108
|
+
name: string;
|
|
109
|
+
}
|
|
110
|
+
export interface RawIntegrationApplication {
|
|
111
|
+
id: string;
|
|
112
|
+
name: string;
|
|
113
|
+
icon: string | null;
|
|
114
|
+
description: string;
|
|
115
|
+
bot?: RawUser;
|
|
116
|
+
}
|
|
117
|
+
export interface RawBan {
|
|
118
|
+
reason: string | null;
|
|
119
|
+
user: RawUser;
|
|
120
|
+
}
|
|
121
|
+
export interface RawWelcomeScreen {
|
|
122
|
+
description: string | null;
|
|
123
|
+
welcome_channels: Array<RawWelcomeScreenChannel>;
|
|
124
|
+
}
|
|
125
|
+
export interface RawWelcomeScreenChannel {
|
|
126
|
+
channel_id: string;
|
|
127
|
+
description: string;
|
|
128
|
+
emoji_id: string | null;
|
|
129
|
+
emoji_name: string | null;
|
|
130
|
+
}
|
|
131
|
+
export interface RawGuildOnboarding {
|
|
132
|
+
guild_id: string;
|
|
133
|
+
prompts: Array<RawOnboardingPrompt>;
|
|
134
|
+
default_channel_ids: Array<string>;
|
|
135
|
+
enabled: boolean;
|
|
136
|
+
mode: OnboardingMode;
|
|
137
|
+
}
|
|
138
|
+
export interface RawOnboardingPrompt {
|
|
139
|
+
id: string;
|
|
140
|
+
type: PromptTypes;
|
|
141
|
+
options: Array<RawPromptOption>;
|
|
142
|
+
title: string;
|
|
143
|
+
single_select: boolean;
|
|
144
|
+
required: boolean;
|
|
145
|
+
in_onboarding: boolean;
|
|
146
|
+
}
|
|
147
|
+
export interface RawPromptOption {
|
|
148
|
+
id: string;
|
|
149
|
+
channel_ids: Array<string>;
|
|
150
|
+
role_ids: Array<string>;
|
|
151
|
+
emoji: RawEmoji;
|
|
152
|
+
title: string;
|
|
153
|
+
description: string | null;
|
|
154
|
+
}
|
|
155
|
+
export interface JSONGuild {
|
|
156
|
+
id: string;
|
|
157
|
+
name: string;
|
|
158
|
+
icon: string | null;
|
|
159
|
+
iconHash?: string | null;
|
|
160
|
+
splash: string | null;
|
|
161
|
+
discoverySplash: string | null;
|
|
162
|
+
owner?: boolean;
|
|
163
|
+
ownerId: string;
|
|
164
|
+
permissions?: string;
|
|
165
|
+
region?: string | null;
|
|
166
|
+
afkChannelId: string | null;
|
|
167
|
+
afkTimeout: number;
|
|
168
|
+
widgetEnabled?: boolean;
|
|
169
|
+
widgetChannelId?: string | null;
|
|
170
|
+
verificationLevel: VerificationLevel;
|
|
171
|
+
defaultMessageNotifications: DefaultMessageNotificationLevel;
|
|
172
|
+
explicitContentFilter: ExplicitContentFilterLevel;
|
|
173
|
+
roles: Array<Role>;
|
|
174
|
+
emojis: Array<JSONEmoji>;
|
|
175
|
+
features: Array<GuildFeatures>;
|
|
176
|
+
mfaLevel: MFALevel;
|
|
177
|
+
applicationId: string | null;
|
|
178
|
+
systemChannelId: string | null;
|
|
179
|
+
systemChannelFlags: SystemChannelFlags;
|
|
180
|
+
rulesChannelId: string | null;
|
|
181
|
+
maxPresences?: number | null;
|
|
182
|
+
maxMembers?: number;
|
|
183
|
+
vanityURLCode: string | null;
|
|
184
|
+
description: string | null;
|
|
185
|
+
banner: string | null;
|
|
186
|
+
premiumTier: PremiumTier;
|
|
187
|
+
premiumSubscriptionCount?: number;
|
|
188
|
+
preferredLocale: string;
|
|
189
|
+
publicUpdatesChannelId: string | null;
|
|
190
|
+
maxVideoChannelUsers?: number;
|
|
191
|
+
approximateMemberCount?: number;
|
|
192
|
+
approximatePresenceCount?: number;
|
|
193
|
+
welcomeScreen?: JSONWelcomeScreen;
|
|
194
|
+
nsfwLevel: GuildNSFWLevel;
|
|
195
|
+
stickers?: Array<JSONSticker>;
|
|
196
|
+
premiumProgressBarEnabled: boolean;
|
|
197
|
+
safetyAlertsChannelId: string | null;
|
|
198
|
+
}
|
|
199
|
+
export interface JSONGuildPreview {
|
|
200
|
+
id: string;
|
|
201
|
+
name: string;
|
|
202
|
+
icon: string | null;
|
|
203
|
+
splash: string | null;
|
|
204
|
+
discoverySplash: string | null;
|
|
205
|
+
emojis: Array<JSONEmoji>;
|
|
206
|
+
features: Array<GuildFeatures>;
|
|
207
|
+
approximateMemberCount?: number;
|
|
208
|
+
approximatePresenceCount?: number;
|
|
209
|
+
description: string | null;
|
|
210
|
+
stickers?: Array<JSONSticker>;
|
|
211
|
+
}
|
|
212
|
+
export interface JSONGuildWidgetSettings {
|
|
213
|
+
enabled: boolean;
|
|
214
|
+
channelId: string | null;
|
|
215
|
+
}
|
|
216
|
+
export interface JSONGuildWidget {
|
|
217
|
+
id: string;
|
|
218
|
+
name: string;
|
|
219
|
+
instantInvite: string | null;
|
|
220
|
+
channels: Array<Channel>;
|
|
221
|
+
members: Array<User>;
|
|
222
|
+
presenceCount: number;
|
|
223
|
+
}
|
|
224
|
+
export interface JSONGuildMember {
|
|
225
|
+
user?: User;
|
|
226
|
+
nick?: string | null;
|
|
227
|
+
avatar?: string | null;
|
|
228
|
+
roles: Array<string>;
|
|
229
|
+
joinedAt: number;
|
|
230
|
+
premiumSince?: number | null;
|
|
231
|
+
deaf: boolean;
|
|
232
|
+
mute: boolean;
|
|
233
|
+
flags: GuildMemberFlags;
|
|
234
|
+
pending?: boolean;
|
|
235
|
+
permissions?: string;
|
|
236
|
+
communicationDisabledUntil?: number | null;
|
|
237
|
+
}
|
|
238
|
+
export interface JSONIntegration {
|
|
239
|
+
guildId: string;
|
|
240
|
+
id: string;
|
|
241
|
+
name: string;
|
|
242
|
+
type: string;
|
|
243
|
+
enabled: boolean;
|
|
244
|
+
syncing?: boolean;
|
|
245
|
+
roleId?: string;
|
|
246
|
+
enableEmoticons?: boolean;
|
|
247
|
+
expireBehavior?: IntegrationExpireBehaviors;
|
|
248
|
+
expireGracePeriod?: number;
|
|
249
|
+
user?: User;
|
|
250
|
+
account: JSONIntegrationAccount;
|
|
251
|
+
syncedAt?: number;
|
|
252
|
+
subscriberCount?: number;
|
|
253
|
+
revoked?: boolean;
|
|
254
|
+
application?: JSONIntegrationApplication;
|
|
255
|
+
scopes?: Array<OAuth2Scopes>;
|
|
256
|
+
}
|
|
257
|
+
export interface JSONIntegrationAccount {
|
|
258
|
+
id: string;
|
|
259
|
+
name: string;
|
|
260
|
+
}
|
|
261
|
+
export interface JSONIntegrationApplication {
|
|
262
|
+
id: string;
|
|
263
|
+
name: string;
|
|
264
|
+
icon: string | null;
|
|
265
|
+
description: string;
|
|
266
|
+
bot?: User;
|
|
267
|
+
}
|
|
268
|
+
export interface JSONBan {
|
|
269
|
+
reason: string | null;
|
|
270
|
+
user: User;
|
|
271
|
+
}
|
|
272
|
+
export interface JSONWelcomeScreen {
|
|
273
|
+
description: string | null;
|
|
274
|
+
welcomeChannels: Array<JSONWelcomeScreenChannel>;
|
|
275
|
+
}
|
|
276
|
+
export interface JSONWelcomeScreenChannel {
|
|
277
|
+
channelId: string;
|
|
278
|
+
description: string;
|
|
279
|
+
emojiId: string | null;
|
|
280
|
+
emojiName: string | null;
|
|
281
|
+
}
|
|
282
|
+
export interface JSONGuildOnboarding {
|
|
283
|
+
guildId: string;
|
|
284
|
+
prompts: Array<JSONOnboardingPrompt>;
|
|
285
|
+
defaultChannelIds: Array<string>;
|
|
286
|
+
enabled: boolean;
|
|
287
|
+
mode: OnboardingMode;
|
|
288
|
+
}
|
|
289
|
+
export interface JSONOnboardingPrompt {
|
|
290
|
+
id: string;
|
|
291
|
+
type: PromptTypes;
|
|
292
|
+
options: Array<JSONPromptOption>;
|
|
293
|
+
title: string;
|
|
294
|
+
singleSelect: boolean;
|
|
295
|
+
required: boolean;
|
|
296
|
+
inOnboarding: boolean;
|
|
297
|
+
}
|
|
298
|
+
export interface JSONPromptOption {
|
|
299
|
+
id: string;
|
|
300
|
+
channelIds: Array<string>;
|
|
301
|
+
roleIds: Array<string>;
|
|
302
|
+
emoji: JSONEmoji;
|
|
303
|
+
title: string;
|
|
304
|
+
description: string | null;
|
|
305
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"guild.js","sourceRoot":"","sources":["../../src/types/guild.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export * from "./application";
|
|
2
|
+
export * from "./application-role-connection-metadata";
|
|
3
|
+
export * from "./audit-log";
|
|
4
|
+
export * from "./auto-moderation";
|
|
5
|
+
export * from "./channel";
|
|
6
|
+
export * from "./emoji";
|
|
7
|
+
export * from "./gateway-events";
|
|
8
|
+
export * from "./guild";
|
|
9
|
+
export * from "./guild-scheduled-event";
|
|
10
|
+
export * from "./guild-template";
|
|
11
|
+
export * from "./invite";
|
|
12
|
+
export * from "./oauth2";
|
|
13
|
+
export * from "./stage-instance";
|
|
14
|
+
export * from "./sticker";
|
|
15
|
+
export * from "./user";
|
|
16
|
+
export * from "./voice";
|
|
17
|
+
export * from "./webhook";
|
|
18
|
+
export * from "./role";
|
|
19
|
+
export * from "./team";
|
|
20
|
+
export * from "./application-command";
|
|
21
|
+
export * from "./message-components";
|
|
22
|
+
export * from "./interaction";
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./application"), exports);
|
|
18
|
+
__exportStar(require("./application-role-connection-metadata"), exports);
|
|
19
|
+
__exportStar(require("./audit-log"), exports);
|
|
20
|
+
__exportStar(require("./auto-moderation"), exports);
|
|
21
|
+
__exportStar(require("./channel"), exports);
|
|
22
|
+
__exportStar(require("./emoji"), exports);
|
|
23
|
+
__exportStar(require("./gateway-events"), exports);
|
|
24
|
+
__exportStar(require("./guild"), exports);
|
|
25
|
+
__exportStar(require("./guild-scheduled-event"), exports);
|
|
26
|
+
__exportStar(require("./guild-template"), exports);
|
|
27
|
+
__exportStar(require("./invite"), exports);
|
|
28
|
+
__exportStar(require("./oauth2"), exports);
|
|
29
|
+
__exportStar(require("./stage-instance"), exports);
|
|
30
|
+
__exportStar(require("./sticker"), exports);
|
|
31
|
+
__exportStar(require("./user"), exports);
|
|
32
|
+
__exportStar(require("./voice"), exports);
|
|
33
|
+
__exportStar(require("./webhook"), exports);
|
|
34
|
+
__exportStar(require("./role"), exports);
|
|
35
|
+
__exportStar(require("./team"), exports);
|
|
36
|
+
__exportStar(require("./application-command"), exports);
|
|
37
|
+
__exportStar(require("./message-components"), exports);
|
|
38
|
+
__exportStar(require("./interaction"), exports);
|
|
39
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,yEAAuD;AACvD,8CAA4B;AAC5B,oDAAkC;AAClC,4CAA0B;AAC1B,0CAAwB;AACxB,mDAAiC;AACjC,0CAAwB;AACxB,0DAAwC;AACxC,mDAAiC;AACjC,2CAAyB;AACzB,2CAAyB;AACzB,mDAAiC;AACjC,4CAA0B;AAC1B,yCAAuB;AACvB,0CAAwB;AACxB,4CAA0B;AAC1B,yCAAuB;AACvB,yCAAuB;AACvB,wDAAsC;AACtC,uDAAqC;AACrC,gDAA8B"}
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
import type { RawAttachment, RawChannel, RawGuildMember, RawMessage, RawUser, RawSelectOption, RawRole, JSONAttachment, JSONSelectOption } from ".";
|
|
2
|
+
import type { Channel, GuildMember, Message, Role, User } from "../structures";
|
|
3
|
+
import type { ComponentTypes, InteractionType } from "../utils/constants";
|
|
4
|
+
export interface RawInteraction {
|
|
5
|
+
id: string;
|
|
6
|
+
application_id: string;
|
|
7
|
+
type: InteractionType;
|
|
8
|
+
data?: RawApplicationCommandData & RawMessageComponentData & RawModalSubmitData;
|
|
9
|
+
guild_id?: string;
|
|
10
|
+
channel_id?: string;
|
|
11
|
+
member?: RawGuildMember;
|
|
12
|
+
user?: RawUser;
|
|
13
|
+
token: string;
|
|
14
|
+
version: number;
|
|
15
|
+
message?: RawMessage;
|
|
16
|
+
app_permissions?: string;
|
|
17
|
+
locale?: string;
|
|
18
|
+
guild_locale?: string;
|
|
19
|
+
}
|
|
20
|
+
export interface RawApplicationCommandData {
|
|
21
|
+
id: string;
|
|
22
|
+
name: string;
|
|
23
|
+
type: number;
|
|
24
|
+
resolved?: RawResolvedData;
|
|
25
|
+
options?: Array<RawApplicationCommandInteractionDataOption>;
|
|
26
|
+
guild_id?: string;
|
|
27
|
+
target_id?: string;
|
|
28
|
+
}
|
|
29
|
+
export interface RawMessageComponentData {
|
|
30
|
+
custom_id: string;
|
|
31
|
+
component_type: number;
|
|
32
|
+
values?: Array<RawSelectOption>;
|
|
33
|
+
}
|
|
34
|
+
export interface RawModalSubmitData {
|
|
35
|
+
custom_id: string;
|
|
36
|
+
components: Array<{
|
|
37
|
+
type: ComponentTypes.ActionRow;
|
|
38
|
+
components: Array<{
|
|
39
|
+
type: ComponentTypes.TextInput;
|
|
40
|
+
custom_id: string;
|
|
41
|
+
style: number;
|
|
42
|
+
label: string;
|
|
43
|
+
min_length?: number;
|
|
44
|
+
max_length?: number;
|
|
45
|
+
required?: boolean;
|
|
46
|
+
value?: string;
|
|
47
|
+
placeholder?: string;
|
|
48
|
+
}>;
|
|
49
|
+
}>;
|
|
50
|
+
}
|
|
51
|
+
export interface RawResolvedData {
|
|
52
|
+
users?: Array<RawUser>;
|
|
53
|
+
members?: Array<RawGuildMember>;
|
|
54
|
+
roles?: Array<RawRole>;
|
|
55
|
+
channels?: Array<RawChannel>;
|
|
56
|
+
messages?: Array<RawMessage>;
|
|
57
|
+
attachments?: Array<RawAttachment>;
|
|
58
|
+
}
|
|
59
|
+
export interface RawApplicationCommandInteractionDataOption {
|
|
60
|
+
name: string;
|
|
61
|
+
type: number;
|
|
62
|
+
value?: string | number | boolean;
|
|
63
|
+
options?: Array<RawApplicationCommandInteractionDataOption>;
|
|
64
|
+
focused?: boolean;
|
|
65
|
+
}
|
|
66
|
+
export interface RawMessageInteraction {
|
|
67
|
+
id: string;
|
|
68
|
+
type: InteractionType;
|
|
69
|
+
name: string;
|
|
70
|
+
user: RawUser;
|
|
71
|
+
member?: RawGuildMember;
|
|
72
|
+
}
|
|
73
|
+
export interface JSONInteraction {
|
|
74
|
+
id: string;
|
|
75
|
+
applicationId: string;
|
|
76
|
+
type: InteractionType;
|
|
77
|
+
data?: JSONApplicationCommandData & JSONMessageComponentData & JSONModalSubmitData;
|
|
78
|
+
guildId?: string;
|
|
79
|
+
channelId?: string;
|
|
80
|
+
member?: GuildMember;
|
|
81
|
+
user?: User;
|
|
82
|
+
token: string;
|
|
83
|
+
version: number;
|
|
84
|
+
message?: Message;
|
|
85
|
+
appPermissions?: string;
|
|
86
|
+
locale?: string;
|
|
87
|
+
guildLocale?: string;
|
|
88
|
+
}
|
|
89
|
+
export interface JSONApplicationCommandData {
|
|
90
|
+
id: string;
|
|
91
|
+
name: string;
|
|
92
|
+
type: number;
|
|
93
|
+
resolved?: JSONResolvedData;
|
|
94
|
+
options?: Array<JSONApplicationCommandInteractionDataOption>;
|
|
95
|
+
guildId?: string;
|
|
96
|
+
targetId?: string;
|
|
97
|
+
}
|
|
98
|
+
export interface JSONMessageComponentData {
|
|
99
|
+
customId: string;
|
|
100
|
+
componentType: number;
|
|
101
|
+
values?: Array<JSONSelectOption>;
|
|
102
|
+
}
|
|
103
|
+
export interface JSONModalSubmitData {
|
|
104
|
+
customId: string;
|
|
105
|
+
components: Array<{
|
|
106
|
+
type: ComponentTypes.ActionRow;
|
|
107
|
+
components: Array<{
|
|
108
|
+
type: ComponentTypes.TextInput;
|
|
109
|
+
customId: string;
|
|
110
|
+
style: number;
|
|
111
|
+
label: string;
|
|
112
|
+
minLength?: number;
|
|
113
|
+
maxLength?: number;
|
|
114
|
+
required?: boolean;
|
|
115
|
+
value?: string;
|
|
116
|
+
placeholder?: string;
|
|
117
|
+
}>;
|
|
118
|
+
}>;
|
|
119
|
+
}
|
|
120
|
+
export interface JSONResolvedData {
|
|
121
|
+
users?: Array<User>;
|
|
122
|
+
members?: Array<GuildMember>;
|
|
123
|
+
roles?: Array<Role>;
|
|
124
|
+
channels?: Array<Channel>;
|
|
125
|
+
messages?: Array<Message>;
|
|
126
|
+
attachments?: Array<JSONAttachment>;
|
|
127
|
+
}
|
|
128
|
+
export interface JSONApplicationCommandInteractionDataOption {
|
|
129
|
+
name: string;
|
|
130
|
+
type: number;
|
|
131
|
+
value?: string | number | boolean;
|
|
132
|
+
options?: Array<JSONApplicationCommandInteractionDataOption>;
|
|
133
|
+
focused?: boolean;
|
|
134
|
+
}
|
|
135
|
+
export interface JSONMessageInteraction {
|
|
136
|
+
id: string;
|
|
137
|
+
type: InteractionType;
|
|
138
|
+
name: string;
|
|
139
|
+
user: User;
|
|
140
|
+
member?: GuildMember;
|
|
141
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"interaction.js","sourceRoot":"","sources":["../../src/types/interaction.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import type { RawApplication, RawChannel, RawGuild, RawGuildMember, RawGuildScheduledEvent, RawUser } from ".";
|
|
2
|
+
import type { Application, Channel, Guild, GuildMember, GuildScheduledEvent, User } from "../structures";
|
|
3
|
+
export interface RawInvite {
|
|
4
|
+
code: string;
|
|
5
|
+
guild?: RawGuild;
|
|
6
|
+
channel: RawChannel;
|
|
7
|
+
inviter?: RawUser;
|
|
8
|
+
target_type?: number;
|
|
9
|
+
target_user?: RawUser;
|
|
10
|
+
target_application?: RawApplication;
|
|
11
|
+
approximate_presence_count?: number;
|
|
12
|
+
approximate_member_count?: number;
|
|
13
|
+
expires_at?: string | null;
|
|
14
|
+
stage_instance?: RawInviteStageInstance;
|
|
15
|
+
guild_scheduled_event?: RawGuildScheduledEvent;
|
|
16
|
+
}
|
|
17
|
+
export interface RawInviteMetadata {
|
|
18
|
+
uses: number;
|
|
19
|
+
max_uses: number;
|
|
20
|
+
max_age: number;
|
|
21
|
+
temporary: boolean;
|
|
22
|
+
created_at: string;
|
|
23
|
+
}
|
|
24
|
+
export interface RawInviteStageInstance {
|
|
25
|
+
members: Array<RawGuildMember>;
|
|
26
|
+
participant_count: number;
|
|
27
|
+
speaker_count: number;
|
|
28
|
+
topic: string;
|
|
29
|
+
}
|
|
30
|
+
export interface JSONInvite {
|
|
31
|
+
code: string;
|
|
32
|
+
guild?: Guild;
|
|
33
|
+
channel: Channel;
|
|
34
|
+
inviter?: User;
|
|
35
|
+
targetType?: number;
|
|
36
|
+
targetUser?: User;
|
|
37
|
+
targetApplication?: Application;
|
|
38
|
+
approximatePresenceCount?: number;
|
|
39
|
+
approximateMemberCount?: number;
|
|
40
|
+
expiresAt?: string | null;
|
|
41
|
+
stageInstance?: JSONInviteStageInstance;
|
|
42
|
+
guildScheduledEvent?: GuildScheduledEvent;
|
|
43
|
+
}
|
|
44
|
+
export interface JSONInviteMetadata {
|
|
45
|
+
uses: number;
|
|
46
|
+
maxUses: number;
|
|
47
|
+
maxAge: number;
|
|
48
|
+
temporary: boolean;
|
|
49
|
+
createdAt: string;
|
|
50
|
+
}
|
|
51
|
+
export interface JSONInviteStageInstance {
|
|
52
|
+
members: Array<GuildMember>;
|
|
53
|
+
participantCount: number;
|
|
54
|
+
speakerCount: number;
|
|
55
|
+
topic: string;
|
|
56
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"invite.js","sourceRoot":"","sources":["../../src/types/invite.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import type { JSONEmoji, RawEmoji } from ".";
|
|
2
|
+
import type { ChannelTypes } from "../utils/constants";
|
|
3
|
+
export interface RawButton {
|
|
4
|
+
type: number;
|
|
5
|
+
style: number;
|
|
6
|
+
label?: string;
|
|
7
|
+
emoji?: RawEmoji;
|
|
8
|
+
custom_id?: string;
|
|
9
|
+
url?: string;
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
}
|
|
12
|
+
export interface RawSelectMenu {
|
|
13
|
+
type: number;
|
|
14
|
+
custom_id: string;
|
|
15
|
+
options?: Array<RawSelectOption>;
|
|
16
|
+
channel_types?: Array<ChannelTypes>;
|
|
17
|
+
placeholder?: string;
|
|
18
|
+
min_values?: number;
|
|
19
|
+
max_values?: number;
|
|
20
|
+
disabled?: boolean;
|
|
21
|
+
}
|
|
22
|
+
export interface RawSelectOption {
|
|
23
|
+
label: string;
|
|
24
|
+
value: string;
|
|
25
|
+
description?: string;
|
|
26
|
+
emoji?: RawEmoji;
|
|
27
|
+
default?: boolean;
|
|
28
|
+
}
|
|
29
|
+
export interface RawTextInput {
|
|
30
|
+
type: number;
|
|
31
|
+
custom_id: string;
|
|
32
|
+
style: number;
|
|
33
|
+
label: string;
|
|
34
|
+
min_length?: number;
|
|
35
|
+
max_length?: number;
|
|
36
|
+
required?: boolean;
|
|
37
|
+
value?: string;
|
|
38
|
+
placeholder?: string;
|
|
39
|
+
}
|
|
40
|
+
export interface JSONButton {
|
|
41
|
+
type: number;
|
|
42
|
+
style: number;
|
|
43
|
+
label?: string;
|
|
44
|
+
emoji?: JSONEmoji;
|
|
45
|
+
customId?: string;
|
|
46
|
+
url?: string;
|
|
47
|
+
disabled?: boolean;
|
|
48
|
+
}
|
|
49
|
+
export interface JSONSelectMenu {
|
|
50
|
+
type: number;
|
|
51
|
+
customId: string;
|
|
52
|
+
options?: Array<JSONSelectOption>;
|
|
53
|
+
channelTypes?: Array<ChannelTypes>;
|
|
54
|
+
placeholder?: string;
|
|
55
|
+
minValues?: number;
|
|
56
|
+
maxValues?: number;
|
|
57
|
+
disabled?: boolean;
|
|
58
|
+
}
|
|
59
|
+
export interface JSONSelectOption {
|
|
60
|
+
label: string;
|
|
61
|
+
value: string;
|
|
62
|
+
description?: string;
|
|
63
|
+
emoji?: JSONEmoji;
|
|
64
|
+
default?: boolean;
|
|
65
|
+
}
|
|
66
|
+
export interface JSONTextInput {
|
|
67
|
+
type: number;
|
|
68
|
+
customId: string;
|
|
69
|
+
style: number;
|
|
70
|
+
label: string;
|
|
71
|
+
minLength?: number;
|
|
72
|
+
maxLength?: number;
|
|
73
|
+
required?: boolean;
|
|
74
|
+
value?: string;
|
|
75
|
+
placeholder?: string;
|
|
76
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"message-components.js","sourceRoot":"","sources":["../../src/types/message-components.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { RawApplication, RawUser } from ".";
|
|
2
|
+
import type { Application, User } from "../structures";
|
|
3
|
+
export interface RawResponse {
|
|
4
|
+
application: RawApplication;
|
|
5
|
+
scopes: Array<string>;
|
|
6
|
+
expires: number;
|
|
7
|
+
user?: RawUser;
|
|
8
|
+
}
|
|
9
|
+
export interface JSONResponse {
|
|
10
|
+
application: Application;
|
|
11
|
+
scopes: Array<string>;
|
|
12
|
+
expires: number;
|
|
13
|
+
user?: User;
|
|
14
|
+
}
|