We use Quicksight with an embed on our React page. Users log on to our enviroment and are able to use QS dashboarding here. We do work with RLS in our datasets.
I am trying to achieve dynamic parameter defaults however I do not seem to get user information when users log on to our React page. I am trying to figure out what is necessary to get the information back to QS so I can build a dataset with usernames and their default values. These users do not have a QS login so I can’t get this information from my ‘Manage Quicksight’.
Can anyone guide me to the necessary steps so I can explain this to my development team?
Also, is there any other documentation next to this YT vid I found?
To implement dynamic parameter defaults in embedded Quick Sight dashboards, you need to pass user information via the embedding process using the generateEmbedUrlForAnonymousUser or generateEmbedUrlForRegisteredUser API with namespace parameters [1]. For users without Quick Sight logins, you’ll need to leverage the embedding context and pass user attributes through the embedding API call.
When embedding Quick Sight dashboards in a React application, the core challenge is passing user context from your application to Quick Sight, especially when users don’t have direct Quick Sight logins. This is critical for implementing dynamic parameter defaults and row-level security (RLS).
The key to solving this issue is to pass user information during the embedding process:
For anonymous users (users without Quick Sight accounts):
This approach uses the generateEmbedUrlForAnonymousUser API with the Identities parameter to pass user context
You’ll need to set up a dataset that maps usernames to their default parameter values
Create a mapping table in your data source with columns for:
Username
Default parameter values
Any RLS constraints
Configure your Quick Sight dataset with RLS using this mapping table, referencing the username passed during embedding.
Implement Parameter Defaults Based on User Context
Use calculated fields in your Quick Sight analysis that reference the user information passed during embedding
Hi @NJK90,
Since we have not heard back, I’ll go ahead and close out this topic. However, if you have any additional questions, feel free to create a new post in the community and link this topic for relevant information if needed.