Skip to content

API for determining Personal Access Token scopes? #24345

Answered by hwine
hwine asked this question in API and Webhooks
Discussion options

You must be logged in to vote

Got the answer from Ivan support:

If it hadn’t been revoked, you could have figured our which scopes it has by making any API call with that token (https://developer.github.com/v3/#authentication) and then looking at the X-OAuth-Scopes response header. That header tells you which scopes the token has.

I’ve spent so much time staring at JSON that I forgot about the HTTP headers. /o\

Thanks, Ivan!

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Answer selected
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants