Skip to main content

Notifications

Community site session details

Community site session details

Session Id : JE9+qkqnzj/C62IPN+dT3C
Power Automate - General Discussion
Answered

Power automate flow failing on approval with 401 error code

Like (0) ShareShare
ReportReport
Posted on 28 Jan 2021 02:37:18 by 45

Hi all,

I've created and tested a multiple approval flow which works when I test it. Basically how it works is that for a selected item --> send approval 1 --> send email to approver 1 --> send approver 2 --->send email approver 2-->send approver 3 -->send email approver 3. However when it is production I get failures at different approval stages with a 401 error code.

 

Here is the overall flow that I have created:

1st level approval1st level approval2nd level approval2nd level approval3rd level approval3rd level approval4th level approval with failure4th level approval with failure

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

this is the error code description: 

Error from token exchange: Runtime call was blocked because connection has error status: Enabled| Error, and office365 is in the block list. Connection errors: [ParameterName: token, Error: Code: Unauthorized, Message: 'Failed to refresh access token for service: aadcertificate. Correlation Id=09a7d3da-4820-44b4-b8ec-4e223f85ce98, UTC TimeStamp=1/27/2021 1:03:18 AM, Error: Failed to acquire token from AAD: An internal error occurred.
']

 

I'll get this error code on different sections of the flow on different runs..

 

At first I thought it was to do with some timout but then I checked that flows can run for 30 days which is well within my bounds for these cases.

 

can anyone show some insight on this?

  • shaikhii Profile Picture
    4 on 14 Mar 2024 at 12:38:52
    Re: Power automate flow failing on approval with 401 error code

    While connecting to SharePoint, attached screenshot occur

  • Verified answer
    manuelstgomes Profile Picture
    6,625 on 30 Jan 2021 at 11:13:15
    Re: Power automate flow failing on approval with 401 error code

    Hi @ctw1991 

     

    Please see @pcmccull 's post. With that information, that may be a known issue.

     

    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.

    Cheers
    Manuel

  • Verified answer
    pcmccull Profile Picture
    87 on 29 Jan 2021 at 23:50:13
    Re: Power automate flow failing on approval with 401 error code

    This seems to be a new issue with Power Automate and not the typical Connection needs to be reconnected issue:

    https://powerusers.microsoft.com/t5/I-Found-A-Bug/Failed-to-refresh-access-token-for-service/td-p/809553

     

    The flows will run correctly many times and then a random action on a random run will fail with this error. Then the next run will be fine. 

     

     

  • manuelstgomes Profile Picture
    6,625 on 28 Jan 2021 at 08:59:59
    Re: Power automate flow failing on approval with 401 error code

    Hi @ctw1991 

     

    Indeed it doesn't make sense, but it's the only thing that can explain why you're getting these types of issues. 

     

    Connections are fragile in a sense and sometimes get screwed up. It's annoying, I know.

     

    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.

    Cheers
    Manuel

  • ctw1991 Profile Picture
    45 on 28 Jan 2021 at 08:38:42
    Re: Power automate flow failing on approval with 401 error code

    Hi,

    Thanks for replying. However The flow is running in other parts with the same connection (send email) without any issue. So I dont see why I would need to reconnect? 

    Please advise

  • manuelstgomes Profile Picture
    6,625 on 28 Jan 2021 at 08:05:40
    Re: Power automate flow failing on approval with 401 error code

    HI @ctw1991 

     

    This is an issue with the connection. Sometimes connections get broken due to changes in permissions, for example, so you need to refresh it.

    Screenshot_2021-01-28_at_08_01_51.jpg

     

    Please check if the connection has some warning and if not, try adding a new one just for this case for testing.

    If it works, please go back to your "Data>Connections" tab and check if you can re-connect or need to create a new one.

     

    Can you please check if and let me know if you have any questions?

     

    If I have answered your question, please mark your post as Solved.
    If you like my response, please give it a Thumbs Up.

    Cheers
    Manuel

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

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,645 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 65,997 Most Valuable Professional

Leaderboard