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

Community site session details

Session Id :
Power Automate - Building Flows
Answered

Approval Flow - How to make attachments optional

(1) ShareShare
ReportReport
Posted on by 44

Hello! In an approval workflow, I need for the approver to be able to approve one to four files at the same time (main file, with possible additional supporting documents).

 

When I configure the Approver Process, I have put in the Attachment 2 field the parameters that I have captured in the manual input for the possible second file that can be attached.

 

cebolamonica_0-1604754076778.png

 

However, if in the manual input the user does not designate a second file, then the approval flow errs out. 

 

cebolamonica_1-1604754268302.png

 

Is there a way to make the second (and third, and fourth) attachments optional, so does it doesn't err out?

 

Thank you so much!

 

I have the same question (0)
  • Verified answer
    Pstork1 Profile Picture
    68,295 Most Valuable Professional on at
    Re: Approval Flow - How to make attachments optional

    If you build the Attachments as a JSON Array and then attach them as an array you won't need to specify the exact number of attachments.  You can switch to the array input using the button in the upper right hand corner of the attachment section of the approval dialog.  Take a look at the solution in this post for how to add attachments to an array.

    https://powerusers.microsoft.com/t5/Building-Flows/Creating-array-of-attachments-for-apporval-email/td-p/77328#:~:text=%20Re%3A%20Creating%20array%20of%20attachments%20for%20apporval,choose%20the%20Item%20ID%20from%20the...%20More%20 

  • tom_riha Profile Picture
    10,179 Most Valuable Professional on at
    Re: Approval Flow - How to make attachments optional

    Hello @cebolamonica ,

    you have to store the attachments and their content into an array variable and then use that variable in the task action.

    To get all the attachments and append them into the variable use the code below, it's the format the 'Approval task' action expects. Just replace the <...> parts with your dynamic content. 

     

     

    {
     "Name": <DisplayName>,
     "content": <Attachment Content>
    }

     

     

    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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 659 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 386 Moderator

#3
chiaraalina Profile Picture

chiaraalina 290

Last 30 days Overall leaderboard