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 : 5gaJweJdjEuyrQeGE22gGP
Power Automate - Building Flows
Unanswered

Flow Error: The response is not in a JSON format.

Like (0) ShareShare
ReportReport
Posted on 29 Aug 2023 16:08:32 by 10

So I know that there are tons of responses out there on this error but I am not finding the response I need or the fix I need so I am going to post this up under my specific situation.  

 

I have a flow that goes against Dataverse and the idea is to pull and SSRS report, push it to a PDF, and then email said PDF.  I found the steps here and they look legit:  https://reenhanced.com/2021/download-dynamics-365-reports-as-a-pdf-with-power-automate/ 

 

So here is my problem.  At the point of this process where I am downloading the PDF via the created URL is when I get the JSON error that I see here:

{
  "error": {
    "code": 302,
    "source": "flow-apim-unitedstates-002-eastus-01.azure-apim.net",
    "clientRequestId": "f55c3bc9-ad66-46fa-9e19-834533fd4668",
    "message": "The response is not in a JSON format.",
    "innerError": "<html><head><title>Object moved</title></head><body>\r\n<h2>Object moved to <a href=\"/_common/error/err.aspx?BackUri=&amp;ErrorCode=0x80048287&amp;Parm0=%0d%0a%0d%0a&amp;RequestUri=%2fReserved.ReportViewerWebControl.axd%3fReportSession%3dxjjfwhifrwnz5d55nbsn1szz%26Culture%3d1033%26CultureOverrides%3dTrue%26UICulture%3d1033%26UICultureOverrides%3dTrue%26ReportStack%3d1%26ControlID%3d1914e4cf91924830ad0d0b63b1580b31%26RSProxy%3dhttps%253a%252f%252fbn1700srs.nam.reporting.cds.dynamics.com%252freportserver%26OpType%3dExport%26FileName%3dMASB%2bInvoice%26ContentDisposition%3dAlwaysAttachment%26Format%3dPDF%26rc%3aPrintOnOpen%3dtrue&amp;user_lcid=1033\">here</a>.</h2>\r\n</body></html>\r\n"
  }
}
 
My flow looks like this in the area of pulling that URL:
bigjay_0-1693325092117.png

Looking at the failure, this is what I am seeing:

bigjay_1-1693325142919.png

 

The URL that is being used in the GET request:  /Reserved.ReportViewerWebControl.axd?ReportSession=xjjfwhifrwnz5d55nbsn1szz&Culture=1033&CultureOverrides=True&UICulture=1033&UICultureOverrides=True&ReportStack=1&ControlID=1914e4cf91924830ad0d0b63b1580b31&RSProxy=https%3a%2f%2fbn1700srs.nam.reporting.cds.dynamics.com%2freportserver&OpType=Export&FileName=MASB+Invoice&ContentDisposition=AlwaysAttachment&Format=PDF&rc:PrintOnOpen=true

 

I have attempted to use Headers in the HTTP GET request of Accept: */* and Accept: application/json.  I have tried with both there and with each on their own.  

 

What am I missing or what simple step is missing in this?  

 

Thanks.

 

Jayson

  • jlarner Profile Picture
    10 on 28 Sep 2023 at 12:11:14
    Re: Flow Error: The response is not in a JSON format.

    Kind of forgot I had this question out there.  I did find a workable solution for this.  Turns out this pull can error out like this so the suggestion was "try again".  Since this is an automated process, I put the pull into a Do While loop to run until successful.  When it fails, historical tracking shows that it typically is within roughly 5 reattempts so I set my Do While to max out at 20 just in case.  I set a variable to be incremented only when the process completes properly and that breaks the Do While.

    bigjay_0-1695903067360.png

     

  • rina1 Profile Picture
    2 on 28 Sep 2023 at 09:18:27
    Re: Flow Error: The response is not in a JSON format.

    I have the same problem !

    did you found a solution?

    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

Responsible AI policies

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

Telen Wang – Community Spotlight

We are honored to recognize Telen Wang as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Tomac Profile Picture

Tomac 986 Moderator

#2
stampcoin Profile Picture

stampcoin 699 Super User 2025 Season 2

#3
Riyaz_riz11 Profile Picture

Riyaz_riz11 577 Super User 2025 Season 2

Loading complete