Utilizing the implicit OAuth flow, the access token is provided upon redirection back to your application post confirmation of the permission page. However, GitHub does not endorse the implicit flow.
Hence, it is impossible to directly obtain an access_token
from GitHub upon browser redirection to your application. Instead, GitHub will furnish only a temporary code
.
To acquire the access_token
, you must initiate a POST-request to https://github.com/login/oauth/access_token with the aforementioned temporary code
. The presence of client secrecy is vital for the success of this request.
Given that sharing the client secret is prohibited, exposing it to your Angular application is not feasible. Therefore, the involvement of a server becomes necessary.