aws_sdk_customerprofiles/operation/put_integration/_put_integration_output.rs
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct PutIntegrationOutput {
/// <p>The unique name of the domain.</p>
pub domain_name: ::std::string::String,
/// <p>The URI of the S3 bucket or any other type of data source.</p>
pub uri: ::std::string::String,
/// <p>The name of the profile object type.</p>
pub object_type_name: ::std::option::Option<::std::string::String>,
/// <p>The timestamp of when the domain was created.</p>
pub created_at: ::aws_smithy_types::DateTime,
/// <p>The timestamp of when the domain was most recently edited.</p>
pub last_updated_at: ::aws_smithy_types::DateTime,
/// <p>The tags used to organize, track, or control access for this resource.</p>
pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
/// <p>A map in which each key is an event type from an external application such as Segment or Shopify, and each value is an <code>ObjectTypeName</code> (template) used to ingest the event. It supports the following event types: <code>SegmentIdentify</code>, <code>ShopifyCreateCustomers</code>, <code>ShopifyUpdateCustomers</code>, <code>ShopifyCreateDraftOrders</code>, <code>ShopifyUpdateDraftOrders</code>, <code>ShopifyCreateOrders</code>, and <code>ShopifyUpdatedOrders</code>.</p>
pub object_type_names: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
/// <p>Unique identifier for the workflow.</p>
pub workflow_id: ::std::option::Option<::std::string::String>,
/// <p>Boolean that shows if the Flow that's associated with the Integration is created in Amazon Appflow, or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition.</p>
pub is_unstructured: ::std::option::Option<bool>,
/// <p>The Amazon Resource Name (ARN) of the IAM role. The Integration uses this role to make Customer Profiles requests on your behalf.</p>
pub role_arn: ::std::option::Option<::std::string::String>,
/// <p>A list of unique names for active event triggers associated with the integration. This list would be empty if no Event Trigger is associated with the integration.</p>
pub event_trigger_names: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
_request_id: Option<String>,
}
impl PutIntegrationOutput {
/// <p>The unique name of the domain.</p>
pub fn domain_name(&self) -> &str {
use std::ops::Deref;
self.domain_name.deref()
}
/// <p>The URI of the S3 bucket or any other type of data source.</p>
pub fn uri(&self) -> &str {
use std::ops::Deref;
self.uri.deref()
}
/// <p>The name of the profile object type.</p>
pub fn object_type_name(&self) -> ::std::option::Option<&str> {
self.object_type_name.as_deref()
}
/// <p>The timestamp of when the domain was created.</p>
pub fn created_at(&self) -> &::aws_smithy_types::DateTime {
&self.created_at
}
/// <p>The timestamp of when the domain was most recently edited.</p>
pub fn last_updated_at(&self) -> &::aws_smithy_types::DateTime {
&self.last_updated_at
}
/// <p>The tags used to organize, track, or control access for this resource.</p>
pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
self.tags.as_ref()
}
/// <p>A map in which each key is an event type from an external application such as Segment or Shopify, and each value is an <code>ObjectTypeName</code> (template) used to ingest the event. It supports the following event types: <code>SegmentIdentify</code>, <code>ShopifyCreateCustomers</code>, <code>ShopifyUpdateCustomers</code>, <code>ShopifyCreateDraftOrders</code>, <code>ShopifyUpdateDraftOrders</code>, <code>ShopifyCreateOrders</code>, and <code>ShopifyUpdatedOrders</code>.</p>
pub fn object_type_names(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
self.object_type_names.as_ref()
}
/// <p>Unique identifier for the workflow.</p>
pub fn workflow_id(&self) -> ::std::option::Option<&str> {
self.workflow_id.as_deref()
}
/// <p>Boolean that shows if the Flow that's associated with the Integration is created in Amazon Appflow, or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition.</p>
pub fn is_unstructured(&self) -> ::std::option::Option<bool> {
self.is_unstructured
}
/// <p>The Amazon Resource Name (ARN) of the IAM role. The Integration uses this role to make Customer Profiles requests on your behalf.</p>
pub fn role_arn(&self) -> ::std::option::Option<&str> {
self.role_arn.as_deref()
}
/// <p>A list of unique names for active event triggers associated with the integration. This list would be empty if no Event Trigger is associated with the integration.</p>
///
/// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.event_trigger_names.is_none()`.
pub fn event_trigger_names(&self) -> &[::std::string::String] {
self.event_trigger_names.as_deref().unwrap_or_default()
}
}
impl ::aws_types::request_id::RequestId for PutIntegrationOutput {
fn request_id(&self) -> Option<&str> {
self._request_id.as_deref()
}
}
impl PutIntegrationOutput {
/// Creates a new builder-style object to manufacture [`PutIntegrationOutput`](crate::operation::put_integration::PutIntegrationOutput).
pub fn builder() -> crate::operation::put_integration::builders::PutIntegrationOutputBuilder {
crate::operation::put_integration::builders::PutIntegrationOutputBuilder::default()
}
}
/// A builder for [`PutIntegrationOutput`](crate::operation::put_integration::PutIntegrationOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct PutIntegrationOutputBuilder {
pub(crate) domain_name: ::std::option::Option<::std::string::String>,
pub(crate) uri: ::std::option::Option<::std::string::String>,
pub(crate) object_type_name: ::std::option::Option<::std::string::String>,
pub(crate) created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) last_updated_at: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
pub(crate) object_type_names: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
pub(crate) workflow_id: ::std::option::Option<::std::string::String>,
pub(crate) is_unstructured: ::std::option::Option<bool>,
pub(crate) role_arn: ::std::option::Option<::std::string::String>,
pub(crate) event_trigger_names: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
_request_id: Option<String>,
}
impl PutIntegrationOutputBuilder {
/// <p>The unique name of the domain.</p>
/// This field is required.
pub fn domain_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.domain_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The unique name of the domain.</p>
pub fn set_domain_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.domain_name = input;
self
}
/// <p>The unique name of the domain.</p>
pub fn get_domain_name(&self) -> &::std::option::Option<::std::string::String> {
&self.domain_name
}
/// <p>The URI of the S3 bucket or any other type of data source.</p>
/// This field is required.
pub fn uri(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.uri = ::std::option::Option::Some(input.into());
self
}
/// <p>The URI of the S3 bucket or any other type of data source.</p>
pub fn set_uri(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.uri = input;
self
}
/// <p>The URI of the S3 bucket or any other type of data source.</p>
pub fn get_uri(&self) -> &::std::option::Option<::std::string::String> {
&self.uri
}
/// <p>The name of the profile object type.</p>
pub fn object_type_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.object_type_name = ::std::option::Option::Some(input.into());
self
}
/// <p>The name of the profile object type.</p>
pub fn set_object_type_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.object_type_name = input;
self
}
/// <p>The name of the profile object type.</p>
pub fn get_object_type_name(&self) -> &::std::option::Option<::std::string::String> {
&self.object_type_name
}
/// <p>The timestamp of when the domain was created.</p>
/// This field is required.
pub fn created_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.created_at = ::std::option::Option::Some(input);
self
}
/// <p>The timestamp of when the domain was created.</p>
pub fn set_created_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.created_at = input;
self
}
/// <p>The timestamp of when the domain was created.</p>
pub fn get_created_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.created_at
}
/// <p>The timestamp of when the domain was most recently edited.</p>
/// This field is required.
pub fn last_updated_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.last_updated_at = ::std::option::Option::Some(input);
self
}
/// <p>The timestamp of when the domain was most recently edited.</p>
pub fn set_last_updated_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.last_updated_at = input;
self
}
/// <p>The timestamp of when the domain was most recently edited.</p>
pub fn get_last_updated_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.last_updated_at
}
/// Adds a key-value pair to `tags`.
///
/// To override the contents of this collection use [`set_tags`](Self::set_tags).
///
/// <p>The tags used to organize, track, or control access for this resource.</p>
pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut hash_map = self.tags.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.tags = ::std::option::Option::Some(hash_map);
self
}
/// <p>The tags used to organize, track, or control access for this resource.</p>
pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
self.tags = input;
self
}
/// <p>The tags used to organize, track, or control access for this resource.</p>
pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
&self.tags
}
/// Adds a key-value pair to `object_type_names`.
///
/// To override the contents of this collection use [`set_object_type_names`](Self::set_object_type_names).
///
/// <p>A map in which each key is an event type from an external application such as Segment or Shopify, and each value is an <code>ObjectTypeName</code> (template) used to ingest the event. It supports the following event types: <code>SegmentIdentify</code>, <code>ShopifyCreateCustomers</code>, <code>ShopifyUpdateCustomers</code>, <code>ShopifyCreateDraftOrders</code>, <code>ShopifyUpdateDraftOrders</code>, <code>ShopifyCreateOrders</code>, and <code>ShopifyUpdatedOrders</code>.</p>
pub fn object_type_names(
mut self,
k: impl ::std::convert::Into<::std::string::String>,
v: impl ::std::convert::Into<::std::string::String>,
) -> Self {
let mut hash_map = self.object_type_names.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.object_type_names = ::std::option::Option::Some(hash_map);
self
}
/// <p>A map in which each key is an event type from an external application such as Segment or Shopify, and each value is an <code>ObjectTypeName</code> (template) used to ingest the event. It supports the following event types: <code>SegmentIdentify</code>, <code>ShopifyCreateCustomers</code>, <code>ShopifyUpdateCustomers</code>, <code>ShopifyCreateDraftOrders</code>, <code>ShopifyUpdateDraftOrders</code>, <code>ShopifyCreateOrders</code>, and <code>ShopifyUpdatedOrders</code>.</p>
pub fn set_object_type_names(
mut self,
input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
) -> Self {
self.object_type_names = input;
self
}
/// <p>A map in which each key is an event type from an external application such as Segment or Shopify, and each value is an <code>ObjectTypeName</code> (template) used to ingest the event. It supports the following event types: <code>SegmentIdentify</code>, <code>ShopifyCreateCustomers</code>, <code>ShopifyUpdateCustomers</code>, <code>ShopifyCreateDraftOrders</code>, <code>ShopifyUpdateDraftOrders</code>, <code>ShopifyCreateOrders</code>, and <code>ShopifyUpdatedOrders</code>.</p>
pub fn get_object_type_names(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
&self.object_type_names
}
/// <p>Unique identifier for the workflow.</p>
pub fn workflow_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.workflow_id = ::std::option::Option::Some(input.into());
self
}
/// <p>Unique identifier for the workflow.</p>
pub fn set_workflow_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.workflow_id = input;
self
}
/// <p>Unique identifier for the workflow.</p>
pub fn get_workflow_id(&self) -> &::std::option::Option<::std::string::String> {
&self.workflow_id
}
/// <p>Boolean that shows if the Flow that's associated with the Integration is created in Amazon Appflow, or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition.</p>
pub fn is_unstructured(mut self, input: bool) -> Self {
self.is_unstructured = ::std::option::Option::Some(input);
self
}
/// <p>Boolean that shows if the Flow that's associated with the Integration is created in Amazon Appflow, or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition.</p>
pub fn set_is_unstructured(mut self, input: ::std::option::Option<bool>) -> Self {
self.is_unstructured = input;
self
}
/// <p>Boolean that shows if the Flow that's associated with the Integration is created in Amazon Appflow, or with ObjectTypeName equals _unstructured via API/CLI in flowDefinition.</p>
pub fn get_is_unstructured(&self) -> &::std::option::Option<bool> {
&self.is_unstructured
}
/// <p>The Amazon Resource Name (ARN) of the IAM role. The Integration uses this role to make Customer Profiles requests on your behalf.</p>
pub fn role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.role_arn = ::std::option::Option::Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of the IAM role. The Integration uses this role to make Customer Profiles requests on your behalf.</p>
pub fn set_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.role_arn = input;
self
}
/// <p>The Amazon Resource Name (ARN) of the IAM role. The Integration uses this role to make Customer Profiles requests on your behalf.</p>
pub fn get_role_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.role_arn
}
/// Appends an item to `event_trigger_names`.
///
/// To override the contents of this collection use [`set_event_trigger_names`](Self::set_event_trigger_names).
///
/// <p>A list of unique names for active event triggers associated with the integration. This list would be empty if no Event Trigger is associated with the integration.</p>
pub fn event_trigger_names(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.event_trigger_names.unwrap_or_default();
v.push(input.into());
self.event_trigger_names = ::std::option::Option::Some(v);
self
}
/// <p>A list of unique names for active event triggers associated with the integration. This list would be empty if no Event Trigger is associated with the integration.</p>
pub fn set_event_trigger_names(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.event_trigger_names = input;
self
}
/// <p>A list of unique names for active event triggers associated with the integration. This list would be empty if no Event Trigger is associated with the integration.</p>
pub fn get_event_trigger_names(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.event_trigger_names
}
pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
self._request_id = Some(request_id.into());
self
}
pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
self._request_id = request_id;
self
}
/// Consumes the builder and constructs a [`PutIntegrationOutput`](crate::operation::put_integration::PutIntegrationOutput).
/// This method will fail if any of the following fields are not set:
/// - [`domain_name`](crate::operation::put_integration::builders::PutIntegrationOutputBuilder::domain_name)
/// - [`uri`](crate::operation::put_integration::builders::PutIntegrationOutputBuilder::uri)
/// - [`created_at`](crate::operation::put_integration::builders::PutIntegrationOutputBuilder::created_at)
/// - [`last_updated_at`](crate::operation::put_integration::builders::PutIntegrationOutputBuilder::last_updated_at)
pub fn build(
self,
) -> ::std::result::Result<crate::operation::put_integration::PutIntegrationOutput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::put_integration::PutIntegrationOutput {
domain_name: self.domain_name.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"domain_name",
"domain_name was not specified but it is required when building PutIntegrationOutput",
)
})?,
uri: self.uri.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"uri",
"uri was not specified but it is required when building PutIntegrationOutput",
)
})?,
object_type_name: self.object_type_name,
created_at: self.created_at.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"created_at",
"created_at was not specified but it is required when building PutIntegrationOutput",
)
})?,
last_updated_at: self.last_updated_at.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"last_updated_at",
"last_updated_at was not specified but it is required when building PutIntegrationOutput",
)
})?,
tags: self.tags,
object_type_names: self.object_type_names,
workflow_id: self.workflow_id,
is_unstructured: self.is_unstructured,
role_arn: self.role_arn,
event_trigger_names: self.event_trigger_names,
_request_id: self._request_id,
})
}
}