Last active
January 2, 2016 00:43
-
-
Save ischurov/6e03acc98004f0440aa9 to your computer and use it in GitHub Desktop.
Upload all JPG files in folder to Flickr using `flickrapi`.
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
import flickrapi # we're using http://stuvel.eu/flickrapi | |
import glob | |
api_key="xxx" | |
api_secret="xxx" | |
# get your own on https://www.flickr.com/services/api/ | |
flickr = flickrapi.FlickrAPI(api_key, api_secret) | |
flickr.authenticate_via_browser(perms='write') | |
for f in glob.glob("*.JPG"): | |
flickr.upload(filename=f) | |
print "%s is uploaded" % f | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment