Struct google_api_proto::google::cloud::dialogflow::v2beta1::participants_client::ParticipantsClient
source · pub struct ParticipantsClient<T> { /* private fields */ }
Expand description
Service for managing [Participants][google.cloud.dialogflow.v2beta1.Participant].
Implementations§
source§impl<T> ParticipantsClient<T>where
T: GrpcService<BoxBody>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
impl<T> ParticipantsClient<T>where
T: GrpcService<BoxBody>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
pub fn new(inner: T) -> Self
pub fn with_origin(inner: T, origin: Uri) -> Self
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> ParticipantsClient<InterceptedService<T, F>>where
F: Interceptor,
T::ResponseBody: Default,
T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>,
<T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,
sourcepub fn send_compressed(self, encoding: CompressionEncoding) -> Self
pub fn send_compressed(self, encoding: CompressionEncoding) -> Self
Compress requests with the given encoding.
This requires the server to support it otherwise it might respond with an error.
sourcepub fn accept_compressed(self, encoding: CompressionEncoding) -> Self
pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self
Enable decompressing responses.
sourcepub fn max_decoding_message_size(self, limit: usize) -> Self
pub fn max_decoding_message_size(self, limit: usize) -> Self
Limits the maximum size of a decoded message.
Default: 4MB
sourcepub fn max_encoding_message_size(self, limit: usize) -> Self
pub fn max_encoding_message_size(self, limit: usize) -> Self
Limits the maximum size of an encoded message.
Default: usize::MAX
sourcepub async fn create_participant(
&mut self,
request: impl IntoRequest<CreateParticipantRequest>,
) -> Result<Response<Participant>, Status>
pub async fn create_participant( &mut self, request: impl IntoRequest<CreateParticipantRequest>, ) -> Result<Response<Participant>, Status>
Creates a new participant in a conversation.
sourcepub async fn get_participant(
&mut self,
request: impl IntoRequest<GetParticipantRequest>,
) -> Result<Response<Participant>, Status>
pub async fn get_participant( &mut self, request: impl IntoRequest<GetParticipantRequest>, ) -> Result<Response<Participant>, Status>
Retrieves a conversation participant.
sourcepub async fn list_participants(
&mut self,
request: impl IntoRequest<ListParticipantsRequest>,
) -> Result<Response<ListParticipantsResponse>, Status>
pub async fn list_participants( &mut self, request: impl IntoRequest<ListParticipantsRequest>, ) -> Result<Response<ListParticipantsResponse>, Status>
Returns the list of all participants in the specified conversation.
sourcepub async fn update_participant(
&mut self,
request: impl IntoRequest<UpdateParticipantRequest>,
) -> Result<Response<Participant>, Status>
pub async fn update_participant( &mut self, request: impl IntoRequest<UpdateParticipantRequest>, ) -> Result<Response<Participant>, Status>
Updates the specified participant.
sourcepub async fn analyze_content(
&mut self,
request: impl IntoRequest<AnalyzeContentRequest>,
) -> Result<Response<AnalyzeContentResponse>, Status>
pub async fn analyze_content( &mut self, request: impl IntoRequest<AnalyzeContentRequest>, ) -> Result<Response<AnalyzeContentResponse>, Status>
Adds a text (chat, for example), or audio (phone recording, for example) message from a participant into the conversation.
Note: Always use agent versions for production traffic sent to virtual agents. See Versions and environments.
sourcepub async fn streaming_analyze_content(
&mut self,
request: impl IntoStreamingRequest<Message = StreamingAnalyzeContentRequest>,
) -> Result<Response<Streaming<StreamingAnalyzeContentResponse>>, Status>
pub async fn streaming_analyze_content( &mut self, request: impl IntoStreamingRequest<Message = StreamingAnalyzeContentRequest>, ) -> Result<Response<Streaming<StreamingAnalyzeContentResponse>>, Status>
Adds a text (e.g., chat) or audio (e.g., phone recording) message from a participant into the conversation. Note: This method is only available through the gRPC API (not REST).
The top-level message sent to the client by the server is
StreamingAnalyzeContentResponse
. Multiple response messages can be
returned in order. The first one or more messages contain the
recognition_result
field. Each result represents a more complete
transcript of what the user said. The next message contains the
reply_text
field, and potentially the reply_audio
and/or the
automated_agent_reply
fields.
Note: Always use agent versions for production traffic sent to virtual agents. See Versions and environments.
sourcepub async fn suggest_articles(
&mut self,
request: impl IntoRequest<SuggestArticlesRequest>,
) -> Result<Response<SuggestArticlesResponse>, Status>
pub async fn suggest_articles( &mut self, request: impl IntoRequest<SuggestArticlesRequest>, ) -> Result<Response<SuggestArticlesResponse>, Status>
Gets suggested articles for a participant based on specific historical messages.
Note that [ListSuggestions][google.cloud.dialogflow.v2beta1.Participants.ListSuggestions] will only list the auto-generated suggestions, while [CompileSuggestion][google.cloud.dialogflow.v2beta1.Participants.CompileSuggestion] will try to compile suggestion based on the provided conversation context in the real time.
sourcepub async fn suggest_faq_answers(
&mut self,
request: impl IntoRequest<SuggestFaqAnswersRequest>,
) -> Result<Response<SuggestFaqAnswersResponse>, Status>
pub async fn suggest_faq_answers( &mut self, request: impl IntoRequest<SuggestFaqAnswersRequest>, ) -> Result<Response<SuggestFaqAnswersResponse>, Status>
Gets suggested faq answers for a participant based on specific historical messages.
sourcepub async fn suggest_smart_replies(
&mut self,
request: impl IntoRequest<SuggestSmartRepliesRequest>,
) -> Result<Response<SuggestSmartRepliesResponse>, Status>
pub async fn suggest_smart_replies( &mut self, request: impl IntoRequest<SuggestSmartRepliesRequest>, ) -> Result<Response<SuggestSmartRepliesResponse>, Status>
Gets smart replies for a participant based on specific historical messages.
sourcepub async fn suggest_knowledge_assist(
&mut self,
request: impl IntoRequest<SuggestKnowledgeAssistRequest>,
) -> Result<Response<SuggestKnowledgeAssistResponse>, Status>
pub async fn suggest_knowledge_assist( &mut self, request: impl IntoRequest<SuggestKnowledgeAssistRequest>, ) -> Result<Response<SuggestKnowledgeAssistResponse>, Status>
Gets knowledge assist suggestions based on historical messages.
sourcepub async fn list_suggestions(
&mut self,
request: impl IntoRequest<ListSuggestionsRequest>,
) -> Result<Response<ListSuggestionsResponse>, Status>
pub async fn list_suggestions( &mut self, request: impl IntoRequest<ListSuggestionsRequest>, ) -> Result<Response<ListSuggestionsResponse>, Status>
Deprecated: Use inline suggestion, event based suggestion or Suggestion* API instead. See [HumanAgentAssistantConfig.name][google.cloud.dialogflow.v2beta1.HumanAgentAssistantConfig.name] for more details. Removal Date: 2020-09-01.
Retrieves suggestions for live agents.
This method should be used by human agent client software to fetch auto
generated suggestions in real-time, while the conversation with an end user
is in progress. The functionality is implemented in terms of the
list
pagination
design pattern. The client app should use the next_page_token
field
to fetch the next batch of suggestions. suggestions
are sorted by
create_time
in descending order.
To fetch latest suggestion, just set page_size
to 1.
To fetch new suggestions without duplication, send request with filter
create_time_epoch_microseconds > [first item's create_time of previous request]
and empty page_token.
sourcepub async fn compile_suggestion(
&mut self,
request: impl IntoRequest<CompileSuggestionRequest>,
) -> Result<Response<CompileSuggestionResponse>, Status>
pub async fn compile_suggestion( &mut self, request: impl IntoRequest<CompileSuggestionRequest>, ) -> Result<Response<CompileSuggestionResponse>, Status>
Deprecated. use [SuggestArticles][google.cloud.dialogflow.v2beta1.Participants.SuggestArticles] and [SuggestFaqAnswers][google.cloud.dialogflow.v2beta1.Participants.SuggestFaqAnswers] instead.
Gets suggestions for a participant based on specific historical messages.
Note that [ListSuggestions][google.cloud.dialogflow.v2beta1.Participants.ListSuggestions] will only list the auto-generated suggestions, while [CompileSuggestion][google.cloud.dialogflow.v2beta1.Participants.CompileSuggestion] will try to compile suggestion based on the provided conversation context in the real time.
Trait Implementations§
source§impl<T: Clone> Clone for ParticipantsClient<T>
impl<T: Clone> Clone for ParticipantsClient<T>
source§fn clone(&self) -> ParticipantsClient<T>
fn clone(&self) -> ParticipantsClient<T>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl<T> !Freeze for ParticipantsClient<T>
impl<T> RefUnwindSafe for ParticipantsClient<T>where
T: RefUnwindSafe,
impl<T> Send for ParticipantsClient<T>where
T: Send,
impl<T> Sync for ParticipantsClient<T>where
T: Sync,
impl<T> Unpin for ParticipantsClient<T>where
T: Unpin,
impl<T> UnwindSafe for ParticipantsClient<T>where
T: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request