Get a first look at what's coming. The Developer Passport Australia Release Preview kicks off March 12. Dive in! 

Redirect users to Workspace directly

Kaustubh k
Tera Expert

Hi All,

How can we redirect certain users on the basis of roles directly to a custom workspace as soon as they log in.

 

Thanks in Advance

6 REPLIES 6

ChiragA11796440
Tera Contributor

 

You can redirect users to a specific Workspace based on their role at login using the glide.entry.page.script system property.

Step 1: Create a Script Include

Navigate to:

System Definition → Script Includes

Create a new Script Include:

  • Name: RoleBasedWorkspaceRedirect

  • Accessible from: All application scopes

  • Client callable: Unchecked

Add the following script:

 

 
var RoleBasedWorkspaceRedirect = Class.create();
RoleBasedWorkspaceRedirect.prototype = {

getRedirectURL: function() {

var user = gs.getUser();

if (user.hasRole('admin')) {
return '/now/workspace/admin';
}

if (user.hasRole('itil')) {
return '/now/workspace/agent';
}

if (user.hasRole('sn_hr_core.basic')) {
return '/now/workspace/hr';
}

return '/now/nav/ui/home'; // Default fallback
},

type: 'RoleBasedWorkspaceRedirect'
};
 

Step 2: Set the System Property

Navigate to: System Properties → Security

Open property: glide.entry.page.script

 

Set its value to: new RoleBasedWorkspaceRedirect().getRedirectURL();

Save the property.


If this solution resolved your issue, please consider marking it as Helpful or Correct so others can benefit from it as well.

yashkamde
Mega Sage

Hello @Kaustubh k ,

1) Navigate to System properties > "glide.ux.user_criteria_enabled" 

-> check if it is enabled or not 

Screenshot 2026-02-27 164110.png

 

2) Then navigate to User Criteria Records > search "ITIL non-admin"

-> Add the Users, Groups or Roles you want redirect to the workspace

Screenshot 2026-02-27 163950.png

 

If my response helped mark as helpful and accept the solution.