TABLE OF CONTENTS
Introduction
Guidelines to enable social media login option (Google and Facebook) in Znode webstore.
Steps for Google Login
- Create a developer’s account and start a new project.
- Go to developers.google.com and create a developer account.
- Go to console.developers.google.com and create a new project.
- Add hosted web store URL’s in the developer’s account.
- Open the project and click “Credentials” under “APIs and Services”
- Open the project and click “Credentials” under “APIs and Services”
- Click on “Create Credentials” and then “OAuth client ID” from the drop-down
- From the screen that follows, select “Web Application” and click “Create”.
- Open the client and copy“Client ID” and “Client secret” in a notepad. It will be needed during step 3
- In the client under “Authorized redirect URIs”, add the following two entries and click on“Save”:
- URL of your webstore followed by “/signin-google”.
- URL of your webstore followed by “/User/ExternalLoginCallback/”
- Add entries in the ‘ZnodePortalLoginProvider’ table with proper keys
Steps for Facebook Login
- Create a developer’s account and create a new app
- Go to developers.facebook.com and create a developer account.
- Go to “My Apps” and create a new app
- Add hosted web store URLs in the developer’s account
- Open the project and click “Credentials” under “API’s and Services”
- In the app, go to Settings -> Basic
- Copy “App ID” and “App Secret” in a notepad. It will be needed during step 3. Add the. URL of the webstore under App Domains
- Click on “Add Platform -> Website”, add the URL of the webstore under “Site URL” and click “Save Changes”
- Go to Products ->Facebook Login ->Settings
- Under “Client OAuth Settings>Valid OAuth Redirect URLs”, add the following two entries and click on “Save Changes”
- URL of your webstore
- URL of your web store followed by “/signin-facebook/”.
- Change the “Live” toggle to active.
- Add entries in the ‘ZnodePortalLoginProvider’ table with proper keys
Znode Logins
Username - [email protected]
Password - znode@1234
Important SQL queries for Znode:
select * from ZnodePortalLoginProvider
select * from ZnodeLoginProvider
select * from ZnodeDomain
insert into ZnodePortalLoginProvider (PortalId, LoginProviderId, ProviderKey, SecretKey, DomainId,
CreatedBy, CreatedDate, ModifiedBy, ModifiedDate) values (1, 2, KEY, PASSWORD, 17, 2, '2017-02-13
00:00:00.000', 2, '2017-02-13 00:00:00.000')