Install a Search Client in Salesforce Communities (Lightning)

In this article, you will learn how to replace the default Salesforce component, Search Results, with a SearchUnify package. The SearchUnify package runs as a native app and can fetch results from your org and external sources, such as your organization's YouTube channels, Slack discussions, and GitHub repositories right into your Community Cloud. The installation takes only a few minutes but goes a long way in enhancing user experience.

Comparison of Search Results Component and SearchUnify Package

When users are confronted with thousands of posts and articles, most choose to run a search. As a Salesforce admin, you can improve user experience by replacing the default Search Results component with a powerful SearchUnify package. This table summarizes the key differences between the both.

  Search Results (Component) SearchUnify Package
Default Component Yes No
Native Support Yes Yes
Global (Org) Search No

Yes

Objects Supported Articles, Discussions Articles, Discussions, and all other standard and custom objects
Results from External Sources No Yes

Salesforce Default Permissions

Search clients on your org adhere to default Salesforce positions, which means that a Guest User cannot see any cases on the search results page and a Partner can see all the cases concerning his or her Contacts. The table summarizes the default permissions followed on the Salesforce search client.

Permissions Chart

User Type Salesforce Object Accessibility (Visibility) 
Partner Case All the cases that belong to the Partner's Contacts.
Articles 1. All the public articles
2. All the articles visible to the Partner
Internal Cases All the cases in the org
Articles All the articles in Knowledge
Guest User Cases Cannot see any cases.
Articles All the public articles.
Customer Case All the cases that belong to the Customer's contacts.
Articles 1. All the public articles
2. All the articles visible to the Customer

Enable SearchUnify Search on Salesforce Communities

Create a Salesforce Lightning Search Client

  1. Ensure that Salesforce Communities are enabled. Skip this step if you already have a community.
  2. Create a Salesforce Lightning search client.
  3. Configure the Salesforce Lightning search client.

Install SearchUnify Package

  1. Visit Salesforce AppExchange, look up "searchunify", and open the top listing, SearchUnify - Cognitive Search & Insights for Salesforce.

  2. Click Get It Now.

  3. If prompted, log in with your Salesforce admin credentials.

  4. It's usually a good practice to install an app on Sandbox, instead of Production.

  5. Install the app for All Users. A warning might come up. Overlook it and proceed with installation.

In the end an Installation Successful message will greet you.

Connect Salesforce Org with SearchUnify Instance

The data flow between SearchUnify and your Salesforce org is managed through Remote Sites, of which two must be created before you can proceed with configuration. For instructions, check out Create Remote Sites in Salesforce.

Process SearchUnify Package

  1. Click Salesforce App Launcher and then View All.

  2. Find SearchUnify Configuration and click it open.

  3. Create a remote site using URL on the Search Configuration screen.

    1. Select Lightning from Choose Search Platform. A configurations page will appear. Enter the details and click Process.
      • Select your community for configuration. Choose a Salesforce community where the search client will be installed.
      • Enter Service Endpoint. It is your SearchUnify instance URL.
      • Enter Provision Key. You can get it from your SearchUnify representative.
      • Enter UID. It is your search client ID.
      • Enter community page name. Select or create a page with full-width and only one column. The page name should be limited to lowercase letters and hyphens. Spaces are not allowed.

Add SearchUnify Instance to CSP Trusted Sites

  1. From Setup, go to Quick Find Box, find CSP Trusted Sites, and open it.

  2. Click New Trusted Site.

  3. In the form that opens, enter "SearchUnify" in Trusted Site Name and {{instance URL}} in Trusted Site URL.

  4. Check all the CSP Directives and click Save.

Insert SearchUnify Search Component to a Community Page

  1. Open your community in the Builder mode. (From Setup, go to All Communities through Quick Find Box, and click Builder.)
  2. Move to Security from .
  3. Select Allow Inline Scripts and Script Access to Whitelisted Third-party Hosts from the Script Security Level dropdown.

  4. Click from the sidebar, select Theme, and enter Configure.

  5. Click , and from the Search Component drop-down select SUAuthBanner_1234 (where 1234 are the first four digits of your UID).

  6. Drag SUAuthSearch_1234 (where 1234 are the first four digits of your UID) to the Content section of the page you have selected or created.

You have successfully installed SearchUnify on Salesforce Communities.

Last updatedFriday, February 26, 2021

Was this article helpful? Send us your review at help-feedback@searchunify.com