@discordjs/core 1.3.0-dev.1721607094-b2970bb2d → 2.0.0-dev.1721866231-bf6761a44
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/http-only.js +1 -1
- package/dist/http-only.js.map +1 -1
- package/dist/http-only.mjs +1 -1
- package/dist/http-only.mjs.map +1 -1
- package/dist/index.d.mts +69 -73
- package/dist/index.d.ts +69 -73
- package/dist/index.js +4 -8
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -8
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.d.mts
CHANGED
|
@@ -1839,86 +1839,82 @@ interface IntrinsicProps {
|
|
|
1839
1839
|
*/
|
|
1840
1840
|
shardId: number;
|
|
1841
1841
|
}
|
|
1842
|
-
interface
|
|
1842
|
+
interface ToEventProps<Data> extends IntrinsicProps {
|
|
1843
1843
|
data: Data;
|
|
1844
1844
|
}
|
|
1845
1845
|
interface MappedEvents {
|
|
1846
1846
|
[GatewayDispatchEvents.ApplicationCommandPermissionsUpdate]: [
|
|
1847
|
-
|
|
1847
|
+
ToEventProps<GatewayApplicationCommandPermissionsUpdateDispatchData>
|
|
1848
1848
|
];
|
|
1849
1849
|
[GatewayDispatchEvents.AutoModerationActionExecution]: [
|
|
1850
|
-
|
|
1851
|
-
];
|
|
1852
|
-
[GatewayDispatchEvents.AutoModerationRuleCreate]: [WithIntrinsicProps<GatewayAutoModerationRuleCreateDispatchData>];
|
|
1853
|
-
[GatewayDispatchEvents.AutoModerationRuleDelete]: [WithIntrinsicProps<GatewayAutoModerationRuleDeleteDispatchData>];
|
|
1854
|
-
[GatewayDispatchEvents.AutoModerationRuleUpdate]: [WithIntrinsicProps<GatewayAutoModerationRuleUpdateDispatchData>];
|
|
1855
|
-
[GatewayDispatchEvents.ChannelCreate]: [WithIntrinsicProps<GatewayChannelCreateDispatchData>];
|
|
1856
|
-
[GatewayDispatchEvents.ChannelDelete]: [WithIntrinsicProps<GatewayChannelDeleteDispatchData>];
|
|
1857
|
-
[GatewayDispatchEvents.ChannelPinsUpdate]: [WithIntrinsicProps<GatewayChannelPinsUpdateDispatchData>];
|
|
1858
|
-
[GatewayDispatchEvents.ChannelUpdate]: [WithIntrinsicProps<GatewayChannelUpdateDispatchData>];
|
|
1859
|
-
[GatewayDispatchEvents.EntitlementCreate]: [WithIntrinsicProps<GatewayEntitlementCreateDispatchData>];
|
|
1860
|
-
[GatewayDispatchEvents.EntitlementDelete]: [WithIntrinsicProps<GatewayEntitlementDeleteDispatchData>];
|
|
1861
|
-
[GatewayDispatchEvents.EntitlementUpdate]: [WithIntrinsicProps<GatewayEntitlementUpdateDispatchData>];
|
|
1862
|
-
[GatewayDispatchEvents.GuildAuditLogEntryCreate]: [WithIntrinsicProps<GatewayGuildAuditLogEntryCreateDispatchData>];
|
|
1863
|
-
[GatewayDispatchEvents.GuildBanAdd]: [WithIntrinsicProps<GatewayGuildBanAddDispatchData>];
|
|
1864
|
-
[GatewayDispatchEvents.GuildBanRemove]: [WithIntrinsicProps<GatewayGuildBanRemoveDispatchData>];
|
|
1865
|
-
[GatewayDispatchEvents.GuildCreate]: [WithIntrinsicProps<GatewayGuildCreateDispatchData>];
|
|
1866
|
-
[GatewayDispatchEvents.GuildDelete]: [WithIntrinsicProps<GatewayGuildDeleteDispatchData>];
|
|
1867
|
-
[GatewayDispatchEvents.GuildEmojisUpdate]: [WithIntrinsicProps<GatewayGuildEmojisUpdateDispatchData>];
|
|
1868
|
-
[GatewayDispatchEvents.GuildIntegrationsUpdate]: [WithIntrinsicProps<GatewayGuildIntegrationsUpdateDispatchData>];
|
|
1869
|
-
[GatewayDispatchEvents.GuildMemberAdd]: [WithIntrinsicProps<GatewayGuildMemberAddDispatchData>];
|
|
1870
|
-
[GatewayDispatchEvents.GuildMemberRemove]: [WithIntrinsicProps<GatewayGuildMemberRemoveDispatchData>];
|
|
1871
|
-
[GatewayDispatchEvents.GuildMemberUpdate]: [WithIntrinsicProps<GatewayGuildMemberUpdateDispatchData>];
|
|
1872
|
-
[GatewayDispatchEvents.GuildMembersChunk]: [WithIntrinsicProps<GatewayGuildMembersChunkDispatchData>];
|
|
1873
|
-
[GatewayDispatchEvents.GuildRoleCreate]: [WithIntrinsicProps<GatewayGuildRoleCreateDispatchData>];
|
|
1874
|
-
[GatewayDispatchEvents.GuildRoleDelete]: [WithIntrinsicProps<GatewayGuildRoleDeleteDispatchData>];
|
|
1875
|
-
[GatewayDispatchEvents.GuildRoleUpdate]: [WithIntrinsicProps<GatewayGuildRoleUpdateDispatchData>];
|
|
1876
|
-
[GatewayDispatchEvents.GuildScheduledEventCreate]: [WithIntrinsicProps<GatewayGuildScheduledEventCreateDispatchData>];
|
|
1877
|
-
[GatewayDispatchEvents.GuildScheduledEventDelete]: [WithIntrinsicProps<GatewayGuildScheduledEventDeleteDispatchData>];
|
|
1878
|
-
[GatewayDispatchEvents.GuildScheduledEventUpdate]: [WithIntrinsicProps<GatewayGuildScheduledEventUpdateDispatchData>];
|
|
1879
|
-
[GatewayDispatchEvents.GuildScheduledEventUserAdd]: [
|
|
1880
|
-
WithIntrinsicProps<GatewayGuildScheduledEventUserAddDispatchData>
|
|
1850
|
+
ToEventProps<GatewayAutoModerationActionExecutionDispatchData>
|
|
1881
1851
|
];
|
|
1852
|
+
[GatewayDispatchEvents.AutoModerationRuleCreate]: [ToEventProps<GatewayAutoModerationRuleCreateDispatchData>];
|
|
1853
|
+
[GatewayDispatchEvents.AutoModerationRuleDelete]: [ToEventProps<GatewayAutoModerationRuleDeleteDispatchData>];
|
|
1854
|
+
[GatewayDispatchEvents.AutoModerationRuleUpdate]: [ToEventProps<GatewayAutoModerationRuleUpdateDispatchData>];
|
|
1855
|
+
[GatewayDispatchEvents.ChannelCreate]: [ToEventProps<GatewayChannelCreateDispatchData>];
|
|
1856
|
+
[GatewayDispatchEvents.ChannelDelete]: [ToEventProps<GatewayChannelDeleteDispatchData>];
|
|
1857
|
+
[GatewayDispatchEvents.ChannelPinsUpdate]: [ToEventProps<GatewayChannelPinsUpdateDispatchData>];
|
|
1858
|
+
[GatewayDispatchEvents.ChannelUpdate]: [ToEventProps<GatewayChannelUpdateDispatchData>];
|
|
1859
|
+
[GatewayDispatchEvents.EntitlementCreate]: [ToEventProps<GatewayEntitlementCreateDispatchData>];
|
|
1860
|
+
[GatewayDispatchEvents.EntitlementDelete]: [ToEventProps<GatewayEntitlementDeleteDispatchData>];
|
|
1861
|
+
[GatewayDispatchEvents.EntitlementUpdate]: [ToEventProps<GatewayEntitlementUpdateDispatchData>];
|
|
1862
|
+
[GatewayDispatchEvents.GuildAuditLogEntryCreate]: [ToEventProps<GatewayGuildAuditLogEntryCreateDispatchData>];
|
|
1863
|
+
[GatewayDispatchEvents.GuildBanAdd]: [ToEventProps<GatewayGuildBanAddDispatchData>];
|
|
1864
|
+
[GatewayDispatchEvents.GuildBanRemove]: [ToEventProps<GatewayGuildBanRemoveDispatchData>];
|
|
1865
|
+
[GatewayDispatchEvents.GuildCreate]: [ToEventProps<GatewayGuildCreateDispatchData>];
|
|
1866
|
+
[GatewayDispatchEvents.GuildDelete]: [ToEventProps<GatewayGuildDeleteDispatchData>];
|
|
1867
|
+
[GatewayDispatchEvents.GuildEmojisUpdate]: [ToEventProps<GatewayGuildEmojisUpdateDispatchData>];
|
|
1868
|
+
[GatewayDispatchEvents.GuildIntegrationsUpdate]: [ToEventProps<GatewayGuildIntegrationsUpdateDispatchData>];
|
|
1869
|
+
[GatewayDispatchEvents.GuildMemberAdd]: [ToEventProps<GatewayGuildMemberAddDispatchData>];
|
|
1870
|
+
[GatewayDispatchEvents.GuildMemberRemove]: [ToEventProps<GatewayGuildMemberRemoveDispatchData>];
|
|
1871
|
+
[GatewayDispatchEvents.GuildMemberUpdate]: [ToEventProps<GatewayGuildMemberUpdateDispatchData>];
|
|
1872
|
+
[GatewayDispatchEvents.GuildMembersChunk]: [ToEventProps<GatewayGuildMembersChunkDispatchData>];
|
|
1873
|
+
[GatewayDispatchEvents.GuildRoleCreate]: [ToEventProps<GatewayGuildRoleCreateDispatchData>];
|
|
1874
|
+
[GatewayDispatchEvents.GuildRoleDelete]: [ToEventProps<GatewayGuildRoleDeleteDispatchData>];
|
|
1875
|
+
[GatewayDispatchEvents.GuildRoleUpdate]: [ToEventProps<GatewayGuildRoleUpdateDispatchData>];
|
|
1876
|
+
[GatewayDispatchEvents.GuildScheduledEventCreate]: [ToEventProps<GatewayGuildScheduledEventCreateDispatchData>];
|
|
1877
|
+
[GatewayDispatchEvents.GuildScheduledEventDelete]: [ToEventProps<GatewayGuildScheduledEventDeleteDispatchData>];
|
|
1878
|
+
[GatewayDispatchEvents.GuildScheduledEventUpdate]: [ToEventProps<GatewayGuildScheduledEventUpdateDispatchData>];
|
|
1879
|
+
[GatewayDispatchEvents.GuildScheduledEventUserAdd]: [ToEventProps<GatewayGuildScheduledEventUserAddDispatchData>];
|
|
1882
1880
|
[GatewayDispatchEvents.GuildScheduledEventUserRemove]: [
|
|
1883
|
-
|
|
1884
|
-
];
|
|
1885
|
-
[GatewayDispatchEvents.GuildStickersUpdate]: [WithIntrinsicProps<GatewayGuildStickersUpdateDispatchData>];
|
|
1886
|
-
[GatewayDispatchEvents.GuildUpdate]: [WithIntrinsicProps<GatewayGuildUpdateDispatchData>];
|
|
1887
|
-
[GatewayDispatchEvents.IntegrationCreate]: [WithIntrinsicProps<GatewayIntegrationCreateDispatchData>];
|
|
1888
|
-
[GatewayDispatchEvents.IntegrationDelete]: [WithIntrinsicProps<GatewayIntegrationDeleteDispatchData>];
|
|
1889
|
-
[GatewayDispatchEvents.IntegrationUpdate]: [WithIntrinsicProps<GatewayIntegrationUpdateDispatchData>];
|
|
1890
|
-
[GatewayDispatchEvents.InteractionCreate]: [WithIntrinsicProps<GatewayInteractionCreateDispatchData>];
|
|
1891
|
-
[GatewayDispatchEvents.InviteCreate]: [WithIntrinsicProps<GatewayInviteCreateDispatchData>];
|
|
1892
|
-
[GatewayDispatchEvents.InviteDelete]: [WithIntrinsicProps<GatewayInviteDeleteDispatchData>];
|
|
1893
|
-
[GatewayDispatchEvents.MessageCreate]: [WithIntrinsicProps<GatewayMessageCreateDispatchData>];
|
|
1894
|
-
[GatewayDispatchEvents.MessageDelete]: [WithIntrinsicProps<GatewayMessageDeleteDispatchData>];
|
|
1895
|
-
[GatewayDispatchEvents.MessageDeleteBulk]: [WithIntrinsicProps<GatewayMessageDeleteBulkDispatchData>];
|
|
1896
|
-
[GatewayDispatchEvents.MessagePollVoteAdd]: [WithIntrinsicProps<GatewayMessagePollVoteDispatchData>];
|
|
1897
|
-
[GatewayDispatchEvents.MessagePollVoteRemove]: [WithIntrinsicProps<GatewayMessagePollVoteDispatchData>];
|
|
1898
|
-
[GatewayDispatchEvents.MessageReactionAdd]: [WithIntrinsicProps<GatewayMessageReactionAddDispatchData>];
|
|
1899
|
-
[GatewayDispatchEvents.MessageReactionRemove]: [WithIntrinsicProps<GatewayMessageReactionRemoveDispatchData>];
|
|
1900
|
-
[GatewayDispatchEvents.MessageReactionRemoveAll]: [WithIntrinsicProps<GatewayMessageReactionRemoveAllDispatchData>];
|
|
1901
|
-
[GatewayDispatchEvents.MessageReactionRemoveEmoji]: [
|
|
1902
|
-
WithIntrinsicProps<GatewayMessageReactionRemoveEmojiDispatchData>
|
|
1881
|
+
ToEventProps<GatewayGuildScheduledEventUserRemoveDispatchData>
|
|
1903
1882
|
];
|
|
1904
|
-
[GatewayDispatchEvents.
|
|
1905
|
-
[GatewayDispatchEvents.
|
|
1906
|
-
[GatewayDispatchEvents.
|
|
1907
|
-
[GatewayDispatchEvents.
|
|
1908
|
-
[GatewayDispatchEvents.
|
|
1909
|
-
[GatewayDispatchEvents.
|
|
1910
|
-
[GatewayDispatchEvents.
|
|
1911
|
-
[GatewayDispatchEvents.
|
|
1912
|
-
[GatewayDispatchEvents.
|
|
1913
|
-
[GatewayDispatchEvents.
|
|
1914
|
-
[GatewayDispatchEvents.
|
|
1915
|
-
[GatewayDispatchEvents.
|
|
1916
|
-
[GatewayDispatchEvents.
|
|
1917
|
-
[GatewayDispatchEvents.
|
|
1918
|
-
[GatewayDispatchEvents.
|
|
1919
|
-
[GatewayDispatchEvents.
|
|
1920
|
-
[GatewayDispatchEvents.
|
|
1921
|
-
[GatewayDispatchEvents.
|
|
1883
|
+
[GatewayDispatchEvents.GuildStickersUpdate]: [ToEventProps<GatewayGuildStickersUpdateDispatchData>];
|
|
1884
|
+
[GatewayDispatchEvents.GuildUpdate]: [ToEventProps<GatewayGuildUpdateDispatchData>];
|
|
1885
|
+
[GatewayDispatchEvents.IntegrationCreate]: [ToEventProps<GatewayIntegrationCreateDispatchData>];
|
|
1886
|
+
[GatewayDispatchEvents.IntegrationDelete]: [ToEventProps<GatewayIntegrationDeleteDispatchData>];
|
|
1887
|
+
[GatewayDispatchEvents.IntegrationUpdate]: [ToEventProps<GatewayIntegrationUpdateDispatchData>];
|
|
1888
|
+
[GatewayDispatchEvents.InteractionCreate]: [ToEventProps<GatewayInteractionCreateDispatchData>];
|
|
1889
|
+
[GatewayDispatchEvents.InviteCreate]: [ToEventProps<GatewayInviteCreateDispatchData>];
|
|
1890
|
+
[GatewayDispatchEvents.InviteDelete]: [ToEventProps<GatewayInviteDeleteDispatchData>];
|
|
1891
|
+
[GatewayDispatchEvents.MessageCreate]: [ToEventProps<GatewayMessageCreateDispatchData>];
|
|
1892
|
+
[GatewayDispatchEvents.MessageDelete]: [ToEventProps<GatewayMessageDeleteDispatchData>];
|
|
1893
|
+
[GatewayDispatchEvents.MessageDeleteBulk]: [ToEventProps<GatewayMessageDeleteBulkDispatchData>];
|
|
1894
|
+
[GatewayDispatchEvents.MessagePollVoteAdd]: [ToEventProps<GatewayMessagePollVoteDispatchData>];
|
|
1895
|
+
[GatewayDispatchEvents.MessagePollVoteRemove]: [ToEventProps<GatewayMessagePollVoteDispatchData>];
|
|
1896
|
+
[GatewayDispatchEvents.MessageReactionAdd]: [ToEventProps<GatewayMessageReactionAddDispatchData>];
|
|
1897
|
+
[GatewayDispatchEvents.MessageReactionRemove]: [ToEventProps<GatewayMessageReactionRemoveDispatchData>];
|
|
1898
|
+
[GatewayDispatchEvents.MessageReactionRemoveAll]: [ToEventProps<GatewayMessageReactionRemoveAllDispatchData>];
|
|
1899
|
+
[GatewayDispatchEvents.MessageReactionRemoveEmoji]: [ToEventProps<GatewayMessageReactionRemoveEmojiDispatchData>];
|
|
1900
|
+
[GatewayDispatchEvents.MessageUpdate]: [ToEventProps<GatewayMessageUpdateDispatchData>];
|
|
1901
|
+
[GatewayDispatchEvents.PresenceUpdate]: [ToEventProps<GatewayPresenceUpdateDispatchData>];
|
|
1902
|
+
[GatewayDispatchEvents.Ready]: [ToEventProps<GatewayReadyDispatchData>];
|
|
1903
|
+
[GatewayDispatchEvents.Resumed]: [ToEventProps<never>];
|
|
1904
|
+
[GatewayDispatchEvents.StageInstanceCreate]: [ToEventProps<GatewayStageInstanceCreateDispatchData>];
|
|
1905
|
+
[GatewayDispatchEvents.StageInstanceDelete]: [ToEventProps<GatewayStageInstanceDeleteDispatchData>];
|
|
1906
|
+
[GatewayDispatchEvents.StageInstanceUpdate]: [ToEventProps<GatewayStageInstanceUpdateDispatchData>];
|
|
1907
|
+
[GatewayDispatchEvents.ThreadCreate]: [ToEventProps<GatewayThreadCreateDispatchData>];
|
|
1908
|
+
[GatewayDispatchEvents.ThreadDelete]: [ToEventProps<GatewayThreadDeleteDispatchData>];
|
|
1909
|
+
[GatewayDispatchEvents.ThreadListSync]: [ToEventProps<GatewayThreadListSyncDispatchData>];
|
|
1910
|
+
[GatewayDispatchEvents.ThreadMemberUpdate]: [ToEventProps<GatewayThreadMemberUpdateDispatchData>];
|
|
1911
|
+
[GatewayDispatchEvents.ThreadMembersUpdate]: [ToEventProps<GatewayThreadMembersUpdateDispatchData>];
|
|
1912
|
+
[GatewayDispatchEvents.ThreadUpdate]: [ToEventProps<GatewayThreadUpdateDispatchData>];
|
|
1913
|
+
[GatewayDispatchEvents.TypingStart]: [ToEventProps<GatewayTypingStartDispatchData>];
|
|
1914
|
+
[GatewayDispatchEvents.UserUpdate]: [ToEventProps<GatewayUserUpdateDispatchData>];
|
|
1915
|
+
[GatewayDispatchEvents.VoiceServerUpdate]: [ToEventProps<GatewayVoiceServerUpdateDispatchData>];
|
|
1916
|
+
[GatewayDispatchEvents.VoiceStateUpdate]: [ToEventProps<GatewayVoiceStateUpdateDispatchData>];
|
|
1917
|
+
[GatewayDispatchEvents.WebhooksUpdate]: [ToEventProps<GatewayWebhooksUpdateDispatchData>];
|
|
1922
1918
|
}
|
|
1923
1919
|
interface ManagerShardEventsMap extends MappedEvents {
|
|
1924
1920
|
}
|
|
@@ -1991,7 +1987,7 @@ declare class Client extends AsyncEventEmitter<MappedEvents> {
|
|
|
1991
1987
|
* @param options - The options for updating the presence
|
|
1992
1988
|
*/
|
|
1993
1989
|
updatePresence(shardId: number, options: GatewayPresenceUpdateData): Promise<void>;
|
|
1994
|
-
private
|
|
1990
|
+
private toEventProps;
|
|
1995
1991
|
}
|
|
1996
1992
|
|
|
1997
1993
|
interface DescriptiveRawFile extends RawFile {
|
|
@@ -2031,4 +2027,4 @@ declare function withFiles(files: DescriptiveRawFile[], options: APIInteractionR
|
|
|
2031
2027
|
*/
|
|
2032
2028
|
declare const version: string;
|
|
2033
2029
|
|
|
2034
|
-
export { API, ApplicationCommandsAPI, ApplicationsAPI, ChannelsAPI, Client, type ClientOptions, type DescriptiveRawFile, type Gateway, GuildsAPI, InteractionsAPI, type IntrinsicProps, InvitesAPI, type ManagerShardEventsMap, type MappedEvents, MonetizationAPI, OAuth2API, PollAPI, type RequestGuildMembersResult, RoleConnectionsAPI, StageInstancesAPI, type StartForumThreadOptions, StickersAPI, ThreadsAPI, UsersAPI, VoiceAPI, WebhooksAPI,
|
|
2030
|
+
export { API, ApplicationCommandsAPI, ApplicationsAPI, ChannelsAPI, Client, type ClientOptions, type DescriptiveRawFile, type Gateway, GuildsAPI, InteractionsAPI, type IntrinsicProps, InvitesAPI, type ManagerShardEventsMap, type MappedEvents, MonetizationAPI, OAuth2API, PollAPI, type RequestGuildMembersResult, RoleConnectionsAPI, StageInstancesAPI, type StartForumThreadOptions, StickersAPI, ThreadsAPI, type ToEventProps, UsersAPI, VoiceAPI, WebhooksAPI, version, withFiles };
|
package/dist/index.d.ts
CHANGED
|
@@ -1839,86 +1839,82 @@ interface IntrinsicProps {
|
|
|
1839
1839
|
*/
|
|
1840
1840
|
shardId: number;
|
|
1841
1841
|
}
|
|
1842
|
-
interface
|
|
1842
|
+
interface ToEventProps<Data> extends IntrinsicProps {
|
|
1843
1843
|
data: Data;
|
|
1844
1844
|
}
|
|
1845
1845
|
interface MappedEvents {
|
|
1846
1846
|
[GatewayDispatchEvents.ApplicationCommandPermissionsUpdate]: [
|
|
1847
|
-
|
|
1847
|
+
ToEventProps<GatewayApplicationCommandPermissionsUpdateDispatchData>
|
|
1848
1848
|
];
|
|
1849
1849
|
[GatewayDispatchEvents.AutoModerationActionExecution]: [
|
|
1850
|
-
|
|
1851
|
-
];
|
|
1852
|
-
[GatewayDispatchEvents.AutoModerationRuleCreate]: [WithIntrinsicProps<GatewayAutoModerationRuleCreateDispatchData>];
|
|
1853
|
-
[GatewayDispatchEvents.AutoModerationRuleDelete]: [WithIntrinsicProps<GatewayAutoModerationRuleDeleteDispatchData>];
|
|
1854
|
-
[GatewayDispatchEvents.AutoModerationRuleUpdate]: [WithIntrinsicProps<GatewayAutoModerationRuleUpdateDispatchData>];
|
|
1855
|
-
[GatewayDispatchEvents.ChannelCreate]: [WithIntrinsicProps<GatewayChannelCreateDispatchData>];
|
|
1856
|
-
[GatewayDispatchEvents.ChannelDelete]: [WithIntrinsicProps<GatewayChannelDeleteDispatchData>];
|
|
1857
|
-
[GatewayDispatchEvents.ChannelPinsUpdate]: [WithIntrinsicProps<GatewayChannelPinsUpdateDispatchData>];
|
|
1858
|
-
[GatewayDispatchEvents.ChannelUpdate]: [WithIntrinsicProps<GatewayChannelUpdateDispatchData>];
|
|
1859
|
-
[GatewayDispatchEvents.EntitlementCreate]: [WithIntrinsicProps<GatewayEntitlementCreateDispatchData>];
|
|
1860
|
-
[GatewayDispatchEvents.EntitlementDelete]: [WithIntrinsicProps<GatewayEntitlementDeleteDispatchData>];
|
|
1861
|
-
[GatewayDispatchEvents.EntitlementUpdate]: [WithIntrinsicProps<GatewayEntitlementUpdateDispatchData>];
|
|
1862
|
-
[GatewayDispatchEvents.GuildAuditLogEntryCreate]: [WithIntrinsicProps<GatewayGuildAuditLogEntryCreateDispatchData>];
|
|
1863
|
-
[GatewayDispatchEvents.GuildBanAdd]: [WithIntrinsicProps<GatewayGuildBanAddDispatchData>];
|
|
1864
|
-
[GatewayDispatchEvents.GuildBanRemove]: [WithIntrinsicProps<GatewayGuildBanRemoveDispatchData>];
|
|
1865
|
-
[GatewayDispatchEvents.GuildCreate]: [WithIntrinsicProps<GatewayGuildCreateDispatchData>];
|
|
1866
|
-
[GatewayDispatchEvents.GuildDelete]: [WithIntrinsicProps<GatewayGuildDeleteDispatchData>];
|
|
1867
|
-
[GatewayDispatchEvents.GuildEmojisUpdate]: [WithIntrinsicProps<GatewayGuildEmojisUpdateDispatchData>];
|
|
1868
|
-
[GatewayDispatchEvents.GuildIntegrationsUpdate]: [WithIntrinsicProps<GatewayGuildIntegrationsUpdateDispatchData>];
|
|
1869
|
-
[GatewayDispatchEvents.GuildMemberAdd]: [WithIntrinsicProps<GatewayGuildMemberAddDispatchData>];
|
|
1870
|
-
[GatewayDispatchEvents.GuildMemberRemove]: [WithIntrinsicProps<GatewayGuildMemberRemoveDispatchData>];
|
|
1871
|
-
[GatewayDispatchEvents.GuildMemberUpdate]: [WithIntrinsicProps<GatewayGuildMemberUpdateDispatchData>];
|
|
1872
|
-
[GatewayDispatchEvents.GuildMembersChunk]: [WithIntrinsicProps<GatewayGuildMembersChunkDispatchData>];
|
|
1873
|
-
[GatewayDispatchEvents.GuildRoleCreate]: [WithIntrinsicProps<GatewayGuildRoleCreateDispatchData>];
|
|
1874
|
-
[GatewayDispatchEvents.GuildRoleDelete]: [WithIntrinsicProps<GatewayGuildRoleDeleteDispatchData>];
|
|
1875
|
-
[GatewayDispatchEvents.GuildRoleUpdate]: [WithIntrinsicProps<GatewayGuildRoleUpdateDispatchData>];
|
|
1876
|
-
[GatewayDispatchEvents.GuildScheduledEventCreate]: [WithIntrinsicProps<GatewayGuildScheduledEventCreateDispatchData>];
|
|
1877
|
-
[GatewayDispatchEvents.GuildScheduledEventDelete]: [WithIntrinsicProps<GatewayGuildScheduledEventDeleteDispatchData>];
|
|
1878
|
-
[GatewayDispatchEvents.GuildScheduledEventUpdate]: [WithIntrinsicProps<GatewayGuildScheduledEventUpdateDispatchData>];
|
|
1879
|
-
[GatewayDispatchEvents.GuildScheduledEventUserAdd]: [
|
|
1880
|
-
WithIntrinsicProps<GatewayGuildScheduledEventUserAddDispatchData>
|
|
1850
|
+
ToEventProps<GatewayAutoModerationActionExecutionDispatchData>
|
|
1881
1851
|
];
|
|
1852
|
+
[GatewayDispatchEvents.AutoModerationRuleCreate]: [ToEventProps<GatewayAutoModerationRuleCreateDispatchData>];
|
|
1853
|
+
[GatewayDispatchEvents.AutoModerationRuleDelete]: [ToEventProps<GatewayAutoModerationRuleDeleteDispatchData>];
|
|
1854
|
+
[GatewayDispatchEvents.AutoModerationRuleUpdate]: [ToEventProps<GatewayAutoModerationRuleUpdateDispatchData>];
|
|
1855
|
+
[GatewayDispatchEvents.ChannelCreate]: [ToEventProps<GatewayChannelCreateDispatchData>];
|
|
1856
|
+
[GatewayDispatchEvents.ChannelDelete]: [ToEventProps<GatewayChannelDeleteDispatchData>];
|
|
1857
|
+
[GatewayDispatchEvents.ChannelPinsUpdate]: [ToEventProps<GatewayChannelPinsUpdateDispatchData>];
|
|
1858
|
+
[GatewayDispatchEvents.ChannelUpdate]: [ToEventProps<GatewayChannelUpdateDispatchData>];
|
|
1859
|
+
[GatewayDispatchEvents.EntitlementCreate]: [ToEventProps<GatewayEntitlementCreateDispatchData>];
|
|
1860
|
+
[GatewayDispatchEvents.EntitlementDelete]: [ToEventProps<GatewayEntitlementDeleteDispatchData>];
|
|
1861
|
+
[GatewayDispatchEvents.EntitlementUpdate]: [ToEventProps<GatewayEntitlementUpdateDispatchData>];
|
|
1862
|
+
[GatewayDispatchEvents.GuildAuditLogEntryCreate]: [ToEventProps<GatewayGuildAuditLogEntryCreateDispatchData>];
|
|
1863
|
+
[GatewayDispatchEvents.GuildBanAdd]: [ToEventProps<GatewayGuildBanAddDispatchData>];
|
|
1864
|
+
[GatewayDispatchEvents.GuildBanRemove]: [ToEventProps<GatewayGuildBanRemoveDispatchData>];
|
|
1865
|
+
[GatewayDispatchEvents.GuildCreate]: [ToEventProps<GatewayGuildCreateDispatchData>];
|
|
1866
|
+
[GatewayDispatchEvents.GuildDelete]: [ToEventProps<GatewayGuildDeleteDispatchData>];
|
|
1867
|
+
[GatewayDispatchEvents.GuildEmojisUpdate]: [ToEventProps<GatewayGuildEmojisUpdateDispatchData>];
|
|
1868
|
+
[GatewayDispatchEvents.GuildIntegrationsUpdate]: [ToEventProps<GatewayGuildIntegrationsUpdateDispatchData>];
|
|
1869
|
+
[GatewayDispatchEvents.GuildMemberAdd]: [ToEventProps<GatewayGuildMemberAddDispatchData>];
|
|
1870
|
+
[GatewayDispatchEvents.GuildMemberRemove]: [ToEventProps<GatewayGuildMemberRemoveDispatchData>];
|
|
1871
|
+
[GatewayDispatchEvents.GuildMemberUpdate]: [ToEventProps<GatewayGuildMemberUpdateDispatchData>];
|
|
1872
|
+
[GatewayDispatchEvents.GuildMembersChunk]: [ToEventProps<GatewayGuildMembersChunkDispatchData>];
|
|
1873
|
+
[GatewayDispatchEvents.GuildRoleCreate]: [ToEventProps<GatewayGuildRoleCreateDispatchData>];
|
|
1874
|
+
[GatewayDispatchEvents.GuildRoleDelete]: [ToEventProps<GatewayGuildRoleDeleteDispatchData>];
|
|
1875
|
+
[GatewayDispatchEvents.GuildRoleUpdate]: [ToEventProps<GatewayGuildRoleUpdateDispatchData>];
|
|
1876
|
+
[GatewayDispatchEvents.GuildScheduledEventCreate]: [ToEventProps<GatewayGuildScheduledEventCreateDispatchData>];
|
|
1877
|
+
[GatewayDispatchEvents.GuildScheduledEventDelete]: [ToEventProps<GatewayGuildScheduledEventDeleteDispatchData>];
|
|
1878
|
+
[GatewayDispatchEvents.GuildScheduledEventUpdate]: [ToEventProps<GatewayGuildScheduledEventUpdateDispatchData>];
|
|
1879
|
+
[GatewayDispatchEvents.GuildScheduledEventUserAdd]: [ToEventProps<GatewayGuildScheduledEventUserAddDispatchData>];
|
|
1882
1880
|
[GatewayDispatchEvents.GuildScheduledEventUserRemove]: [
|
|
1883
|
-
|
|
1884
|
-
];
|
|
1885
|
-
[GatewayDispatchEvents.GuildStickersUpdate]: [WithIntrinsicProps<GatewayGuildStickersUpdateDispatchData>];
|
|
1886
|
-
[GatewayDispatchEvents.GuildUpdate]: [WithIntrinsicProps<GatewayGuildUpdateDispatchData>];
|
|
1887
|
-
[GatewayDispatchEvents.IntegrationCreate]: [WithIntrinsicProps<GatewayIntegrationCreateDispatchData>];
|
|
1888
|
-
[GatewayDispatchEvents.IntegrationDelete]: [WithIntrinsicProps<GatewayIntegrationDeleteDispatchData>];
|
|
1889
|
-
[GatewayDispatchEvents.IntegrationUpdate]: [WithIntrinsicProps<GatewayIntegrationUpdateDispatchData>];
|
|
1890
|
-
[GatewayDispatchEvents.InteractionCreate]: [WithIntrinsicProps<GatewayInteractionCreateDispatchData>];
|
|
1891
|
-
[GatewayDispatchEvents.InviteCreate]: [WithIntrinsicProps<GatewayInviteCreateDispatchData>];
|
|
1892
|
-
[GatewayDispatchEvents.InviteDelete]: [WithIntrinsicProps<GatewayInviteDeleteDispatchData>];
|
|
1893
|
-
[GatewayDispatchEvents.MessageCreate]: [WithIntrinsicProps<GatewayMessageCreateDispatchData>];
|
|
1894
|
-
[GatewayDispatchEvents.MessageDelete]: [WithIntrinsicProps<GatewayMessageDeleteDispatchData>];
|
|
1895
|
-
[GatewayDispatchEvents.MessageDeleteBulk]: [WithIntrinsicProps<GatewayMessageDeleteBulkDispatchData>];
|
|
1896
|
-
[GatewayDispatchEvents.MessagePollVoteAdd]: [WithIntrinsicProps<GatewayMessagePollVoteDispatchData>];
|
|
1897
|
-
[GatewayDispatchEvents.MessagePollVoteRemove]: [WithIntrinsicProps<GatewayMessagePollVoteDispatchData>];
|
|
1898
|
-
[GatewayDispatchEvents.MessageReactionAdd]: [WithIntrinsicProps<GatewayMessageReactionAddDispatchData>];
|
|
1899
|
-
[GatewayDispatchEvents.MessageReactionRemove]: [WithIntrinsicProps<GatewayMessageReactionRemoveDispatchData>];
|
|
1900
|
-
[GatewayDispatchEvents.MessageReactionRemoveAll]: [WithIntrinsicProps<GatewayMessageReactionRemoveAllDispatchData>];
|
|
1901
|
-
[GatewayDispatchEvents.MessageReactionRemoveEmoji]: [
|
|
1902
|
-
WithIntrinsicProps<GatewayMessageReactionRemoveEmojiDispatchData>
|
|
1881
|
+
ToEventProps<GatewayGuildScheduledEventUserRemoveDispatchData>
|
|
1903
1882
|
];
|
|
1904
|
-
[GatewayDispatchEvents.
|
|
1905
|
-
[GatewayDispatchEvents.
|
|
1906
|
-
[GatewayDispatchEvents.
|
|
1907
|
-
[GatewayDispatchEvents.
|
|
1908
|
-
[GatewayDispatchEvents.
|
|
1909
|
-
[GatewayDispatchEvents.
|
|
1910
|
-
[GatewayDispatchEvents.
|
|
1911
|
-
[GatewayDispatchEvents.
|
|
1912
|
-
[GatewayDispatchEvents.
|
|
1913
|
-
[GatewayDispatchEvents.
|
|
1914
|
-
[GatewayDispatchEvents.
|
|
1915
|
-
[GatewayDispatchEvents.
|
|
1916
|
-
[GatewayDispatchEvents.
|
|
1917
|
-
[GatewayDispatchEvents.
|
|
1918
|
-
[GatewayDispatchEvents.
|
|
1919
|
-
[GatewayDispatchEvents.
|
|
1920
|
-
[GatewayDispatchEvents.
|
|
1921
|
-
[GatewayDispatchEvents.
|
|
1883
|
+
[GatewayDispatchEvents.GuildStickersUpdate]: [ToEventProps<GatewayGuildStickersUpdateDispatchData>];
|
|
1884
|
+
[GatewayDispatchEvents.GuildUpdate]: [ToEventProps<GatewayGuildUpdateDispatchData>];
|
|
1885
|
+
[GatewayDispatchEvents.IntegrationCreate]: [ToEventProps<GatewayIntegrationCreateDispatchData>];
|
|
1886
|
+
[GatewayDispatchEvents.IntegrationDelete]: [ToEventProps<GatewayIntegrationDeleteDispatchData>];
|
|
1887
|
+
[GatewayDispatchEvents.IntegrationUpdate]: [ToEventProps<GatewayIntegrationUpdateDispatchData>];
|
|
1888
|
+
[GatewayDispatchEvents.InteractionCreate]: [ToEventProps<GatewayInteractionCreateDispatchData>];
|
|
1889
|
+
[GatewayDispatchEvents.InviteCreate]: [ToEventProps<GatewayInviteCreateDispatchData>];
|
|
1890
|
+
[GatewayDispatchEvents.InviteDelete]: [ToEventProps<GatewayInviteDeleteDispatchData>];
|
|
1891
|
+
[GatewayDispatchEvents.MessageCreate]: [ToEventProps<GatewayMessageCreateDispatchData>];
|
|
1892
|
+
[GatewayDispatchEvents.MessageDelete]: [ToEventProps<GatewayMessageDeleteDispatchData>];
|
|
1893
|
+
[GatewayDispatchEvents.MessageDeleteBulk]: [ToEventProps<GatewayMessageDeleteBulkDispatchData>];
|
|
1894
|
+
[GatewayDispatchEvents.MessagePollVoteAdd]: [ToEventProps<GatewayMessagePollVoteDispatchData>];
|
|
1895
|
+
[GatewayDispatchEvents.MessagePollVoteRemove]: [ToEventProps<GatewayMessagePollVoteDispatchData>];
|
|
1896
|
+
[GatewayDispatchEvents.MessageReactionAdd]: [ToEventProps<GatewayMessageReactionAddDispatchData>];
|
|
1897
|
+
[GatewayDispatchEvents.MessageReactionRemove]: [ToEventProps<GatewayMessageReactionRemoveDispatchData>];
|
|
1898
|
+
[GatewayDispatchEvents.MessageReactionRemoveAll]: [ToEventProps<GatewayMessageReactionRemoveAllDispatchData>];
|
|
1899
|
+
[GatewayDispatchEvents.MessageReactionRemoveEmoji]: [ToEventProps<GatewayMessageReactionRemoveEmojiDispatchData>];
|
|
1900
|
+
[GatewayDispatchEvents.MessageUpdate]: [ToEventProps<GatewayMessageUpdateDispatchData>];
|
|
1901
|
+
[GatewayDispatchEvents.PresenceUpdate]: [ToEventProps<GatewayPresenceUpdateDispatchData>];
|
|
1902
|
+
[GatewayDispatchEvents.Ready]: [ToEventProps<GatewayReadyDispatchData>];
|
|
1903
|
+
[GatewayDispatchEvents.Resumed]: [ToEventProps<never>];
|
|
1904
|
+
[GatewayDispatchEvents.StageInstanceCreate]: [ToEventProps<GatewayStageInstanceCreateDispatchData>];
|
|
1905
|
+
[GatewayDispatchEvents.StageInstanceDelete]: [ToEventProps<GatewayStageInstanceDeleteDispatchData>];
|
|
1906
|
+
[GatewayDispatchEvents.StageInstanceUpdate]: [ToEventProps<GatewayStageInstanceUpdateDispatchData>];
|
|
1907
|
+
[GatewayDispatchEvents.ThreadCreate]: [ToEventProps<GatewayThreadCreateDispatchData>];
|
|
1908
|
+
[GatewayDispatchEvents.ThreadDelete]: [ToEventProps<GatewayThreadDeleteDispatchData>];
|
|
1909
|
+
[GatewayDispatchEvents.ThreadListSync]: [ToEventProps<GatewayThreadListSyncDispatchData>];
|
|
1910
|
+
[GatewayDispatchEvents.ThreadMemberUpdate]: [ToEventProps<GatewayThreadMemberUpdateDispatchData>];
|
|
1911
|
+
[GatewayDispatchEvents.ThreadMembersUpdate]: [ToEventProps<GatewayThreadMembersUpdateDispatchData>];
|
|
1912
|
+
[GatewayDispatchEvents.ThreadUpdate]: [ToEventProps<GatewayThreadUpdateDispatchData>];
|
|
1913
|
+
[GatewayDispatchEvents.TypingStart]: [ToEventProps<GatewayTypingStartDispatchData>];
|
|
1914
|
+
[GatewayDispatchEvents.UserUpdate]: [ToEventProps<GatewayUserUpdateDispatchData>];
|
|
1915
|
+
[GatewayDispatchEvents.VoiceServerUpdate]: [ToEventProps<GatewayVoiceServerUpdateDispatchData>];
|
|
1916
|
+
[GatewayDispatchEvents.VoiceStateUpdate]: [ToEventProps<GatewayVoiceStateUpdateDispatchData>];
|
|
1917
|
+
[GatewayDispatchEvents.WebhooksUpdate]: [ToEventProps<GatewayWebhooksUpdateDispatchData>];
|
|
1922
1918
|
}
|
|
1923
1919
|
interface ManagerShardEventsMap extends MappedEvents {
|
|
1924
1920
|
}
|
|
@@ -1991,7 +1987,7 @@ declare class Client extends AsyncEventEmitter<MappedEvents> {
|
|
|
1991
1987
|
* @param options - The options for updating the presence
|
|
1992
1988
|
*/
|
|
1993
1989
|
updatePresence(shardId: number, options: GatewayPresenceUpdateData): Promise<void>;
|
|
1994
|
-
private
|
|
1990
|
+
private toEventProps;
|
|
1995
1991
|
}
|
|
1996
1992
|
|
|
1997
1993
|
interface DescriptiveRawFile extends RawFile {
|
|
@@ -2031,4 +2027,4 @@ declare function withFiles(files: DescriptiveRawFile[], options: APIInteractionR
|
|
|
2031
2027
|
*/
|
|
2032
2028
|
declare const version: string;
|
|
2033
2029
|
|
|
2034
|
-
export { API, ApplicationCommandsAPI, ApplicationsAPI, ChannelsAPI, Client, type ClientOptions, type DescriptiveRawFile, type Gateway, GuildsAPI, InteractionsAPI, type IntrinsicProps, InvitesAPI, type ManagerShardEventsMap, type MappedEvents, MonetizationAPI, OAuth2API, PollAPI, type RequestGuildMembersResult, RoleConnectionsAPI, StageInstancesAPI, type StartForumThreadOptions, StickersAPI, ThreadsAPI, UsersAPI, VoiceAPI, WebhooksAPI,
|
|
2030
|
+
export { API, ApplicationCommandsAPI, ApplicationsAPI, ChannelsAPI, Client, type ClientOptions, type DescriptiveRawFile, type Gateway, GuildsAPI, InteractionsAPI, type IntrinsicProps, InvitesAPI, type ManagerShardEventsMap, type MappedEvents, MonetizationAPI, OAuth2API, PollAPI, type RequestGuildMembersResult, RoleConnectionsAPI, StageInstancesAPI, type StartForumThreadOptions, StickersAPI, ThreadsAPI, type ToEventProps, UsersAPI, VoiceAPI, WebhooksAPI, version, withFiles };
|
package/dist/index.js
CHANGED
|
@@ -2715,12 +2715,8 @@ var Client = class extends import_async_event_emitter.AsyncEventEmitter {
|
|
|
2715
2715
|
this.rest = rest;
|
|
2716
2716
|
this.gateway = gateway;
|
|
2717
2717
|
this.api = new API(rest);
|
|
2718
|
-
this.gateway.on(import_ws.WebSocketShardEvents.Dispatch, (
|
|
2719
|
-
this.emit(
|
|
2720
|
-
dispatch.t,
|
|
2721
|
-
// @ts-expect-error event props can't be resolved properly, but they are correct
|
|
2722
|
-
this.wrapIntrinsicProps(dispatch.d, shardId)
|
|
2723
|
-
);
|
|
2718
|
+
this.gateway.on(import_ws.WebSocketShardEvents.Dispatch, (dispatch, shardId) => {
|
|
2719
|
+
this.emit(dispatch.t, this.toEventProps(dispatch.d, shardId));
|
|
2724
2720
|
});
|
|
2725
2721
|
}
|
|
2726
2722
|
/**
|
|
@@ -2835,7 +2831,7 @@ var Client = class extends import_async_event_emitter.AsyncEventEmitter {
|
|
|
2835
2831
|
d: options
|
|
2836
2832
|
});
|
|
2837
2833
|
}
|
|
2838
|
-
|
|
2834
|
+
toEventProps(obj, shardId) {
|
|
2839
2835
|
return {
|
|
2840
2836
|
api: this.api,
|
|
2841
2837
|
shardId,
|
|
@@ -2863,7 +2859,7 @@ __name(withFiles, "withFiles");
|
|
|
2863
2859
|
|
|
2864
2860
|
// src/index.ts
|
|
2865
2861
|
__reExport(src_exports, require("discord-api-types/v10"), module.exports);
|
|
2866
|
-
var version = "
|
|
2862
|
+
var version = "2.0.0-dev.1721866231-bf6761a44";
|
|
2867
2863
|
// Annotate the CommonJS export names for ESM import in node:
|
|
2868
2864
|
0 && (module.exports = {
|
|
2869
2865
|
API,
|