java.lang.Object
com.irurueta.authserver.authorization.infrastructure.sms.SnsSmsSender
All Implemented Interfaces:
SmsSender

public class SnsSmsSender extends Object implements SmsSender
SmsSender that publishes directly to a phone number through Amazon SNS. Every failure becomes a SmsDeliveryException without the recipient or the text.
  • Field Details

    • FAILURE_MESSAGE

      static final String FAILURE_MESSAGE
      Generic failure description.
      See Also:
    • client

      private final software.amazon.awssdk.services.sns.SnsClient client
      SNS client.
  • Constructor Details

    • SnsSmsSender

      public SnsSmsSender()
  • Method Details

    • send

      public void send(PhoneNumber to, String text)
      Description copied from interface: SmsSender
      Sends a text message.
      Specified by:
      send in interface SmsSender
      Parameters:
      to - recipient.
      text - text of the message.