web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Error in standard appr...
Power Automate
Answered

Error in standard approval workflow

(0) ShareShare
ReportReport
Posted on by 28
Hello,
I have created one of the "out of the box" document approval workflows for SharePoint. The workflow is joined to a specific library, and a user can initiate the workflow manually on a document. Apart from configuring the location for the flow (Sharepoint site and library), I have altered nothing in the workflow. 
 
But when running, the flow gives an error when the email detailing the completion of the workflow (approved or rejected, or in Dutch "goedgekeurd/afgewezen") is to be sent. I continually get this error: "Action 'Item_approved' failed: The 'inputs.parameters' of workflow operation 'Item_approved' of type 'OpenApiConnection' is not valid. Error details: Input parameter 'emailMessage/To' is required to be of type 'String/email'. The runtime value '"cnVzcy5oZXJhbGRAbW4ubmw="' to be converted doesn't have the expected format 'string/email'."
 
Searching various proposals in this forum haven't helped me yet, except to see that the same kind of error occurs in various kinds of workflows. I am something of a neophyte in this, I admit, and so don't always understand the logic of various segments in the flows themselves (yet).
 
Below are some screen shots of the workflow, the initialization variables, and the error itself. Any help would be greatly appreciated.
 
Categories:
I have the same question (0)
  • Verified answer
    Expiscornovus Profile Picture
    33,784 Most Valuable Professional on at
    That is the encoded version of the email address value (x-ms-user-email-encoded). Try using the x-ms-user-email one instead.
     
    Try the below expression to retrieve that specific property.
    triggerOutputs()?['headers']?['x-ms-user-email']
     
     



    Happy to help out 😁

    I share more #PowerAutomate and #SharePointOnline content on my Blog, Bluesky profile or Youtube Channel
  • RussH Profile Picture
    28 on at
    Yes, that did it! I took the expression you gave and added it as an expression. Works perfectly now. Many thanks!
     
    BBut I am a bit puzzled why the original expression didn't work there. It was the "out of the box" expression given by the workflow itself. I seems rather strange to include an expression in a publicly available workflow which doesn't work. But perhaps I'm thinking a bit simplistically about this.
  • Expiscornovus Profile Picture
    33,784 Most Valuable Professional on at
    Yes, the description of that dynamic content field does not reflect what it actually is, an encoded user email value.
     
    Imho, the display name of that field should have been User email encoded instead of User email, this way people know what they are using. But that requires a change in the action of this SharePoint connector by the author, in this case Microsoft. That would be feedback for Microsoft.
     
    Btw, you could also use the encoded one in your setup as well. Only in that case you would need to decode it back to a string with a base64ToString function. 😁
     
    base64ToString(triggerOutputs()?['headers']?['x-ms-user-email-encoded'])
     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 286

#2
David_MA Profile Picture

David_MA 256 Super User 2026 Season 1

#3
Expiscornovus Profile Picture

Expiscornovus 225 Most Valuable Professional

Last 30 days Overall leaderboard