Skip to content
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

OAuth scopes other than read, write, and follow do not work #1098

Open
myConsciousness opened this issue Dec 5, 2022 · 1 comment
Open

Comments

@myConsciousness
Copy link

myConsciousness commented Dec 5, 2022

Hi amazing developers,

I'm trying OAuth 2.0 on mastodon, but if I use any scope other than read, write, follow, it's rejected during authentication.

For example, if I send a request with the following scope:

  • read:accounts

Then I get an error message that requested scope is invalid.

スクリーンショット 2022-12-05 15 34 35

I checked it works only with read, write, follow.

スクリーンショット 2022-12-05 15 40 55

Are there special procedures required to use these less granular scopes?

@coderbarns
Copy link

Hi! For anyone facing this problem in the future, you need to specify the exact scopes you want available for your OAuth app during registration:

POST /api/v1/apps HTTP/1.1
scope='read write follow read:accounts'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants