Hi
I am getting the below error
my domain is whitelisted under Domains and Embedding option
below is my front end code
<head>
<title>Dashboard Embedding Example</title>
<script type="text/javascript">
const embedDashboard = async () => {
const {
createEmbeddingContext,
} = QuickSightEmbedding;
const embbedURL = '@ViewBag.embeddUlr';
const embeddingContext = await createEmbeddingContext();
const containerDiv = document.getElementById("embedding-container");
const frameOptions = {
// replace the value below with the one generated via embedding API
url:embbedURL,
container: containerDiv,
height: "700px",
width: "1000px",
};
const contentOptions = {
locale: "en-US",
toolbarOptions: {
export: true,
undoRedo: true, // use this option to show or hide the undo and redo buttons
reset: true, // use this option to show or hide the reset button
},
attributionOptions: {
overlayContent: true,
},
};
const embeddedDashboard = await embeddingContext.embedDashboard(frameOptions, contentOptions);
};
</script>
</head>
<body onload="embedDashboard()">
<div id="embedding-container"></div>
</body>
below is my backend code
public string GenerateEmbedUrlForRegisteredUserAsync()
{
var quicksightClient = new AmazonQuickSightClient(
awsAccessKeyId,
awsSecretAccessKey,
RegionEndpoint.USEast1);
BookmarksConfigurations bookmarks = new BookmarksConfigurations { Enabled = true };
StatePersistenceConfigurations statePersistenceConfigurations = new StatePersistenceConfigurations { Enabled = true };
RegisteredUserDashboardFeatureConfigurations registeredUserDashboardFeatureConfigurations = new RegisteredUserDashboardFeatureConfigurations
{
Bookmarks = bookmarks,
StatePersistence = statePersistenceConfigurations,
};
RegisteredUserDashboardEmbeddingConfiguration registeredUserDashboardEmbeddingConfiguration
= new RegisteredUserDashboardEmbeddingConfiguration
{
InitialDashboardId = dashboardId,
FeatureConfigurations = registeredUserDashboardFeatureConfigurations
};
RegisteredUserEmbeddingExperienceConfiguration registeredUserEmbeddingExperienceConfiguration
= new RegisteredUserEmbeddingExperienceConfiguration
{
Dashboard = registeredUserDashboardEmbeddingConfiguration
};
string url = quicksightClient.GenerateEmbedUrlForRegisteredUserAsync(new GenerateEmbedUrlForRegisteredUserRequest
{
AwsAccountId = accountId,
ExperienceConfiguration = registeredUserEmbeddingExperienceConfiguration,
UserArn = usrARN,
SessionLifetimeInMinutes = 100
}).Result.EmbedUrl;
return url;
}
I followed multiple tutorial but nothing worked