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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Outlook REST API "Inte...
Power Automate
Unanswered

Outlook REST API "Internal Server Error" for any query -- new line added to URI?

(0) ShareShare
ReportReport
Posted on by
I have been trying to use the "Send an HTTP Request" action in the office365 Outlook connector, and every time it tries, I get a 500 Internal Server Error response.
 
My parameters are:
 
Method: GET
 
I'm not using any advanced parameters at the moment, because I can't get even a simple request to work.
 
When I look at a failed request, this is what I see:
Parameters:
{
  "Uri": "https://graph.microsoft.com/v1.0/me/mailFolders/\n",
  "Method": "GET"
}
Status code: 500
Body:
{
  "error": {
    "code": 500,
    "message": "Object reference not set to an instance of an object.",
    "source": "(some guid).19.common.usa002.azure-apihub.net",
    "path": "choose[7]\\when[1]",
    "policyId": "",
    "clientRequestId": "(some guid)",
    "dreeSet": "true"
  }
}
I redacted the GUIDs in case they are sensitive, I don't know.
 
Anyways, I noticed that any Uri that is sent always has a `\n` at the end, which would normally be a new line character but it looks like it's sending the raw slash + n, and I'm guessing that's the reason. If that's the case, how do I fix it? There's no new line at the end of my URI value in the text box.
Categories:
I have the same question (0)
  • David_MA Profile Picture
    12,966 Super User 2025 Season 2 on at
    Remove the highlighted portion of the Uri: https://graph.microsoft.com/v1.0/me/mailFolders/\n
     
    What were you trying to do with "/\n"?
     
    To fix it, you will need to show your workflow and how you have configured the HTTP request. Since you type in the Uri in the action, I don't know how it is getting passed through the HTTP request when the flow runs without seeing it.
     
    You can use the Graph API explorer at Graph Explorer | Try Microsoft Graph APIs - Microsoft Graph to test this with.
  • JW-04030208-0 Profile Picture
    on at
    I'm not adding the \n, that's the problem. I don't know how it's being added there.
     
    This is what my configuration of the action is: 
     
    I have tested the URI in the graph explorer and it works just fine there.
  • David_MA Profile Picture
    12,966 Super User 2025 Season 2 on at
    Just ran it, no issues:
     
    I would configure it as shown above. If you copy and pasted the value into the URI field, the \n is probably hidden. If you copy and paste, be sure to paste it as plain text or manually enter the value into the field.
     
  • JW-04030208-0 Profile Picture
    on at
    For some reason, I have tried to reply to this twice now and it doesn't appear to be posting.
     
    I typed everything exactly how you have yours, and the code view still shows a \n at the end of the URI. Without the / at the end, like you have, I now get a 411 status code, and it says "HTTP Error 411. The request must be chunked or have a content length."
  • Verified answer
    David_MA Profile Picture
    12,966 Super User 2025 Season 2 on at
    I would try deleting the action and add it back in. Maybe also switch to using the old designer. There have been numerous issues with the new designer and maybe something with it is causing the \n character to be added. Although, the flow I created used the new designer and I had no issue. You should check to make sure you are using the Microsoft Outlook 365 HTTP action as I show in my earlier post. Your screen shot does not show which action you are using for the HTTP request.
  • JW-04030208-0 Profile Picture
    on at
    You know what? I just went to the old designer like you suggested, and this is what the URI box looked like:
     
    and it worked as soon as I deleted the new line that was there. It looks like the answer here is "don't use the new designer" haha

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 538 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 405 Moderator

#3
abm abm Profile Picture

abm abm 252 Most Valuable Professional

Last 30 days Overall leaderboard