Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Level up your Power BI skills this month - build one visual each week and tell better stories with data! Get started

Reply
JibinSebastian
Helper III
Helper III

Semantic Model Refresh using Service principal issue

We are trying to set up a service principal for semantic model refresh. We have created the service principal ID, a security group, and added the service principal to all the required workspaces.

However, when we try to create a new connection for the semantic model to the Gold Fabric Warehouse using the service principal, we encounter the following error:

“Unable to create connection for the following reason: It looks like the refresh token expired. Please go to this dataset’s settings page and re-enter the credentials for the data source.”

Are we missing something in the setup?

Specifically, what value should be provided in the Service Principal ID field?

Could someone help me understand the correct way to configure this? I am new to Fabric and currently managing Fabric on my own in the organization. We do have a tenant admin who has already created the service principal.

JibinSebastian_0-1768407054142.png

 



1 ACCEPTED SOLUTION

Thanks @Zanqueta  I changed the Service principal id as Client ID and i made sure 

  1. Confirm the Service principal ID is the Application (client) ID.
  2. Generate a Client Secret in Azure AD:
    • Go to App registrations → Your App → Certificates & Secrets → New client secret.
    • Copy the value and enter it in the Service principal key field.
  3. Ensure permissions:
    • Add Power BI Service API permissions (e.g., Tenant.ReadWrite.All) and grant Admin consent.
  4. In Fabric:
    • Enable service principals in tenant settings.
    • Add the service principal to the workspace with Admin or Member rights.

      still the same issue persists

View solution in original post

4 REPLIES 4
Zanqueta
Super User
Super User

Hi @JibinSebastian,

 

Service principal ID is the Application (client) ID, and the Service principal key is the Client Secret. Without these, authentication fails and triggers the error.

 

The error occurs because the service principal credentials are incomplete or misconfigured. In the New Connection form:
  • Tenant ID: This should be your organisation’s Azure AD directory ID.
  • Service principal ID: This must be the Application (client) ID of the registered app in Azure AD (not the Object ID).
  • Service principal key: This is the Client Secret generated for the app in Azure AD.
The message about the refresh token usually means:
  • The client secret is missing or incorrect.
  • The service principal does not have the required permissions.
  • Admin consent for API permissions has not been granted.

Steps to Fix

  1. Confirm the Service principal ID is the Application (client) ID.
  2. Generate a Client Secret in Azure AD:
    • Go to App registrations → Your App → Certificates & Secrets → New client secret.
    • Copy the value and enter it in the Service principal key field.
  3. Ensure permissions:
    • Add Power BI Service API permissions (e.g., Tenant.ReadWrite.All) and grant Admin consent.
  4. In Fabric:
    • Enable service principals in tenant settings.
    • Add the service principal to the workspace with Admin or Member rights.

Official Documentation

https://learn.microsoft.com/en-us/fabric/security/service-principal

 

If this response was helpful in any way, I’d gladly accept a 👍much like the joy of seeing a DAX measure work first time without needing another FILTER.

Please mark it as the correct solution. It helps other community members find their way faster (and saves them from another endless loop 🌀.

If this response was helpful in any way, I’d gladly accept a kudo.
Please mark it as the correct solution. It helps other community members find their way faster.
Connect with me on LinkedIn

Thanks @Zanqueta  I changed the Service principal id as Client ID and i made sure 

  1. Confirm the Service principal ID is the Application (client) ID.
  2. Generate a Client Secret in Azure AD:
    • Go to App registrations → Your App → Certificates & Secrets → New client secret.
    • Copy the value and enter it in the Service principal key field.
  3. Ensure permissions:
    • Add Power BI Service API permissions (e.g., Tenant.ReadWrite.All) and grant Admin consent.
  4. In Fabric:
    • Enable service principals in tenant settings.
    • Add the service principal to the workspace with Admin or Member rights.

      still the same issue persists
JibinSebastian
Helper III
Helper III

@azruld  I saw that semantic model issue happend to you. Could you please help me to setup the serivce principal and semantic model refresh

After providing the client id it worked thank you so much @Zanqueta 

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

Fabric SQL PBI Data Days

Data Days 2026 coming soon!

Sign up to receive a private message when registration opens and key events begin.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.