Skip to content

algolia-samples/internal-search

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Internal search with Google Drive, Salesforce and Confluence

This sample app allows you to index and search content from Google Drive, Salesforce and Confluence in a single interface.

Features

The sample app uses the following features:

  • Easily index content from Google Drive, Salesforce and Confluence to Algolia using Tray.io with little code
  • Search all your content in a single search interface built with React InstantSearch
  • Dynamically display facets using DynamicWidgets

A flowchart of the internal search sample application

Demo (Try it yourself!)

A short video clip displaying the Algolia internal search application

Access the demo

How to run the sample app locally

The client is a React app using React InstantSearch.

This sample app collects data from Google Drive, Salesforce, and Confluence. The indexing for each data source is implemented in three different Tray.io workflows.

1. Clone this repository

git clone [email protected]:algolia-samples/internal-search.git

Copy the file .env.example to the directory of the client and rename it to .env.

cp .env.example client/.env

2. Set up Algolia

To use this sample app, you need an Algolia account. If you don't have one already, create an account for free. Note your Application ID.

In the .env file, set the environment variables ALGOLIA_APP_ID:

ALGOLIA_APP_ID=<replace-with-your-algolia-app-id>

3. Create your Algolia index

After you set up your Algolia account and Algolia application, create and populate an index.

To upload your data, you can use the Algolia dashboard or use one of Algolia's API clients.

After creating the index, set the environment variables ALGOLIA_INDEX_NAME and ALGOLIA_API_KEY in the .env file:

ALGOLIA_INDEX_NAME=<replace-with-your-algolia-index-name>
ALGOLIA_API_KEY=<replace-with-your-algolia-api-key>

6. Populate your index using Tray.io

We provide three Tray.io workflows for indexing the content, one for each data source:

For example, if you want to index content from Salesforce:

  1. Create an account on Tray.io (They offer a 14 days trial period).
  2. Upload the workflow JSON file (Tray.io will ask you to authenticate against Algolia and Salesforce).
  3. On Tray.io, set the indexName in the project's config data.
  4. Run the workflow!

7. Start the client

Requirements

  • Node.js, at least version 10
  • Configured .env file

How to run

  1. Install dependencies
npm install
  1. Run the app
npm start
  1. Go to localhost:3000

Resources

Contributing

This template is open source and welcomes contributions. All contributions are subject to our Code of Conduct.

Authors