Class SmsFailoverNotifier.Builder

java.lang.Object
com.chatmotorapi.api.notify.failover.SmsFailoverNotifier.Builder
Enclosing class:
SmsFailoverNotifier

public static class SmsFailoverNotifier.Builder
extends Object
Builder class for SmsFailoverNotifier. This class follows the builder pattern to configure and create instances of SmsFailoverNotifier.
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • logger

      public SmsFailoverNotifier.Builder logger​(org.slf4j.Logger logger)
      Sets the logger used for logging operational information.
      Parameters:
      logger - the Logger to use
      Returns:
      this Builder instance for chaining
    • accountSid

      public SmsFailoverNotifier.Builder accountSid​(String accountSid)
      Sets the Twilio Account SID required for API access.
      Parameters:
      accountSid - the Twilio Account SID
      Returns:
      this Builder instance for chaining
    • authToken

      public SmsFailoverNotifier.Builder authToken​(String authToken)
      Sets the Twilio Auth Token required for API access.
      Parameters:
      authToken - the Twilio Auth Token
      Returns:
      this Builder instance for chaining
    • phoneNumbers

      public SmsFailoverNotifier.Builder phoneNumbers​(List<String> phoneNumbers)
      Sets the list of phone numbers to notify in the event of a failover.
      Parameters:
      phoneNumbers - the list of phone numbers
      Returns:
      this Builder instance for chaining
    • messageText

      public SmsFailoverNotifier.Builder messageText​(String messageText)
      Sets the message text to send to all phone numbers.
      Parameters:
      messageText - the message text
      Returns:
      this Builder instance for chaining
    • fromPhoneNumber

      public SmsFailoverNotifier.Builder fromPhoneNumber​(String fromPhoneNumber)
      Sets the Twilio phone number from which the message will be sent.
      Parameters:
      fromPhoneNumber - the Twilio phone number
      Returns:
      this Builder instance for chaining
    • build

      public SmsFailoverNotifier build()
      Builds and returns a SmsFailoverNotifier configured with this builder's settings.
      Returns:
      a new SmsFailoverNotifier instance