Skip to content

TrailheadDX '21: Demystifying OAuth Flows in Salesforce

Notifications You must be signed in to change notification settings

2sundhar/et-tdx21-oauth

 
 

Repository files navigation

TrailheaDX '21 - OAuth flows

How to select Salesforce oAuth flow?

This repo is part of a session I did on Trailhead DX '21 named "Demystifying OAuth Flows in Salesforce".

There is also a direct link to the second recording here.

Setup demo

  • Open both folders
code Heroku
code Salesforce
  • Create scratch org
    • Copy values (UN, PW, instanceUrl) from [sfdx force:user:display --json] to Heroku's .env file
    • Remove the last "/" from the URL
  • Manually update ORG
    • Org > Setup > Security CORS > Check [Enable CORS for OAuth endpoints]
  • Open Connected App
    • Org > Setup > App Manager > View TDX21_IandAM
    • Copy [Consumer Key] and [Consumer Secret]
    • Check [Enable for Device Flow]
  • Open Heroku App and edit .env file
    • Update values
  • Build Webserver project using lwc-services build -m development
  • Run server node ./src/server/_WEB.js
  • Open https://localhost:4001
    • DO NOT USE 127.0.0.1

About

TrailheadDX '21: Demystifying OAuth Flows in Salesforce

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 70.6%
  • Shell 18.3%
  • HTML 10.0%
  • EJS 0.6%
  • CSS 0.3%
  • Apex 0.2%