I'm embedding a Power BI report in a web page, using the AppOwnsData sample as a base. Everything is working fine, using the Service Principal for authentication. However, now I'd like to pass through an "Effective Identity". When I initially try this, I get the error:
InvalidRequest: Creating embed token for accessing dataset xxx shouldn't have effective identity
When I'm generating the token request parameters, if I query the dataset (like this):
var dataset = await client.Datasets.GetDatasetByIdInGroupAsync(workspaceId, datasetId);
isEffectiveIdentityRequired = dataset.IsEffectiveIdentityRequired;
I get a false - i.e. Effective Identity is not required.
I, therefore, have a two part question:
- Is it possible to change this from the dataset configuration in PowerBI (or if not, how can this ever be true)?
- Am I correct in assuming that
dataset.IsEffectiveIdentityRequired == false
would cause this error if the effective identity were passed through (the wording implies that whilst it may not be required, it may still be provided).