Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can you send SNS push notification from lambda function in Amazon AWS?

I am developing an application with Amazon AWS and what I am trying to achieve is to attach a lambda function to DynamoDB table, so after a new row is added ,the lambda function is triggered. In the above mentioned lambda function I want to add the functionality to send a push notification with Amazon SNS service, but I could not find any information in their documentation if that is possible and if it is, what exactly needs to be done to get it working? What I found in their documentation is that you can attach lambda function trigger to a SNS topic, which means that after a notification is pushed then the function is called, but what I am interested in is to send a push notification directly from lambda function. I would appreciate if someone shed some light on this topic for me.

like image 787
axel Avatar asked Oct 14 '15 06:10

axel


People also ask

How to send notifications from AWS simple notification service using lambda?

Please replace the Target Arn value with the ARN value of the SNS topic which you want to send notifications from this AWS Lambda function. To fetch the SNS topic ARN value, you can go to AWS Simple Notification Service SNS dashboard and list the Topics.

What is SNS in AWS Lambda?

AWS SNS stands for Simple Notification Service. SNS is easy to send messages to the endpoints. Using Amazon SNS, the user can send messages or Emails to distributed systems and services and mobile devices. SNS notifications can also trigger a Lambda function.

How do I get email notifications from AWS SNS?

To use an AWS Lambda function to receive an email from SNS when any of your AWS Glue jobs fail a retry, do the following: Create an Amazon SNS topic. Create an AWS Lambda function. Create an Amazon EventBridge event that uses the Lambda function to initiate email notifications.

How do I process notifications from Amazon Simple Notification service (Amazon SNS)?

You can use a Lambda function to process Amazon Simple Notification Service (Amazon SNS) notifications. Amazon SNS supports Lambda functions as a target for messages sent to a topic. You can subscribe your function to topics in the same account or in other AWS accounts.


1 Answers

Yes, you can call any of the API functions from Lambda. Perhaps if you posted some code and the errors you are getting you could get more specific help.

like image 198
E.J. Brennan Avatar answered Nov 15 '22 09:11

E.J. Brennan