describeSearch method
Returns the current status and metadata of a single search, including the
query that was submitted, the search type, and — when the search has
failed — the reason. Use this to poll a search started with
StartSearch until it reaches a terminal status
(SUCCEEDED or FAILED).
May throw AccessDeniedException.
May throw InternalFailureException.
May throw InvalidRequestException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
Parameter searchId :
The identifier of the search to describe.
Parameter workspaceName :
The name of the workspace the search belongs to.
Implementation
Future<DescribeSearchResponse> describeSearch({
required String searchId,
required String workspaceName,
}) async {
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri:
'/workspaces/${Uri.encodeComponent(workspaceName)}/searches/${Uri.encodeComponent(searchId)}',
hostPrefix: 'data.',
exceptionFnMap: _exceptionFns,
);
return DescribeSearchResponse.fromJson(response);
}