I’ve looked for solutions to automatically download and archive all of my Google Voice voicemail messages, without success.
Fortunately I discovered the PyGoogleVoice project (http://code.google.com/p/pygooglevoice/). Google Voice for Python allows you to interface with the Google Voice API from within your Python apps.
Since I only wanted to download the mp3 files for each of my voicemail messages, I modified the example code to suite my needs. Here is a sanitized copy of my google voice backup script:
#!/usr/bin/env python from googlevoice import Voice from pprint import pprint download_dir = '/home/joet3ch/voicemail' voice = Voice() voice.login('my_username', 'my_password') for message in voice.voicemail().messages: message.download(download_dir) #message.delete()
Uncomment the last line ‘message.delete()’ to automatically delete the message from Google’s servers after your download is complete.
To fully automate the backup script, schedule the job with cron. Here is an example that will run the script every day at 1am.
0 1 * * * /home/joet3ch/scripts/google_voice_backup.py