Shamma Negi
Kilo Sage
Kilo Sage

Hi All,

 

Today I would like to cover that how we can create a flow with roles. See below:

 

Create a flow or subflow that runs with assigned roles. Assigning roles enables you to create a user-initiated flow that runs with its own roles rather than the user's roles.

 

Create a user-initiated flow that runs with its own roles and not the roles of the user.  For example, allow a user-initiated flow to run with elevated privileges such as a limited admin role.

 

Assigning roles to a flow:

 

Role selection

 

A flow runs as either the system user or as the user who initiates the session. You can only assign roles to flows that run as the user who initiates the session. When the flow runs as the system user, it runs with the system role, and individual role selection isn't available.

You can assign multiple roles to a flow. Selecting new roles replaces the flow's original roles. If roles aren't selected, the flow runs with the roles of the user who initiates the session.

The roles you can select for a flow depend on the roles you have and the application scope of the flow. Assign any roles you that have access to in a particular scope, except high-security roles. You can't assign the following roles to a flow:
  • admin
  • security_admin
  • application-specific admin roles, such as an application admin role for Human Resources.

 

How to give or assign roles to a Flow. See below:

 

  1. Navigate to All > Process Automation > Flow Designer.
  2. Click + New > Flow or + New > Subflow.
  3. On the Flow Properties form, define the Name, Protection, Application, and Description for the flow.
    For more information, see Create a flow.
  4. In the Run As field, select User who initiates session.
    Role selection is not available if the System User option is selected in the Run As field.
  5. In the Run with role(s) field, select the roles that you want the flow to execute with.
    The roles you select replace any roles that the user normally has. If you don't select any roles, then the flow runs with the roles normally associated with the user.
    For example, an inbound email flow normally runs as an existing user or as the Guest user when there is no existing user. Since the Guest user has limited access, you could add the itil role to ensure that the inbound email flow always runs with the itil role.
  6. Click Submit.
    Note: If you have the Explicit Roles plugin (com.glide.explicit_roles) activated, add the snc_internal role to your flow.
 
Hope it helps.
I hope this article helpful. Please mark it as helpful and bookmark if you like it.