What should be taken care while writing a code in UiPath so that other developers can understand our code easily?

What should be taken care while writing a code in UiPath so that other developers can understand our code easily ?

1 Like

Hi! @Vikram212 ,

In UIPath you have activities which you can easily drag and drop from the activities panel.

have a view on this


and here you can write 2 to 3 lines of code. and it is very easy to write and read. and also everyone can easily understand.
for basic process please refer below



It’s always recommended to follow the best practices

Hope this may help you


Hi @Vikram212,

Few points that we consider in our day to day projects as below:

  1. Try to make use of Reframework as much as possible as it has exception handling features already included which you can further enhance. Also, when a particular framework is being used by everyone, it’s easy to delegate responsibility to others for and share work because everyone would know what parts of the projects(initialisation, picking a transaction, processing transaction and cleaning up in the end) can be found under which section so troubleshooting becomes fairly easy.

  2. Make the code modular as much as possible that means having different workflows for parts of the process.

  3. Creating e separate folder in root folder named as ‘Application’ which should contain all workflows related to application functionality. And rest workflows related to framework would be already under Framework folder. This way you won’t end up cluttering the root folder of the process. There would be only 3 files - main, process and project.Json

  4. Use detailed annotations for each and every sequence/activity to define what is being done in there.

  5. Rename activity/sequence names to meaningfully define the purpose.

  6. Having proper logging of the steps specially at start of the sequence and at the end. Proper logging helps in troubleshooting quite well. But need to ensure we are not logging any customer sensitive information here.

  7. Use code repositories like Git or Svn so changes are frequently checked in there with comments and collaboration is effective among all developers.

  8. Make use of workflow analyzer feature of uipath for code review and also a peer review before deploying the changes to ensure proper code practices were followed by the developer.

  9. Proper documentation of exception scenarios handled in the project so everyone has a fair idea of what is being handled and what still needs to be handled.

  10. While defining Assets in the orchestrator make sure there are proper descriptions attached for each and every asset.

  11. Proper descriptions for queue, storage bucket, process etc.

  12. Standard naming conventions for project and it’s components.

  13. And last but not the least, you can consider enabling governance in your organization to ensure any security related stuff is enforced throughout. Additionally can enforce code practices also via this.

Hope this clarifies.

Apart from this, please refer documentations as suggested by @Srini84.



Here you go with UiPath suggested documents in best automation practices

Hope this would help you

Cheers @Vikram212

Hi @Vikram212,

I hope we have been able to resolve your query.
If yes, would suggest to close this topic so others can also benefit whenever come across similar query :slight_smile: