Skip to content

search_sample_queries

Operation

search_sample_queries

search_sample_queries(request: SearchSampleQueriesInput | SearchSampleQueriesInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[SearchSampleQueriesInputDict]) -> SearchSampleQueriesOutput
Warning

CloudTrail Lake will no longer be open to new customers starting May 31, 2026. If you would like to use CloudTrail Lake, sign up prior to that date. Existing customers can continue to use the service as normal. For more information, see CloudTrail Lake availability change.

Searches sample queries and returns a list of sample queries that are sorted by relevance. To search for sample queries, provide a natural language SearchPhrase in English.

Parameters:

Name Type Description Default
request SearchSampleQueriesInput | SearchSampleQueriesInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[SearchSampleQueriesInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
SearchSampleQueriesOutput

An instance of SearchSampleQueriesOutput.

search_sample_queries async

search_sample_queries(request: SearchSampleQueriesInput | SearchSampleQueriesInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[SearchSampleQueriesInputDict]) -> SearchSampleQueriesOutput
Warning

CloudTrail Lake will no longer be open to new customers starting May 31, 2026. If you would like to use CloudTrail Lake, sign up prior to that date. Existing customers can continue to use the service as normal. For more information, see CloudTrail Lake availability change.

Searches sample queries and returns a list of sample queries that are sorted by relevance. To search for sample queries, provide a natural language SearchPhrase in English.

Parameters:

Name Type Description Default
request SearchSampleQueriesInput | SearchSampleQueriesInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[SearchSampleQueriesInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
SearchSampleQueriesOutput

An instance of SearchSampleQueriesOutput.

Input

Pass the input as keyword arguments, a positional dictionary, or a positional model object. Pass plugins separately as a keyword argument.

SearchSampleQueriesInputDict

Bases: TypedDict

Dictionary form of SearchSampleQueriesInput.

Attributes

max_results instance-attribute
max_results: int | None

The maximum number of results to return on a single page. The default value is 10.

next_token instance-attribute
next_token: str | None

A token you can use to get the next page of results. The length constraint is in characters, not words.

search_phrase instance-attribute
search_phrase: Required[str]

The natural language phrase to use for the semantic search. The phrase must be in English. The length constraint is in characters, not words.

SearchSampleQueriesInput dataclass

Bases: _SerdeShape

Dataclass for SearchSampleQueriesInput structure.

Attributes

max_results class-attribute instance-attribute
max_results: int | None = ...

The maximum number of results to return on a single page. The default value is 10.

next_token class-attribute instance-attribute
next_token: str | None = ...

A token you can use to get the next page of results. The length constraint is in characters, not words.

search_phrase class-attribute instance-attribute
search_phrase: str | None = ...

The natural language phrase to use for the semantic search. The phrase must be in English. The length constraint is in characters, not words.

Output

SearchSampleQueriesOutput dataclass

Bases: _SerdeShape

Dataclass for SearchSampleQueriesOutput structure.

Attributes

next_token class-attribute instance-attribute
next_token: str | None = ...

A token you can use to get the next page of results.

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.

search_results class-attribute instance-attribute
search_results: list[SearchSampleQueriesSearchResult] | None = ...

A list of objects containing the search results ordered from most relevant to least relevant.