>我目前正在尝试通过httr包与Twitter的Streaming API进行交互:
library(httr)
my_app <- oauth_app('twitter', consumerKey, consumerSecret)
twitter_token <- oauth1.0_token(oauth_endpoints('twitter'), my_app)
这带来了以下问题和错误:
Use a local file to cache OAuth access credentials between R sessions?
1: Yes
2: No
Selection: 2
Error in init_oauth1.0(endpoint, app, permission = params$permission) :
client error: (401) Unauthorized
如何解决问题?
如果你在推特OAuth上遇到问题,首先检查回调网址是否http://localhost:1410