Class CfnPhoneNumberProps.Builder
java.lang.Object
software.amazon.awscdk.services.smsvoice.CfnPhoneNumberProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnPhoneNumberProps>
- Enclosing interface:
CfnPhoneNumberProps
@Stability(Stable)
public static final class CfnPhoneNumberProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnPhoneNumberProps>
A builder for
CfnPhoneNumberProps
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.deletionProtectionEnabled
(Boolean deletionProtectionEnabled) Sets the value ofCfnPhoneNumberProps.getDeletionProtectionEnabled()
deletionProtectionEnabled
(IResolvable deletionProtectionEnabled) Sets the value ofCfnPhoneNumberProps.getDeletionProtectionEnabled()
isoCountryCode
(String isoCountryCode) Sets the value ofCfnPhoneNumberProps.getIsoCountryCode()
mandatoryKeywords
(IResolvable mandatoryKeywords) Sets the value ofCfnPhoneNumberProps.getMandatoryKeywords()
mandatoryKeywords
(CfnPhoneNumber.MandatoryKeywordsProperty mandatoryKeywords) Sets the value ofCfnPhoneNumberProps.getMandatoryKeywords()
numberCapabilities
(List<String> numberCapabilities) Sets the value ofCfnPhoneNumberProps.getNumberCapabilities()
numberType
(String numberType) Sets the value ofCfnPhoneNumberProps.getNumberType()
optionalKeywords
(List<? extends Object> optionalKeywords) Sets the value ofCfnPhoneNumberProps.getOptionalKeywords()
optionalKeywords
(IResolvable optionalKeywords) Sets the value ofCfnPhoneNumberProps.getOptionalKeywords()
optOutListName
(String optOutListName) Sets the value ofCfnPhoneNumberProps.getOptOutListName()
selfManagedOptOutsEnabled
(Boolean selfManagedOptOutsEnabled) Sets the value ofCfnPhoneNumberProps.getSelfManagedOptOutsEnabled()
selfManagedOptOutsEnabled
(IResolvable selfManagedOptOutsEnabled) Sets the value ofCfnPhoneNumberProps.getSelfManagedOptOutsEnabled()
Sets the value ofCfnPhoneNumberProps.getTags()
twoWay
(IResolvable twoWay) Sets the value ofCfnPhoneNumberProps.getTwoWay()
twoWay
(CfnPhoneNumber.TwoWayProperty twoWay) Sets the value ofCfnPhoneNumberProps.getTwoWay()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
isoCountryCode
Sets the value ofCfnPhoneNumberProps.getIsoCountryCode()
- Parameters:
isoCountryCode
- The two-character code, in ISO 3166-1 alpha-2 format, for the country or region. This parameter is required.- Returns:
this
-
mandatoryKeywords
@Stability(Stable) public CfnPhoneNumberProps.Builder mandatoryKeywords(IResolvable mandatoryKeywords) Sets the value ofCfnPhoneNumberProps.getMandatoryKeywords()
- Parameters:
mandatoryKeywords
- Creates or updates aMandatoryKeyword
configuration on an origination phone number For more information, see Keywords in the End User Messaging User Guide. This parameter is required.- Returns:
this
-
mandatoryKeywords
@Stability(Stable) public CfnPhoneNumberProps.Builder mandatoryKeywords(CfnPhoneNumber.MandatoryKeywordsProperty mandatoryKeywords) Sets the value ofCfnPhoneNumberProps.getMandatoryKeywords()
- Parameters:
mandatoryKeywords
- Creates or updates aMandatoryKeyword
configuration on an origination phone number For more information, see Keywords in the End User Messaging User Guide. This parameter is required.- Returns:
this
-
numberCapabilities
@Stability(Stable) public CfnPhoneNumberProps.Builder numberCapabilities(List<String> numberCapabilities) Sets the value ofCfnPhoneNumberProps.getNumberCapabilities()
- Parameters:
numberCapabilities
- Indicates if the phone number will be used for text messages, voice messages, or both. This parameter is required.- Returns:
this
-
numberType
Sets the value ofCfnPhoneNumberProps.getNumberType()
- Parameters:
numberType
- The type of phone number to request. This parameter is required.The
ShortCode
number type is not supported in AWS CloudFormation .- Returns:
this
-
deletionProtectionEnabled
@Stability(Stable) public CfnPhoneNumberProps.Builder deletionProtectionEnabled(Boolean deletionProtectionEnabled) Sets the value ofCfnPhoneNumberProps.getDeletionProtectionEnabled()
- Parameters:
deletionProtectionEnabled
- By default this is set to false. When set to true the phone number can't be deleted.- Returns:
this
-
deletionProtectionEnabled
@Stability(Stable) public CfnPhoneNumberProps.Builder deletionProtectionEnabled(IResolvable deletionProtectionEnabled) Sets the value ofCfnPhoneNumberProps.getDeletionProtectionEnabled()
- Parameters:
deletionProtectionEnabled
- By default this is set to false. When set to true the phone number can't be deleted.- Returns:
this
-
optionalKeywords
@Stability(Stable) public CfnPhoneNumberProps.Builder optionalKeywords(IResolvable optionalKeywords) Sets the value ofCfnPhoneNumberProps.getOptionalKeywords()
- Parameters:
optionalKeywords
- A keyword is a word that you can search for on a particular phone number or pool. It is also a specific word or phrase that an end user can send to your number to elicit a response, such as an informational message or a special offer. When your number receives a message that begins with a keyword, End User Messaging responds with a customizable message. Optional keywords are differentiated from mandatory keywords. For more information, see Keywords in the End User Messaging User Guide.- Returns:
this
-
optionalKeywords
@Stability(Stable) public CfnPhoneNumberProps.Builder optionalKeywords(List<? extends Object> optionalKeywords) Sets the value ofCfnPhoneNumberProps.getOptionalKeywords()
- Parameters:
optionalKeywords
- A keyword is a word that you can search for on a particular phone number or pool. It is also a specific word or phrase that an end user can send to your number to elicit a response, such as an informational message or a special offer. When your number receives a message that begins with a keyword, End User Messaging responds with a customizable message. Optional keywords are differentiated from mandatory keywords. For more information, see Keywords in the End User Messaging User Guide.- Returns:
this
-
optOutListName
Sets the value ofCfnPhoneNumberProps.getOptOutListName()
- Parameters:
optOutListName
- The name of the OptOutList associated with the phone number.- Returns:
this
-
selfManagedOptOutsEnabled
@Stability(Stable) public CfnPhoneNumberProps.Builder selfManagedOptOutsEnabled(Boolean selfManagedOptOutsEnabled) Sets the value ofCfnPhoneNumberProps.getSelfManagedOptOutsEnabled()
- Parameters:
selfManagedOptOutsEnabled
- When set to false and an end recipient sends a message that begins with HELP or STOP to one of your dedicated numbers, End User Messaging automatically replies with a customizable message and adds the end recipient to the OptOutList. When set to true you're responsible for responding to HELP and STOP requests. You're also responsible for tracking and honoring opt-out request. For more information see Self-managed opt-outs- Returns:
this
-
selfManagedOptOutsEnabled
@Stability(Stable) public CfnPhoneNumberProps.Builder selfManagedOptOutsEnabled(IResolvable selfManagedOptOutsEnabled) Sets the value ofCfnPhoneNumberProps.getSelfManagedOptOutsEnabled()
- Parameters:
selfManagedOptOutsEnabled
- When set to false and an end recipient sends a message that begins with HELP or STOP to one of your dedicated numbers, End User Messaging automatically replies with a customizable message and adds the end recipient to the OptOutList. When set to true you're responsible for responding to HELP and STOP requests. You're also responsible for tracking and honoring opt-out request. For more information see Self-managed opt-outs- Returns:
this
-
tags
Sets the value ofCfnPhoneNumberProps.getTags()
- Parameters:
tags
- An array of tags (key and value pairs) to associate with the requested phone number.- Returns:
this
-
twoWay
Sets the value ofCfnPhoneNumberProps.getTwoWay()
- Parameters:
twoWay
- Describes the two-way SMS configuration for a phone number. For more information, see Two-way SMS messaging in the End User Messaging User Guide.- Returns:
this
-
twoWay
Sets the value ofCfnPhoneNumberProps.getTwoWay()
- Parameters:
twoWay
- Describes the two-way SMS configuration for a phone number. For more information, see Two-way SMS messaging in the End User Messaging User Guide.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnPhoneNumberProps>
- Returns:
- a new instance of
CfnPhoneNumberProps
- Throws:
NullPointerException
- if any required attribute was not provided
-