Skip to content

Instantly share code, notes, and snippets.

@snahor
Created April 11, 2012 16:04
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 snahor/2360253 to your computer and use it in GitHub Desktop.
Save snahor/2360253 to your computer and use it in GitHub Desktop.
import urllib
URL = 'http://api.tropo.com/1.0/sessions'
TOKEN = ''
def send_sms(to, shout):
params = urllib.urlencode({
'action': 'create',
'token': TOKEN,
'shout': shout,
'to': to,
})
opener = urllib.urlopen(URL + '?' + params)
response = opener.read()
# whatever u want
message(shout, {'network': "SMS", 'to': to})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment