Is there any way I can login to my github account via my username and password and generate personal access token using api ?
UPDATE: per this blog post, they've deprecated the OAuth Authorizations API, that support generating personal access tokens.
so now, you'll have to generate it using the web settings page instead.
Original answer:
Calls to OAuth Authorizations API
If you're making OAuth Authorization API calls to manage your OAuth app's authorizations or to create personal access or OAuth tokens like:
curl -u my_username:my_password -X POST "https://api.github.com/authorizations" -d '{"scopes":["public_repo"], "note":"my token", "client_id":"my_client_id", "client_secret":"my_client_secret"}'Then you must switch to the web application flow to generate access tokens.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With