DiscordGo v0.24.0
Hang tight, this one is the biggest yet
Important notice
From this release forward, DiscordGo will require Go 1.13+ to run.
Breaking changes of master
Since v.0.23.0
we've been recommending everyone to use @master
version for slash commands, context menus and other new stuff.
This led to a big problem with versioning and breaking changes, because some of the features weren't implemented fully, had some problems didn't properly function or didn't fully reflect the API, and so there was a number of breaking changes since the base feature PRs:
- Some of
InteractionResponseTypes
were removed. #930 InteractionResponseACKWithSource
was renamed toInteractionResponseDeferredChannelMessageWithSource
. #930- Type of
MinValues
inSelectMenu
was changed to*float64
, to allow for the default values when field isn't set. #1026 InteractionApplicationCommandResponseData
has been renamed toInteractionResponseData
. #933ButtonEmoji
was renamed toComponentEmoji
. #954ApplicationCommandInteractionData
has been removed, useInteraction.ApplicationCommandData()
instead. #954MessageTypeApplicationCommand
was replaced byMessageTypeChatInputCommand
. #978
API version v9
Now DiscordGo uses API v9! Due to this fact this release includes a couple of breaking changes regarding the API:
Breaking changes
- User account login, endpoints and methods were dropped. #1087
Embed
now is replaced withEmbeds
inMessageSend
andMessageEdit
. #1000EndpointApplications
no longer points to OAuth2 applications. UseEndpointOAuth2Applications
for that instead. #856TargetUserType
field inInvite
andTargetUserType
type are renamed toTargetType
. Additionally all the constants namedInviteTargetUserType<Name>
were renamed toInviteTarget<Name>
. See #1105 for more infoRedirectURIs
were removed fromApplication
- All user flags now use
UserFlag
type instead ofint
. #937 - REST API functions now will now return wrapped version of
ErrJSONUnmarshal
. For error checkerrors.Is
orerrors.Unwrap
should be used. #924 ErrCodeMaximumFriendsReached
andErrCodeNoteTooLong
error codes were removed. #1096
New features
- Guild preview #818
- Slash commands #856
- Constraints for slash command number options #1026
- Button component #933
- Selects component #954
- Context menus #978
- Ephemeral attachments #1008
- Slash commands options auto completion #1014
- Guild member timeouts #1061
- Interaction locale #1073
- Stickers #1057
- Modals #1049
- Application commands: attachment option #1088
- Threads #1058
- Guild stickers #1095
- Guild Templates #1091
- Guild Member avatars #1077
- Guild Scheduled Events #1032
InviteCreate
andInviteDelete
events #1105- User banners and accent colors #1117
Bug fixes
EndpointInvite
now points to correct API endpoint #892- RTP extended header is now parsed correctly #880
Other changes
- Addition of
Required
flag forresp-type
option of/responses
command in slash commands example #886 - Missing permission constants #906
- Addition of missing fields to
Activity
andGetCustomEmojis
toMessage
#895 - Addition of
Permissions
field toMember
#902 github.com/gorilla/websocket
was bumped to 1.4.2 #896- Correction of slash commands example spelling & grammar #905
- Fix of some typos detected by goreportcard #925
- Addition of
ApplicationCommandOptionMentionable
#918 - Bulk application command overwrite endpoint #926
- Wrapping of ErrJSONUnmarshal to include error message #924
- Addition of ping pong example for direct messages #882
- Addition of
ApplicationCommandInteractionDataResolved
#919 - Fix of
UserFlags
constants types #937 - Webhook message endpoint #948
- Support of attachments in webhooks and interaction responses #931
- Addition of
SessionStartLimit
field toGatewayBotResponse
#949 - Addition of
BeforeDelete
field toGuildDelete
#962 - Addition of
ActivityTypeCompeting
#990 - Addition of
ActivityTypeWatching
#983 - Channel type restrictions for
ApplicationCommandOption
#1015 - Fix of some links and wording in the docs #1010
- Addition of
Guild.BannerURL
method #1023 - Addition of
Member
toMessageReactionAdd
#1042 - Missing
MessageFlags
values #1089 - Missing audit log keys and actions #1098
- Missing JSON error codes #1096
- Missing intents #1097
- Addition of
DefaultPermission
field toApplicationCommand
#1071 - Addition of
Disabled
field toSelectMenu
#1102 - Implementation of removal procedure for slash commands example #1103
- Addition of
Interaction
field toMessage
#1112
Special thanks
- @42atomys
- @andresperezl
- @arHSM
- @chanbakjsd2
- @cnpryer
- @codemicro
- @constantoine
- @courtier
- @Dev-Bjorn
- @elliotwms
- @evieDelta
- @ewohltman
- @Fahim-Ferdous
- @FedorLap2006
- @galberti
- @ghost
- @Heanthor
- @Jleagle
- @Jordan-Cartwright
- @mutemule
- @Nv7-GitHub
- @Pedro-Pessoa
- @pixelrazor
- @plally
- @post04
- @QPixel
- @SmoothieNoIce
- @TopiSenpai
- @vertex-admin
- @xIceArcher
- @Xpl0itR
- @zephyrtronium
Full Changelog: v0.23.2...v0.24.0