disgroove 3.0.1-dev.c1d6d42 → 3.0.2
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/LICENSE +1 -1
- package/dist/lib/Client.d.ts +53 -11
- package/dist/lib/Client.js +79 -23
- package/dist/lib/constants.d.ts +21 -9
- package/dist/lib/constants.js +21 -8
- package/dist/lib/gateway/Dispatcher.js +1 -0
- package/dist/lib/gateway/Shard.js +1 -0
- package/dist/lib/gateway/Transmitter.js +2 -1
- package/dist/lib/rest/Endpoints.d.ts +5 -1
- package/dist/lib/rest/Endpoints.js +9 -1
- package/dist/lib/rest/RequestManager.d.ts +1 -0
- package/dist/lib/rest/RequestManager.js +2 -3
- package/dist/lib/transformers/ApplicationCommands.js +2 -0
- package/dist/lib/transformers/Applications.js +2 -0
- package/dist/lib/transformers/Channels.d.ts +3 -0
- package/dist/lib/transformers/Channels.js +24 -0
- package/dist/lib/transformers/Components.js +2 -0
- package/dist/lib/transformers/Lobbies.d.ts +3 -1
- package/dist/lib/transformers/Lobbies.js +31 -0
- package/dist/lib/types/application-command.d.ts +2 -0
- package/dist/lib/types/application.d.ts +2 -0
- package/dist/lib/types/channel.d.ts +4 -2
- package/dist/lib/types/components.d.ts +4 -2
- package/dist/lib/types/gateway-events.d.ts +9 -3
- package/dist/lib/types/lobby.d.ts +38 -1
- package/dist/lib/types/message.d.ts +20 -0
- package/dist/lib/utils/formatters.d.ts +2 -0
- package/dist/lib/utils/formatters.js +5 -0
- package/dist/package.json +6 -5
- package/package.json +7 -6
|
@@ -197,6 +197,16 @@ export interface RawAttachment {
|
|
|
197
197
|
clip_created_at?: timestamp;
|
|
198
198
|
application?: RawApplication | null;
|
|
199
199
|
}
|
|
200
|
+
/** https://docs.discord.com/developers/resources/message#attachment-object-attachment-request-structure */
|
|
201
|
+
export interface RawAttachmentRequest {
|
|
202
|
+
id: snowflake | number;
|
|
203
|
+
filename?: string;
|
|
204
|
+
title?: string;
|
|
205
|
+
description?: string;
|
|
206
|
+
duration_secs?: number;
|
|
207
|
+
waveform?: string;
|
|
208
|
+
is_spoiler?: boolean;
|
|
209
|
+
}
|
|
200
210
|
/** https://discord.com/developers/docs/resources/message#channel-mention-object-channel-mention-structure */
|
|
201
211
|
export interface RawChannelMention {
|
|
202
212
|
id: snowflake;
|
|
@@ -419,6 +429,16 @@ export interface Attachment {
|
|
|
419
429
|
clipCreatedAt?: timestamp;
|
|
420
430
|
application?: Application | null;
|
|
421
431
|
}
|
|
432
|
+
/** https://docs.discord.com/developers/resources/message#attachment-object-attachment-request-structure */
|
|
433
|
+
export interface AttachmentRequest {
|
|
434
|
+
id: snowflake | number;
|
|
435
|
+
filename?: string;
|
|
436
|
+
title?: string;
|
|
437
|
+
description?: string;
|
|
438
|
+
durationSecs?: number;
|
|
439
|
+
waveform?: string;
|
|
440
|
+
isSpoiler?: boolean;
|
|
441
|
+
}
|
|
422
442
|
/** https://discord.com/developers/docs/resources/message#channel-mention-object-channel-mention-structure */
|
|
423
443
|
export interface ChannelMention {
|
|
424
444
|
id: snowflake;
|
|
@@ -7,6 +7,8 @@ export declare function channelMention(channelId: snowflake): string;
|
|
|
7
7
|
/** https://discord.com/developers/docs/reference#message-formatting-formats */
|
|
8
8
|
export declare function roleMention(roleId: snowflake): string;
|
|
9
9
|
/** https://discord.com/developers/docs/reference#message-formatting-formats */
|
|
10
|
+
export declare function gameProfile(gameId: snowflake): string;
|
|
11
|
+
/** https://discord.com/developers/docs/reference#message-formatting-formats */
|
|
10
12
|
export declare function slashCommandMention(commandName: string, commandId: snowflake, subCommandName?: string, subCommandGroupName?: string): string;
|
|
11
13
|
/** https://discord.com/developers/docs/reference#message-formatting-formats */
|
|
12
14
|
export declare function customEmoji(emojiName: string, emojiId: snowflake, animated?: boolean): string;
|
|
@@ -3,6 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.userMention = userMention;
|
|
4
4
|
exports.channelMention = channelMention;
|
|
5
5
|
exports.roleMention = roleMention;
|
|
6
|
+
exports.gameProfile = gameProfile;
|
|
6
7
|
exports.slashCommandMention = slashCommandMention;
|
|
7
8
|
exports.customEmoji = customEmoji;
|
|
8
9
|
exports.unixTimestamp = unixTimestamp;
|
|
@@ -23,6 +24,10 @@ function roleMention(roleId) {
|
|
|
23
24
|
return `<@&${roleId}>`;
|
|
24
25
|
}
|
|
25
26
|
/** https://discord.com/developers/docs/reference#message-formatting-formats */
|
|
27
|
+
function gameProfile(gameId) {
|
|
28
|
+
return `<@$${gameId}>`;
|
|
29
|
+
}
|
|
30
|
+
/** https://discord.com/developers/docs/reference#message-formatting-formats */
|
|
26
31
|
function slashCommandMention(commandName, commandId, subCommandName, subCommandGroupName) {
|
|
27
32
|
return subCommandName
|
|
28
33
|
? subCommandGroupName
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "disgroove",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.2",
|
|
4
4
|
"description": "A module to interface with Discord",
|
|
5
5
|
"main": "./dist/lib/index.js",
|
|
6
6
|
"types": "./dist/lib/index.d.ts",
|
|
@@ -18,19 +18,20 @@
|
|
|
18
18
|
"rest",
|
|
19
19
|
"wrapper"
|
|
20
20
|
],
|
|
21
|
-
"author": "
|
|
21
|
+
"author": "Sergio Gotuzzo",
|
|
22
22
|
"license": "MIT",
|
|
23
23
|
"bugs": {
|
|
24
24
|
"url": "https://github.com/sergiogotuzzo/disgroove/issues"
|
|
25
25
|
},
|
|
26
26
|
"homepage": "https://github.com/sergiogotuzzo/disgroove#readme",
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@types/node": "^22.
|
|
28
|
+
"@types/node": "^22.20.1",
|
|
29
29
|
"@types/ws": "^8.18.1",
|
|
30
30
|
"typescript": "^5.9.3",
|
|
31
|
-
"undici-types": "^7.
|
|
31
|
+
"undici-types": "^7.29.1",
|
|
32
|
+
"@types/bun": "latest"
|
|
32
33
|
},
|
|
33
34
|
"dependencies": {
|
|
34
|
-
"ws": "^8.
|
|
35
|
+
"ws": "^8.21.3"
|
|
35
36
|
}
|
|
36
37
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "disgroove",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.2",
|
|
4
4
|
"description": "A module to interface with Discord",
|
|
5
5
|
"main": "./dist/lib/index.js",
|
|
6
6
|
"types": "./dist/lib/index.d.ts",
|
|
@@ -18,19 +18,20 @@
|
|
|
18
18
|
"rest",
|
|
19
19
|
"wrapper"
|
|
20
20
|
],
|
|
21
|
-
"author": "
|
|
21
|
+
"author": "Sergio Gotuzzo",
|
|
22
22
|
"license": "MIT",
|
|
23
23
|
"bugs": {
|
|
24
24
|
"url": "https://github.com/sergiogotuzzo/disgroove/issues"
|
|
25
25
|
},
|
|
26
26
|
"homepage": "https://github.com/sergiogotuzzo/disgroove#readme",
|
|
27
27
|
"devDependencies": {
|
|
28
|
-
"@types/node": "^22.
|
|
28
|
+
"@types/node": "^22.20.1",
|
|
29
29
|
"@types/ws": "^8.18.1",
|
|
30
30
|
"typescript": "^5.9.3",
|
|
31
|
-
"undici-types": "^7.
|
|
31
|
+
"undici-types": "^7.29.1",
|
|
32
|
+
"@types/bun": "latest"
|
|
32
33
|
},
|
|
33
34
|
"dependencies": {
|
|
34
|
-
"ws": "^8.
|
|
35
|
+
"ws": "^8.21.3"
|
|
35
36
|
}
|
|
36
|
-
}
|
|
37
|
+
}
|