Interface SearchEventsRequest.Builder
- All Superinterfaces:
AwsRequest.Builder,Buildable,CopyableBuilder<SearchEventsRequest.Builder,,SearchEventsRequest> OpenSearchMemoryRequest.Builder,SdkBuilder<SearchEventsRequest.Builder,,SearchEventsRequest> SdkPojo,SdkRequest.Builder
- Enclosing class:
SearchEventsRequest
-
Method Summary
Modifier and TypeMethodDescriptionThe actor whose events to search (exact match).maxResults(Integer maxResults) The maximum number of events to return, from 1 to 100.The token for the next set of results.overrideConfiguration(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer) Add an optional request override configuration.overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) Add an optional request override configuration.The query: a subset of the OpenSearch Query DSL (seeSearchQuery), validated by the same rules as onSearchMemories.sessionIds(String... sessionIds) Returns only events from one of these sessions (exact match).sessionIds(Collection<String> sessionIds) Returns only events from one of these sessions (exact match).The sort order (seeSearchSort).The space whose events to search.Methods inherited from interface software.amazon.awssdk.awscore.AwsRequest.Builder
overrideConfigurationMethods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copyMethods inherited from interface software.amazon.awssdk.services.opensearchmemory.model.OpenSearchMemoryRequest.Builder
buildMethods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, buildMethods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
Method Details
-
spaceId
The space whose events to search. Use
actorIdandsessionIdsto narrow the search within it.- Parameters:
spaceId- The space whose events to search. UseactorIdandsessionIdsto narrow the search within it.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
actorId
The actor whose events to search (exact match). Required: every search covers exactly one actor, and an event stored without an actor is never returned. Narrow the search further with
sessionIds, combined by AND. This is the only way to filter by actor: a query that referencessystem_metadata.actor_idfails withValidationException(reasonnonFilterableField).- Parameters:
actorId- The actor whose events to search (exact match). Required: every search covers exactly one actor, and an event stored without an actor is never returned. Narrow the search further withsessionIds, combined by AND. This is the only way to filter by actor: a query that referencessystem_metadata.actor_idfails withValidationException(reasonnonFilterableField).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
sessionIds
Returns only events from one of these sessions (exact match). Combined with
actorIdby AND. Omit for no session filter. An empty list fails validation. An event stored without a session never matches a session filter. This is the only way to filter by session: a query that referencessystem_metadata.session_idfails withValidationException(reasonnonFilterableField).- Parameters:
sessionIds- Returns only events from one of these sessions (exact match). Combined withactorIdby AND. Omit for no session filter. An empty list fails validation. An event stored without a session never matches a session filter. This is the only way to filter by session: a query that referencessystem_metadata.session_idfails withValidationException(reasonnonFilterableField).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
sessionIds
Returns only events from one of these sessions (exact match). Combined with
actorIdby AND. Omit for no session filter. An empty list fails validation. An event stored without a session never matches a session filter. This is the only way to filter by session: a query that referencessystem_metadata.session_idfails withValidationException(reasonnonFilterableField).- Parameters:
sessionIds- Returns only events from one of these sessions (exact match). Combined withactorIdby AND. Omit for no session filter. An empty list fails validation. An event stored without a session never matches a session filter. This is the only way to filter by session: a query that referencessystem_metadata.session_idfails withValidationException(reasonnonFilterableField).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
query
The query: a subset of the OpenSearch Query DSL (see
SearchQuery), validated by the same rules as onSearchMemories. Query event text astextand embeddings asvector. A search covers both conversation turns and chunks of documents submitted as ablob. You can't use actor and session fields here. Use the top-levelactorIdandsessionIds.To search only the content of particular events, filter on
event_idswithtermorterms, for example with thesourceEventIdsthat aSearchMemoriesresult returns. Atermsclause onevent_idscan list up to 10 event IDs. More IDs fail withValidationException(reasonqueryBodyTooLarge). You can useevent_idsonly interm,terms, andexistsqueries.- Parameters:
query- The query: a subset of the OpenSearch Query DSL (seeSearchQuery), validated by the same rules as onSearchMemories. Query event text astextand embeddings asvector. A search covers both conversation turns and chunks of documents submitted as ablob. You can't use actor and session fields here. Use the top-levelactorIdandsessionIds.To search only the content of particular events, filter on
event_idswithtermorterms, for example with thesourceEventIdsthat aSearchMemoriesresult returns. Atermsclause onevent_idscan list up to 10 event IDs. More IDs fail withValidationException(reasonqueryBodyTooLarge). You can useevent_idsonly interm,terms, andexistsqueries.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
sort
The sort order (see
SearchSort). Omit to return the most relevant events first.- Parameters:
sort- The sort order (seeSearchSort). Omit to return the most relevant events first.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
maxResults
The maximum number of events to return, from 1 to 100. The default is 20.
- Parameters:
maxResults- The maximum number of events to return, from 1 to 100. The default is 20.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
nextToken
The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
- Parameters:
nextToken- The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
overrideConfiguration
SearchEventsRequest.Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration) Description copied from interface:AwsRequest.BuilderAdd an optional request override configuration.- Specified by:
overrideConfigurationin interfaceAwsRequest.Builder- Parameters:
overrideConfiguration- The override configuration.- Returns:
- This object for method chaining.
-
overrideConfiguration
SearchEventsRequest.Builder overrideConfiguration(Consumer<AwsRequestOverrideConfiguration.Builder> builderConsumer) Description copied from interface:AwsRequest.BuilderAdd an optional request override configuration.- Specified by:
overrideConfigurationin interfaceAwsRequest.Builder- Parameters:
builderConsumer- AConsumerto which an emptyAwsRequestOverrideConfiguration.Builderwill be given.- Returns:
- This object for method chaining.
-