#[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
pub fn new() -> Self
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 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more