Flickr API:如何(成功)获得带有特定标签的新照片(私人)的推送通知?

Flickr API: How to (successfully) get push notification for new photos(private) with specific tags?

我正在使用 this php flickr 库。我添加了以下 flickr push_subscription 函数:

function push_subscribe ($topic = NULL, $callback = NULL, $verify = NULL, $verify_token = NULL, $lease_seconds = NULL, $tags = NULL) {

return $this->call('flickr.push.subscribe', array('topic' => $topic, 'callback' => $callback, 'verify' => $verify, 'verify_token' => $verify_token, 'lease_seconds' => $lease_seconds, 'tags' => $tags)); 
}

之后订阅了主题设置为"tags"的推送通知:

$res = $f->push_subscribe("tags", "http://mysite.herokuapp.com/flickr/push-notification.php", "async", NULL, NULL, "personal");

在使用 getsubscription 订阅后,我收到了如下回复:

[0] => Array ( [topic] => tags [callback] => mysite.herokuapp.com/flickr/push-notification.php [pending] => 1 [date_create] => 1435469765 [expiry] => 0 [verify_attempts] => 1 )

[stat] => ok

我的回调 url 是我网站上的一个 php 脚本:

<?php
if (isset($_GET['hub_challenge'])) {
  print $_GET['hub_challenge'];
}
else {
  $xml=file_get_contents("php://input");
  file_put_contents('endpoint.txt',$xml);
}

但是我在上传带有特定标签的新照片后没有得到任何东西? endpoint.txt 文件是 empty.Why?

我错过了什么?

根据此 Flickr blog,Flickr Push API 目前仅支持具有 public 可见性的图像:

It’s possible that we may relax some of these restrictions in the future, but for now a PuSH feed is essentially what a signed-out user could get just by grabbing the RSS feeds from various people’s photostreams.

此外,API只能由专业帐户用户使用。

现在,博客 post 是 2011 年的,所以我认为情况有所不同,但 Flickr Push API docs 上的文字表明它仍处于试验阶段...注意我还没有测试 Flickr Push API。