Created
December 25, 2011 02:47
-
-
Save wozozo/1518658 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# coding: utf-8 | |
import time | |
from pydelicious import get_all, delete | |
USERNAME = '' | |
PASSWORD = '' | |
def _delete(): | |
api_data = get_all(USERNAME, PASSWORD) | |
if len(api_data) == 0: | |
return False | |
for data in api_data: | |
delete(USERNAME, PASSWORD, data['href']) | |
print "deleted: %s" % data['href'] | |
time.sleep(1) | |
def main(): | |
while True: | |
if _delete() is False: | |
break | |
if __name__ == '__main__': | |
main() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment