Search
The SearchWrapper
class provides methods to perform searches.
Methods
Make a search request
Description: This method performs a search across a specific index based on the provided parameters and returns a paginated iterator of search results.
If you wish to use images as queries, ensure that your images meet the following requirements:
- Format: JPEG and PNG.
- Dimension: Must be at least 64 x 64 pixels.
- Size: Must not exceed 5MB.
If you wish to use images as queries, ensure that your images meet the following requirements:
- Format: JPEG and PNG.
- Dimension: Must be at least 64 x 64 pixels.
- Size: Must not exceed 5MB.
If you wish to use images as queries, ensure that your images meet the following requirements:
- Format: JPEG and PNG.
- Dimension: Must be at least 64 x 64 pixels.
- Size: Must not exceed 5MB.
If you wish to use images as queries, ensure that your images meet the following requirements:
- Format: JPEG and PNG.
- Dimension: Must be at least 64 x 64 pixels.
- Size: Must not exceed 5MB.
Function signature and example:
Parameters:
The SearchCreateRequest
interface defines the parameters for performing a search:
Return value: Return value: Returns a Promise
that resolves to a Page<SearchItem>
object that implements AsyncIterable
, allowing you to iterate through the paginated search results.
The Page
class contains the following properties and methods:
The SearchItem
interface contains the following properties:
The SearchItemClipsItem
interface contains the following properties:
API Reference: Any-to-video search.
Related guides:
Error codes
This section lists the most common error messages you may encounter while performing search requests.
search_option_not_supported
- Search option
{search_option}
is not supported for index{index_id}
. Please use one of the following search options:{supported_search_option}
.
- Search option
search_option_combination_not_supported
- Search option
{search_option}
is not supported with{other_combination}
.
- Search option
search_filter_invalid
- Filter used in search is invalid. Please use the valid filter syntax by following filtering documentation.
search_page_token_expired
- The token that identifies the page to be retrieved is expired or invalid. You must make a new search request. Token:
{next_page_token}
.
- The token that identifies the page to be retrieved is expired or invalid. You must make a new search request. Token:
index_not_supported_for_search
:- You can only perform search requests on indexes with an engine from the Marengo family enabled.