Get manager (V2) - 404 Error: User Not Found, Code: ResourceNotFound
I ran into this same error today, after trying to optimize a flow which was working fine a few hours ago.
This whole flow stuff seems to be on some pretty shaky ground. It my second day using this and I have already run into 3 bugs.
Solution:
Turns out that if you use the "Select fields" in advanced options of the previous step, and don't include userPrincipalName, you get this worthless error message which says nothing about the actual problem.
This took me an hour to nail down the true root cause.
"user not found" ? Really ? How about "UPN missing" ? Or how about don't show UPN as an available choice in the Dynamic Content options of GetManager if the previous step GetMyProfile did not even include it !
Inputs
{
"api": {
"runtimeUrl": "https://flow-apim-msmanaged-na-eastus2-01.azure-apim.net/apim/office365users"
},
"connection": {
"name": "/providers/Microsoft.PowerApps/apis/shared_office365users/connections/5962745f8a4a43abb086"
}
}Path
/codeless/v1.0/users//manager
404 Response
"Flow error:
{
""error"": {
""code"": ""ResourceNotFound"",
""message"": ""User not found"",
""innerError"": {
""request-id"": ""ef98033e-692c-4b68-ad0d-79041dd337b8"",
""date"": ""2019-10-09T22:23:30""
}
}
}"