I am trying to build a simple kivy app for mobiles / desktops which uses Twitter to authenticate users at the login screen. I am using Tweepy with Python to authenticate the users.
The authentication process works fine when I run the code from command line.  It generates a redirect url which I open in a browser to authenticate the user and then it generates a pin. The pin is copied and entered into the command line interface of the parent Python program as an input and the authentication process completes successfully.
Is there a way to copy the generated pin from the browser's html content and directly use it as an input in the program without any human intervention? This would enhance the user experience and people would not get confused as to what to do with the PIN. I was playing around with the weburl, urllib and htmlparser libraries in Python and was wondering if there any way to achieve this behaviour?
Please help.
You need to create an intermediate web app which runs on a server with a static ip address. The authentication code / PIN should be returned by Twitter to this intermediate app, which in turn can exchange it with your mobile/desktop app.
How to achieve authentication with Twitter in Kivy App without manual intervention