Created
January 12, 2012 05:27
-
-
Save orenmazor/1598946 to your computer and use it in GitHub Desktop.
python snippet to decode base64
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 base64 import b64decode | |
for attachment in inbound_json["attachment"]: | |
blob = b64decode(attachment["Content"]) | |
file = open(attachment["Name"],"w") | |
file.write(blob) | |
file.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment