public final class SnsSubscriptionConfirmation extends SnsMessage
confirmSubscription()
method to visit the confirmation URL via this object.Modifier and Type | Method and Description |
---|---|
ConfirmSubscriptionResult |
confirmSubscription()
Will attempt to confirm the subscription by visiting the URL at
getSubscribeUrl() . |
String |
getMessage() |
URL |
getSubscribeUrl() |
String |
getToken() |
void |
handle(SnsMessageHandler handler)
Calls the appropriate 'handle' method on
SnsMessageHandler depending on the subtype. |
getMessageId, getTimestamp, getTopicArn
public String getMessage()
You have chosen to subscribe to the topic arn:aws:sns:us-east-1:123456789012:MyTopic.\nTo confirm the subscription,
visit the SubscribeURL included in this message.
public URL getSubscribeUrl()
AmazonSNS.confirmSubscription(ConfirmSubscriptionRequest)
action to confirm the subscription.public String getToken()
AmazonSNS.confirmSubscription(ConfirmSubscriptionRequest)
action to confirm
the subscription. Alternatively, you can simply visit the SubscribeURL.public void handle(SnsMessageHandler handler)
SnsMessage
SnsMessageHandler
depending on the subtype.handle
in class SnsMessage
handler
- Handler to deliver message to.public ConfirmSubscriptionResult confirmSubscription() throws SdkClientException
getSubscribeUrl()
.SdkClientException
- if confirmation could not be confirmed.