昨天在弄 RSS 2.0版本的时候顺便把这两个API放出来. 一个是获取粉丝列表, 一个是获取关注列表, 两个都是返回JSON格式的数据, 数据每小时更新缓存. 目前暂时只能获取微信群里的成员, 但不排除之后扩展到全网. 需要入群者可以联系 @justyy
举例说明 – 我的关注列表:
https://uploadbeta.com/api/steemit/account/following/?cached&id=justyy
举例说明 – 我的粉丝列表:
https://uploadbeta.com/api/steemit/account/followed/?cached&id=justyy
然后在PHP里可以简单封装一下:
1 2 3 4 5 6 7 | function getFollowing($id) { return json_decode(file_get_contents("https://uploadbeta.com/api/steemit/account/following/?cached&id=$id"), true); } function getFollowed($id) { return json_decode(file_get_contents("https://uploadbeta.com/api/steemit/account/followed/?cached&id=$id"), true); } |
function getFollowing($id) { return json_decode(file_get_contents("https://uploadbeta.com/api/steemit/account/following/?cached&id=$id"), true); } function getFollowed($id) { return json_decode(file_get_contents("https://uploadbeta.com/api/steemit/account/followed/?cached&id=$id"), true); }
据说, 关注大神所关注的是成功的第一步:
1 | print_r(array_diff(getFollowing('tumutanzi'), getFollowing('justyy'))); |
print_r(array_diff(getFollowing('tumutanzi'), getFollowing('justyy')));
这样就能知道 @tumutanzi 关注的 而我却还没有关注的人.
新技能, 你 get 了么? 在使用过程中如有建议或者BUG反馈, 请直接 @justyy (微信或 steemit 都可以)
英文: SteemIt API – Two APIs to get the followers and following list in the Wechat Group
强烈推荐
- 英国代购-畅购英伦
- TopCashBack 返现 (英国购物必备, 积少成多, 我2年来一共得了3000多英镑)
- Quidco 返现 (也是很不错的英国返现网站, 返现率高)
- 注册就送10美元, 免费使用2个月的 DigitalOcean 云主机(性价比超高, 每月只需5美元)
- 注册就送10美元, 免费使用4个月的 Vultr 云主机(性价比超高, 每月只需2.5美元)
- 注册就送10美元, 免费使用2个月的 阿里 云主机(性价比超高, 每月只需4.5美元)
- 注册就送20美元, 免费使用4个月的 Linode 云主机(性价比超高, 每月只需5美元) (折扣码: PodCastInit2022)
- PlusNet 英国光纤(超快, 超划算! 用户名 doctorlai)
- 刷了美国运通信用卡一年得到的积分 换了 485英镑
- 注册就送50英镑 – 英国最便宜最划算的电气提供商
- 能把比特币莱特币变现的银行卡! 不需要手续费就可以把虚拟货币法币兑换
微信公众号: 小赖子的英国生活和资讯 JustYYUK