All the catalog items should available for specific group members. how can I do that?

rutik_Wadhawane
Tera Expert

I have a requirement like, all the catalog items should available for specific group members. how can i do that?
More than 800 catalog Items are present over there so how can I make them Available for It's Group Member?

3 REPLIES 3

Deepak Shaerma
Kilo Sage

HI @rutik_Wadhawane 
especially when dealing with a large number of items (like your case of over 800 items), requires a strategic approach to ensure that the configuration is both manageable and maintainable.

1. Use Access Control Rules
Create Access Control Rules that specifically target the “sc_cat_item” table and define the conditions under which a user or group can read (view) or order (execute) catalog items. You’ll likely use a condition that checks if the current user is a member of the specific group. However, creating individual ACRs for each of the 800+ items is not practical. Instead, you would create more generic rules.

2. Leverage User Criteria

User Criteria in ServiceNow allows you to control who can view and order catalog items based on roles, groups, and other user attributes. This can be an efficient way to manage access without directly modifying each catalog item:

Create User Criteria: Navigate to Product Catalog > Catalog Definitions > User Criteria and create a new user criterion that specifies the group condition.

Apply User Criteria to Catalog Items: You can apply user criteria to catalog items or categories. For bulk application, here are a few strategies:

Manually: If there’s a manageable subset of items that share the same access requirements, you might individually edit those items to attach the relevant user criteria. This is impractical for very large numbers of items unless there’s a clear pattern to leverage.

Use a Script: For a large volume of items, consider writing and executing a background script that iterates over catalog items to programmatically set the user criteria field (sc_cat_item.user_criteria). This requires some familiarity with ServiceNow scripting and access to the script execution capabilities in your instance.

 

var catItems = new GlideRecord('sc_cat_item');
catItems.query(); // Add query conditions if needed
while(catItems.next()) {
catItems.user_criteria = 'sys_id_of_user_criteria'; // Set the User Criteria sys_id
catItems.update();
}

 

3. Review Existing Configurations If you’re working in an existing ServiceNow environment, it’s also important to review any existing configurations that may already be in place for controlling access to catalog items. This includes existing Access Control Rules, User Criteria, or Catalog Item configurations that might influence or override the changes you plan to apply.
Note: Please Mark this Helpful and Accepted Solution. If this Helps you to understand. This will help both the community and me..
- Keep Learning ‌‌
Thanks & Regards 
Deepak Sharma 


rutik_Wadhawane
Tera Expert

Any other ways we do it, please suggest me.

Vishwa Pandya19
Mega Sage

Hello Rutik,

 

May I ask why those 800 catalog items are not visible to users in the first place? 
Is there any kind of restriction?

 

What roles do the group members have? (the group members whom the catalog items need to be visible).