Enum SubscriptionProtocol

java.lang.Object
java.lang.Enum<SubscriptionProtocol>
software.amazon.awscdk.services.sns.SubscriptionProtocol
All Implemented Interfaces:
Serializable, Comparable<SubscriptionProtocol>, java.lang.constant.Constable

@Generated(value="jsii-pacmak/1.97.0 (build 729de35)", date="2024-04-18T17:54:25.055Z") @Stability(Stable) public enum SubscriptionProtocol extends Enum<SubscriptionProtocol>
The type of subscription, controlling the type of the endpoint parameter.

Example:

 import software.amazon.awscdk.services.kinesisfirehose.alpha.DeliveryStream;
 DeliveryStream stream;
 Topic topic = new Topic(this, "Topic");
 Subscription.Builder.create(this, "Subscription")
         .topic(topic)
         .endpoint(stream.getDeliveryStreamArn())
         .protocol(SubscriptionProtocol.FIREHOSE)
         .subscriptionRoleArn("SAMPLE_ARN")
         .build();
 
  • Enum Constant Details

    • HTTP

      @Stability(Stable) public static final SubscriptionProtocol HTTP
      JSON-encoded message is POSTED to an HTTP url.
    • HTTPS

      @Stability(Stable) public static final SubscriptionProtocol HTTPS
      JSON-encoded message is POSTed to an HTTPS url.
    • EMAIL

      @Stability(Stable) public static final SubscriptionProtocol EMAIL
      Notifications are sent via email.
    • EMAIL_JSON

      @Stability(Stable) public static final SubscriptionProtocol EMAIL_JSON
      Notifications are JSON-encoded and sent via mail.
    • SMS

      @Stability(Stable) public static final SubscriptionProtocol SMS
      Notification is delivered by SMS.
    • SQS

      @Stability(Stable) public static final SubscriptionProtocol SQS
      Notifications are enqueued into an SQS queue.
    • APPLICATION

      @Stability(Stable) public static final SubscriptionProtocol APPLICATION
      JSON-encoded notifications are sent to a mobile app endpoint.
    • LAMBDA

      @Stability(Stable) public static final SubscriptionProtocol LAMBDA
      Notifications trigger a Lambda function.
    • FIREHOSE

      @Stability(Stable) public static final SubscriptionProtocol FIREHOSE
      Notifications put records into a firehose delivery stream.
  • Method Details

    • values

      public static SubscriptionProtocol[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static SubscriptionProtocol valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null