Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowTry your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now
Hello,
I regularly receive the following error in one of our Power BI models that is connected to Databricks:
Data source error: {"error":{"code":"DMTS_OAuthTokenRefreshFailedError","pbi.error":{"code":"DMTS_OAuthTokenRefreshFailedError","details":[{"code":"DM_ErrorDetailNameCode_UnderlyingErrorMessage","detail":{"type":1,"value":"[DataSource.Error] Web.Contents failed to get contents from [cluster name here] (400): Bad Request"}}],"exceptionCulprit":1}}
The engineer supporting the environment has advised that everything appears to be working correctly, and that the only occasional issues relate to column errors.
However, the issue persists and occurs almost daily. Manually selecting “Edit Credentials” in the dataset settings temporarily resolves the refresh issue, but only until the next occurrence.
Would anyone have any ideas on what could be causing this, or what areas would be worth investigating further?
Thank you.
Solved! Go to Solution.
Hi @koralka,
Thanks for reaching fabric community, will happy to assist.
This looks related to the stored OAuth credential/token used by Power BI Service for the Databricks source. Edit credentials will fix this issue temporarily.
Can you answer the questions below?
Service principal authentication for Power BI and Databricks:
https://learn.microsoft.com/en-us/azure/databricks/partners/bi/power-bi-m2m
Power BI refresh troubleshooting steps:
https://learn.microsoft.com/power-bi/connect-data/refresh-troubleshooting-refresh-scenarios
PLease consider this as an accepted solution if it helps or give it some kudos.
Thanks,
Here I am attaching some microsoft documentations, you can have a look to get the information. Can you allowed to update the connection to use service principal instead OAuth?
https://learn.microsoft.com/en-us/entra/identity/monitoring-health/how-to-view-applied-conditional-a...
https://learn.microsoft.com/en-us/entra/identity/conditional-access/troubleshoot-conditional-access
https://learn.microsoft.com/en-us/entra/identity-platform/configurable-token-lifetimes
Note: I used AI only to help paraphrase this response.
Hi @koralka,
Thanks for reaching fabric community, will happy to assist.
This looks related to the stored OAuth credential/token used by Power BI Service for the Databricks source. Edit credentials will fix this issue temporarily.
Can you answer the questions below?
Service principal authentication for Power BI and Databricks:
https://learn.microsoft.com/en-us/azure/databricks/partners/bi/power-bi-m2m
Power BI refresh troubleshooting steps:
https://learn.microsoft.com/power-bi/connect-data/refresh-troubleshooting-refresh-scenarios
PLease consider this as an accepted solution if it helps or give it some kudos.
Thanks,
Hi @Lodha_Jaydeep
Thank you for your answer!
To answer some questions:
- The connection uses personal user OAuth login
- Conditional Access, MFA/session policies, or token lifetime policies changed - where would I check that
- The Databricks SQL warehouse should be available during refresh
- All queries use the same HTTP path
I'd appreciate some further insight.
Thank you
Here I am attaching some microsoft documentations, you can have a look to get the information. Can you allowed to update the connection to use service principal instead OAuth?
https://learn.microsoft.com/en-us/entra/identity/monitoring-health/how-to-view-applied-conditional-a...
https://learn.microsoft.com/en-us/entra/identity/conditional-access/troubleshoot-conditional-access
https://learn.microsoft.com/en-us/entra/identity-platform/configurable-token-lifetimes
Note: I used AI only to help paraphrase this response.
Hello,
Thank you for those, I will have a look. In terms of changing to service principal - how would I do that? Would I need to create a new connection under 'Manage Connections and Gateways'?
I'm not sure how that works. When I go to Settings -> Data Source Credentials -> Edit Credentials, I only have the following options as Authentication methods: OAuth2, Key, Basic.
Thank you for your help
Hi @koralka,
Your answer is in my 1st post. Please go through the documenataion for the service princiapal authentication.
Hi @koralka ,
Thank you for reaching out to the Microsoft Community Forum. could you please try the proposed solution shared by @Lodha_Jaydeep ? Let us know if you’re still facing the same issue we’ll be happy to assist you further.
Regards,
Dinesh
Hi @koralka ,
We haven’t heard from you on the last response and was just checking back to see if you have a resolution yet. And, if you have any further query do let us know.
Regards,
Dinesh
Hello, yes, apologies. The first response should be now accepted as a solution.
Regards
Karolina
Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.
Check out the May 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 16 | |
| 12 | |
| 11 | |
| 8 | |
| 7 |
| User | Count |
|---|---|
| 35 | |
| 33 | |
| 32 | |
| 29 | |
| 20 |