Skip to main content
Version: Latest

search

Enterprise
description

Returns documents according to the given search filters. For search-specific errors see SearchErrors enum.

The exact number of results is not guaranteed. The maximum number is determined by the "limit" argument, but you can get less than that and even 0 result on the page, but still more results available on the next pages. Please, use SearchResponse.cursor to check if there are more results available 'with caution!'.

If you normally have access to 5 years of data and you'd like to use the "filter.date.customRange" filter, you will be able to search for user-content even if it is older than 5 years. To achieve that, you first need to restrict "filter.types.ids" to only user-content. You could specify e.g. ids: ["1060"], which means you are requesting all types of user-content. Alternatively, you could specify some of the user-content child ids (values 1061-1067). For example, ids: ["1061", "1062"] would provide only user-content of subtypes "Emailed In" and "Uploads".

search(
filter: SearchFilter
limit: Int = 10
cursor: String
sorting: SearchSorting
): SearchResponse

Arguments

search.filter ● SearchFilter input

search.limit ● Int scalar

Limits the number of results. The maximum limit is 100.

search.cursor ● String scalar

Pagination is cursor based. To get a next page of results, provide a cursor form a previous response. When using a cursor, make sure the supplied filters stay the same as in the initial request, otherwise the results may be unpredictable. If you don't get a cursor in a response, it means there are no more results.

search.sorting ● SearchSorting input

Sets sorting order for search results

Type

SearchResponse object

Loading...