Last active
December 25, 2015 11:49
-
-
Save hunnycode/6972427 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Get twilio-ruby from twilio.com/docs/ruby/install | |
require 'rubygems' # This line not needed for ruby > 1.8 | |
require 'twilio-ruby' | |
# Get your Account Sid and Auth Token from twilio.com/user/account | |
account_sid = 'your account sid' | |
auth_token = 'your auth token' | |
@client = Twilio::REST::Client.new account_sid, auth_token | |
# Loop over numbers and print out a property for each one | |
@client.account.incoming_phone_numbers.list.each do |number| | |
puts number.sid | |
puts number.phone_number | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment