I am trying to authenticate an application with the API.
Here\'s How:
webbrowser.open
.
After the user authenticates with stack exchange, the SE page will redirect back to your page ("redirect_uri" below). Your code currently redirects to https://stackexchange.com/oauth/login_success ; instead, you should redirect to a page you control.
source: https://api.stackexchange.com/docs/authentication