Views:

There are two versions of Single Sign-on. One is when you connect your Azure Entra or Google Workspace to Webdashboard and use the same account to login to all your applications, including Webdashboard. The second is when you integrate Webdashboard inside your extranet. This article deals with the second option.

 

Embedding Webdashboard or just one report is done is just two steps:

  • Generate a security token
  • Add the security token to the embed link

 

It's important to note that you are responsible for the authentication and the authorization of the user. The flow would look something like this:

Step 1:

Navigates to de login page of your extranet.

 

Step 2:

With your auth provider you make sure the signin is safe (username/password/MFA etc)

 

Step 3:

Now the user is allowed to open the page where you embed Webdashboard or Report pages

 

Step 4:

In the background your call the Webdashboard DevAPI, specifically for this user. A token is returned that is valid for a short time period (minutes).

 

Step 5:

You embed Webdashboard or a report with this token in the url. 

 

Now the user willl automatically sign-in to Webdashboard and open the embedded report.

How to get the token (step 4): 

In Webdashboard open settings → Development. And navigate to the Single Sign-on tab.

Under actions enable SSO and copy the SSO Key. 
Optionally: Add Calling Ip for more security. If your SSO Key get stolen, this would make sure calls can only be made from your server. If left empty, we'll not check on IP's.

 

Now click the Documentation link:

Webdashboard Development API documentation

 

Here open the SetSSO endpoint.

You can try it out here, create a post with your portalid and secret you just created and the username (email) of the user you want to signin with. Click ‘Try it out’. 

It will return a ssoLoginToken.

How to Embed (step 5)

You can embed the entire webdashboard site in your extranet, or use a direct link to the report.
 

Report Embed link

This URL is found in the menu on the left.

The embed URL for a report looks something like this:
https://app.webdashboard.com/en/embed?workspaceId=x&reportId=x&portalId=x

 

Full Webdashboard embed link

To embed Webdashboard in your Intranet, all you need to do is adding embed-mode=true to the URL.

For example, if you want to start on the home page:

https://app.webdashboard.com/en/home?embed-mode=true

 

Now you have one of the two embed URLs add ssologintoken=[ssoLoginToken] to the URL

if your ssoLoginToken looks like this 0abe8b93-190c-4960-86e6-0c55d9f7f007

 

A report embed URL would look like this:

https://app.webdashboard.com/en/embed?workspaceId=x&reportId=x&portalId=x&ssologintoken=0abe8b93-190c-4960-86e6-0c55d9f7f007
 
A webdashboard embed URL would look like this:
 
This also works with custom domains if you want. 
 
You can find code examples how to implement this in multiple programming languages in Webdashboard:
Settings → Development and then open de Single Sign-On tab