Skip to main content

Notifications

Power Apps - Building Power Apps
Answered

Retain JSON formatting when using in Create file

(0) ShareShare
ReportReport
Posted on by

Hi,

 

I have a JSON response from a HTTP request which I want to retain the formatiing on. What I am experiencing is that when I place my JSON into a file content it flattens it onto one line. I need it formatted as JSON as I am subsequently using it for a PowerShell.

 

I need to retain the json on separate lines like this
{
"mail": "pretend@email adress",
"otherMails": "pretend@email adress"
},
{
"mail": "pretend@email adress",
"otherMails": "pretend@email adress"
}

 

However when I place it into the file content it always saves on one line.
Screenshot 2019-09-03_17-44-33-217.pngScreenshot 2019-09-03_17-40-56-719.pngScreenshot 2019-09-03_17-42-33-493.pngScreenshot 2019-09-03_17-43-07-047.png

When I use the create file action I create the outer JSON manually then place the variable in the middle.

Screenshot 2019-09-03_17-52-29-149.png

 

Thanks,

Yvonne

 

  • Verified answer
    Lisabel0 Profile Picture
    Lisabel0 154 on at
    Re: Retain JSON formatting when using in Create file

    Try to repost in https://powerusers.microsoft.com/t5/Microsoft-Flow-Community/ct-p/FlowCommunity.

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,666

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,996

Leaderboard