Resolution when Unattended job using Wait For Document Data Validation Action and Resume fails with Error "You are not authorized!" .
Job execution is unable to resume after completing an action in Action Center due to Wait For Document Classification Action And Resume activity throwing "You are not authorized!" error .
Root Cause: Inadequate permissions provided to the Robot user.
Troubleshooting:Check the full stack trace in the error message to see if a specific call is specified that is throwing the error. For example in the following error message, the message in bold indicates that the Users View permission is missing from the Robot that is executing the process.
Process was aborted due to OrchestratorException with message: You are not authorized!
Full Exception: UiPath.DocumentUnderstanding.Persistence.OrchestratorException: You are not authorized! ---> System.Exception: Microsoft.Rest.HttpOperationException: Operation returned an invalid status code 'Forbidden' at UiPath.DocumentUnderstanding.Persistence.Users.<GetUsersWithHttpMessagesAsync>d__5.MoveNext()
Check the roles and permissions that have been provided for the Robot user in Orchestrator. (See Managing Roles for more information on how to check the roles and permissions for the user.)
The appropriate permissions should be granted by adding the Robot account executing the job to the following two groups,
- Allow to be Automation User
- Automation User.
If the error message listed above in the Troubleshooting Step is present, and the user does not have the Users View role provided in Orchestrator, be sure to enable this permission
The Wait For Document Classification Action And Resume activity also requires the Robot user to have the following Folder level Permissions for the Robots role in Orchestrator:
For Storage Files permissions, View and Delete options are selected.
For Storage Buckets permissions, View option is selected. For Actions permissions, View option is selected.
See our document Wait For Document Classification Action And Resume for reference.
If the issue still occurs after providing the required permissions as listed above, gather and share the following information with the UiPath Support Team
- Set the Robot's logging level to verbose and then replicate the error. (To set the logging level to verbose, this can be accomplished via the Assistant -> Preferences -> Orchestrator settings page, or do so via Orchestrator -> Manage Access -> Edit the user that the process will be executed on if Unattended.)
- After causing the issue to occur, please share the Event Viewer logs from the robot machine: How to get Application Logs from the Event Viewer.
- Also share the Robot Execution logs: The robot logs are located here: %localappdata%/UiPath/Logs
- Confirm the version of Studio/Robot for the machine where the issue is occurring.
- Share the project files (Xaml, project.json, etc) in a zipped folder if possible.
- Capture a Fiddler trace on the machine while replicating the error. See How To Use Fiddler As A Proxy For The Robot Service To Collect Information.