Skip to content

Instantly share code, notes, and snippets.

@sasamijp
Created July 31, 2015 06:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sasamijp/09f45d44331455a52e18 to your computer and use it in GitHub Desktop.
Save sasamijp/09f45d44331455a52e18 to your computer and use it in GitHub Desktop.
show tweet url by status_id
# -*- encoding:utf-8 -*-
require 'twitter'
class Const
CONSUMER_KEY = ''
CONSUMER_SECRET = ''
ACCESS_TOKEN = ''
ACCESS_TOKEN_SECRET = ''
end
rest = Twitter::REST::Client.new do |config|
config.consumer_key = Const::CONSUMER_KEY
config.consumer_secret = Const::CONSUMER_SECRET
config.access_token = Const::ACCESS_TOKEN
config.access_token_secret = Const::ACCESS_TOKEN_SECRET
end
puts rest.status(gets.chomp , options={}).url
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment