Repository navigation
fix: explain the restricted_scopes error returned when installing an app - #708
Merged
Merged
Conversation
The apps.developerInstall method returns restricted_scopes when the installer can't grant a requested scope, such as admin and audit scopes or the Slack Connect bot scopes. Add a message and remediation so the error says what happened and how to resolve it.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #708 +/- ##
=======================================
Coverage 78.14% 78.15%
=======================================
Files 239 239
Lines 18125 18125
=======================================
+ Hits 14164 14165 +1
+ Misses 3961 3960 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Member
Author
|
Thanks for the review @zimeg 🙇🏻 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog
The
restricted_scopeserror now explains which kinds of scopes need an admin or owner to install, and how to resolve it.Summary
This pull request adds a message and remediation for the
restricted_scopesAPI error.apps.developerInstallreturnsrestricted_scopeswhen the installer can't grant a requested scope, such as admin and audit scopes.conversations.connect:manageandconversations.connect:writeto installers without the matching permission, matching the OAuth install flow.Preview
N/A
Testing
conversations.connect:managetooauth_config.scopes.botin an app manifest.slack installand confirm the error shows the new message and remediation.Notes
errorsdetails fromapps.developerInstall, so no further CLI change is needed for that.Requirements