Welcome!
Account linking demo
We demonstrate two user flows in this demo site: OAuth account linking flow and Post-login save subscription flow using OAuth auth code flow.
- OAuth account linking (This will open SwG Console DevTools)
- Post-login save subscription
Note: for this demo, you'll need to be added as SwG Developer role in GCP project: 'swgtest-342109' in order to access SwG Console DevTools.
Remix instruction
If you want to try it using your own publication ID, make a copy of this demo and configure it with your own parameters.
- Click 'Remix on Glitch' and make note of the new domain_name created (e.g. https://bloody-awesome-project.glitch.me)
- From your GCP project, add domain_name created in (1) to the Authorized Javascript Origins of your OAuth Client. This OAuth Client must be the one you configured for your SwG publication.
- In the same page with (2), add domain_name/auth to the Authorized redirect URIs of your OAuth Client. (e.g. https://bloody-awesome-project.glitch.me/auth)
- Update the following constant values in server.js: _PUBLICATION_ID, _GCP_PROJECT_ID, _GAL_CLIENT_ID.