@discordjs/core 3.0.0-dev.1762819348-37a38883d → 3.0.0-dev.1762862514-d3d6777ef
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 +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +20 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +20 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +6 -6
package/dist/index.d.mts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { REST, RequestData, RawFile } from '@discordjs/rest';
|
|
2
2
|
import * as discord_api_types_v10 from 'discord-api-types/v10';
|
|
3
|
-
import { Snowflake, RESTGetAPIApplicationCommandsQuery, RESTGetAPIApplicationCommandsResult, RESTPostAPIApplicationCommandsJSONBody, RESTPatchAPIApplicationCommandJSONBody, RESTPutAPIApplicationCommandsJSONBody, RESTPutAPIApplicationCommandsResult, RESTGetAPIApplicationGuildCommandsQuery, RESTGetAPIApplicationGuildCommandsResult, RESTPostAPIApplicationGuildCommandsJSONBody, RESTPostAPIApplicationGuildCommandsResult, RESTGetAPIApplicationGuildCommandResult, RESTPatchAPIApplicationGuildCommandJSONBody, RESTPatchAPIApplicationGuildCommandResult, RESTPutAPIApplicationGuildCommandsJSONBody, RESTPutAPIApplicationGuildCommandsResult, RESTGetAPIGuildApplicationCommandsPermissionsResult, RESTPutAPIApplicationCommandPermissionsJSONBody, RESTPatchCurrentApplicationJSONBody, RESTGetAPIApplicationEmojisResult, RESTPostAPIApplicationEmojiJSONBody, RESTPatchAPIApplicationEmojiJSONBody, RESTPostAPIGuildForumThreadsJSONBody, RESTPostAPIChannelMessageJSONBody, RESTPatchAPIChannelMessageJSONBody, RESTGetAPIChannelMessageReactionUsersQuery, RESTGetAPIChannelMessageReactionUsersResult, RESTPatchAPIChannelJSONBody, RESTGetAPIChannelMessagesQuery, RESTGetAPIChannelMessagesResult, RESTGetAPIChannelMessagesPinsQuery, RESTGetAPIChannelMessagesPinsResult, RESTPostAPIChannelInviteJSONBody, RESTGetAPIChannelInvitesResult, RESTPostAPIChannelThreadsJSONBody, RESTPostAPIChannelThreadsResult, RESTGetAPIChannelThreadsArchivedQuery, RESTGetAPIChannelUsersThreadsArchivedResult, RESTPostAPIChannelWebhookJSONBody, RESTGetAPIChannelWebhooksResult, RESTPutAPIChannelPermissionJSONBody, RESTPostAPISoundboardSendSoundJSONBody, RESTPutAPIChannelRecipientJSONBody, RESTPostAPIGuildStickerFormDataBody, RESTGetAPIGuildQuery, RESTPatchAPIGuildJSONBody, RESTPutAPIGuildMemberJSONBody, RESTPutAPIGuildMemberResult, RESTGetAPIGuildMembersQuery, RESTGetAPIGuildMembersResult, RESTGetAPIGuildChannelsResult, RESTPostAPIGuildChannelJSONBody, RESTPatchAPIGuildChannelPositionsJSONBody, RESTGetAPIGuildBansQuery, RESTGetAPIGuildBansResult, RESTPutAPIGuildBanJSONBody, RESTPostAPIGuildBulkBanJSONBody, RESTPostAPIGuildBulkBanResult, RESTGetAPIGuildRolesResult, RESTPostAPIGuildRoleJSONBody, RESTPatchAPIGuildRolePositionsJSONBody, RESTPatchAPIGuildRolePositionsResult, RESTPatchAPIGuildRoleJSONBody, RESTGetAPIGuildPruneCountQuery, RESTGetAPIGuildPruneCountResult, RESTPostAPIGuildPruneJSONBody, RESTPostAPIGuildPruneResult, RESTGetAPIGuildVoiceRegionsResult, RESTGetAPIGuildInvitesResult, RESTGetAPIGuildIntegrationsResult, RESTPatchAPIGuildWidgetSettingsJSONBody, RESTGetAPIGuildVanityUrlResult, GuildWidgetStyle, RESTPatchAPIGuildWelcomeScreenJSONBody, RESTGetAPIGuildEmojisResult, RESTPostAPIGuildEmojiJSONBody, RESTPatchAPIGuildEmojiJSONBody, RESTGetAPIGuildScheduledEventsQuery, RESTGetAPIGuildScheduledEventsResult, RESTPostAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventQuery, RESTPatchAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventUsersQuery, RESTGetAPIGuildScheduledEventUsersResult, RESTGetAPIGuildTemplatesResult, RESTPatchAPIGuildTemplateJSONBody, RESTGetAPIGuildStickersResult, RESTPatchAPIGuildStickerJSONBody, RESTGetAPIAuditLogQuery, RESTGetAPIAutoModerationRulesResult, RESTPostAPIAutoModerationRuleJSONBody, RESTPatchAPIAutoModerationRuleJSONBody, RESTGetAPIGuildMembersSearchQuery, RESTGetAPIGuildMembersSearchResult, RESTPatchAPIGuildMemberJSONBody, RESTPostAPIGuildTemplatesJSONBody, RESTGetAPIGuildWebhooksResult, RESTPutAPIGuildOnboardingJSONBody, RESTGetAPIGuildSoundboardSoundsResult, RESTPostAPIGuildSoundboardSoundJSONBody, RESTPatchAPIGuildSoundboardSoundJSONBody, RESTPutAPIGuildIncidentActionsJSONBody, RESTPatchAPIWebhookJSONBody, RESTPostAPIWebhookWithTokenJSONBody, RESTPostAPIWebhookWithTokenQuery, RESTPostAPIWebhookWithTokenWaitResult, RESTPostAPIWebhookWithTokenSlackQuery, RESTPostAPIWebhookWithTokenGitHubQuery, RESTGetAPIWebhookWithTokenMessageQuery, RESTPatchAPIWebhookWithTokenMessageJSONBody, RESTPatchAPIWebhookWithTokenMessageQuery, APIInteractionResponseCallbackData, RESTPostAPIInteractionCallbackQuery, APIInteractionResponseDeferredChannelMessageWithSource, APICommandAutocompleteInteractionResponseCallbackData, APIModalInteractionResponseCallbackData, RESTPostAPIInteractionCallbackWithResponseResult, RESTGetAPIInviteQuery, RESTGetAPISKUsResult, RESTGetAPISKUSubscriptionsQuery, RESTGetAPISKUSubscriptionsResult, RESTGetAPIEntitlementsQuery, RESTGetAPIEntitlementsResult, RESTPostAPIEntitlementJSONBody, RESTOAuth2AuthorizationQuery, RESTPostOAuth2AccessTokenURLEncodedData, RESTPostOAuth2AccessTokenResult, RESTPostOAuth2RefreshTokenURLEncodedData, RESTPostOAuth2ClientCredentialsURLEncodedData, RESTGetAPIOAuth2CurrentApplicationResult, RESTGetAPIOAuth2CurrentAuthorizationResult, RESTPostOAuth2TokenRevocationQuery, RESTGetAPIPollAnswerVotersQuery, RESTGetAPIPollAnswerVotersResult, RESTGetAPIApplicationRoleConnectionMetadataResult, RESTPutAPIApplicationRoleConnectionMetadataJSONBody, RESTPutAPIApplicationRoleConnectionMetadataResult, RESTGetAPISoundboardDefaultSoundsResult, RESTPostAPIStageInstanceJSONBody, RESTPatchAPIStageInstanceJSONBody, RESTGetStickerPacksResult, RESTGetAPIChannelThreadMemberQuery, RESTGetAPIChannelThreadMemberResult, RESTGetAPIChannelThreadMembersResult, RESTGetAPICurrentUserGuildsQuery, RESTGetAPICurrentUserGuildsResult, RESTPatchAPICurrentUserJSONBody, RESTPatchAPICurrentGuildMemberJSONBody, RESTGetAPICurrentUserConnectionsResult, RESTPutAPICurrentUserApplicationRoleConnectionJSONBody, RESTGetAPIVoiceRegionsResult, RESTPatchAPIGuildVoiceStateUserJSONBody, RESTPatchAPIGuildVoiceStateCurrentMemberJSONBody, GatewaySendPayload, GatewayDispatchEvents, GatewayApplicationCommandPermissionsUpdateDispatchData, GatewayAutoModerationActionExecutionDispatchData, GatewayAutoModerationRuleCreateDispatchData, GatewayAutoModerationRuleDeleteDispatchData, GatewayAutoModerationRuleUpdateDispatchData, GatewayChannelCreateDispatchData, GatewayChannelDeleteDispatchData, GatewayChannelPinsUpdateDispatchData, GatewayChannelUpdateDispatchData, GatewayEntitlementCreateDispatchData, GatewayEntitlementDeleteDispatchData, GatewayEntitlementUpdateDispatchData, GatewayGuildAuditLogEntryCreateDispatchData, GatewayGuildBanAddDispatchData, GatewayGuildBanRemoveDispatchData, GatewayGuildCreateDispatchData, GatewayGuildDeleteDispatchData, GatewayGuildEmojisUpdateDispatchData, GatewayGuildIntegrationsUpdateDispatchData, GatewayGuildMemberAddDispatchData, GatewayGuildMemberRemoveDispatchData, GatewayGuildMemberUpdateDispatchData, GatewayGuildMembersChunkDispatchData, GatewayGuildRoleCreateDispatchData, GatewayGuildRoleDeleteDispatchData, GatewayGuildRoleUpdateDispatchData, GatewayGuildScheduledEventCreateDispatchData, GatewayGuildScheduledEventDeleteDispatchData, GatewayGuildScheduledEventUpdateDispatchData, GatewayGuildScheduledEventUserAddDispatchData, GatewayGuildScheduledEventUserRemoveDispatchData, GatewayGuildSoundboardSoundCreateDispatch, GatewayGuildSoundboardSoundDeleteDispatch, GatewayGuildSoundboardSoundUpdateDispatch, GatewayGuildSoundboardSoundsUpdateDispatch, GatewaySoundboardSoundsDispatchData, GatewayGuildStickersUpdateDispatchData, GatewayGuildUpdateDispatchData, GatewayIntegrationCreateDispatchData, GatewayIntegrationDeleteDispatchData, GatewayIntegrationUpdateDispatchData, GatewayInteractionCreateDispatchData, GatewayInviteCreateDispatchData, GatewayInviteDeleteDispatchData, GatewayMessageCreateDispatchData, GatewayMessageDeleteDispatchData, GatewayMessageDeleteBulkDispatchData, GatewayMessagePollVoteDispatchData, GatewayMessageReactionAddDispatchData, GatewayMessageReactionRemoveDispatchData, GatewayMessageReactionRemoveAllDispatchData, GatewayMessageReactionRemoveEmojiDispatchData, GatewayMessageUpdateDispatchData, GatewayPresenceUpdateDispatchData, GatewayReadyDispatchData, GatewayStageInstanceCreateDispatchData, GatewayStageInstanceDeleteDispatchData, GatewayStageInstanceUpdateDispatchData, GatewaySubscriptionCreateDispatchData, GatewaySubscriptionDeleteDispatchData, GatewaySubscriptionUpdateDispatchData, GatewayThreadCreateDispatchData, GatewayThreadDeleteDispatchData, GatewayThreadListSyncDispatchData, GatewayThreadMemberUpdateDispatchData, GatewayThreadMembersUpdateDispatchData, GatewayThreadUpdateDispatchData, GatewayTypingStartDispatchData, GatewayUserUpdateDispatchData, GatewayVoiceServerUpdateDispatchData, GatewayVoiceStateUpdateDispatchData, GatewayWebhooksUpdateDispatchData, GatewayRequestGuildMembersData, GatewayRequestSoundboardSoundsData, GatewayVoiceStateUpdateData, GatewayPresenceUpdateData } from 'discord-api-types/v10';
|
|
3
|
+
import { Snowflake, RESTGetAPIApplicationCommandsQuery, RESTGetAPIApplicationCommandsResult, RESTPostAPIApplicationCommandsJSONBody, RESTPatchAPIApplicationCommandJSONBody, RESTPutAPIApplicationCommandsJSONBody, RESTPutAPIApplicationCommandsResult, RESTGetAPIApplicationGuildCommandsQuery, RESTGetAPIApplicationGuildCommandsResult, RESTPostAPIApplicationGuildCommandsJSONBody, RESTPostAPIApplicationGuildCommandsResult, RESTGetAPIApplicationGuildCommandResult, RESTPatchAPIApplicationGuildCommandJSONBody, RESTPatchAPIApplicationGuildCommandResult, RESTPutAPIApplicationGuildCommandsJSONBody, RESTPutAPIApplicationGuildCommandsResult, RESTGetAPIGuildApplicationCommandsPermissionsResult, RESTPutAPIApplicationCommandPermissionsJSONBody, RESTPatchCurrentApplicationJSONBody, RESTGetAPIApplicationEmojisResult, RESTPostAPIApplicationEmojiJSONBody, RESTPatchAPIApplicationEmojiJSONBody, RESTPostAPIGuildForumThreadsJSONBody, RESTPostAPIChannelMessageJSONBody, RESTPatchAPIChannelMessageJSONBody, RESTGetAPIChannelMessageReactionUsersQuery, RESTGetAPIChannelMessageReactionUsersResult, RESTPatchAPIChannelJSONBody, RESTGetAPIChannelMessagesQuery, RESTGetAPIChannelMessagesResult, RESTGetAPIChannelMessagesPinsQuery, RESTGetAPIChannelMessagesPinsResult, RESTPostAPIChannelInviteJSONBody, RESTGetAPIChannelInvitesResult, RESTPostAPIChannelThreadsJSONBody, RESTPostAPIChannelThreadsResult, RESTGetAPIChannelThreadsArchivedQuery, RESTGetAPIChannelUsersThreadsArchivedResult, RESTPostAPIChannelWebhookJSONBody, RESTGetAPIChannelWebhooksResult, RESTPutAPIChannelPermissionJSONBody, RESTPostAPISoundboardSendSoundJSONBody, RESTPutAPIChannelRecipientJSONBody, RESTPostAPIGuildStickerFormDataBody, RESTGetAPIGuildQuery, RESTPatchAPIGuildJSONBody, RESTPutAPIGuildMemberJSONBody, RESTPutAPIGuildMemberResult, RESTGetAPIGuildMembersQuery, RESTGetAPIGuildMembersResult, RESTGetAPIGuildChannelsResult, RESTPostAPIGuildChannelJSONBody, RESTPatchAPIGuildChannelPositionsJSONBody, RESTGetAPIGuildBansQuery, RESTGetAPIGuildBansResult, RESTPutAPIGuildBanJSONBody, RESTPostAPIGuildBulkBanJSONBody, RESTPostAPIGuildBulkBanResult, RESTGetAPIGuildRolesResult, RESTPostAPIGuildRoleJSONBody, RESTPatchAPIGuildRolePositionsJSONBody, RESTPatchAPIGuildRolePositionsResult, RESTPatchAPIGuildRoleJSONBody, RESTGetAPIGuildPruneCountQuery, RESTGetAPIGuildPruneCountResult, RESTPostAPIGuildPruneJSONBody, RESTPostAPIGuildPruneResult, RESTGetAPIGuildVoiceRegionsResult, RESTGetAPIGuildInvitesResult, RESTGetAPIGuildIntegrationsResult, RESTPatchAPIGuildWidgetSettingsJSONBody, RESTGetAPIGuildVanityUrlResult, GuildWidgetStyle, RESTPatchAPIGuildWelcomeScreenJSONBody, RESTGetAPIGuildEmojisResult, RESTPostAPIGuildEmojiJSONBody, RESTPatchAPIGuildEmojiJSONBody, RESTGetAPIGuildScheduledEventsQuery, RESTGetAPIGuildScheduledEventsResult, RESTPostAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventQuery, RESTPatchAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventUsersQuery, RESTGetAPIGuildScheduledEventUsersResult, RESTGetAPIGuildTemplatesResult, RESTPatchAPIGuildTemplateJSONBody, RESTGetAPIGuildStickersResult, RESTPatchAPIGuildStickerJSONBody, RESTGetAPIAuditLogQuery, RESTGetAPIAutoModerationRulesResult, RESTPostAPIAutoModerationRuleJSONBody, RESTPatchAPIAutoModerationRuleJSONBody, RESTGetAPIGuildMembersSearchQuery, RESTGetAPIGuildMembersSearchResult, RESTPatchAPIGuildMemberJSONBody, RESTPostAPIGuildTemplatesJSONBody, RESTGetAPIGuildWebhooksResult, RESTPutAPIGuildOnboardingJSONBody, RESTGetAPIGuildSoundboardSoundsResult, RESTPostAPIGuildSoundboardSoundJSONBody, RESTPatchAPIGuildSoundboardSoundJSONBody, RESTPutAPIGuildIncidentActionsJSONBody, RESTPatchAPIWebhookJSONBody, RESTPostAPIWebhookWithTokenJSONBody, RESTPostAPIWebhookWithTokenQuery, RESTPostAPIWebhookWithTokenWaitResult, RESTPostAPIWebhookWithTokenSlackQuery, RESTPostAPIWebhookWithTokenGitHubQuery, RESTGetAPIWebhookWithTokenMessageQuery, RESTPatchAPIWebhookWithTokenMessageJSONBody, RESTPatchAPIWebhookWithTokenMessageQuery, APIInteractionResponseCallbackData, RESTPostAPIInteractionCallbackQuery, APIInteractionResponseDeferredChannelMessageWithSource, APICommandAutocompleteInteractionResponseCallbackData, APIModalInteractionResponseCallbackData, RESTPostAPIInteractionCallbackWithResponseResult, RESTGetAPIInviteQuery, RESTGetAPISKUsResult, RESTGetAPISKUSubscriptionsQuery, RESTGetAPISKUSubscriptionsResult, RESTGetAPIEntitlementsQuery, RESTGetAPIEntitlementsResult, RESTPostAPIEntitlementJSONBody, RESTOAuth2AuthorizationQuery, RESTPostOAuth2AccessTokenURLEncodedData, RESTPostOAuth2AccessTokenResult, RESTPostOAuth2RefreshTokenURLEncodedData, RESTPostOAuth2ClientCredentialsURLEncodedData, RESTGetAPIOAuth2CurrentApplicationResult, RESTGetAPIOAuth2CurrentAuthorizationResult, RESTPostOAuth2TokenRevocationQuery, RESTGetAPIPollAnswerVotersQuery, RESTGetAPIPollAnswerVotersResult, RESTGetAPIApplicationRoleConnectionMetadataResult, RESTPutAPIApplicationRoleConnectionMetadataJSONBody, RESTPutAPIApplicationRoleConnectionMetadataResult, RESTGetAPISoundboardDefaultSoundsResult, RESTPostAPIStageInstanceJSONBody, RESTPatchAPIStageInstanceJSONBody, RESTGetStickerPacksResult, RESTGetAPIChannelThreadMemberQuery, RESTGetAPIChannelThreadMemberResult, RESTGetAPIChannelThreadMembersResult, RESTGetAPICurrentUserGuildsQuery, RESTGetAPICurrentUserGuildsResult, RESTPatchAPICurrentUserJSONBody, RESTPatchAPICurrentGuildMemberJSONBody, RESTGetAPICurrentUserConnectionsResult, RESTPutAPICurrentUserApplicationRoleConnectionJSONBody, RESTGetAPIVoiceRegionsResult, RESTPatchAPIGuildVoiceStateUserJSONBody, RESTPatchAPIGuildVoiceStateCurrentMemberJSONBody, GatewaySendPayload, GatewayDispatchEvents, GatewayApplicationCommandPermissionsUpdateDispatchData, GatewayAutoModerationActionExecutionDispatchData, GatewayAutoModerationRuleCreateDispatchData, GatewayAutoModerationRuleDeleteDispatchData, GatewayAutoModerationRuleUpdateDispatchData, GatewayChannelCreateDispatchData, GatewayChannelDeleteDispatchData, GatewayChannelPinsUpdateDispatchData, GatewayChannelUpdateDispatchData, GatewayEntitlementCreateDispatchData, GatewayEntitlementDeleteDispatchData, GatewayEntitlementUpdateDispatchData, GatewayGuildAuditLogEntryCreateDispatchData, GatewayGuildBanAddDispatchData, GatewayGuildBanRemoveDispatchData, GatewayGuildCreateDispatchData, GatewayGuildDeleteDispatchData, GatewayGuildEmojisUpdateDispatchData, GatewayGuildIntegrationsUpdateDispatchData, GatewayGuildMemberAddDispatchData, GatewayGuildMemberRemoveDispatchData, GatewayGuildMemberUpdateDispatchData, GatewayGuildMembersChunkDispatchData, GatewayGuildRoleCreateDispatchData, GatewayGuildRoleDeleteDispatchData, GatewayGuildRoleUpdateDispatchData, GatewayGuildScheduledEventCreateDispatchData, GatewayGuildScheduledEventDeleteDispatchData, GatewayGuildScheduledEventUpdateDispatchData, GatewayGuildScheduledEventUserAddDispatchData, GatewayGuildScheduledEventUserRemoveDispatchData, GatewayGuildSoundboardSoundCreateDispatch, GatewayGuildSoundboardSoundDeleteDispatch, GatewayGuildSoundboardSoundUpdateDispatch, GatewayGuildSoundboardSoundsUpdateDispatch, GatewaySoundboardSoundsDispatchData, GatewayGuildStickersUpdateDispatchData, GatewayGuildUpdateDispatchData, GatewayIntegrationCreateDispatchData, GatewayIntegrationDeleteDispatchData, GatewayIntegrationUpdateDispatchData, GatewayInteractionCreateDispatchData, GatewayInviteCreateDispatchData, GatewayInviteDeleteDispatchData, GatewayMessageCreateDispatchData, GatewayMessageDeleteDispatchData, GatewayMessageDeleteBulkDispatchData, GatewayMessagePollVoteDispatchData, GatewayMessageReactionAddDispatchData, GatewayMessageReactionRemoveDispatchData, GatewayMessageReactionRemoveAllDispatchData, GatewayMessageReactionRemoveEmojiDispatchData, GatewayMessageUpdateDispatchData, GatewayPresenceUpdateDispatchData, GatewayRateLimitedDispatchData, GatewayReadyDispatchData, GatewayStageInstanceCreateDispatchData, GatewayStageInstanceDeleteDispatchData, GatewayStageInstanceUpdateDispatchData, GatewaySubscriptionCreateDispatchData, GatewaySubscriptionDeleteDispatchData, GatewaySubscriptionUpdateDispatchData, GatewayThreadCreateDispatchData, GatewayThreadDeleteDispatchData, GatewayThreadListSyncDispatchData, GatewayThreadMemberUpdateDispatchData, GatewayThreadMembersUpdateDispatchData, GatewayThreadUpdateDispatchData, GatewayTypingStartDispatchData, GatewayUserUpdateDispatchData, GatewayVoiceServerUpdateDispatchData, GatewayVoiceStateUpdateDispatchData, GatewayWebhooksUpdateDispatchData, GatewayRequestGuildMembersData, GatewayRequestSoundboardSoundsData, GatewayVoiceStateUpdateData, GatewayPresenceUpdateData } from 'discord-api-types/v10';
|
|
4
4
|
export * from 'discord-api-types/v10';
|
|
5
5
|
import { AsyncEventEmitter } from '@vladfrangu/async_event_emitter';
|
|
6
6
|
import { Awaitable } from '@discordjs/util';
|
|
7
|
+
export { GatewayRateLimitError } from '@discordjs/util';
|
|
7
8
|
import { WebSocketShardEvents, ManagerShardEventsMap as ManagerShardEventsMap$1 } from '@discordjs/ws';
|
|
8
9
|
import * as discord_api_types_globals from 'discord-api-types/globals';
|
|
9
10
|
|
|
@@ -2329,6 +2330,7 @@ interface MappedEvents {
|
|
|
2329
2330
|
[GatewayDispatchEvents.MessageReactionRemoveEmoji]: [ToEventProps<GatewayMessageReactionRemoveEmojiDispatchData>];
|
|
2330
2331
|
[GatewayDispatchEvents.MessageUpdate]: [ToEventProps<GatewayMessageUpdateDispatchData>];
|
|
2331
2332
|
[GatewayDispatchEvents.PresenceUpdate]: [ToEventProps<GatewayPresenceUpdateDispatchData>];
|
|
2333
|
+
[GatewayDispatchEvents.RateLimited]: [ToEventProps<GatewayRateLimitedDispatchData>];
|
|
2332
2334
|
[GatewayDispatchEvents.Ready]: [ToEventProps<GatewayReadyDispatchData>];
|
|
2333
2335
|
[GatewayDispatchEvents.Resumed]: [ToEventProps<never>];
|
|
2334
2336
|
[GatewayDispatchEvents.StageInstanceCreate]: [ToEventProps<GatewayStageInstanceCreateDispatchData>];
|
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { REST, RequestData, RawFile } from '@discordjs/rest';
|
|
2
2
|
import * as discord_api_types_v10 from 'discord-api-types/v10';
|
|
3
|
-
import { Snowflake, RESTGetAPIApplicationCommandsQuery, RESTGetAPIApplicationCommandsResult, RESTPostAPIApplicationCommandsJSONBody, RESTPatchAPIApplicationCommandJSONBody, RESTPutAPIApplicationCommandsJSONBody, RESTPutAPIApplicationCommandsResult, RESTGetAPIApplicationGuildCommandsQuery, RESTGetAPIApplicationGuildCommandsResult, RESTPostAPIApplicationGuildCommandsJSONBody, RESTPostAPIApplicationGuildCommandsResult, RESTGetAPIApplicationGuildCommandResult, RESTPatchAPIApplicationGuildCommandJSONBody, RESTPatchAPIApplicationGuildCommandResult, RESTPutAPIApplicationGuildCommandsJSONBody, RESTPutAPIApplicationGuildCommandsResult, RESTGetAPIGuildApplicationCommandsPermissionsResult, RESTPutAPIApplicationCommandPermissionsJSONBody, RESTPatchCurrentApplicationJSONBody, RESTGetAPIApplicationEmojisResult, RESTPostAPIApplicationEmojiJSONBody, RESTPatchAPIApplicationEmojiJSONBody, RESTPostAPIGuildForumThreadsJSONBody, RESTPostAPIChannelMessageJSONBody, RESTPatchAPIChannelMessageJSONBody, RESTGetAPIChannelMessageReactionUsersQuery, RESTGetAPIChannelMessageReactionUsersResult, RESTPatchAPIChannelJSONBody, RESTGetAPIChannelMessagesQuery, RESTGetAPIChannelMessagesResult, RESTGetAPIChannelMessagesPinsQuery, RESTGetAPIChannelMessagesPinsResult, RESTPostAPIChannelInviteJSONBody, RESTGetAPIChannelInvitesResult, RESTPostAPIChannelThreadsJSONBody, RESTPostAPIChannelThreadsResult, RESTGetAPIChannelThreadsArchivedQuery, RESTGetAPIChannelUsersThreadsArchivedResult, RESTPostAPIChannelWebhookJSONBody, RESTGetAPIChannelWebhooksResult, RESTPutAPIChannelPermissionJSONBody, RESTPostAPISoundboardSendSoundJSONBody, RESTPutAPIChannelRecipientJSONBody, RESTPostAPIGuildStickerFormDataBody, RESTGetAPIGuildQuery, RESTPatchAPIGuildJSONBody, RESTPutAPIGuildMemberJSONBody, RESTPutAPIGuildMemberResult, RESTGetAPIGuildMembersQuery, RESTGetAPIGuildMembersResult, RESTGetAPIGuildChannelsResult, RESTPostAPIGuildChannelJSONBody, RESTPatchAPIGuildChannelPositionsJSONBody, RESTGetAPIGuildBansQuery, RESTGetAPIGuildBansResult, RESTPutAPIGuildBanJSONBody, RESTPostAPIGuildBulkBanJSONBody, RESTPostAPIGuildBulkBanResult, RESTGetAPIGuildRolesResult, RESTPostAPIGuildRoleJSONBody, RESTPatchAPIGuildRolePositionsJSONBody, RESTPatchAPIGuildRolePositionsResult, RESTPatchAPIGuildRoleJSONBody, RESTGetAPIGuildPruneCountQuery, RESTGetAPIGuildPruneCountResult, RESTPostAPIGuildPruneJSONBody, RESTPostAPIGuildPruneResult, RESTGetAPIGuildVoiceRegionsResult, RESTGetAPIGuildInvitesResult, RESTGetAPIGuildIntegrationsResult, RESTPatchAPIGuildWidgetSettingsJSONBody, RESTGetAPIGuildVanityUrlResult, GuildWidgetStyle, RESTPatchAPIGuildWelcomeScreenJSONBody, RESTGetAPIGuildEmojisResult, RESTPostAPIGuildEmojiJSONBody, RESTPatchAPIGuildEmojiJSONBody, RESTGetAPIGuildScheduledEventsQuery, RESTGetAPIGuildScheduledEventsResult, RESTPostAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventQuery, RESTPatchAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventUsersQuery, RESTGetAPIGuildScheduledEventUsersResult, RESTGetAPIGuildTemplatesResult, RESTPatchAPIGuildTemplateJSONBody, RESTGetAPIGuildStickersResult, RESTPatchAPIGuildStickerJSONBody, RESTGetAPIAuditLogQuery, RESTGetAPIAutoModerationRulesResult, RESTPostAPIAutoModerationRuleJSONBody, RESTPatchAPIAutoModerationRuleJSONBody, RESTGetAPIGuildMembersSearchQuery, RESTGetAPIGuildMembersSearchResult, RESTPatchAPIGuildMemberJSONBody, RESTPostAPIGuildTemplatesJSONBody, RESTGetAPIGuildWebhooksResult, RESTPutAPIGuildOnboardingJSONBody, RESTGetAPIGuildSoundboardSoundsResult, RESTPostAPIGuildSoundboardSoundJSONBody, RESTPatchAPIGuildSoundboardSoundJSONBody, RESTPutAPIGuildIncidentActionsJSONBody, RESTPatchAPIWebhookJSONBody, RESTPostAPIWebhookWithTokenJSONBody, RESTPostAPIWebhookWithTokenQuery, RESTPostAPIWebhookWithTokenWaitResult, RESTPostAPIWebhookWithTokenSlackQuery, RESTPostAPIWebhookWithTokenGitHubQuery, RESTGetAPIWebhookWithTokenMessageQuery, RESTPatchAPIWebhookWithTokenMessageJSONBody, RESTPatchAPIWebhookWithTokenMessageQuery, APIInteractionResponseCallbackData, RESTPostAPIInteractionCallbackQuery, APIInteractionResponseDeferredChannelMessageWithSource, APICommandAutocompleteInteractionResponseCallbackData, APIModalInteractionResponseCallbackData, RESTPostAPIInteractionCallbackWithResponseResult, RESTGetAPIInviteQuery, RESTGetAPISKUsResult, RESTGetAPISKUSubscriptionsQuery, RESTGetAPISKUSubscriptionsResult, RESTGetAPIEntitlementsQuery, RESTGetAPIEntitlementsResult, RESTPostAPIEntitlementJSONBody, RESTOAuth2AuthorizationQuery, RESTPostOAuth2AccessTokenURLEncodedData, RESTPostOAuth2AccessTokenResult, RESTPostOAuth2RefreshTokenURLEncodedData, RESTPostOAuth2ClientCredentialsURLEncodedData, RESTGetAPIOAuth2CurrentApplicationResult, RESTGetAPIOAuth2CurrentAuthorizationResult, RESTPostOAuth2TokenRevocationQuery, RESTGetAPIPollAnswerVotersQuery, RESTGetAPIPollAnswerVotersResult, RESTGetAPIApplicationRoleConnectionMetadataResult, RESTPutAPIApplicationRoleConnectionMetadataJSONBody, RESTPutAPIApplicationRoleConnectionMetadataResult, RESTGetAPISoundboardDefaultSoundsResult, RESTPostAPIStageInstanceJSONBody, RESTPatchAPIStageInstanceJSONBody, RESTGetStickerPacksResult, RESTGetAPIChannelThreadMemberQuery, RESTGetAPIChannelThreadMemberResult, RESTGetAPIChannelThreadMembersResult, RESTGetAPICurrentUserGuildsQuery, RESTGetAPICurrentUserGuildsResult, RESTPatchAPICurrentUserJSONBody, RESTPatchAPICurrentGuildMemberJSONBody, RESTGetAPICurrentUserConnectionsResult, RESTPutAPICurrentUserApplicationRoleConnectionJSONBody, RESTGetAPIVoiceRegionsResult, RESTPatchAPIGuildVoiceStateUserJSONBody, RESTPatchAPIGuildVoiceStateCurrentMemberJSONBody, GatewaySendPayload, GatewayDispatchEvents, GatewayApplicationCommandPermissionsUpdateDispatchData, GatewayAutoModerationActionExecutionDispatchData, GatewayAutoModerationRuleCreateDispatchData, GatewayAutoModerationRuleDeleteDispatchData, GatewayAutoModerationRuleUpdateDispatchData, GatewayChannelCreateDispatchData, GatewayChannelDeleteDispatchData, GatewayChannelPinsUpdateDispatchData, GatewayChannelUpdateDispatchData, GatewayEntitlementCreateDispatchData, GatewayEntitlementDeleteDispatchData, GatewayEntitlementUpdateDispatchData, GatewayGuildAuditLogEntryCreateDispatchData, GatewayGuildBanAddDispatchData, GatewayGuildBanRemoveDispatchData, GatewayGuildCreateDispatchData, GatewayGuildDeleteDispatchData, GatewayGuildEmojisUpdateDispatchData, GatewayGuildIntegrationsUpdateDispatchData, GatewayGuildMemberAddDispatchData, GatewayGuildMemberRemoveDispatchData, GatewayGuildMemberUpdateDispatchData, GatewayGuildMembersChunkDispatchData, GatewayGuildRoleCreateDispatchData, GatewayGuildRoleDeleteDispatchData, GatewayGuildRoleUpdateDispatchData, GatewayGuildScheduledEventCreateDispatchData, GatewayGuildScheduledEventDeleteDispatchData, GatewayGuildScheduledEventUpdateDispatchData, GatewayGuildScheduledEventUserAddDispatchData, GatewayGuildScheduledEventUserRemoveDispatchData, GatewayGuildSoundboardSoundCreateDispatch, GatewayGuildSoundboardSoundDeleteDispatch, GatewayGuildSoundboardSoundUpdateDispatch, GatewayGuildSoundboardSoundsUpdateDispatch, GatewaySoundboardSoundsDispatchData, GatewayGuildStickersUpdateDispatchData, GatewayGuildUpdateDispatchData, GatewayIntegrationCreateDispatchData, GatewayIntegrationDeleteDispatchData, GatewayIntegrationUpdateDispatchData, GatewayInteractionCreateDispatchData, GatewayInviteCreateDispatchData, GatewayInviteDeleteDispatchData, GatewayMessageCreateDispatchData, GatewayMessageDeleteDispatchData, GatewayMessageDeleteBulkDispatchData, GatewayMessagePollVoteDispatchData, GatewayMessageReactionAddDispatchData, GatewayMessageReactionRemoveDispatchData, GatewayMessageReactionRemoveAllDispatchData, GatewayMessageReactionRemoveEmojiDispatchData, GatewayMessageUpdateDispatchData, GatewayPresenceUpdateDispatchData, GatewayReadyDispatchData, GatewayStageInstanceCreateDispatchData, GatewayStageInstanceDeleteDispatchData, GatewayStageInstanceUpdateDispatchData, GatewaySubscriptionCreateDispatchData, GatewaySubscriptionDeleteDispatchData, GatewaySubscriptionUpdateDispatchData, GatewayThreadCreateDispatchData, GatewayThreadDeleteDispatchData, GatewayThreadListSyncDispatchData, GatewayThreadMemberUpdateDispatchData, GatewayThreadMembersUpdateDispatchData, GatewayThreadUpdateDispatchData, GatewayTypingStartDispatchData, GatewayUserUpdateDispatchData, GatewayVoiceServerUpdateDispatchData, GatewayVoiceStateUpdateDispatchData, GatewayWebhooksUpdateDispatchData, GatewayRequestGuildMembersData, GatewayRequestSoundboardSoundsData, GatewayVoiceStateUpdateData, GatewayPresenceUpdateData } from 'discord-api-types/v10';
|
|
3
|
+
import { Snowflake, RESTGetAPIApplicationCommandsQuery, RESTGetAPIApplicationCommandsResult, RESTPostAPIApplicationCommandsJSONBody, RESTPatchAPIApplicationCommandJSONBody, RESTPutAPIApplicationCommandsJSONBody, RESTPutAPIApplicationCommandsResult, RESTGetAPIApplicationGuildCommandsQuery, RESTGetAPIApplicationGuildCommandsResult, RESTPostAPIApplicationGuildCommandsJSONBody, RESTPostAPIApplicationGuildCommandsResult, RESTGetAPIApplicationGuildCommandResult, RESTPatchAPIApplicationGuildCommandJSONBody, RESTPatchAPIApplicationGuildCommandResult, RESTPutAPIApplicationGuildCommandsJSONBody, RESTPutAPIApplicationGuildCommandsResult, RESTGetAPIGuildApplicationCommandsPermissionsResult, RESTPutAPIApplicationCommandPermissionsJSONBody, RESTPatchCurrentApplicationJSONBody, RESTGetAPIApplicationEmojisResult, RESTPostAPIApplicationEmojiJSONBody, RESTPatchAPIApplicationEmojiJSONBody, RESTPostAPIGuildForumThreadsJSONBody, RESTPostAPIChannelMessageJSONBody, RESTPatchAPIChannelMessageJSONBody, RESTGetAPIChannelMessageReactionUsersQuery, RESTGetAPIChannelMessageReactionUsersResult, RESTPatchAPIChannelJSONBody, RESTGetAPIChannelMessagesQuery, RESTGetAPIChannelMessagesResult, RESTGetAPIChannelMessagesPinsQuery, RESTGetAPIChannelMessagesPinsResult, RESTPostAPIChannelInviteJSONBody, RESTGetAPIChannelInvitesResult, RESTPostAPIChannelThreadsJSONBody, RESTPostAPIChannelThreadsResult, RESTGetAPIChannelThreadsArchivedQuery, RESTGetAPIChannelUsersThreadsArchivedResult, RESTPostAPIChannelWebhookJSONBody, RESTGetAPIChannelWebhooksResult, RESTPutAPIChannelPermissionJSONBody, RESTPostAPISoundboardSendSoundJSONBody, RESTPutAPIChannelRecipientJSONBody, RESTPostAPIGuildStickerFormDataBody, RESTGetAPIGuildQuery, RESTPatchAPIGuildJSONBody, RESTPutAPIGuildMemberJSONBody, RESTPutAPIGuildMemberResult, RESTGetAPIGuildMembersQuery, RESTGetAPIGuildMembersResult, RESTGetAPIGuildChannelsResult, RESTPostAPIGuildChannelJSONBody, RESTPatchAPIGuildChannelPositionsJSONBody, RESTGetAPIGuildBansQuery, RESTGetAPIGuildBansResult, RESTPutAPIGuildBanJSONBody, RESTPostAPIGuildBulkBanJSONBody, RESTPostAPIGuildBulkBanResult, RESTGetAPIGuildRolesResult, RESTPostAPIGuildRoleJSONBody, RESTPatchAPIGuildRolePositionsJSONBody, RESTPatchAPIGuildRolePositionsResult, RESTPatchAPIGuildRoleJSONBody, RESTGetAPIGuildPruneCountQuery, RESTGetAPIGuildPruneCountResult, RESTPostAPIGuildPruneJSONBody, RESTPostAPIGuildPruneResult, RESTGetAPIGuildVoiceRegionsResult, RESTGetAPIGuildInvitesResult, RESTGetAPIGuildIntegrationsResult, RESTPatchAPIGuildWidgetSettingsJSONBody, RESTGetAPIGuildVanityUrlResult, GuildWidgetStyle, RESTPatchAPIGuildWelcomeScreenJSONBody, RESTGetAPIGuildEmojisResult, RESTPostAPIGuildEmojiJSONBody, RESTPatchAPIGuildEmojiJSONBody, RESTGetAPIGuildScheduledEventsQuery, RESTGetAPIGuildScheduledEventsResult, RESTPostAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventQuery, RESTPatchAPIGuildScheduledEventJSONBody, RESTGetAPIGuildScheduledEventUsersQuery, RESTGetAPIGuildScheduledEventUsersResult, RESTGetAPIGuildTemplatesResult, RESTPatchAPIGuildTemplateJSONBody, RESTGetAPIGuildStickersResult, RESTPatchAPIGuildStickerJSONBody, RESTGetAPIAuditLogQuery, RESTGetAPIAutoModerationRulesResult, RESTPostAPIAutoModerationRuleJSONBody, RESTPatchAPIAutoModerationRuleJSONBody, RESTGetAPIGuildMembersSearchQuery, RESTGetAPIGuildMembersSearchResult, RESTPatchAPIGuildMemberJSONBody, RESTPostAPIGuildTemplatesJSONBody, RESTGetAPIGuildWebhooksResult, RESTPutAPIGuildOnboardingJSONBody, RESTGetAPIGuildSoundboardSoundsResult, RESTPostAPIGuildSoundboardSoundJSONBody, RESTPatchAPIGuildSoundboardSoundJSONBody, RESTPutAPIGuildIncidentActionsJSONBody, RESTPatchAPIWebhookJSONBody, RESTPostAPIWebhookWithTokenJSONBody, RESTPostAPIWebhookWithTokenQuery, RESTPostAPIWebhookWithTokenWaitResult, RESTPostAPIWebhookWithTokenSlackQuery, RESTPostAPIWebhookWithTokenGitHubQuery, RESTGetAPIWebhookWithTokenMessageQuery, RESTPatchAPIWebhookWithTokenMessageJSONBody, RESTPatchAPIWebhookWithTokenMessageQuery, APIInteractionResponseCallbackData, RESTPostAPIInteractionCallbackQuery, APIInteractionResponseDeferredChannelMessageWithSource, APICommandAutocompleteInteractionResponseCallbackData, APIModalInteractionResponseCallbackData, RESTPostAPIInteractionCallbackWithResponseResult, RESTGetAPIInviteQuery, RESTGetAPISKUsResult, RESTGetAPISKUSubscriptionsQuery, RESTGetAPISKUSubscriptionsResult, RESTGetAPIEntitlementsQuery, RESTGetAPIEntitlementsResult, RESTPostAPIEntitlementJSONBody, RESTOAuth2AuthorizationQuery, RESTPostOAuth2AccessTokenURLEncodedData, RESTPostOAuth2AccessTokenResult, RESTPostOAuth2RefreshTokenURLEncodedData, RESTPostOAuth2ClientCredentialsURLEncodedData, RESTGetAPIOAuth2CurrentApplicationResult, RESTGetAPIOAuth2CurrentAuthorizationResult, RESTPostOAuth2TokenRevocationQuery, RESTGetAPIPollAnswerVotersQuery, RESTGetAPIPollAnswerVotersResult, RESTGetAPIApplicationRoleConnectionMetadataResult, RESTPutAPIApplicationRoleConnectionMetadataJSONBody, RESTPutAPIApplicationRoleConnectionMetadataResult, RESTGetAPISoundboardDefaultSoundsResult, RESTPostAPIStageInstanceJSONBody, RESTPatchAPIStageInstanceJSONBody, RESTGetStickerPacksResult, RESTGetAPIChannelThreadMemberQuery, RESTGetAPIChannelThreadMemberResult, RESTGetAPIChannelThreadMembersResult, RESTGetAPICurrentUserGuildsQuery, RESTGetAPICurrentUserGuildsResult, RESTPatchAPICurrentUserJSONBody, RESTPatchAPICurrentGuildMemberJSONBody, RESTGetAPICurrentUserConnectionsResult, RESTPutAPICurrentUserApplicationRoleConnectionJSONBody, RESTGetAPIVoiceRegionsResult, RESTPatchAPIGuildVoiceStateUserJSONBody, RESTPatchAPIGuildVoiceStateCurrentMemberJSONBody, GatewaySendPayload, GatewayDispatchEvents, GatewayApplicationCommandPermissionsUpdateDispatchData, GatewayAutoModerationActionExecutionDispatchData, GatewayAutoModerationRuleCreateDispatchData, GatewayAutoModerationRuleDeleteDispatchData, GatewayAutoModerationRuleUpdateDispatchData, GatewayChannelCreateDispatchData, GatewayChannelDeleteDispatchData, GatewayChannelPinsUpdateDispatchData, GatewayChannelUpdateDispatchData, GatewayEntitlementCreateDispatchData, GatewayEntitlementDeleteDispatchData, GatewayEntitlementUpdateDispatchData, GatewayGuildAuditLogEntryCreateDispatchData, GatewayGuildBanAddDispatchData, GatewayGuildBanRemoveDispatchData, GatewayGuildCreateDispatchData, GatewayGuildDeleteDispatchData, GatewayGuildEmojisUpdateDispatchData, GatewayGuildIntegrationsUpdateDispatchData, GatewayGuildMemberAddDispatchData, GatewayGuildMemberRemoveDispatchData, GatewayGuildMemberUpdateDispatchData, GatewayGuildMembersChunkDispatchData, GatewayGuildRoleCreateDispatchData, GatewayGuildRoleDeleteDispatchData, GatewayGuildRoleUpdateDispatchData, GatewayGuildScheduledEventCreateDispatchData, GatewayGuildScheduledEventDeleteDispatchData, GatewayGuildScheduledEventUpdateDispatchData, GatewayGuildScheduledEventUserAddDispatchData, GatewayGuildScheduledEventUserRemoveDispatchData, GatewayGuildSoundboardSoundCreateDispatch, GatewayGuildSoundboardSoundDeleteDispatch, GatewayGuildSoundboardSoundUpdateDispatch, GatewayGuildSoundboardSoundsUpdateDispatch, GatewaySoundboardSoundsDispatchData, GatewayGuildStickersUpdateDispatchData, GatewayGuildUpdateDispatchData, GatewayIntegrationCreateDispatchData, GatewayIntegrationDeleteDispatchData, GatewayIntegrationUpdateDispatchData, GatewayInteractionCreateDispatchData, GatewayInviteCreateDispatchData, GatewayInviteDeleteDispatchData, GatewayMessageCreateDispatchData, GatewayMessageDeleteDispatchData, GatewayMessageDeleteBulkDispatchData, GatewayMessagePollVoteDispatchData, GatewayMessageReactionAddDispatchData, GatewayMessageReactionRemoveDispatchData, GatewayMessageReactionRemoveAllDispatchData, GatewayMessageReactionRemoveEmojiDispatchData, GatewayMessageUpdateDispatchData, GatewayPresenceUpdateDispatchData, GatewayRateLimitedDispatchData, GatewayReadyDispatchData, GatewayStageInstanceCreateDispatchData, GatewayStageInstanceDeleteDispatchData, GatewayStageInstanceUpdateDispatchData, GatewaySubscriptionCreateDispatchData, GatewaySubscriptionDeleteDispatchData, GatewaySubscriptionUpdateDispatchData, GatewayThreadCreateDispatchData, GatewayThreadDeleteDispatchData, GatewayThreadListSyncDispatchData, GatewayThreadMemberUpdateDispatchData, GatewayThreadMembersUpdateDispatchData, GatewayThreadUpdateDispatchData, GatewayTypingStartDispatchData, GatewayUserUpdateDispatchData, GatewayVoiceServerUpdateDispatchData, GatewayVoiceStateUpdateDispatchData, GatewayWebhooksUpdateDispatchData, GatewayRequestGuildMembersData, GatewayRequestSoundboardSoundsData, GatewayVoiceStateUpdateData, GatewayPresenceUpdateData } from 'discord-api-types/v10';
|
|
4
4
|
export * from 'discord-api-types/v10';
|
|
5
5
|
import { AsyncEventEmitter } from '@vladfrangu/async_event_emitter';
|
|
6
6
|
import { Awaitable } from '@discordjs/util';
|
|
7
|
+
export { GatewayRateLimitError } from '@discordjs/util';
|
|
7
8
|
import { WebSocketShardEvents, ManagerShardEventsMap as ManagerShardEventsMap$1 } from '@discordjs/ws';
|
|
8
9
|
import * as discord_api_types_globals from 'discord-api-types/globals';
|
|
9
10
|
|
|
@@ -2329,6 +2330,7 @@ interface MappedEvents {
|
|
|
2329
2330
|
[GatewayDispatchEvents.MessageReactionRemoveEmoji]: [ToEventProps<GatewayMessageReactionRemoveEmojiDispatchData>];
|
|
2330
2331
|
[GatewayDispatchEvents.MessageUpdate]: [ToEventProps<GatewayMessageUpdateDispatchData>];
|
|
2331
2332
|
[GatewayDispatchEvents.PresenceUpdate]: [ToEventProps<GatewayPresenceUpdateDispatchData>];
|
|
2333
|
+
[GatewayDispatchEvents.RateLimited]: [ToEventProps<GatewayRateLimitedDispatchData>];
|
|
2332
2334
|
[GatewayDispatchEvents.Ready]: [ToEventProps<GatewayReadyDispatchData>];
|
|
2333
2335
|
[GatewayDispatchEvents.Resumed]: [ToEventProps<never>];
|
|
2334
2336
|
[GatewayDispatchEvents.StageInstanceCreate]: [ToEventProps<GatewayStageInstanceCreateDispatchData>];
|
package/dist/index.js
CHANGED
|
@@ -28,6 +28,7 @@ __export(index_exports, {
|
|
|
28
28
|
ChannelsAPI: () => ChannelsAPI,
|
|
29
29
|
Client: () => Client,
|
|
30
30
|
GatewayAPI: () => GatewayAPI,
|
|
31
|
+
GatewayRateLimitError: () => import_util2.GatewayRateLimitError,
|
|
31
32
|
GuildsAPI: () => GuildsAPI,
|
|
32
33
|
InteractionsAPI: () => InteractionsAPI,
|
|
33
34
|
InvitesAPI: () => InvitesAPI,
|
|
@@ -3200,6 +3201,18 @@ var Client = class extends import_async_event_emitter.AsyncEventEmitter {
|
|
|
3200
3201
|
const nonce = options.nonce ?? import_snowflake.DiscordSnowflake.generate().toString();
|
|
3201
3202
|
const controller = new AbortController();
|
|
3202
3203
|
let timer = createTimer(controller, timeout);
|
|
3204
|
+
const onRatelimit = /* @__PURE__ */ __name(({ data }) => {
|
|
3205
|
+
if (data.meta.nonce === nonce) {
|
|
3206
|
+
controller.abort(new import_util.GatewayRateLimitError(data, options));
|
|
3207
|
+
}
|
|
3208
|
+
}, "onRatelimit");
|
|
3209
|
+
const cleanup = /* @__PURE__ */ __name(() => {
|
|
3210
|
+
if (timer) {
|
|
3211
|
+
(0, import_node_timers.clearTimeout)(timer);
|
|
3212
|
+
}
|
|
3213
|
+
this.off(import_v1019.GatewayDispatchEvents.RateLimited, onRatelimit);
|
|
3214
|
+
}, "cleanup");
|
|
3215
|
+
this.on(import_v1019.GatewayDispatchEvents.RateLimited, onRatelimit);
|
|
3203
3216
|
await this.gateway.send(shardId, {
|
|
3204
3217
|
op: import_v1019.GatewayOpcodes.RequestGuildMembers,
|
|
3205
3218
|
// eslint-disable-next-line id-length
|
|
@@ -3229,13 +3242,14 @@ var Client = class extends import_async_event_emitter.AsyncEventEmitter {
|
|
|
3229
3242
|
}
|
|
3230
3243
|
} catch (error) {
|
|
3231
3244
|
if (error instanceof Error && error.name === "AbortError") {
|
|
3245
|
+
if (error.cause instanceof import_util.GatewayRateLimitError) {
|
|
3246
|
+
throw error.cause;
|
|
3247
|
+
}
|
|
3232
3248
|
throw new Error("Request timed out");
|
|
3233
3249
|
}
|
|
3234
3250
|
throw error;
|
|
3235
3251
|
} finally {
|
|
3236
|
-
|
|
3237
|
-
(0, import_node_timers.clearTimeout)(timer);
|
|
3238
|
-
}
|
|
3252
|
+
cleanup();
|
|
3239
3253
|
}
|
|
3240
3254
|
}
|
|
3241
3255
|
/**
|
|
@@ -3397,7 +3411,8 @@ __name(withFiles, "withFiles");
|
|
|
3397
3411
|
|
|
3398
3412
|
// src/index.ts
|
|
3399
3413
|
__reExport(index_exports, require("discord-api-types/v10"), module.exports);
|
|
3400
|
-
var
|
|
3414
|
+
var import_util2 = require("@discordjs/util");
|
|
3415
|
+
var version = "3.0.0-dev.1762862514-d3d6777ef";
|
|
3401
3416
|
// Annotate the CommonJS export names for ESM import in node:
|
|
3402
3417
|
0 && (module.exports = {
|
|
3403
3418
|
API,
|
|
@@ -3406,6 +3421,7 @@ var version = "3.0.0-dev.1762819348-37a38883d";
|
|
|
3406
3421
|
ChannelsAPI,
|
|
3407
3422
|
Client,
|
|
3408
3423
|
GatewayAPI,
|
|
3424
|
+
GatewayRateLimitError,
|
|
3409
3425
|
GuildsAPI,
|
|
3410
3426
|
InteractionsAPI,
|
|
3411
3427
|
InvitesAPI,
|