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 / Attaching Multiple Fil...
Power Automate
Suggested Answer

Attaching Multiple Files to Approval in Power Automate

(1) ShareShare
ReportReport
Posted on by 4

I am facing an issue with attaching documents in an approval flow. My form includes two questions for document uploads, and I need these files to be sent as attachments in the approval step. I’ve set up the flow with two actions for file content: two Compose actions, two Initialize Variable actions, and two "Apply to Each" loops to get the file content and append it to an array variable.

However, I encounter a problem when trying to include both initialized variables as attachments in the "Start and Wait for an Approval" action. The flow fails to save when I attempt to add both variables in the attachments section.

I receive the following error:

Flow save failed with code 'OpenApiOperationParameterValidationFailed' and message 'Input parameter 'WebhookApprovalCreationInput' validation failed in workflow operation 'Start_and_wait_for_an_approval': The parameter with value '"[\n {@{variables('VendorInvoice')}},\n {@{variables('VoidCheque')}}\n]"' in path 'WebhookApprovalCreationInput/attachments' with type/format 'String' is not convertible to type/format 'Array'.'.

I have attached screenshots of how I structured the Initialize Variables in file attachments and the complete flow. Any guidance or help to resolve this issue would be greatly appreciated!

Screenshot 2024-09-04 185102.png
Screenshot 2024-09-04 185142.png
Categories:
I have the same question (0)
  • Nived_Nambiar Profile Picture
    18,138 Super User 2026 Season 1 on at
    Hi, 
     
    could you please share how both variables are structured?
     
    if each variable represent file, then its structure should be like below object
     
    {
    "name": "name of file",
    "content":"content bytes of file which is obtained from get file content"
    }
     
    Thanks & Regards,
    Nived N 
    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs
     Found my answer helpful? Please consider marking it as the solution!
     Your appreciation keeps me motivated. Thank you!

     
  • CU04092247-0 Profile Picture
    4 on at
    Hi Nived,
     
    Thank you for your quick response. the following are my "Append to array variable" screenshots,
     
     
    Also, I have used Initialize Variable to these two. The problem arises when I attempt to include these to in the attachment section of "Start and wait for an approval". The following screenshot shows how I have included in the attachment area,
     
     
    It works if I only include one variable. For example, "VendorInvoice". But if I try to include both as in the previous screenshot, it does not even let me save the flow and shows this error,

    Flow save failed with code 'OpenApiOperationParameterValidationFailed' and message 'Input parameter 'WebhookApprovalCreationInput' validation failed in workflow operation 'Start_and_wait_for_an_approval': The parameter with value '"[\n {@{variables('VendorInvoice')}},\n {@{variables('VoidCheque')}}\n]"' in path 'WebhookApprovalCreationInput/attachments' with type/format 'String' is not convertible to type/format 'Array'.'.
     
    Your assistance would be highly appreciated. It would be great if you have already created a video on how to include two question uploads to approval process. Also, I am available for your personal training as well.

    Thanks,
    Inam Ul Haq
    LinkedIn: www.linkedin.com/in/inam-ul-haq18
  • Suggested answer
    Nived_Nambiar Profile Picture
    18,138 Super User 2026 Season 1 on at
    Hi,
     
    The Attachment field accepts array of object, not array of arrays :).
     
    In that case, create one array variable and append both file objects to that array variable and place it there. It would solve the issue.
     
    Thanks & Regards,
    Nived N 
    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs
     Found my answer helpful? Please consider marking it as the solution!
     Your appreciation keeps me motivated. Thank you!

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 276 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 169

#3
Haque Profile Picture

Haque 154

Last 30 days Overall leaderboard