#[non_exhaustive]pub struct AutomatedAgentConfig {
pub agent: String,
pub session_ttl: Option<Duration>,
/* private fields */
}conversation-profiles or conversations only.Expand description
Defines the Automated Agent to connect to a conversation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.agent: StringRequired. ID of the Dialogflow agent environment to use.
This project needs to either be the same project as the conversation or you
need to grant service-<Conversation Project Number>@gcp-sa-dialogflow.iam.gserviceaccount.com the Dialogflow API Service Agent role in this project.
-
For ES agents, use format:
projects/<Project ID>/locations/<Location ID>/agent/environments/<Environment ID or '-'>. If environment is not specified, the defaultdraftenvironment is used. Refer to DetectIntentRequest for more details. -
For CX agents, use format
projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment ID or '-'>. If environment is not specified, the defaultdraftenvironment is used.
session_ttl: Option<Duration>Optional. Configure lifetime of the Dialogflow session. By default, a Dialogflow CX session remains active and its data is stored for 30 minutes after the last request is sent for the session. This value should be no longer than 1 day.
Implementations§
Source§impl AutomatedAgentConfig
impl AutomatedAgentConfig
Sourcepub fn set_session_ttl<T>(self, v: T) -> Self
pub fn set_session_ttl<T>(self, v: T) -> Self
Sets the value of session_ttl.
§Example
use wkt::Duration;
let x = AutomatedAgentConfig::new().set_session_ttl(Duration::default()/* use setters */);Sourcepub fn set_or_clear_session_ttl<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_session_ttl<T>(self, v: Option<T>) -> Self
Sets or clears the value of session_ttl.
§Example
use wkt::Duration;
let x = AutomatedAgentConfig::new().set_or_clear_session_ttl(Some(Duration::default()/* use setters */));
let x = AutomatedAgentConfig::new().set_or_clear_session_ttl(None::<Duration>);Trait Implementations§
Source§impl Clone for AutomatedAgentConfig
impl Clone for AutomatedAgentConfig
Source§fn clone(&self) -> AutomatedAgentConfig
fn clone(&self) -> AutomatedAgentConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AutomatedAgentConfig
impl Debug for AutomatedAgentConfig
Source§impl Default for AutomatedAgentConfig
impl Default for AutomatedAgentConfig
Source§fn default() -> AutomatedAgentConfig
fn default() -> AutomatedAgentConfig
Source§impl Message for AutomatedAgentConfig
impl Message for AutomatedAgentConfig
Source§impl PartialEq for AutomatedAgentConfig
impl PartialEq for AutomatedAgentConfig
impl StructuralPartialEq for AutomatedAgentConfig
Auto Trait Implementations§
impl Freeze for AutomatedAgentConfig
impl RefUnwindSafe for AutomatedAgentConfig
impl Send for AutomatedAgentConfig
impl Sync for AutomatedAgentConfig
impl Unpin for AutomatedAgentConfig
impl UnsafeUnpin for AutomatedAgentConfig
impl UnwindSafe for AutomatedAgentConfig
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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