Using user criteria to show Knowledge base if user can see article

Isaac Swoboda1
Tera Contributor

At my company there is an ask to create our knowledge bases locked down for teams. Most of the content in these knowledge bases is only relevant to the team who owns the knowledge base. Every now and then though there is a user outside of the team who would benefit from the content of one article. The team would like to have a custom field on the article which is like the watch list and contains the users who can see the article. However, they do not want them to see the rest of the articles in the teams knowledge base.

How do I leverage user criteria of a knowledge base Can Read to allow this? I need users to be able to go to the knowledge homepage and see the knowledge base within which they have one article to read.

Would the only way to do this be to add the user to the knowledge base Can Read criteria and then put a query business rule on the the knowledge table to filter out things they should not have access to? I am not sure how this will impact searching the Knowledge home, if the searching will only adhere to the user criteria and return results for all the knowledge articles in the knowledge base which match the search instead of just the one article they have access to.

Any guidance would be helpful.

1 REPLY 1

Dave Aiken
ServiceNow Employee
ServiceNow Employee

Another option for solving this without writing any code would be to utilize the Roles field on the KB article in addition to the User Criteria related list on the Knowledge Base.



This would work nicely if, in the scenario you described, each team's KB can also be tied to a specific role that all team members must have.   You would then set the Roles field of all articles in the KB to this role.   You can open access to an additional non-team member by adding them to the user criteria of the KB, but unless they have the role(s) assigned to the individual articles, they will not be able to see anything.   You can then, remove the role restrictions on the article that you want them to see.