Find Files And Folders: Code: generalException Message: An error Occurred Sending The Request-- Microsoft Office 365 Activities

Error in Find Files and Folders, Upload File activity of Microsoft Office 365 activities general exception Message " An error occurred sending the request " .

For the error "Find Files And Folders: Code: generalException Message: An error occurred sending the request". Kindly validate the below steps,

  1. Check if the Multi-Factor Authentication (MFA) is enabled or not?

Kindly note that IntegratedWindowsAuthentication or UsernameAndPassword authentication types do not work when Multi-Factor Authentication (MFA) is enabled. Refer Microsoft Office 365 Scope.

  1. Also make sure to enable the site permissions and shared permissions,
  • Sites.Read.All
  • Sites.ReadWrite.All

For more info on permissions, follow the link Office365-setup. Follow the same steps during the integration.

  • Alternatively, ApplicationIdAndSecret and ApplicationIdAndCertificate authentication types are appropriate for Unattended automation and work regardless of whether the MFA is enabled or disabled.


What MFA should be enabled? Is this a setting within MS or something inside UiPath?

Hello @Dany_Valdez , MFA in Share point MS365 should be disabled.

You need to check your internet option settings.

Hope this will help!!

So, I was using the ‘Find Files and Folders’ activity to read a file from SharePoint and kept getting this error, which led me to this page when looking for a solution. Though I had performed all the points mentioned in this post. But, there was a very stupid thing I was doing and that took me hours to realise the root cause of this error. So, if you have this problem, you should double-check the following:

The reason of this error: In Aunthentication property of Microsoft Office 365 Scope activity, I had selected serives (Files and Shared). while the account I was using was only authorized for shared services.

MicrosoftTeams-image (10)

Solution : Selected only Shared services

MicrosoftTeams-image (9)

And that’s all it was !! :sweat_smile: