Auth0 Home Blog Docs

If you are using Auth0 Lock and trying to get a JWT token returned



I searched far and wide to find this solution and now trying to reduce the pain for others. I am using the latest version of Auth0 Lock, "auth0-lock": "^11.7.0". I was trying to figure out how to get back a JWT and not just the opaque string that is the accessToken. The answer is to update the config options for responseType to be responseType: 'token id_token'. Full options object I have.

const options = {
  container: "lock-container",
  allowSignUp: false,
  auth: {
    responseType: "token id_token",
    redirect: false,
    sso: true,
    params: {
      scope: "openid profile email",