GETTING STARTED
SearchAssist Overview
SearchAssist Introduction
Onboarding SearchAssist
Build your first App
Glossary
Release Notes
What's new in SearchAssist
Previous Versions

CONCEPTS
Managing Sources
Introduction
Files
Web Pages
FAQs
Structured Data 
Connectors
Introduction to Connectors
SharePoint Connector
Confluence Cloud Connector
Confluence Server Connector
Zendesk Connector
ServiceNow Connector
Salesforce Connector
Azure Storage Connector
Google Drive Connector
Dropbox Connector
Oracle Knowledge Connector
DotCMS Connector
RACL
Virtual Assistants
Managing Indices
Introduction
Index Fields
Traits
Workbench
Introduction to Workbench
Field Mapping
Entity Extraction
Traits Extraction
Keyword Extraction
Exclude Document
Semantic Meaning
Snippet Extraction
Custom LLM Prompts
Index Settings
Index Languages
Managing Chunks
Chunk Browser
Managing Relevance
Introduction
Weights
Highlighting
Presentable
Synonyms
Stop Words
Search Relevance
Spell Correction
Prefix Search
Custom Configurations
Personalizing Results
Introduction
Answer Snippets
Introduction
Extractive Model
Generative Model
Enabling Both Models
Simulation and Testing
Debugging
Best Practices and Points to Remember
Troubleshooting Answers
Answer Snippets Support Across Content Sources
Result Ranking
Facets
Business Rules
Introduction
Contextual Rules
NLP Rules
Engagement
Small Talk
Bot Actions
Designing Search Experience
Introduction
Search Interface
Result Templates
Testing
Preview and Test
Debug Tool
Running Experiments
Introduction
Experiments
Analyzing Search Performance
Overview
Dashboard
User Engagement
Search Insights
Result Insights
Answer Insights

ADMINISTRATION
General Settings
Credentials
Channels
Team
Collaboration
Integrations
OpenAI Integration
Azure OpenAI Integration
Custom Integration
Billing and Usage
Plan Details
Usage Logs
Order and Invoices

SearchAssist APIs
API Introduction
API List

SearchAssist SDK

HOW TOs
Use Custom Fields to Filter Search Results and Answers
Add Custom Metadata to Ingested Content
Write Painless Scripts
Configure Business Rules for Generative Answers

Analytics APIs

Get Analytics API

This API can be used to fetch analytics data generated by the SearchAssist application. You can apply filters to fetch specific reports.

Method POST
Endpoint <host_url>/searchassistapi/external/stream/<streamId>/analytics
Content-Type application/json
Auth <JWT Token>
API Scope     Analytics

Query Parameters

Parameters Description Mandatory
streamId Provide your application ID here.  Yes
indexPipelineId The index configuration Id No. When not provided, default index configuration is used.
Offset Number of records to skip while fetching the response.  No. When not provided, the default value of 0 is used. 
Limit This is the number of records to be fetched as response to the API call, starting with a record after the skip count. No. When not provided, the default value of 50 is used.

Request Parameters

Parameters Description Mandatory
type This field can take the following values:

  • MostSearchedQuries
  • TopQuriesWithNoResults
  • QueriesWithNoClicks
  • SearchHistogram
  • UsersChart
  • UsersBusyChart
  • QueriesWithNoResults
  • QueriesWithResults
  • SearchQueryResults
  • TopSearchResults
  • MostUsedDevices
  • MostUsedBrowsers
  • MostUsedGeoLocations
  • MostUsersSentiments
  • Results
  • SearchQueriesForResult
  • MostClickedPositions
  • FeedbackStats
  • TotalUsersStats
  • TotalSearchesStats
  • QueriesWithAnswers
  • QueriesWithNoAnswers

You can also fetch data grouped by user identities using the following types:

  • QueriesWithResultsGroupedByUser
  • QueriesWithNoResultsGroupedByUser
  • QueriesWithAnswersGroupedByUser
  • QueriesWithNoAnswersGroupedByUser
  • SearchQueriesForResultGroupedByUser
Yes
group This field can take the following values:

  • hour
  • date
  • week
No
filters This field can be used to provide the time frame for which the data is to be generated. 

  • from: timestamp that indicates the beginning of the time duration for which data is to be retrieved.
  • to: timestamp that indicates the end of the time duration for which data is to be retrieved. 
No

Sample Request

{
  "type": "QueriesWithResults",
  "group": "hour",
  "filters": {
    "from": "2024-01-01T11:48:34.404Z",
    "to": "2024-01-05T11:48:34.404Z"
  }
}

Export Analytics API

This API is used to export analytics information to a file. It creates a job of type ‘DATA_EXPORT’ to export the data. To download the file, use the job id and get the URL of the file with exported data using the Job APIs.

Currently, this API limits data export to a maximum duration of a week. If the duration is more than a week, an error is thrown. 

Method POST
Endpoint <host_url>/searchassistapi/external/stream/<stream-id>/analytics/export
Content-Type application/json
Authorization auth: <JWT Token>
API Scope Analytics

Query Parameters

Parameters Description Mandatory
Stream ID Provide your application ID here.  Yes

Request Parameters

Parameters Description Mandatory
filters

This field indicates the time frame for which the data is to be exported. 

  • from: timestamp that indicates the beginning of the duration for which data is to be retrieved.
  • to: timestamp that indicates the end of the duration for which data is to be retrieved. 

Note: Currently, the total duration cannot exceed one week. 

No

Sample Request

{
  "filters": {
    "from": "2024-07-12T07:32:58.611Z",
    "to": "2024-07-18T07:32:58.611Z"
  }
}

Sample Response

{
   "_id": "fj-c18261fa-75c8-5bd9-8c18-2b9f8bbc28a2",
   "hidden": false,
   "read": false,
   "status": "INPROGRESS",
   "percentageDone": 0,
   "title": "Exporting Analytics Data - JSON",
   "message": "Exporting Analytics Data - JSON",
   "lMod": "2024-07-18T11:11:22.000Z",
   "startedAt": "2024-07-18T11:11:22.600Z",
   "timedOut": false,
   "jobType": "DATA_EXPORT",
   "streamId": "st-628ade91-3522-5516-8d4c-b475556adfca",
   "searchIndexId": "sidx-bd7314c5-4cac-5261-a9eb-9b4f1b1026f1",
   "fileInfo": {
       "ext": "json"
   },
   "createdBy": "u-088b4f05-31b4-56d9-b59d-70d863a07f5f",
   "directoryInfo": null,
   "opType": "Manual",
   "extractionSourceId": null,
   "contentId": [],
   "error": [],
   "parentJobId": null,
   "createdOn": "2024-07-18T11:11:22.604Z",
   "__v": 0
}

Analytics APIs

Get Analytics API

This API can be used to fetch analytics data generated by the SearchAssist application. You can apply filters to fetch specific reports.

Method POST
Endpoint <host_url>/searchassistapi/external/stream/<streamId>/analytics
Content-Type application/json
Auth <JWT Token>
API Scope     Analytics

Query Parameters

Parameters Description Mandatory
streamId Provide your application ID here.  Yes
indexPipelineId The index configuration Id No. When not provided, default index configuration is used.
Offset Number of records to skip while fetching the response.  No. When not provided, the default value of 0 is used. 
Limit This is the number of records to be fetched as response to the API call, starting with a record after the skip count. No. When not provided, the default value of 50 is used.

Request Parameters

Parameters Description Mandatory
type This field can take the following values:

  • MostSearchedQuries
  • TopQuriesWithNoResults
  • QueriesWithNoClicks
  • SearchHistogram
  • UsersChart
  • UsersBusyChart
  • QueriesWithNoResults
  • QueriesWithResults
  • SearchQueryResults
  • TopSearchResults
  • MostUsedDevices
  • MostUsedBrowsers
  • MostUsedGeoLocations
  • MostUsersSentiments
  • Results
  • SearchQueriesForResult
  • MostClickedPositions
  • FeedbackStats
  • TotalUsersStats
  • TotalSearchesStats
  • QueriesWithAnswers
  • QueriesWithNoAnswers

You can also fetch data grouped by user identities using the following types:

  • QueriesWithResultsGroupedByUser
  • QueriesWithNoResultsGroupedByUser
  • QueriesWithAnswersGroupedByUser
  • QueriesWithNoAnswersGroupedByUser
  • SearchQueriesForResultGroupedByUser
Yes
group This field can take the following values:

  • hour
  • date
  • week
No
filters This field can be used to provide the time frame for which the data is to be generated. 

  • from: timestamp that indicates the beginning of the time duration for which data is to be retrieved.
  • to: timestamp that indicates the end of the time duration for which data is to be retrieved. 
No

Sample Request

{
  "type": "QueriesWithResults",
  "group": "hour",
  "filters": {
    "from": "2024-01-01T11:48:34.404Z",
    "to": "2024-01-05T11:48:34.404Z"
  }
}

Export Analytics API

This API is used to export analytics information to a file. It creates a job of type ‘DATA_EXPORT’ to export the data. To download the file, use the job id and get the URL of the file with exported data using the Job APIs.

Currently, this API limits data export to a maximum duration of a week. If the duration is more than a week, an error is thrown. 

Method POST
Endpoint <host_url>/searchassistapi/external/stream/<stream-id>/analytics/export
Content-Type application/json
Authorization auth: <JWT Token>
API Scope Analytics

Query Parameters

Parameters Description Mandatory
Stream ID Provide your application ID here.  Yes

Request Parameters

Parameters Description Mandatory
filters

This field indicates the time frame for which the data is to be exported. 

  • from: timestamp that indicates the beginning of the duration for which data is to be retrieved.
  • to: timestamp that indicates the end of the duration for which data is to be retrieved. 

Note: Currently, the total duration cannot exceed one week. 

No

Sample Request

{
  "filters": {
    "from": "2024-07-12T07:32:58.611Z",
    "to": "2024-07-18T07:32:58.611Z"
  }
}

Sample Response

{
   "_id": "fj-c18261fa-75c8-5bd9-8c18-2b9f8bbc28a2",
   "hidden": false,
   "read": false,
   "status": "INPROGRESS",
   "percentageDone": 0,
   "title": "Exporting Analytics Data - JSON",
   "message": "Exporting Analytics Data - JSON",
   "lMod": "2024-07-18T11:11:22.000Z",
   "startedAt": "2024-07-18T11:11:22.600Z",
   "timedOut": false,
   "jobType": "DATA_EXPORT",
   "streamId": "st-628ade91-3522-5516-8d4c-b475556adfca",
   "searchIndexId": "sidx-bd7314c5-4cac-5261-a9eb-9b4f1b1026f1",
   "fileInfo": {
       "ext": "json"
   },
   "createdBy": "u-088b4f05-31b4-56d9-b59d-70d863a07f5f",
   "directoryInfo": null,
   "opType": "Manual",
   "extractionSourceId": null,
   "contentId": [],
   "error": [],
   "parentJobId": null,
   "createdOn": "2024-07-18T11:11:22.604Z",
   "__v": 0
}