Showing results for 
Search instead for 
Did you mean: 
Super User
Super User

Prettify JSON?

Hello, need some help on this one...

  • Have a JSON file that is "serialized" meaning, 1 long string.
  • Want to "prettify it" meaning, to format it correctly with indents, etc.
  • With the help of others, I created an Azure Function that uses PowerShell to prettify.
  • The response from the Azure Function is indeed formatted correctly.
  • BUT... the Create a File action for OneDrive For Business converts the JSON back to a serial string!

How can I prettify JSON in Flow OR leave formatted JSON as formatted JSON when creating a file? 


  1. Flow overview
    1. image.png
  2. Original file, serialized JSON
    1. image.png
  3. Response from Azure Function (pretty)
    1. image.png
  4. Re-created file, back to serialized JSON
    1. image.png
Community Support Team
Community Support Team

Re: Prettify JSON?


Hi @ericonline ,


I am afraid that the format you expect cannot be modified by Flow.

Since its file type is already .json, it will not affect subsequent use.

Please consider adding some extensions in Visual Studio Code to automatically decorate json data into the expected format.


Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources


Power Platform Online Conference

Speakers, submit your sessions now! Call for speakers ends Feb. 10!


New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!


Power Automate Community User Group Member Badge

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


Incoming: New and improved badges!

We've given our badges an overhaul and also added some brand new ones!


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 Power Automate Community Video Gallery!

Top Solution Authors
Top Kudoed Authors
Users online (3,331)