Skip to content

Instantly share code, notes, and snippets.

@mbmccormick
Created October 9, 2011 01:12
Show Gist options
  • Save mbmccormick/1273138 to your computer and use it in GitHub Desktop.
Save mbmccormick/1273138 to your computer and use it in GitHub Desktop.
Telephony Made Easy with Twilio (Part 2)
def sendCall(self, text, destination, id):
ApiVersion = "2008-08-01"
AccountSid = "AXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
AuthToken = "YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY"
account = twilio.Account(AccountSid, AuthToken)
d = {
'Called' : destination,
'Caller' : '505-609-8968',
'Url' : 'http://remindable.appspot.com/call?id=' + str(id)
}
account.request('/%s/Accounts/%s/Calls' % (ApiVersion, AccountSid), 'POST', d)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment