I found this recently https://github.com/mholt/photobak
Photobak is really close, but Google's API apparently has several issues making it not a true solution. IIRC you can't download the original uploaded bytes, and you can't get the original EXIF data.
[0] http://pyropus.ca/software/getmail/