I am looking to build a lambda script, where I will be able to:
On a very rough level, I can accomplish some of the above tasks with the following methods:
Does anyone know how I can accomplish step 4 and 6?
For step 6, I am thinking of having eventbridge to trigger the notification-generating lambda script whenever a new subscriber is added to topic, but not sure if its doable and also the fact that the existing subscribers will be notified again.
For step 4 I am completely clueless.
Thanks.
You can add a subscriber to a topic with boto3, see docs here: https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/sns.html#SNS.Client.subscribe And if you wont to send something out to that topic you publish to it, see docs here: https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/sns.html#SNS.Client.publish
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.