1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-11-01 04:24:19 +00:00
Commit graph

12 commits

Author SHA1 Message Date
Juby210 4b6bc657dc
discord: Add permission fields to Command (#326)
* api/discord: add DefaultMemberPermissions and DMPermission to commands
* api/discord: invert DMPermission to match NoDefaultPermission
2022-05-08 03:33:56 -07:00
Neo f5f46f5fd4 api: Add localization fields to Application Command creation data 2022-04-12 08:39:44 -07:00
PL Pery 11432e426c
discord: Correct BulkOverwriteGuildCommands parameters (#301) 2022-01-03 13:38:38 -08:00
diamondburned 331ec59dec discord: Refactor interactions and components
This commit gets rid of contain-it-all structs and instead opt for
interface union types containing underlying concrete types with no
overloading.

The code is much more verbose by doing this, but the API is much nicer
to use. The only disadvantage in that regard is the interface assertion
being too verbose and risky for users at times.
2021-11-12 11:38:36 -08:00
samhza bfb644c124
api: Add CurrentApplication (#282)
* discord/api: support fetching bot's Application

* Update api/application.go

Co-authored-by: diamondburned <diamond@arikawa-hi.me>

Co-authored-by: diamondburned <diamond@arikawa-hi.me>
2021-10-03 13:31:48 -07:00
samhza dc92845315
discord: move Interaction over; update api.CommandCreateData (#274)
- Moved gateway.InteractionCreateData to discord.Interaction, now
gateway.InteractionCreateData is a struct that wraps
discord.Interaction.
- Split InteractionData into CommandInteractionData and
ComponentInteractionData.
- Renamed ButtonInteraction to ComponentInteraction.
- Updated api.CommandCreateData to add new fields.
- Update Component types' Type() methods to pointer receivers.
2021-09-09 16:06:44 -07:00
Maximilian von Lindern 19335e5050 api: Pointerize return types for consistency
Pointerize Client.Command, .GuildCommand, .CommandPermissions, and .EditCommandPermissions for consistency
2021-08-15 12:29:30 -07:00
Maximilian von Lindern 244570c280
api: Add support for the X-Audit-Log-Reason header (#259)
* api: add support for the X-Audit-Log-Reason header

* api: inline reason parameter, where data struct has a single field
2021-08-15 18:33:33 +02:00
Nat dbfc49fb08
API: Fix Client.{Guild,}Command() (#264) 2021-08-14 22:27:22 -07:00
Maximilian von Lindern 101fe46313
api: Add missing slash command endpoints (#252)
* api: add missing slash command endpoints
* fix examples
* api: Remove Original prefix from Client.OriginalInteractionResponse,
  EditOriginalResponse, and DeleteOriginalResponse
2021-08-03 11:44:20 -07:00
Samuel Hernandez 40e1a3757d *: Migrated Go Modules to v3 2021-06-01 19:59:01 -07:00
Matthew Penner 7c3374543e Discord: Add basic support for slash commands 2021-01-27 10:44:14 -08:00