Creating a new process that adds items to a queue

I want to create a process that runs hourly that checks a folder to see if a file is present and then sends an API call if the file is present and then does nothing if the file is not present.

I am able to set a time trigger to have the bot run hourly, the issue is I would like to add items to a queue if the file is present and then once the API call is sent, gets the added item in the queue would be marked as a success. So if the bot runs and there are 10 files in the folder it will add 10 items into the queue and then work these 10 items and mark them as successful/faulted etc.

what would be the best way to go about doing this with a Robotic Enterprise Framework

You shouldn’t just assume you need to use REF. If you’re new to UiPath I suggest the transactional process template as a better place to start.

In general you need a dispatcher automation that loops through the files in the folder, moves each file to a new folder and then creates the queue item. The reason you move them out of the original folder is so the dispatcher doesn’t create a queue item for the same file more than once.

Then you have a separate performer automation that grabs a queue item, processes the file with whatever the relevant steps are, then sets the queue item to success or fail.

Do all the queue loading in the Initialization portion of the REframework.

Grab all files from X file location

For each file
- Use “Add queue item” activity and add the file/item information

Move files from folder.

Something to note, if you have access to Microsoft power automate, I would use that. It has triggers that you are looking for, “When a file is added to a folder”. Rather than checking the folder every hour, you can just use Power Automate and then API call orchestrator to start the UiPath job.

I recommend using the integration service. Set up a trigger associated with a shared folder, such as One Drive. Every time a file is placed in the folder, the orchestrator will trigger the process automatically. You need to have an unattended license. I recommend you read this documentation:

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.