unsplash v0.1.0 Unsplash.OAuth
Authorization
Unsplash.OAuth.authorize_url! scope: "public read_user write_user read_photos write_photos write_likes"
Unsplash.OAuth.authorize!(code: auth_code_from_the_callback_above)
Now all calls will be authorized.
Summary
Functions
Generates the authorization url which then authenticates with the user
Functions
Generates the authorization url which then authenticates with the user.
The scope option should be space seperated string of requested scopes.
Possible scopes:
publicAll public actions (default)read_userAccess user’s private data.write_userUpdate the user’s profile.read_photosRead private data from the user’s photos.write_photosUpload photos on the user’s behalf.write_likesLike photos on a the user`s behalf.
Examples
iex> url = Unsplash.OAuth.authorize_url! scope: “public read_user write_user read_photos write_photos write_likes” iex> is_binary(url) true