SNS订阅从未发送/接收? [英] SNS subscription never sent/received?

查看:299
本文介绍了SNS订阅从未发送/接收?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在SNS控制台面板创建了一个HTTP用户。我需要保持每封电子邮件(反弹,投诉)的状态。

I have created one http subscriber in My SNS console panel. I need to maintain the status of each email (bounce, complaints).

我已经设置了一个可公开访问的HTTP端点,创建订阅我的话题,我点击订阅按钮,并在弹出的说,一条确认信息将被发送到订阅的终点。

I have set up a publicly accessible http endpoint, created a subscription to my Topic, I click on the Subscribe button and the popup says "A confirmation message will be sent to the subscribed endpoint."

我只是不知道如何验证我的端点,从Amazon SNS采集后的数据。

I just not understand how to verify my endpoint and collecting the post data from Amazon SNS.

我已经把端点url以下格式。

I have put the endpoint url in below format.

http://example.com/amazon_sns/sns_notification.php

端点都将POST数据追加到一个文本文件中,当我要求到终点,从浏览器中的数据被写入。 有什么不对我做的。

Endpoint will append all post data to a text file, when I request to endpoint from browser the data is written. Is something wrong I am doing.

我一直试图认购1天了,没有运气。任何帮助非常AP preciated。

I've been trying to subscribe for 1 days now, no luck. Any help much appreciated.

推荐答案

在您sns_notification.php将这个

Put this in your sns_notification.php

您将收到的发布到网址与电子邮件的身体,其中来自亚马逊的消息将出现一个链接,确认您的SNS主题订阅。

You will then receive the body that is posted to the url in your email, in which the message from amazon will appear with a link to confirm your SNS topic subscription.

<?php

$headers = apache_request_headers();
$body = @file_get_contents('php://input');

mail("YOUREMAILADDRESS@gmail.com", "ses callback", print_r($headers, 1)."\n---body---\n".$body);

?>

这篇关于SNS订阅从未发送/接收?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆