Created
February 21, 2012 20:50
-
-
Save caseysoftware/1878833 to your computer and use it in GitHub Desktop.
This is a simple script using the Twilio Python module to retrieve Recordings within a certain date range and then delete them.
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
from datetime import date | |
from twilio.rest import TwilioRestClient | |
account = "ACxxxx" | |
token = "xxxxxx" | |
client = TwilioRestClient(account, token) | |
recordings = client.recordings.list(after=date(2012, 1, 1)) | |
for recording in recordings: | |
print recording.sid | |
recording.delete() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment