Reputation: 224
To get Auth code from github I follow below process:
Login page provided by github, and after logged in, it redirects to below site where the value of code changes it each time.
http://www.example.com/oauth_callback/?code=bf9beb5db17ea476fa46
I use value of '?code' query string as 'Auth Code'.
If there any way I could automate this process to get ?code value using application like curl? If it is possible, please give me some suggestion how to get this value.
Upvotes: 0
Views: 43
Reputation: 13458
If you want to do it once, just generate a token once here https://github.com/settings/tokens
If you need to make this interactive for users, this is the auth flow in a Java based Mac OSX client. You could copy this approach, it redirects to a local webserver on localhost.
If you have macs (or linux with manual installation), you could use the client above https://github.com/yschimke/oksocial/wiki/Github
Upvotes: 1