Console embedding URL generation shows caching behavior

I have the following workflow:
The request for console embedding URL is sent from my client to API gateway which relays the request to the Lambda function. The lambda function uses the information in the request to make a describe-user API call to retrieve user metadata in Quick Sight. In the case when the user is registered with a “READER” role and the arrived request says that the role of the user should now be an “AUTHOR” role, the lambda function makes an update-user API call to update the user with the new role. Then the Lambda function proceeds with generating the console embedding URL with the user ARN retrieved from the user-update response object. I can see in Quick Sight manage users that the user is promoted from “READER” to “AUTHOR” by lambda function. However, the console embedding URL still opens the console with “READER” view and is not updated according to the most recent role of the user which is “AUTHOR”.
Does Quick Sight cache the embedding URLs to avoid unnecessary API calls ?!
If yes, how can I gain some visibility into this behavior ?!
If not, anyone knows where this issue is coming from ?!
Thanks.

Hello @HatAbd9241 !

Have you checked this out? > Customizing access to the Amazon QuickSight console - Amazon QuickSight

Hello @WLS-D,

Thank you for your answer and sorry for the late reply. Just came back from vacation.

The reason for the issue I was encountering was due to the fact that Quicksight tracks the Reader sessions based on user ARN and keeps them active for 30 minutes by default and when the user is promoted to an Author while he/she still has an active Reader session, since the user ARN never changes, Quick Sight generates an embedding URL which points to the active session of the user therefore console still opening up on Reader view.

Thank you.

@HatAbd9241 no problem at all! Thank you for posting the solution to help with the community!