How to get Google OAuth 2 API and Developer Keys?
- Monday, May 20, 2013 By Mahalakshmi Kabilan
Want to use Google Login in your website?! That is pretty simple as Google provides OAuth2 standard authorization. With only little effort and minimal coding you can use Google Authentication integrated to your website.
To use Google information to register or login users using Google PHP API library and MySQL, follow the simple steps below.
Get Authorized API Access
For this you may need to acquire client id, secret key and developer key from Google API console.
* Go to Google API console (you might have to sign-in if not already signed).
* Click ”API Access” on the left sidebar, click “Create an OAuth 2.0 Cliend ID“ button.
* A pop-up opens up. Here enter your Project details like name and Product logo (optional), HomePage URL and click next.
* Choose the application type. Eg. WebApplication for websites.
* On the next screen you will get Google Client ID and Client Secret.
* You can also get the JSON downloaded or edit previous settings here.
Get Google Developer Key
This is pretty simple!
* Click ”API Access” on the left sidebar, click “Create New Browser Key“ button and enter the URL here and click ok.
* Just go to “Services” from the left sidebar and click on any of the services listed there.
* You should now be asked to accept some Terms and services (2 steps). Just accept them and the service will be turned on.
* Go to the “API Access” page again and now you will get another key listed below called Simple API Access and this is your developer key!
* Note that the key you have created if for the browser keys and you can also create Server, browser, iOS and Android keys too!