Commit graph

13 commits

Author SHA1 Message Date
plally
ab47f123ba
support allowing webhook edits with files, and responding to interactions with files (#931)
* allow files in webhook message edits

* add Files to WebhookEdit struct

* move the construction of the multipart body for files into a shared function

* allow  interaction responses to have files

* go fmt

* fix err shadowing

* document MakeFilesBody

* rename MakeFilesBody -> EncodeWithFiles. fix InteractionRespond responding twice

* use resp in InteractionRespond files, add basic-command-with-files example command

* import strings and go fmt

* EncodeWithFiles -> MultiPartBodyWithJSON

* go fmt

* fix example for slash_commands

* move files to responsedata
2021-07-30 11:22:08 -04:00
NANI
9b1ba78bc6
Adding millisecond precision to SnowflakeTimestamp utility (#732)
* Millisecond precision

* formatting

* Update util.go

* remove unnecessary int64

* Add unit test for SnowflakeTimestamp

Co-authored-by: NANI <nani@ksoft.si>
Co-authored-by: Carson Hoffman <c@rsonhoffman.com>
2020-06-16 23:43:34 -04:00
necro
e3acfe56f0 added SnowflakeTimestamp utility function to obtain the creation date of a discord snowflake ID 2019-04-12 11:19:31 -04:00
Bruce Marriner
fc7ce3db94 Initial add of new logging system
This adds a LogLevel setting for both Websocket and VoiceConnections
that can be configured to set the specific log level desired. This
also adds a new logging function that adds additional helpful
information when printing out log messages.
2016-04-26 21:17:51 -05:00
jonas747
d1f25d8561 Changed fmt.Print to log.Print 2016-03-21 17:13:39 +01:00
Chris Rhodes
a08dde4262 Support zlib compression. 2016-01-23 21:09:30 -08:00
Bruce Marriner
301fb980d3 Updated copyright year, cleaned up some comments. 2016-01-07 13:50:44 -06:00
Bruce Marriner
35e3966b91 Reworded top comment 2015-11-23 10:16:23 -06:00
Bruce Marriner
abe55ecca7 Some improvements to comments. 2015-11-23 09:45:40 -06:00
Bruce Marriner
f655167761 Several updates to make library more idiomatic Go 2015-11-16 21:39:39 -06:00
Bruce Marriner
2448f72489 Major rewrite of REST API to include constants for all endpoints 2015-11-14 15:46:33 -06:00
Bruce Marriner
2c3ca777f9 Clean up, notes 2015-11-09 14:22:36 -06:00
Bruce Marriner
adac11495a Inital addition of Websocket handling. Lots of moving things around. 2015-11-08 19:26:46 -06:00