discordgo icon indicating copy to clipboard operation
discordgo copied to clipboard

(Golang) Go bindings for Discord

Results 192 discordgo issues
Sort by recently updated
recently updated
newest added

Implement [`resume_gateway_url`](https://discord.com/developers/docs/change-log#sessionspecific-gateway-resume-urls) functionality for the gateway.

feature
gateway

This PR removes a `time.Sleep(1 * time.Second)` from `Session.Close()`. Instead, I implemented the websocket close handshake described in this comment: https://github.com/gorilla/websocket/issues/448#issuecomment-469903859 The reason I would like to see this change...

gateway
improvement

I am trying add a discord slash commands. But i am getting this error. I am using the examples. Copied the entire code to test. [Code](https://github.com/bwmarrin/discordgo/tree/master/examples/slash_commands) ` 2023/12/21 23:39:33 Adding...

## Motivation When trying to register commands using the `ApplicationCommandCreate` function, as done in [the example](https://github.com/bwmarrin/discordgo/blob/master/examples/slash_commands/main.go#L559), I am met with a `405: method not allowed` status code. ## Solution When...

I attempted to reset the token after establishing a connection with the Discord gateway, but it appears that `session.LastHeartbeatAck` continues to update. **Edited:** In line 608, it appears we're never...

This is an alternative solution to https://github.com/bwmarrin/discordgo/pull/1181

rest

Adding support for `sync_id` when unpacking Presence activities. This will give users the ability to get the `Spotify Track ID` from a presence event

undocumented

This is not documented at the moment. The field contains the text you provide when setting a custom voice channel status. ![image](https://github.com/bwmarrin/discordgo/assets/14981592/9ca75834-866b-4d59-b72f-5cf6238c19b9) ![image](https://github.com/bwmarrin/discordgo/assets/14981592/fe2cfc5c-d56d-49d4-ba8c-e71d4e339aeb)

feature
voice
structs

Without the below (or handling this explicitly by the caller), reusing the VoiceChannel causes a panic attempting to send on a closed channel. This ensures the channels are nil'd on...

Couldn't find a way to send a raw gateway message, so added a wrapper function around `wsConn.WriteJSON`

feature
gateway