Base solution for your next web application
Open Closed

Tenant Registration with Social Auth (Self Service Registration #9965


User avatar
0
turbofrank created

Hello,

We are developing an application on ASPNETZERO * , using Angular + .Net Core and struggling to get tenant registration working with Google Auth.

We would like to allow self-registration of our SAAS product, via Google Auth. Ideally when a user clicks Google Auth we would create the tenant if it didn't exist yet, and register that user. Unfortunately it seems that the framework only supports Google Auth for user signin/registration, not for tenant creation.

Has anyone successfully accomplished the above? Are we missing something?

Prerequisites Product Version: 9.0.1 Angular .NET Core ABP: 5.10.1


4 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi @turbofrank

    You are right, by default user registration is supported with external login providers. However, you can create a tenant here when external authentication succeeds if your app already knows the Tenancy Name.

    As an alternative,

    1. You can develop a new page and redirect user to that page when authentication succeeds.
    2. Ask user for tenant information on that page
    3. Create Tenant and set previously created user's TenantId to newly created Tenant's ID when user clicks the submit button on your custom Tenant Registration page.
  • User Avatar
    0
    turbofrank created

    That's what we are doing:

    We are creating the tenant and the user at the same time:

    This data is comming from the google auth.

    The problem is that the logInManager.LoginAsync() is not retriving the all the data after we had register with google and want to login with google:

    The login manager is only getting the Tenant, but no User nor Identity.

  • User Avatar
    0
    turbofrank created

    Bump.

    @ismcagdas, the link you provided is is a 404 not found. Any assistance on the issue we are facing above?

  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    Please add your GitHub user on https://aspnetzero.com/LicenseManagement so you can access the private link.