-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update slash command limits #2667
Conversation
docs/interactions/Slash_Commands.md
Outdated
- An app can have up to 25 subcommands within a subcommand group | ||
- commands can have up to 25 `options` | ||
- options can have up to 25 `choices` | ||
- Maximum of 4000 characters for combined name, description, and value properties for each command and its children |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So I am encouraged to try having a shorter description for each option?
Additionally, what does "for each command and its children" mean? What is an example of a command invocation that wouldn't work?
docs/interactions/Slash_Commands.md
Outdated
- Limitations on [command names](#DOCS_INTERACTIONS_SLASH_COMMANDS/registering-a-command) | ||
- Limitations on [nesting subcommands and groups](#DOCS_INTERACTIONS_SLASH_COMMANDS/nested-subcommands-and-groups) | ||
- Rate limitation of 2 requests per 60 seconds for batch update | ||
- Rate limitation of 5 requests per 20 seconds for all other routes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Rate limitation of 5 requests per 20 seconds for all other routes | |
- Rate limit of 5 requests per 20 seconds for all other routes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only create
, edit
and delete
routes have this limit, get
, get-all
ones are unlimited.
docs/interactions/Slash_Commands.md
Outdated
- Limitations on [command names](#DOCS_INTERACTIONS_SLASH_COMMANDS/registering-a-command) | ||
- Limitations on [nesting subcommands and groups](#DOCS_INTERACTIONS_SLASH_COMMANDS/nested-subcommands-and-groups) | ||
- Rate limitation of 2 requests per 60 seconds for batch update |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the batch update for guilds keyed by guild ID? (Yes I know guild ID is a major parameter in this route, I just have to make sure though :')
- Rate limitation of 2 requests per 60 seconds for batch update | |
- Rate limit of 2 requests per 60 seconds for batch update |
Is there a reason rate limits are documented for slash commands specifically but nowhere else in the docs? |
@RedDaedalus just an oversight on our part. We'll be taking them out in line with the rest of the docs since they're returned in headers. Be nice to Ian he's new ;) |
Co-authored-by: EXPLOSION <git@helvetica.moe>
Co-authored-by: EXPLOSION <git@helvetica.moe>
References: discord/discord-api-docs#2667 - Update application command limits. - Add length assertion for `ApplicationCommandOptionChoice.value`. - Add `ApplicationCommandOptionChoice.__len__`. - Add `ApplicationCommandOption.__len__`. - Add `ApplicationCommand.__len__`. discord/discord-api-docs#2615 - Add `InteractionType`. - Add `InteractionEvent.type`. - Add `Message.interaction`. - Add `file` parameter to `Client.webhook_message_edit`. - Add `file` parameter to `Client.interaction_response_message_edit`. - Add `file` parameter to `Client.interaction_followup_message_edit`. discord/discord-api-docs#2690 - Add `InviteTargetType.EMBEDDED_APPLICATION`. - Add `Invite.target_application`. - Add `target_application` parameter to `Invite.precreate`. - Add `Client.application_invite_create`. discord/discord-api-docs#2692 - Add `ChannelVoice.region` attribute. - Add `region` parameter to `ChannelVoice.precreate`. - Add `region` parameter to `cr_pg_channel_object`. (Inherited by `Client.channel_create`.) - Add `region` parameter to `Client.channel_edit`. - Handle voice client disconnect when moving between voice channels of different regions. Public API: Coroutine generators yielded or returned from slash commands are handled as coroutine generator slash commands themselves. Add `SlashResponse` class. Update `slash.md`. Add `'number'` annotation to slash commands. Add `emoji.md` to topics. Add `Application.precreate`. Internal: Fix a broken docstring in `Color` (Reported by NeKun#9509). Add `URL.subdomain`. Add `URL.raw_subdomain`. Slash commands dropped back type based annotations. Redo slash command syncing to handle extensions correctly. `Application.__new__` could not set `.flags`. Update links in intro. Fix formatting issues in commands extension. `Extension._unload_extension` did not use executor when rendering exception traceback. Missing `ApplicationCommand.__ne__` caused errors (inheritance issues probably). Update `Guild.precreate.__doc__`. Remove unused `Guild.has_animated_icon` attribute (was removed like 1 year ago, lol). Add `region` parameter to `Guild.precreate`. Handle voice client player and reader stop when the guild's voice region changes. Do voice client reconnect for close code `1006`. `User.has_higher_role_than_at` could return `False` when the other other is not in the guild meanwhile self is.
No description provided.