Featurebase AssistantBeta

Hey user! 👋 Feel free to ask me anything about Featurebase. I'm here to help!

Single Sign-On

If your users already have an account in your app, you can use Single Sign-On (SSO) to let them log into Featurebase with it.

This process involves setting up a dedicated page on your website to handle SSO authentication, creating and managing JWT tokens, and finally authenticating your users with Featurebase.

Example feedback board with 'Log in with APP NAME' in the top right.

Steps to Integrate SSO with Featurebase

Here's a summary of the authentication flow:

  • Your user wishes to authenticate and clicks on the Login with YourCompany account button on your feedback board.
  • We redirect them to your websites custom login page and append the return_to parameter to the URL.
    https://yourwebsite.com/sso/featurebase?return_to=https://yourorg.featurebase.app/roadmap
  • Your authentication system logs the user in to your website and creates a JWT token.
  • You return the user back to Featurebase with the generated token and the original return_to parameter passed along.
    https://yourorg.featurebase.app/api/v1/auth/access/jwt?jwt=payload&return_to=https://yourorg.featurebase.app/roadmap
  • Featurebase logs the user in and automatically returns them back to where they started the auhtentication process.

1. Set up a dedicated SSO page

Set up a page on your website that will authenticate the user on your end (e.g https://yourdomain.com/sso/featurebase)

Next, navigate to your Featurebase Dashboard → Settings → SSO, and enter the URL of the page you created in the SSO URL field. This is where Featurebase will redirect users who wish to log in through your app's account.

2. User authentication and JWT token creation

When a user arrives on your SSO page, authenticate them using your app's authentication system and create a JWT Token for them using the next step in this guide. 👇

3. Creating the JWT token on your server

  • Log in to see your private key: xxxxxx

    Store it on your server and make sure not to share it with anyone!
  • On your server, generate a JWT token with your customer data using the example below.

Install required packages

Example

Generate the JWT token

Example

Validate your JWT Token

Paste one of your generated tokens here to check if you did everything correctly.

You must be logged in to check if your token is valid.

For safety, Single Sign-On tokens can't log in users who are admins of any Featurebase organization. These users will have to sign in by themselves.

4. Return the user back to Featurebase.

Redirect the user to the Featurebase JWT endpoint with the JWT and return_to URL.
https://yourorg.featurebase.app/api/v1/auth/access/jwt?jwt=payload&return_to=https://yourorg.featurebase.app/roadmap