Struct google_api_proto::google::cloud::dialogflow::v2::Conversation
source · pub struct Conversation {
pub name: String,
pub lifecycle_state: i32,
pub conversation_profile: String,
pub phone_number: Option<ConversationPhoneNumber>,
pub start_time: Option<Timestamp>,
pub end_time: Option<Timestamp>,
pub conversation_stage: i32,
}
Expand description
Represents a conversation. A conversation is an interaction between an agent, including live agents and Dialogflow agents, and a support customer. Conversations can include phone calls and text-based chat sessions.
Fields§
§name: String
Output only. Identifier. The unique identifier of this conversation.
Format: projects/<Project ID>/locations/<Location ID>/conversations/<Conversation ID>
.
lifecycle_state: i32
Output only. The current state of the Conversation.
conversation_profile: String
Required. The Conversation Profile to be used to configure this
Conversation. This field cannot be updated.
Format: projects/<Project ID>/locations/<Location ID>/conversationProfiles/<Conversation Profile ID>
.
phone_number: Option<ConversationPhoneNumber>
Output only. It will not be empty if the conversation is to be connected over telephony.
start_time: Option<Timestamp>
Output only. The time the conversation was started.
end_time: Option<Timestamp>
Output only. The time the conversation was finished.
conversation_stage: i32
Optional. The stage of a conversation. It indicates whether the virtual agent or a human agent is handling the conversation.
If the conversation is created with the conversation profile that has Dialogflow config set, defaults to [ConversationStage.VIRTUAL_AGENT_STAGE][google.cloud.dialogflow.v2.Conversation.ConversationStage.VIRTUAL_AGENT_STAGE]; Otherwise, defaults to [ConversationStage.HUMAN_ASSIST_STAGE][google.cloud.dialogflow.v2.Conversation.ConversationStage.HUMAN_ASSIST_STAGE].
If the conversation is created with the conversation profile that has Dialogflow config set but explicitly sets conversation_stage to [ConversationStage.HUMAN_ASSIST_STAGE][google.cloud.dialogflow.v2.Conversation.ConversationStage.HUMAN_ASSIST_STAGE], it skips [ConversationStage.VIRTUAL_AGENT_STAGE][google.cloud.dialogflow.v2.Conversation.ConversationStage.VIRTUAL_AGENT_STAGE] stage and directly goes to [ConversationStage.HUMAN_ASSIST_STAGE][google.cloud.dialogflow.v2.Conversation.ConversationStage.HUMAN_ASSIST_STAGE].
Implementations§
source§impl Conversation
impl Conversation
sourcepub fn lifecycle_state(&self) -> LifecycleState
pub fn lifecycle_state(&self) -> LifecycleState
Returns the enum value of lifecycle_state
, or the default if the field is set to an invalid enum value.
sourcepub fn set_lifecycle_state(&mut self, value: LifecycleState)
pub fn set_lifecycle_state(&mut self, value: LifecycleState)
Sets lifecycle_state
to the provided enum value.
sourcepub fn conversation_stage(&self) -> ConversationStage
pub fn conversation_stage(&self) -> ConversationStage
Returns the enum value of conversation_stage
, or the default if the field is set to an invalid enum value.
sourcepub fn set_conversation_stage(&mut self, value: ConversationStage)
pub fn set_conversation_stage(&mut self, value: ConversationStage)
Sets conversation_stage
to the provided enum value.
Trait Implementations§
source§impl Clone for Conversation
impl Clone for Conversation
source§fn clone(&self) -> Conversation
fn clone(&self) -> Conversation
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for Conversation
impl Debug for Conversation
source§impl Default for Conversation
impl Default for Conversation
source§impl Message for Conversation
impl Message for Conversation
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for Conversation
impl PartialEq for Conversation
source§fn eq(&self, other: &Conversation) -> bool
fn eq(&self, other: &Conversation) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for Conversation
Auto Trait Implementations§
impl Freeze for Conversation
impl RefUnwindSafe for Conversation
impl Send for Conversation
impl Sync for Conversation
impl Unpin for Conversation
impl UnwindSafe for Conversation
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