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
Anonymous
Not applicable

Oauth2 scope required for SharePoint lists?

Hello,

 

We have a datasource that is of type "SharePointList".

 

According to the documentation https://learn.microsoft.com/en-us/rest/api/power-bi/gateways/update-datasource, we are updating the OAuth2 credentials with an access token. However we always get a 400 error code. We also do this with an Azure SQL datasource and this work fine for that datasource type.

 

The documentation says "Set the OAuth 2.0 token audience correctly, according to the data source type.".

 

Can you specify which scope is required by the datasource type "SharePointList" so we can retrieve an appropriate access token that can be used to connect?

 

We tried:

 

Thank you!

3 REPLIES 3
Anonymous
Not applicable

Hello @Anonymous,

 

Can you check with your teams what is the scope required for getting an access token that we can set in the OAuth2 credentials for the SharePointList type datasource type ? Graph ? Others ?

 

Thank you!

Anonymous
Not applicable

Hi @Anonymous ,

 

As far as I know, if your data source is SharePoint, I think you can select connection type as SharePoint directly when you configure data source for gateway in Power BI Service.

vrzhoumsft_1-1691048496274.png

 

Best Regards,
Rico Zhou

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

Anonymous
Not applicable

Hello,

 

Thank you for your answer, but actually this was not my question as I was speaking about SharePoint Online (not on-premises) and using the APIs.

 

What is the scope required for getting an access token that we can set in the OAuth2 credentials of the SharePointList type datasource type ? Graph ? Others ?

 

Thank you.

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.