getOrgUsers Step
Description:
This step fetches an organization user based on the organization structure.
Inputs
- workflowUserID – id of the user
- selectOrgUserType – select user type, manager or reporting users
- varGlobalForID – variable or global to store the user IDs
Returns
- True – step executed successfully
- False – step failed to execute
Usage:

Example:
We have included a sample organization structure below for your reference.

Let’s build and execute the “GetOrgUsersDef” example to fetch the Manager ID of the user (MilanD) and the user's reporting to this person.
- Create a new process definition called “GetOrgUsersDef” and open it in Designer mode.
- Drag the "getOrgUsers, getWorkflowUserID” step to the canvas.
- Connect the dots between the “Start” step and other steps, as shown above.
- Define a variable or a global to store the UserID.
- Click the “getWorkflowUserID” step to configure the “Required” properties. Provide a name for the step. Provide the workflow user name. Provide a variable or global to hold the userID after execution. Click the Save button. Note: Click the "AI Predict" button for the Copilot to add new process steps that match your process description.

- The “Logging” setting configuration is necessary for documentation and also measures the workflow progress and the percent complete. This is achieved by configuring the step state and percent fields individually, as shown below. Configure the “Logging” using the following properties.

- Click the first “getOrgUsers” step to configure the “Required” properties. Provide “getOrgUsers (Manager)” as the name. Provide the variable or global that contains the workflow userID from the previous step. Select the user type as “Managers.” Provide the variable or global that holds the manager user ID after execution. Click the Save button. Note: Click the "AI Predict" button for the Copilot to add new process steps that match your process description.

- The “Logging” setting configuration is necessary for documentation and also measures the workflow progress and the percent complete. This is achieved by configuring the step state and percent fields individually, as shown below. Configure the “Logging” using the following properties.

- Click the second “getOrgUsers” step to configure “Settings” properties. Provide “getOrgUsers (Report To Me)” as a name. Provide the variable or global that contains the workflow userID from the previous step. Select users to type as “Reports To Me.” Provide a variable or global that holds the reportee's UserID after execution. Click the Save button. Note: Click the "AI Predict" button for the Copilot to add new process steps that match your process description.

- The “Logging” setting configuration is necessary for documentation and to measure workflow progress and the percentage complete. This is achieved by configuring the step state and percent fields individually, as shown in the images below. Configure the “Logging” using the following properties.

- Save the process definition, create a new instance, and then execute it. Render the process instance. Click the process step. The process step should get the user’s “Manager” and the people “ReportingTo” the user as defined in the FlowWright Organization Structure.

Definition Sample:
You may download the sample definition(s) from the link here and later import them (drag-and-drop) to your FlowWright Process Definition (XML file) or Form Definition (HTML file) page.
Note: Please verify and complete the process steps for any missing configurations, such as file path references and database connections, after import. Then, save the definition to confirm the changes.