Delete all users on Development or Test environments

2 Weeks Ago
JorgeP
HOW TO'S

Summary

 

Sometimes hundreds of users need to be created in the development and testing environments for testing purposes, which then need to be manually removed. Now, you can delete multiple users in batch, which share defined parameters. To do so, follow the steps described below:

Applies to

      

Bizagi 11.2.1   

Considerations

      

1. All users with dependencies to any database table such as autholog, currentassignee, entitylog, wfcase, bauserstatisticscase, userbauth, assignationlog, bastakeholderuser, and business entities tables cannot be deleted.

2. An application that allows the use of Rest services must be used to delete users. We recommend using the Google Chrome extension Postman.

3. The steps described below can only be executed by Bizagi administrators.

4. This functionality works only for Development or Test environments.

5. You must use a URL containing your Bizagi's server name, project name and the controller: Rest/Users/MassUserDeletion (review the what you need to do section below) to execute the Rest service.

6. You must use the verb DELETE

What you need to do

      

1. Enter to the Postman Chrome extension or the desktop application.

2. On the left side of the bar select the verb DELETE

3. On the text field, type the URL with the following structure:
Suppose that the server you are using is called "servername" and the Bizagi project that you want to delete users from is called "project-name", then the URL structure is:
http://servername/project-name/Rest/Users/MassUserDeletion

4. Select the Authorization tab and follow these steps:
On the type dropdown list, select Basic Auth.
On the username section, type the domain and user name which you use to log in to Bizagi (e.g domain\admon).
On the password section, type the password that logs you into Bizagi (e.g admon).

5. Select the Body tab and follow these steps:
On the checkboxes section, select the x-www-form-urlencoded one
On the Key table, add two new keys and its corresponding values:

  • Prefix: determine the users to be deleted whose name begins with the typed values (e.g userprefix).
  • Domain: define the domain of the users to delete (it is set on the Bizagi Work Portal user management basic information).

6. Finally,  at the bottom left of the window on the drop-down list select text. Then click Send at the top right of the window.
The message that appears when the operation is succesfully  completed is "Operation successful. Total users deleted: (number of users deleted)".
In the Status field at the bottom right of the window, Postman  returns one of three values:

  • 200 OK: means that the operation was successful
  • 403 FORBIDDEN: Means that the environment is production, then users cannot be deleted.
  • 500INTERNALERROR: Means that during the operation an error occurred

                                    

Rate this Article:

Details

Last Modified:2 Weeks Ago
Last Modified By: JorgeR
Type: HOWTO
Level: Intermediate
Rated 5 stars based on 1 vote
Article has been viewed 70 times.

Options