Python library to get pictures from source.unsplash.com
Project description
py_unsplash_source is a really really simple library to easily interface with the source.unsplash.com service. Typical usage often looks like this:
#!/usr/bin/env python from py_unsplash_source import PyUnsplashSourceClient su = PyUnsplashSourceClient(width=1920, height=1080) # Random √ image = (su.random_image() .daily() # Or .weekly() .search('nature,landscape')).get() image.save_as('/tmp/random.jpg') # Random from a specific user √ image = (su.image_from_user('gangdise') .from_likes()).get() image.save_as('/tmp/user.jpg') # Random from a collection √ image = su.image_from_collection(145698).get() image.save_as('/tmp/collection.jpg') # Random from featured collection √ image = (su.image_from_featured() .search('nature,landscape', 'sunset')).get() image.save_as('/tmp/featured.jpg') # Speficic image √ image = su.image("ieic5Tq8YMk").get() image.save_as('/tmp/item.jpg')
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for py_unsplash_source-0.1.0.dev0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 17ee7404dbf624b02c5e7486c961a2690648b0f2b853e7c30345ee2a354a3d0c |
|
MD5 | 9f4f1e196322f02135a2f90865fa0a12 |
|
BLAKE2b-256 | 10b84fa0a6ba7c70d49eb413137c02106d40e6c61d81c40dff4aa88b1fd037ec |
Close
Hashes for py_unsplash_source-0.1.0.dev0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 99de907039cd137d6f219eba51610511f8328e212d009c4d9af036d0960efadf |
|
MD5 | 407a9690c4f58c4c1d475ee135a1f5de |
|
BLAKE2b-256 | bbf22865b3965ba6f0d2929e8bd5e1e5e0e9c6a969eabaee17ea5f4398c035ec |