* Add missing application properties
Add IsBotPublic, BotRequiresCodeGrant, and Team properties to IApplication
* To immutable list
* Change list to array
* Add invite events (create and delete)
* Removed unused using
* Fixing IInviteMetadata properties
* Add two new fields to the gateway event
* Better event summary and remarks
* Change how to assign to target variable
Co-Authored-By: Joe4evr <jii.geugten@gmail.com>
* Applying suggested changes to TargetUserType
* Renaming NotDefined to Undefined
* Fixing xml docs
* Changed the summary style format
Co-authored-by: Joe4evr <jii.geugten@gmail.com>
Sometimes Discord messes up and leaves a guild with a null PreferredLocale, causing an error to be thrown. This fixes that from Discord.Net's end even though it's Discord's fault.
* Fix: Using the correct discord domain.
* Fix: Using the correct discord domain.
* Docs: Using the correct discord domain.
* Fix: Changed canary and ptb to the new domain.
* Don't disable when there's no resetTick
Sometimes Discord won't send any ratelimit headers, disabling the semaphore for endpoints that should have them.
* Undo changes and change comment
* Add HttpMethod to BucketIds
* Add X-RateLimit-Bucket
* BucketId changes
- BucketId is it's own class now
- Add WebhookId as a major parameter
- Add shared buckets using the hash and major parameters
* Add webhookId to BucketIds
* Update BucketId and redirect requests
* General bugfixes
* Assign semaphore and follow the same standard as Reset for ResetAfter
fix for: https://github.com/discord-net/Discord.Net/issues/1436
`SlowModeInterval` property causes an exception for Announcement Channel feature if it is enabled on discord. Should be checked whether it is specified or not before set to property.
* Fix Ready and AlwaysDownloadUsers
Ready could fire before downloading all guild data and downloading guild users one guild per time without gateway intents is a waste of a gateway request that can support up to 1000.
* Reduce batchSize and fix count
* Fix typo
* Split xml docs line
Co-authored-by: Christopher Felegy <cfelegy@riseup.net>
* Add Direction.Around to GetMessagesAsync
* Reuse the method
* Reuse GetMany
* Fix limit when getting from cache without message id
* Fix limit when getting from rest without message id
* Change cache return
It will return in a similar way to REST
* Support Gateway Intents
Allows supplying gateway intents through DiscordSocketConfig which will be passed through the IDENTIFY payload, in order to choose what gateway events you want to receive.
* Fixing enum casing
* Feedback
* Updating comment for GuildSubscriptions
* Comment update
The GuildHelper.CreateRoleAsync() was sending 2 requests to create a role. One to create the role, and one to modify the role that was created. This can be done in one request. So i have moved it to a single request to lower the amount of requests send to the api. This will also solve issue #1451.
## Summary
If PartyId isn't present, Discord.Net will throw an InvalidOperationException and not raise `MessageReceived`.
Got this a few times with my bot, stacktrace:
```
System.InvalidOperationException: This property has no value set.
at Discord.Optional`1.get_Value() in ...\Discord.Net\src\Discord.Net.Core\Utils\Optional.cs:line 20
at Discord.WebSocket.SocketMessage.Update(ClientState state, Message model) in ...\Discord.Net\src\Discord.Net.WebSocket\Entities\Messages\SocketMessage.cs:line 157
at Discord.WebSocket.SocketUserMessage.Update(ClientState state, Message model) in ...\Discord.Net\src\Discord.Net.WebSocket\Entities\Messages\SocketUserMessage.cs:line 58
at Discord.WebSocket.SocketUserMessage.Create(DiscordSocketClient discord, ClientState state, SocketUser author, ISocketMessageChannel channel, Message model) in ...\Discord.Net\src\Discord.Net.WebSocket\Entities\Messages\SocketUserMessage.cs:line 53
at Discord.WebSocket.DiscordSocketClient.ProcessMessageAsync(GatewayOpCode opCode, Nullable`1 seq, String type, Object payload) in ...\Discord.Net\src\Discord.Net.WebSocket\DiscordSocketClient.cs:line 1210
```
After looking all properties, this is the only one that could be blamed and was already fixed for `RestMessage`s, see #1337
## Changes
- `Value` to `GetValueOrDefault()` for `PartyId`