#[non_exhaustive]
pub struct EndpointRequestBuilder { /* private fields */ }
Expand description

A builder for EndpointRequest.

Implementations§

source§

impl EndpointRequestBuilder

source

pub fn address(self, input: impl Into<String>) -> Self

The destination address for messages or push notifications that you send to the endpoint. The address varies by channel. For a push-notification channel, use the token provided by the push notification service, such as an Apple Push Notification service (APNs) device token or a Firebase Cloud Messaging (FCM) registration token. For the SMS channel, use a phone number in E.164 format, such as +12065550100. For the email channel, use an email address.

source

pub fn set_address(self, input: Option<String>) -> Self

The destination address for messages or push notifications that you send to the endpoint. The address varies by channel. For a push-notification channel, use the token provided by the push notification service, such as an Apple Push Notification service (APNs) device token or a Firebase Cloud Messaging (FCM) registration token. For the SMS channel, use a phone number in E.164 format, such as +12065550100. For the email channel, use an email address.

source

pub fn get_address(&self) -> &Option<String>

The destination address for messages or push notifications that you send to the endpoint. The address varies by channel. For a push-notification channel, use the token provided by the push notification service, such as an Apple Push Notification service (APNs) device token or a Firebase Cloud Messaging (FCM) registration token. For the SMS channel, use a phone number in E.164 format, such as +12065550100. For the email channel, use an email address.

source

pub fn attributes(self, k: impl Into<String>, v: Vec<String>) -> Self

Adds a key-value pair to attributes.

To override the contents of this collection use set_attributes.

One or more custom attributes that describe the endpoint by associating a name with an array of values. For example, the value of a custom attribute named Interests might be: ["Science", "Music", "Travel"]. You can use these attributes as filter criteria when you create segments. Attribute names are case sensitive.

An attribute name can contain up to 50 characters. An attribute value can contain up to 100 characters. When you define the name of a custom attribute, avoid using the following characters: number sign (#), colon (:), question mark (?), backslash (\), and slash (/). The Amazon Pinpoint console can't display attribute names that contain these characters. This restriction doesn't apply to attribute values.

source

pub fn set_attributes(self, input: Option<HashMap<String, Vec<String>>>) -> Self

One or more custom attributes that describe the endpoint by associating a name with an array of values. For example, the value of a custom attribute named Interests might be: ["Science", "Music", "Travel"]. You can use these attributes as filter criteria when you create segments. Attribute names are case sensitive.

An attribute name can contain up to 50 characters. An attribute value can contain up to 100 characters. When you define the name of a custom attribute, avoid using the following characters: number sign (#), colon (:), question mark (?), backslash (\), and slash (/). The Amazon Pinpoint console can't display attribute names that contain these characters. This restriction doesn't apply to attribute values.

source

pub fn get_attributes(&self) -> &Option<HashMap<String, Vec<String>>>

One or more custom attributes that describe the endpoint by associating a name with an array of values. For example, the value of a custom attribute named Interests might be: ["Science", "Music", "Travel"]. You can use these attributes as filter criteria when you create segments. Attribute names are case sensitive.

An attribute name can contain up to 50 characters. An attribute value can contain up to 100 characters. When you define the name of a custom attribute, avoid using the following characters: number sign (#), colon (:), question mark (?), backslash (\), and slash (/). The Amazon Pinpoint console can't display attribute names that contain these characters. This restriction doesn't apply to attribute values.

source

pub fn channel_type(self, input: ChannelType) -> Self

The channel to use when sending messages or push notifications to the endpoint.

source

pub fn set_channel_type(self, input: Option<ChannelType>) -> Self

The channel to use when sending messages or push notifications to the endpoint.

source

pub fn get_channel_type(&self) -> &Option<ChannelType>

The channel to use when sending messages or push notifications to the endpoint.

source

pub fn demographic(self, input: EndpointDemographic) -> Self

The demographic information for the endpoint, such as the time zone and platform.

source

pub fn set_demographic(self, input: Option<EndpointDemographic>) -> Self

The demographic information for the endpoint, such as the time zone and platform.

source

pub fn get_demographic(&self) -> &Option<EndpointDemographic>

The demographic information for the endpoint, such as the time zone and platform.

source

pub fn effective_date(self, input: impl Into<String>) -> Self

The date and time, in ISO 8601 format, when the endpoint is updated.

source

pub fn set_effective_date(self, input: Option<String>) -> Self

The date and time, in ISO 8601 format, when the endpoint is updated.

source

pub fn get_effective_date(&self) -> &Option<String>

The date and time, in ISO 8601 format, when the endpoint is updated.

source

pub fn endpoint_status(self, input: impl Into<String>) -> Self

Specifies whether to send messages or push notifications to the endpoint. Valid values are: ACTIVE, messages are sent to the endpoint; and, INACTIVE, messages aren’t sent to the endpoint.

Amazon Pinpoint automatically sets this value to ACTIVE when you create an endpoint or update an existing endpoint. Amazon Pinpoint automatically sets this value to INACTIVE if you update another endpoint that has the same address specified by the Address property.

source

pub fn set_endpoint_status(self, input: Option<String>) -> Self

Specifies whether to send messages or push notifications to the endpoint. Valid values are: ACTIVE, messages are sent to the endpoint; and, INACTIVE, messages aren’t sent to the endpoint.

Amazon Pinpoint automatically sets this value to ACTIVE when you create an endpoint or update an existing endpoint. Amazon Pinpoint automatically sets this value to INACTIVE if you update another endpoint that has the same address specified by the Address property.

source

pub fn get_endpoint_status(&self) -> &Option<String>

Specifies whether to send messages or push notifications to the endpoint. Valid values are: ACTIVE, messages are sent to the endpoint; and, INACTIVE, messages aren’t sent to the endpoint.

Amazon Pinpoint automatically sets this value to ACTIVE when you create an endpoint or update an existing endpoint. Amazon Pinpoint automatically sets this value to INACTIVE if you update another endpoint that has the same address specified by the Address property.

source

pub fn location(self, input: EndpointLocation) -> Self

The geographic information for the endpoint.

source

pub fn set_location(self, input: Option<EndpointLocation>) -> Self

The geographic information for the endpoint.

source

pub fn get_location(&self) -> &Option<EndpointLocation>

The geographic information for the endpoint.

source

pub fn metrics(self, k: impl Into<String>, v: f64) -> Self

Adds a key-value pair to metrics.

To override the contents of this collection use set_metrics.

One or more custom metrics that your app reports to Amazon Pinpoint for the endpoint.

source

pub fn set_metrics(self, input: Option<HashMap<String, f64>>) -> Self

One or more custom metrics that your app reports to Amazon Pinpoint for the endpoint.

source

pub fn get_metrics(&self) -> &Option<HashMap<String, f64>>

One or more custom metrics that your app reports to Amazon Pinpoint for the endpoint.

source

pub fn opt_out(self, input: impl Into<String>) -> Self

Specifies whether the user who's associated with the endpoint has opted out of receiving messages and push notifications from you. Possible values are: ALL, the user has opted out and doesn't want to receive any messages or push notifications; and, NONE, the user hasn't opted out and wants to receive all messages and push notifications.

source

pub fn set_opt_out(self, input: Option<String>) -> Self

Specifies whether the user who's associated with the endpoint has opted out of receiving messages and push notifications from you. Possible values are: ALL, the user has opted out and doesn't want to receive any messages or push notifications; and, NONE, the user hasn't opted out and wants to receive all messages and push notifications.

source

pub fn get_opt_out(&self) -> &Option<String>

Specifies whether the user who's associated with the endpoint has opted out of receiving messages and push notifications from you. Possible values are: ALL, the user has opted out and doesn't want to receive any messages or push notifications; and, NONE, the user hasn't opted out and wants to receive all messages and push notifications.

source

pub fn request_id(self, input: impl Into<String>) -> Self

The unique identifier for the most recent request to update the endpoint.

source

pub fn set_request_id(self, input: Option<String>) -> Self

The unique identifier for the most recent request to update the endpoint.

source

pub fn get_request_id(&self) -> &Option<String>

The unique identifier for the most recent request to update the endpoint.

source

pub fn user(self, input: EndpointUser) -> Self

One or more custom attributes that describe the user who's associated with the endpoint.

source

pub fn set_user(self, input: Option<EndpointUser>) -> Self

One or more custom attributes that describe the user who's associated with the endpoint.

source

pub fn get_user(&self) -> &Option<EndpointUser>

One or more custom attributes that describe the user who's associated with the endpoint.

source

pub fn build(self) -> EndpointRequest

Consumes the builder and constructs a EndpointRequest.

Trait Implementations§

source§

impl Clone for EndpointRequestBuilder

source§

fn clone(&self) -> EndpointRequestBuilder

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for EndpointRequestBuilder

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Default for EndpointRequestBuilder

source§

fn default() -> EndpointRequestBuilder

Returns the “default value” for a type. Read more
source§

impl PartialEq for EndpointRequestBuilder

source§

fn eq(&self, other: &EndpointRequestBuilder) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl StructuralPartialEq for EndpointRequestBuilder

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<Unshared, Shared> IntoShared<Shared> for Unshared
where Shared: FromUnshared<Unshared>,

source§

fn into_shared(self) -> Shared

Creates a shared type from an unshared type.
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more