Twitter API:如何知道我是否关注某人

问题描述:

要关注我使用的人api.create_friendship(user_id),并且此方法调用处于try语句中。所以我认为如果我已经在跟踪用户,但是没有,那么这会引发错误。 这是因为.create_friendship(user_id) ... explanation 好吧我无法用错误处理程序检测它,所以如何?! 了解user[« following »]已被twitter API文档弃用...Twitter API:如何知道我是否关注某人

根据the documentation有API调用来查看您是否关注某人。使用friendships/show来确定您是否已经关注用户。

+0

yess it work!谢谢 – user8715867