Skip to content

Instantly share code, notes, and snippets.

@RobSpectre
Created September 27, 2012 19:09
Show Gist options
  • Save RobSpectre/3795833 to your computer and use it in GitHub Desktop.
Save RobSpectre/3795833 to your computer and use it in GitHub Desktop.
Get the last n number of Sms Messages
from twilio.rest import TwilioRestClient
ACCOUNT_SID = 'ACxxxxxxxxxxxxxxxxx'
AUTH_TOKEN = 'yyyyyyyyyyyyyyyyyyyy'
client = TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN)
messages = client.sms.messages.list()
for msg in messages:
print msg.__dict__
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment