DEV Community

Discussion on: 🔑 Google OAuth, Wordpress & YouTube Service API

Collapse
 
icolumbro profile image
Ivan Columbro

Hi, I'm developing a plugin that inserts contacts into a custom table of the WordPress database (name, phone number, email). It is possible to enter data in this table either manually, through a form, or by importing it from WordPress users. I have also developed a feature to import contacts from Google Contacts (Google People). Everything works but I ask you: when I will provide the plugin to my customers how can I do to avoid also providing the client_secret.json file with my credentials for accessing the Google API via OAuth2 together with the plugin? Furthermore, in order to function correctly, I must also authorize the URI redirect in the Google console but I cannot know in advance the URL of the various sites where the plugin will be installed, is it possible to automate (perhaps always through the Google API) this insertion?