Include the bot's permissions in interactions #3310
Answered
by
ckohen
advaith1
asked this question in
API Feature Requests & Ideas
Replies: 2 comments
-
Additionally it would make sense to expand this to the resolved channels as well. Its all fine and gravy to check if a member has permission to do something in that channel, but it makes no difference if the bot can't do that too. Making the request to check immediately can work in some circumstances, but in many it won't. Example: logging channel
|
Beta Was this translation helpful? Give feedback.
0 replies
-
|
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
advaith1
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description
Interactions already compute and provide the invoking member's (and provided members') permission values. However, it doesn't include the bot's permissions (if the application has a bot in the server).
Why This is Needed
Bots are expected to check permissions and not try to make requests that will 403. While this is easy in situations where all roles and channels are cached (usually through gateway events), this is not really possible to do in a stateless environment where you are only receiving interactions via HTTP and not receiving gateway events.
Alternatives Considered
Beta Was this translation helpful? Give feedback.
All reactions