Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Power Automate - Using Connectors
Answered

SharePoint List Item Flow giving an Unauthorised access error

(0) ShareShare
ReportReport
Posted on by 95

I have created a flow for some users to select an item on a Sharepoint list of people and get a list of assets assigned to those people on a different sharepoint site.  The whole point of the script is that I don't have to give them access to the other sharepoint site but can still return information to them.

 

However the Get Items function is failing with the below error:

 

{"odata.error":{"code":"-2147024891, System.UnauthorizedAccessException","message":{"lang":"en-US","value":"Attempted to perform an unauthorized operation."}}}

 

According to the script run it using my powerautomate account to run the Get Item function (that account does have access to the other sharepoint site) and not the account of the user who called the flow in SharePoint (who doesn't have access).

 

If I give the user access to the sharepoint site the error doesn't occur but I don't want to give them access.  The whole point is that I can control what information they can access with Power Automate.  Any help or feedback would be greatly appreciated.

  • eilishourigan Profile Picture
    95 on at
    Re: SharePoint List Item Flow giving an Unauthorised access error

    I found it - it's the Run Only Users section on the Flow Details (landing) page.  I edited there, added my user who I want access and changed the connections to the accounts I wanted used, re tested and it works!!  Using PA for nearly two years now on a daily basis and I never knew that was there!  Thank you so much Scott!!!

  • eilishourigan Profile Picture
    95 on at
    Re: SharePoint List Item Flow giving an Unauthorised access error

    Thanks Scott,  where is the Trigger's Details page?

  • Verified answer
    ScottShearer Profile Picture
    25,228 Most Valuable Professional on at
    Re: SharePoint List Item Flow giving an Unauthorised access error

    @eilishourigan 

    Go to the triggers details page and edit the Run only users.

    How is it configured - is it configured to have the users credentials passed through?  If so, select your connection instead.

    image.png

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Michael Gernaey – Community Spotlight

We are honored to recognize Michael Gernaey as our June 2025 Community…

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 566 Super User 2025 Season 1

#2
David_MA Profile Picture

David_MA 516 Super User 2025 Season 1

#3
stampcoin Profile Picture

stampcoin 492

Featured topics