amazon-sns

Authorization when sending a text message using AmazonSNSClient

五迷三道 提交于 2019-12-05 11:45:54
问题 The official aws documentation on how to send a Textmessage with the aws SDK in java is pretty straightforward. However, when sending a message like shown in the example at the bottom, I'm getting the error User: arn:aws:iam::xxx:user/sms-testing is not authorized to perform: SNS:Publish on resource: +999999999 Note that +999999999 is the phone number passed to the .withPhoneNumber() call, so the aws api complains about my IAM user not having the necessary permission to SNS:Publish a message

Cannot create AWS-SNS GCM account, showing invalid credentials message

独自空忆成欢 提交于 2019-12-05 11:02:28
I have looked for resources on this particular problem with little luck so far so I thought I would try here. I am attempting to create an Amazon Web Service Simple Notification Service app in the AWS-SNS console using GCM. I have created the APNS app for the iOS version with no troubles, however, when attempting to create the GCM version I receive the error: "The credentials you entered are invalid. Please enter valid credentials and try again." In the Google APIs - API Access dashboard I have created both a key for server app and a key for android app. Below are a few screenshots to

Amazon SNS — Change Sender ID

此生再无相见时 提交于 2019-12-05 09:04:52
I want to use Amazon SNS Services to send SMS to a couple of numbers. I have a cronjob that's running once a day and should send a SMS to the numbers which are due in that moment. Now I have a couple of question regarding SNS. Do I create a topic with each run of my cronjob, subscribe the numbers to it, send it, and delete it? Or do I just create a topic in the console and then I just subscribe the numbers, send the message and unsubscribe the numbers again after sending? Further I tried something simple with suppling my ARN and send a message with the content's "Hello World!". The message

How to send HTML mails using Amazon SNS?

时光总嘲笑我的痴心妄想 提交于 2019-12-05 02:22:41
How to send HTML mails using Amazon SNS? or do I need to use SES for that? I went through the documentation but it seems there is no way to send HTML mails using Amazon SNS. You can use Amazon SES to send the emails and SNS to trigger the sending process. Suppose you have an app http://myapp.com where the endpoint /api/send-email takes care of sending HTML email trough Amazon SES. You set up an Amazon SNS topic, subscribe the endpoint /api/send-email to receive notifications and when something happens, the notification will trigger the email. You can setup /api/send-email to take parameters

Amazon SNS -> SQS message body

三世轮回 提交于 2019-12-04 18:52:36
问题 I'm sending a message from an SNS topic to an SQS. When I'm checking the body of the SQS message on my client, the whole of the message metadata is being sent in the SQS body. I.E. if I'm sending a message "Hello World" from the topic, my client is receiving: BenFlowers { "Type" : "Notification", "MessageId" : "84102bd5-8890-4ed5-aeba-c15fafc926dc", "TopicArn" : "arn:aws:sns:eu-west-1:534706846367:HelloWorld", "Message" : "hello World", "Timestamp" : "2012-06-05T13:44:22.360Z",

AWS SNS Endpoint getting disabled on its own

老子叫甜甜 提交于 2019-12-04 12:47:11
I have setup my Android and iOS app to be able to receive notifications via SNS. The setup is working fine and the device do receive the notifications. But later on, the notification starts to fail. I have already enabled logging for both success and failure scenarios. And according to the logs, I keep receiving errors of the form: "Endpoint is disabled:arn:aws:sns:myRegion:myAccount:endpoint/GCM/myApp/myDeviceEndpointHash" I know the error means that the endpoint is disabled. Also, I am aware of the methods of re-enabling the endpoint via console and API. My question is why this keeps on

AWS SNS Publish to specific User via Cognito Identity ID

谁说我不能喝 提交于 2019-12-04 11:29:17
What I'm trying to do here is sending a notification via SNS and APNS when a specific user is part of a newly added DynamoDB Item. I want to send it to the users Cognito Identity ID, not to device token. So Lambda should be triggered when the item is added and then go through a list of Cognito Identity IDs, which is also part of the item. Then Lambda is supposed to publish the push notifications to each Cognito Identity ID. All the devices are registered as endpoints within sns. I also keep the Cognito Identity ID in the "user data" row for the endpoint. But i didn't find a way to send

How to use AWS SQS/SNS as a push notification queue for heavy processing tasks via PHP?

对着背影说爱祢 提交于 2019-12-04 09:19:15
问题 I have a single server running on rackspace which is hosting a single PHP web app. The PHP web app will accept a form submission that then needs to perform a task based on the form field entries. The task (let's called it the generate metadata task) requires quite a lot of processing time. I was wondering how to allow the form submission to be a straightforward save to database and immediately show success page to user while running the generate metadata task in the background. I have

aws boto sns - get endpoint_arn by device token

早过忘川 提交于 2019-12-04 08:05:44
Currently, If we want to add a device to an SNS application using: ep = SNSConnection.create_platform_endpoint(app_arn,device_token,user_data) There is an option that the device was already added in the past. To verify if the device is already added, we're using: def is_device_registered(device_token): list_of_endpoints = SNSConnection.list_endpoints_by_platform_application(AC.INPLAY_CHAT_APPLICATION_SNS_ARN) all_app_endpoints = list_of_endpoints['ListEndpointsByPlatformApplicationResponse']['ListEndpointsByPlatformApplicationResult']['Endpoints'] for ep in all_app_endpoints: ep_device_token =

What is the difference between Amazon SNS and Amazon SQS?

自古美人都是妖i 提交于 2019-12-04 07:18:10
问题 I don't understand when I would use SNS versus SQS, and why are they always coupled together? 回答1: SNS is a distributed publish-subscribe system. Messages are pushed to subscribers as and when they are sent by publishers to SNS. SQS is distributed queuing system. Messages are NOT pushed to receivers. Receivers have to poll or pull messages from SQS . Messages can't be received by multiple receivers at the same time. Any one receiver can receive a message, process and delete it. Other