sn_search.ScriptableSearchAPI Description

nikita_mironov
Kilo Guru

Hi, I wonder if anyone could share sn_search.ScriptableSearchAPI description (methods, parameters). It is used in Chats Quick Action "Search KB" in Agent Workspace. Nothing found in Community / Developer Portal / hi KB.

Thanks in advance.

8 REPLIES 8

aliaksandr
Tera Contributor

Hello,

Have you found any information on this?

Could you share?

khoaphan1
Tera Contributor

Hi, I have a question about the "Search KB" in Agent Workspace too.
I wonder if we can add some conditions to the "Search KB" in Agent Workspace, like when the agent types the keyword, it just shows KBs that satisfy the condition "category=FAQ, country=User's country/blank & brand=User's brand/blank"?

Rahul Jain6
ServiceNow Employee
ServiceNow Employee

searchFilters takes sys_id's from sys_search_filter table. You can add sys_search_filter record under your profile with the required condition so it will filter the records accordingly.

Thank you for your reply @Rahul Jain6 . And I have one more question:

 

About searchFilter list, there are two cases:

1. searchFilter is an empty list (same as OOTB script)

2. searchFilter takes at least 1 sysid from sys_search_filter table (you already replied)

 

When calling api.search() to get KB results from agent's keyword, are there any differences in search results if searchFilter is set in two different cases?