문제

I would like to read the deleted statuses on twitter since i can already have the user_id and status_id of the deleted tatus using "on_delete" method.

here is my code:

require 'rubygems' 
require 'tweetstream'
   TweetStream::Client.new(USER,PASS).follow(3331681,15846407,30592818,21249843,1367531,428333,  196218494,82158673,   :delete => Proc.new{ |status_id, user_id| puts "#{status_id}, #{user_id}"}) do |status|

#is it a retweet
rt=!defined?(status.method_missing("retweeted_status",status.id).class).nil?
puts "retweet?:"
puts rt.inspect 

if status.in_reply_to_screen_name.nil?    
 if rt
   puts "Retweeted by :#{status.user.screen_name}"  
 else
   puts "Screen name :#{status.user.screen_name}" 
 end
else
  puts "From :#{status.user.screen_name} to #{status.in_reply_to_screen_name}"
end
 puts "Text:#{status.text}"
 puts "#{status.created_at}"
 puts '*' * 7
 puts "user id:#{status.user.id}"
 puts "to :#{status.in_reply_to_user_id}"
 puts '--' * 25
end
도움이 되었습니까?

해결책

No, you can't. This is a constraint of the Twitter API rather than any Ruby library. It used to be possible but has since been fixed, breaking tweet recovery services such as tweleted.com in the process.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top