searchEntries method
Searches for Entries matching the given query and scope.
Request parameters:
name - Required. The project to which the request should be attributed
in the following form: projects/{project}/locations/global.
Value must have pattern ^projects/\[^/\]+/locations/\[^/\]+$.
contexts - Optional. Specifies the scope of the context in which the
search will be performed. This scope will also be used to perform IAM
checks, which if passing, will return all resources in the scope.
orderBy - Optional. Specifies the ordering of results. Supported values
are: relevance last_modified_timestamp last_modified_timestamp asc
pageSize - Optional. Number of results in the search page. If <=0, then
defaults to 10. Max limit for page_size is 1000. Throws an invalid
argument for page_size > 1000.
pageToken - Optional. Page token received from a previous SearchEntries
call. Provide this to retrieve the subsequent page.
query - Required. The query against which entries in scope should be
matched. The query syntax is defined in Search syntax for Dataplex
Universal Catalog (https://cloud.google.com/dataplex/docs/search-syntax).
scope - Optional. The scope under which the search should be operating.
It must either be organizations/ or projects/. If it is unspecified, it
defaults to the organization where the project provided in name is
located.
semanticSearch - Optional. Specifies whether the search should
understand the meaning and intent behind the query, rather than just
matching keywords.
$fields - Selector specifying which fields to include in a partial
response.
Completes with a GoogleCloudDataplexV1SearchEntriesResponse.
Completes with a commons.ApiRequestError if the API endpoint returned an error.
If the used http.Client completes with an error when making a REST call,
this method will complete with the same error.
Implementation
async.Future<GoogleCloudDataplexV1SearchEntriesResponse> searchEntries(
core.String name, {
core.List<core.String>? contexts,
core.String? orderBy,
core.int? pageSize,
core.String? pageToken,
core.String? query,
core.String? scope,
core.bool? semanticSearch,
core.String? $fields,
}) async {
final queryParams_ = <core.String, core.List<core.String>>{
'contexts': ?contexts,
'orderBy': ?orderBy == null ? null : [orderBy],
'pageSize': ?pageSize == null ? null : ['${pageSize}'],
'pageToken': ?pageToken == null ? null : [pageToken],
'query': ?query == null ? null : [query],
'scope': ?scope == null ? null : [scope],
'semanticSearch': ?semanticSearch == null ? null : ['${semanticSearch}'],
'fields': ?$fields == null ? null : [$fields],
};
final url_ = 'v1/' + core.Uri.encodeFull('$name') + ':searchEntries';
final response_ = await _requester.request(
url_,
'POST',
queryParams: queryParams_,
);
return GoogleCloudDataplexV1SearchEntriesResponse.fromJson(
response_ as core.Map<core.String, core.dynamic>,
);
}