-
Notifications
You must be signed in to change notification settings - Fork 1
Create a google project at google console
Stefan Kientzler edited this page Apr 25, 2023
·
14 revisions
First step is to create and setup a new project on the google console at https://console.cloud.google.com/.
- Create a project with your prefered name
- Enable the Google People API
-
Create Credentials
- Credential Type
- Select API: People API
- Check the 'User data' option
- OAuth Consent Screen
- Enter App information an Developer contact information
- Scopes
- Type
contactsin the filter and then set check to
[x] .../auth/contacts
[x] .../auth/contacts.readonly
[x] .../auth/contacts.other.readonly.
- Type
- OAuth Client ID
- Select Application type: Web application
- Enter a name for your client (The name of your OAuth 2.0 client is only used to identify the client in the console and will not be shown to end users)
- Authorized redirect URIs
- For live system enter the URI to the script that receives an authentication code after login
- For local development and using the examplecode enter
http://localhost/<path-to-package>/GoogleOauth2Callback.php
- Your Credentials
Download the created credential information in JSON format. For later access, this is always available on the credentials page.For a 'quick start' of the example code, save the credentials in
secrets/google_secrets.jsonin the package directory
- Credential Type
-
Add Test user(s)
While developing/testing your app, you have to add the users that have access asd 'test user'. (Even the own account have to be added):- Join 'APIs & services -> OAuth consent screen' on the left in the google console
- scroll to the section 'Test users'
- add the users you want to have access to your web application (including your own account)
build with phpDocumentor 3 using template phpdoc2githubwiki / (2023-04-26)