aws-sdk-pinpointemail 1.111.0

AWS SDK for Amazon Pinpoint Email Service
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
pub use crate::operation::put_deliverability_dashboard_option::_put_deliverability_dashboard_option_input::PutDeliverabilityDashboardOptionInputBuilder;

pub use crate::operation::put_deliverability_dashboard_option::_put_deliverability_dashboard_option_output::PutDeliverabilityDashboardOptionOutputBuilder;

impl crate::operation::put_deliverability_dashboard_option::builders::PutDeliverabilityDashboardOptionInputBuilder {
    /// Sends a request with this input using the given client.
    pub async fn send_with(
        self,
        client: &crate::Client,
    ) -> ::std::result::Result<
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionOutput,
        ::aws_smithy_runtime_api::client::result::SdkError<
            crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionError,
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
        >,
    > {
        let mut fluent_builder = client.put_deliverability_dashboard_option();
        fluent_builder.inner = self;
        fluent_builder.send().await
    }
}
/// Fluent builder constructing a request to `PutDeliverabilityDashboardOption`.
///
/// <p>Enable or disable the Deliverability dashboard for your Amazon Pinpoint account. When you enable the Deliverability dashboard, you gain access to reputation, deliverability, and other metrics for the domains that you use to send email using Amazon Pinpoint. You also gain the ability to perform predictive inbox placement tests.</p>
/// <p>When you use the Deliverability dashboard, you pay a monthly subscription charge, in addition to any other fees that you accrue by using Amazon Pinpoint. For more information about the features and cost of a Deliverability dashboard subscription, see <a href="http://aws.amazon.com/pinpoint/pricing/">Amazon Pinpoint Pricing</a>.</p>
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
pub struct PutDeliverabilityDashboardOptionFluentBuilder {
    handle: ::std::sync::Arc<crate::client::Handle>,
    inner: crate::operation::put_deliverability_dashboard_option::builders::PutDeliverabilityDashboardOptionInputBuilder,
    config_override: ::std::option::Option<crate::config::Builder>,
}
impl
    crate::client::customize::internal::CustomizableSend<
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionOutput,
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionError,
    > for PutDeliverabilityDashboardOptionFluentBuilder
{
    fn send(
        self,
        config_override: crate::config::Builder,
    ) -> crate::client::customize::internal::BoxFuture<
        crate::client::customize::internal::SendResult<
            crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionOutput,
            crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionError,
        >,
    > {
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
    }
}
impl PutDeliverabilityDashboardOptionFluentBuilder {
    /// Creates a new `PutDeliverabilityDashboardOptionFluentBuilder`.
    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
        Self {
            handle,
            inner: ::std::default::Default::default(),
            config_override: ::std::option::Option::None,
        }
    }
    /// Access the PutDeliverabilityDashboardOption as a reference.
    pub fn as_input(&self) -> &crate::operation::put_deliverability_dashboard_option::builders::PutDeliverabilityDashboardOptionInputBuilder {
        &self.inner
    }
    /// Sends the request and returns the response.
    ///
    /// If an error occurs, an `SdkError` will be returned with additional details that
    /// can be matched against.
    ///
    /// By default, any retryable failures will be retried twice. Retry behavior
    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
    /// set when configuring the client.
    pub async fn send(
        self,
    ) -> ::std::result::Result<
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionOutput,
        ::aws_smithy_runtime_api::client::result::SdkError<
            crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionError,
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
        >,
    > {
        let input = self
            .inner
            .build()
            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
        let runtime_plugins = crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOption::operation_runtime_plugins(
            self.handle.runtime_plugins.clone(),
            &self.handle.conf,
            self.config_override,
        );
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOption::orchestrate(&runtime_plugins, input).await
    }

    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
    pub fn customize(
        self,
    ) -> crate::client::customize::CustomizableOperation<
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionOutput,
        crate::operation::put_deliverability_dashboard_option::PutDeliverabilityDashboardOptionError,
        Self,
    > {
        crate::client::customize::CustomizableOperation::new(self)
    }
    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
        self.set_config_override(::std::option::Option::Some(config_override.into()));
        self
    }

    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
        self.config_override = config_override;
        self
    }
    /// <p>Specifies whether to enable the Deliverability dashboard for your Amazon Pinpoint account. To enable the dashboard, set this value to <code>true</code>.</p>
    pub fn dashboard_enabled(mut self, input: bool) -> Self {
        self.inner = self.inner.dashboard_enabled(input);
        self
    }
    /// <p>Specifies whether to enable the Deliverability dashboard for your Amazon Pinpoint account. To enable the dashboard, set this value to <code>true</code>.</p>
    pub fn set_dashboard_enabled(mut self, input: ::std::option::Option<bool>) -> Self {
        self.inner = self.inner.set_dashboard_enabled(input);
        self
    }
    /// <p>Specifies whether to enable the Deliverability dashboard for your Amazon Pinpoint account. To enable the dashboard, set this value to <code>true</code>.</p>
    pub fn get_dashboard_enabled(&self) -> &::std::option::Option<bool> {
        self.inner.get_dashboard_enabled()
    }
    ///
    /// Appends an item to `SubscribedDomains`.
    ///
    /// To override the contents of this collection use [`set_subscribed_domains`](Self::set_subscribed_domains).
    ///
    /// <p>An array of objects, one for each verified domain that you use to send email and enabled the Deliverability dashboard for.</p>
    pub fn subscribed_domains(mut self, input: crate::types::DomainDeliverabilityTrackingOption) -> Self {
        self.inner = self.inner.subscribed_domains(input);
        self
    }
    /// <p>An array of objects, one for each verified domain that you use to send email and enabled the Deliverability dashboard for.</p>
    pub fn set_subscribed_domains(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::DomainDeliverabilityTrackingOption>>) -> Self {
        self.inner = self.inner.set_subscribed_domains(input);
        self
    }
    /// <p>An array of objects, one for each verified domain that you use to send email and enabled the Deliverability dashboard for.</p>
    pub fn get_subscribed_domains(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::DomainDeliverabilityTrackingOption>> {
        self.inner.get_subscribed_domains()
    }
}