twitch-cli icon indicating copy to clipboard operation
twitch-cli copied to clipboard

[Request] Support for OAuth implicit code flow

Open KS-HTK opened this issue 3 years ago • 0 comments

Would love to see support for OAuth implicit code flow, as described here

Had a bit difficulty getting it to work requiring a lot of requests to the actual api endpoint. It would be great if I could use the Mock-Api for this.

A request would look like this: (user visits this url) http://localhost:8080?redirect_uri=<redirect URI>&response_type=token&client_id=<client id>[&scope=<scope>]

A response would result in the user getting redirected to: <redirect URI>#access_token=<access token>&scope=<scope>&token_type=bearer

<> required [] optional

For the mock-api I do net think including the scope capability is a priority. Simply returning a access token for any user with full scope would be a great start.

P.S. I know, in production api request and redirect_uri should be https (because of access token in hash section of url)

KS-HTK avatar Feb 06 '22 22:02 KS-HTK