Forum Discussion
Issues Embedding Report in Salesforce
Hi Anonymous,
Regarding to issue A:
1. The client info, like client id and client secret, is surely stable. So you can hard-code them. Did you get error message that the client info is invalid?
2. Did you upload all the things in the guide post?
Regarding to issue B:
Can you provide more info? Or I would suggest you open a support ticket here.
Best Regards,
Dale
Background information: The report is located in a Premium capacity workspace and the hope is to distribute the report to the Sales team without needing to grant licenses.
Some additional information about the steps I took:
- Register App with Azure AD using onboarding tool: https://app.powerbi.com/embedsetup/userownsdata (This step wasn’t done as the service account, not sure of the implications of that)
- Grant permissions in AAD as Service Account (master account, admin of workspace)
- Create Salesforce Custom Setting OAuthApp_pbi
- Populate Custom Setting for PowerBI with AAD endpoints along with client id/secret
- Create OAuthController and PowerBIController Apex Classes with code from: https://github.com/Microsoft/BusinessPlatformApps/tree/dev/Samples/Salesforce/EmbedPowerBIReport
- Add Azure AD to Salesforce’s Remote Site Settings
- Create Visualforce Page with code from GitHub repo linked above
- Add Report ID to Visualforce page code
- Navigate to Visualforce page located at: OurSalesforceInstance.com/apex/PowerBI
- In pop up window, log in as the Service Account
Once all of these steps have been completed the iframe renders within Salesforce, but displays "This content is not available". Based on this blog post ( https://www.linkedin.com/pulse/success-power-bi-embedded-salesforce-fred-kaffenberger/ ) my next debugging step would be to use Fiddler to inspect the requests/replies. I'll work on that, but hopefully this additional information might point out where I went wrong.
Let me know if you have any ideas.
Thanks!