Skip to content

Instantly share code, notes, and snippets.

@jacoyutorius
Created April 25, 2013 15:44
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 jacoyutorius/5460756 to your computer and use it in GitHub Desktop.
Save jacoyutorius/5460756 to your computer and use it in GitHub Desktop.
Twilio APIを使って℡をかけるサンプル
require "rubygems"
require "yaml"
require "twilio-ruby"
config = YAML.load(File.read(File.join(File.dirname(__FILE__), '..', 'config.yml')))
if !config
print "config.yml does not found!"
end
@client = Twilio::REST::Client.new config["twilio_config"]["account_sid"] , config["twilio_config"]["auth_token"]
@call = @client.account.calls.create(
:from => "+81**********",
:to => "+81**********",
:url => ''
)
puts @call
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment