TwitterJS和Twitter 1.1 API

时间:2013-04-18 20:24:56

标签: twitter twitter-streaming-api

5月7日,当Twitter 1.0 API消失后,TwitterJS将不再有效吗?

https://code.google.com/p/twitterjs/

由于

1 个答案:

答案 0 :(得分:0)

在研究了这个之后,我能够回答我自己的问题:它不会。

TwitterJS.js API使用1.0和v1方法:

  protocol = document.location.protocol.substr(0, 4) === 'http' ? document.location.protocol : 'http:',
  URLS = {
    search: protocol + '//search.twitter.com/search.json?q=%search%&page=%page|1%&rpp=%limit|100%&since_id=%since|remove%&result_type=recent&include_entities=true', // TODO allow user to change result_type
    timeline: protocol + '//api.twitter.com/1/statuses/user_timeline.json?screen_name=%user%&count=%limit|200%&page=%page|1%&since_id=%since|remove%include_rts=%rts|false%&include_entities=true',
    list: protocol + '//api.twitter.com/1/%user%/lists/%list%/statuses.json?page=%page|1%&per_page=%limit|200%&since_id=%since|remove%&include_entities=true&include_rts=%rts|false%',
    favs: protocol + '//api.twitter.com/1/favorites/%user%.json?include_entities=true&skip_status=true&page=%page|1%&since_id=%since|remove%',
    retweets: protocol + '//api.twitter.com/1/statuses/retweeted_by_user.json?screen_name=%user%&include_entities=true&count=%limit|200%&since_id=%since|remove%&page=%page|1%'
  },