- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2023 07:04 AM
Hello,
Following this article - https://docs.servicenow.com/bundle/tokyo-servicenow-platform/page/build/service-portal/task/search-s... I have created the below Search Source to lookup Knowledge Articles in another instance of ServiceNow we use.
Below is the content in the article that I have pasted into the 'data fetch script field', the highlighted I will change the name of the instance I would like to refer to.
Do I need to add anything else to the data fetch script? I have been given a username and password service account to access but I am unsure where this goes.
This is what I have in the 'facet generation script' field:
Thank you for any assistance!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-25-2023 12:06 AM
does your user have sufficient roles to read those article in the question now. So can you confirm what all your user has (in external system)?
Regards,Sushant Malsure
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-19-2023 08:32 AM - edited 04-19-2023 08:37 AM
Yes it should work for you.
and for warning you can also use global.JSON() if its coped application
Regards,Sushant Malsure
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-21-2023 04:07 AM
Hello,
For some reason, the External Search Source is not working.
Looking at the below I've added our service account details. Replacing "search_user" with "USERNAME" and "search" with "PASSWORD" and I copied the URL directly from the ServiceNow guide only amending the instance name.
Does the account need any specific access requirements, licenses etc? This is just a standard user account with access to the Service Portal only. This account is also in the sys_users table in the external instance of ServiceNow that we are attempting to search, it does NOT exist in the instance where we are configuring the search source - should it be?
Also is the URL correct to reference all knowledge bases in the external instance of ServiceNow which we are attempting to search?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-21-2023 06:00 AM
User you are using should only be present in external instance from where KB article needs to be shared.
But try adding roles like rest_service, web_service_admin , soap_service role to that user to allow read access via this method. You may also want to check read ACLs associated with KB. but try giving roles one by one and see .
Also share the what are you getting on screen when this call is made.
Regards,Sushant Malsure
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-24-2023 01:45 AM - edited 04-24-2023 01:45 AM
If I go to the following URL in a new tab and enter the given credentials (which has no roles):
https://instancename.service-now.com/api/now/table/kb_knowledge?sysparm_query=GOTO123TEXTQUERY321%3D
I get the following error:
It is probably worth noting on 'Employee Center' I have disabled AI Search and removed the following:
and my added search source is here:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-24-2023 02:49 AM
I see you havent added any search text in URL which you are hitting append your query with some text.
Example: sysparm_query=GOTO123TEXTQUERY321%3DSAP
here SAP is the keyword we are searching in KB.
if this didnt work then please add roles to user (said in my previous comment ) and try again
Regards,Sushant Malsure