The Search Terms Report Services API provides functionality for generating a search terms report, adding terms to an existing search terms report, retrying any errors, and viewing the build progress of a specific search terms report.
Search terms reports provide the ability to identify documents containing specific keywords or terms. You can enter multiple terms and generate a report listing the number of hits for each term in a document. To run a search terms report, you must select an active dtSearch index with the terms you wish to search added. To learn more, visit
The following sample use cases illustrate how you can use this service with a search terms report:
Run terms against a new search terms report.
Refresh a search terms report when document results have changed.
Run additional terms on an existing search terms report.
Retry any errors from a previous run of this API.
Get the progress of any running terms in a search terms report.
In addition, you can use the Search Terms Report API through the REST API. For more information, see Search Terms Report Services in REST.
This page contains the following information:
The Relativity.SearchTermsReport.Interfaces namespace contains the methods, classes, and enumerations required to run search terms reports and perform other related tasks. It includes the following interface that you can use to access the services for search terms reports:
The Search Terms Report Services API exposes the following methods on the ISearchTermsReportManager interface in the Relativity.SearchTermsReport.Interfaces namespace:
The following list contains some of the key classes available in the Relativity.Imaging.Services.Interfaces namespace:
In addition, this namespace contains multiple enumerations used for setting properties on search terms report job types. For a complete list of classes and enumerations see Search Terms Report API on the Relativity API reference page.
Complete the following prerequisite to begin development with the Search Terms Report Services API:
Download the Search Terms Report Nuget Package.
This method queues a Run All Terms job for the specified search terms report. This generates counts for each term and can be used the first time you generate a report or to regenerate the count for a report that has already been run.
The following code sample illustrates how to call the RunAllTerms() method by passing the artifact IDs of a workspace and search terms report.
public async System.Threading.Tasks.Task RunAllTerms(Relativity.API.IHelper helper, int workspaceID, int searchTermsReportID) { using (var searchTermsReportManager = helper.GetServicesManager().CreateProxy<Relativity.SearchTermsReport.Interfaces.ISearchTermsReportManager>(Relativity.API.ExecutionIdentity.CurrentUser)) { await searchTermsReportManager.RunAllTerms(workspaceID, searchTermsReportID).ConfigureAwait(false); } }
This method queues a Run Pending Terms job for the specified search terms report. This allows you to add terms to the report by updating any terms that have a pending status.
The following code sample illustrates how to call the RunPendingTerms() method by passing the artifact IDs of a workspace and search terms report.
public async System.Threading.Tasks.Task RunPendingTerms(Relativity.API.IHelper helper, int workspaceID, int searchTermsReportID) { using (var searchTermsReportManager = helper.GetServicesManager().CreateProxy<Relativity.SearchTermsReport.Interfaces.ISearchTermsReportManager>(Relativity.API.ExecutionIdentity.CurrentUser)) { await searchTermsReportManager.RunPendingTerms(workspaceID, searchTermsReportID).ConfigureAwait(false); } }
This method queues a Retry Errors job for the specified search terms report. This attempts to regenerate the report for search terms that returned error messages.
The following code sample illustrates how to call the RetryErrors() method by passing the artifact IDs of a workspace and search terms report.
public async System.Threading.Tasks.Task RetryErrors(Relativity.API.IHelper helper, int workspaceID, int searchTermsReportID) { using (var searchTermsReportManager = helper.GetServicesManager().CreateProxy<Relativity.SearchTermsReport.Interfaces.ISearchTermsReportManager>(Relativity.API.ExecutionIdentity.CurrentUser)) { return searchTermsReportManager.RetryErrors(workspaceID, searchTermsReportID).ConfigureAwait(false); } }
This method allows you to view the build progress for the specified search terms report as well as some statistics about the report.
The following code sample illustrates how to call the GetProgress() method by passing the artifact IDs of a workspace and search terms report.
public async System.Threading.Tasks.Task<Relativity.SearchTermsReport.Interfaces.Models.ProgressResponse> GetProgress(Relativity.API.IHelper helper, int workspaceID, int searchTermsReportID) { using (var searchTermsReportManager = helper.GetServicesManager().CreateProxy<Relativity.SearchTermsReport.Interfaces.ISearchTermsReportManager>(Relativity.API.ExecutionIdentity.CurrentUser)) { return await searchTermsReportManager.GetProgress(workspaceID, searchTermsReportID).ConfigureAwait(false); } }
Community Updates |
|||
Aero Developer FAQ | Evolving the Platform | Most recent release notes | |
Learn more | Learn more | Learn more |
Additional Resources |
|||
![]() |
![]() |
||
Access Third-Party Tools with GitHub | Create .NET Apps Faster with NuGet | ||
Visit github | visit nuget |