Authorization Access Token Redirect not working in any .NET Browser Control

Hi,

I am the developer of a little tool using the Twitch API and since a while my inbox explodes because of users all reporting the same error. I have a feeling it started when V5 was introduced.

I am using the WPF WebBrowser Control with the implicit flow for authorization to get the channels a user has subscribed to:

https://api.twitch.tv/kraken/oauth2/authorize
?response_type=token
&client_id=[my client-id]
&redirect_uri=[my redirect url]
&scope=user_subscriptions
&force_verify=true

In all desktop browsers I get the login screen and after clicking “Log In” I get redirected to the url containing the access token and my defined redirect url.

If I do the exact same thing in any Browser Control in my WPF application, after clicking “log In”, the browser control is stuck on “Sending…” and never redirects to anywhere anymore (not receiving the access token).

If I look at the HTTP traffic with Fiddler, I see the request going out, and response comes back with status code 200… and after that nothing happens anymore.

I have also tried different browser controls based on Chromium (Awesomnium.NET and CefSharp). Those won’t work either. Twitch have also included the http-equiv=“X-UA-Compatible” tag to tell the WPF browser control to use the Edge engine instead of the default IE7 engine.

The weird thing is, I have not touched the code since it worked for the first time and suddenly the authorization workflow fails everywhere (Windows Vista-10, 32 or 64 bit, does not matter). First I thought about a .NET update, but why would all other browser controls fail, too?

My tool has over 8000 downloads a month and I am really bothered right now because I do not have any clue, where else to look for a solution.

Any hints are greatly appreciated :slight_smile: Thanks!

Fake Smile Revolution

So I have found the problem and it seems to be a Twitch problem.

I rechecked my application’s client-id and the redirect url on Twitch and I found a new dropdown box “Application Category”. This dropdown box was not there when I initially registered my application. So it was empty, no entry selected.

I selected a proper entry (Application Integration) and suddenly me and all my users could authorize again… Weird stuff that Twitch developers might look into.

This was a bug related to the .includes function in JavaScript. It has since been fixed. Rest assured that your application category isn’t breaking your integration. :slight_smile:

thanks for the info. must have been a weird coincidence then. i literally pressed “update” in the application settings on Twitch and 30s later everything went smooth again :slight_smile:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.