Forum Discussion
Unable to Configure Scheduled Refresh for a Power BI Report Using Dy365 Finance and Operations
- 2 months ago
amal_01
Power BI attempted to use the stored OAuth refresh token, but Azure AD rejected it.
Try these steps
Power BI Service
↓
Workspace
Semantic Model
Settings
Data source credentials
Edit CredentialsThen
- Authentication = OAuth2
- Privacy Level = Organizational
- Click Sign In
- Login using the same account that has access to D365 F&O.
Solution 2
If clicking Sign In gives the same error:
- Sign out of Microsoft completely.
Open an InPrivate/Incognito browser.
Login again.
- 2 months ago
Hi amal_01
You can edit the dataset credentials. Go to Workspace - Semantic model settings - Data source credentials. Choose Authentication method = OAuth2. Set Privacy level = Organizational. Check Skip test connection. Click Sign in and complete the authentication.
Re authenticate in Power BI Desktop by opening the report in Desktop. Re enter the credentials for D365. Refresh locally to confirm and republish to Power BI service. Check account permissions ensuring the account has access to D365 data.
Prevent future expiry by using a dedicated service account or service principal account. Keep scheduled refresh active so tokens don’t lapse
Hi amal_01,
You are hitting a two-part issue:
- Issue 1 as per screenshot: Your Microsoft browser login session timed out or got confused in the background while you were setting this up.
- Issue 2 - Timeout expired: When you hit "Sign in", Power BI tries to run a test query against your D365 vendor invoice entity. Because D365 OData feeds run live against the transactional database, hitting a large entity may cause system to hang and time out before saving.
You can try -
- Use an Incognito Window: Open a fresh private browsing tab and go straight to the Power BI Service. This clears out the stale authentication tokens causing the error
- Bypass the Connection Test:
- Go back to your semantic model settings and click Edit credentials.
- Choose OAuth2.
- Check the box that says "Skip test connection".
- Click Sign in and authenticate.
Checking that box forces Power BI to save your credentials instantly without forcing D365 to run a heavy validation query on the spot.
Let me know if this helps!
Also, does the report refresh successfully in Power BI Desktop, with the issue occurring only after publishing to the Service?