Login
Immutable PageDiscussionInfoAttachments

Revision 2 as of 2012-12-10 01:00:01

Clear message
alstamber/Egofav

MMA

なにこれ

Rubyとか全然わからない件

   1 puts "Hello, World"

とりあえずOAuthしないとね

   1 @consumer=OAuth::Consumer.new( "key","secret", {
   2     :site=>"https://agree2"
   3 })

   1 {:symbol => value,
   2  :symbol => value,
   3  ...
   4 }

   1 OAuth::AccessToken.new(consumer, ACCESS_TOKEN, ACCESS_SECRET)

ふぁぼスクリプトの挙動を考える

Userstreamへの接続

   1 uri = URI.parse("https://userstream.twitter.com/2/user.json")
   2 https = Net::HTTP.new(uri.host, uri.port)
   3 https.use_ssl = true
   4 https.verify_mode = OpenSSL::SSL::VERIFY_NONE
   5 
   6 https.start do |https|
   7     #do something
   8 end