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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
RajCZ
Frequent Visitor

PowerBIResAPI: Dataset failing with Invalid credential : (Mez file, M code, Gateway connection)

I have two Semantic models(connecting with PowerBIRESP API via MEZ file) , Connector(MEZ file) is setup on Gateway server..

one needs admin permission on PowerBI API and another doesn't need. both are setup 100% same way, only difference is one pulling Power BI metadata that needs admin permission.

while refreshing, "admin" one failing with "Invalid Credential"

 

Connector(MEZ file) is setup on Gateway server.

Now different credentials are here

  1. Service principal and client secret are saved inside connector to be used by M Code.
  2. We have added credentials on Power Bi Gateway connection while creating a gateway connection that is used by Semantic model to use gateway.
  3. User’s credentials who manually logged to Power bi and hit model refresh button.

IF Model returns “Invalid credentials", then what credentials are invalid. What is role of each credential.

What credentials are actually being sed to pull Power bi metadata.

1 ACCEPTED SOLUTION
tharunkumarRTK
Super User
Super User

@RajCZ 

Considering you have service principal id and secret hardcoded in the M code of .MeZ file, you dont need to enter any other credentails while configuring the gateway connection. You can use anonymous authentication.

 

Power BI user credentials and the service account used for gateway installation has nothing to do with the data refresh failure due to invalid credentails. 

 

Need a Power BI Consultation? Hire me on Upwork

 

 

 

Connect on LinkedIn

 

 

 








Did I answer your question? Mark my post as a solution!
If I helped you, click on the Thumbs Up to give Kudos.

Proud to be a Super User!


PBI_SuperUser_Rank@2x.png

View solution in original post

2 REPLIES 2
tharunkumarRTK
Super User
Super User

@RajCZ 

Considering you have service principal id and secret hardcoded in the M code of .MeZ file, you dont need to enter any other credentails while configuring the gateway connection. You can use anonymous authentication.

 

Power BI user credentials and the service account used for gateway installation has nothing to do with the data refresh failure due to invalid credentails. 

 

Need a Power BI Consultation? Hire me on Upwork

 

 

 

Connect on LinkedIn

 

 

 








Did I answer your question? Mark my post as a solution!
If I helped you, click on the Thumbs Up to give Kudos.

Proud to be a Super User!


PBI_SuperUser_Rank@2x.png
RajCZ
Frequent Visitor

4th credential is userid/service id logged on Power bi Gateway.

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

Find out what's new and trending in the Fabric Community.

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.