Login only with Oauth

Hi all,

I have been working on a workflow and looking for a solution that I think I have come up with. Searching the forum I see there are several with similar scenarios so thought I would share.

We are creating an app that has a multiple sign up process that collects communication preferences, connects with stripe etc.

We also want user to be able to login ONLY using Oauth once they have completed the sign up process. As you know if a user clicks on Oauth and they are not signed in and don’t have an account, or have an account with a different email, then a new account will be created. This was a problem as it then bypassed the multi-sign up process (yes we could implement Oauth into our sign up process but didn’t want the extra work).

So we searched long and hard on a workaround that would only allow members who have already signed up to use Oauth (through the method of linking their created account with the social login of their choice).

The work around we came up with was this.

We created two fields under the user in the database- traditional sign up (yes/no) and linked with a specific social account (yes/no). By default both are set to no. When a user creates an account using the multi-sign up process the workflow changes that user’s traditional sign up field to yes. When a user then links their account to that specific social Oauth the field is changed to yes through the workflow.

In our app dashboard we created a full page group that is not visible on page load. This group has some instructions stating that either the person doesn’t have an account or their account is not linked to that specific social login. With button directing to create an account page or login page.

This group has a condition that is set for it to be visible if the current user’s traditional login is no AND their specific social login is connected is no.

When they click on the button to redirect to login or sign up a workflow triggers that does so and also deletes a data thing (current user).

Hope that makes sense and perhaps helps a few.

Glad to hear of other solutions and potential best practices around this.


1 Like

Interesting use case thanks for sharing! I’m curious about how User could possibly login in the following scenarios though:

  • if User logs out before going through the OAuth process
  • if User doesn’t want to create/login with a social account

If OAuth is the only way to login, wouldn’t it make more sense to only have OAuth to signup?

I’m not sure this is true btw, you could have a Signup completed field (yes/no, default = no). When this is no, User gets redirected to the first step of the multi-step signup process
Anyways it sounds like it would have taken less time to configure than what you described above :slight_smile: