Showing results for 
Search instead for 
Did you mean: 
Level: Powered On

List Sharepoint folder



What's the "right way" to get the contents of a Sharepoint folder when you have the path as a string in a variable? The List folder action takes the folder id, not the folder path and the Get files doesn't take a path either (I have the folder path as text in two variables).


As mentioned here I can replace(concat(string1, string2), '/', '%252f') but that's an ugly hack:

  • Unmaintainable if the Flow team decides to change the internal format of the Folder Id
  • Begs the question: are there any other characters apart from '/' that needs to be encoded? Which ones?



Community Support Team
Community Support Team

Re: List Sharepoint folder

Hi @MS2,


Could you please share a screenshot of your flow's configuration?

Could you please show a bit more about your two variables that you mentioned?


Thanks for your feedback, I could not find any document about encoding the special character (such as, '/', '_','-', etc.) within File Identifier or Folder Identifier currently. If I find the document related to it, I would reply here.


Best regards,


Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Level: Powered On

Re: List Sharepoint folder

Hi Kris, I have adopted the replace(concat(string1, string2), '/', '%252f') until I find some other solution. Is there somewhere I could read about which variable formats that are planned as persistent between flow generations. If the official stance is that the Folder Id/File identifier will forever be the encoded path then the above approach is ok (but still ugly). So there are no other encodings apart from the /?




The full expression above goes 

replace(concat('/contact/', string(items('Apply_to_each')?['ATSDocumentsFolder'])),'/','%252f')


Best regards,


Helpful resources


Microsoft Business Applications Virtual Launch Event

Watch the event on demand for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.


Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020.


Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!


Microsoft Learn

Learn how to build the business apps that you need.


Power Platform World Tour

Find out where you can attend!


Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Users Online
Currently online: 367 members 4,691 guests
Please welcome our newest community members: