Experimental project
This is a sandbox project, which contains experimental code for developer use only.
This module is currently under development, and aims to allow users to add images from the Unsplash API as media items to be used in their sites.
This module requires the core Media entity in 8.4.0+ as well as the Crop API Module.
NOTICE: A NORMAL API ACCESS ALLOWS 50 CALLS PER HOUR. THERE IS ONE CALL DONE FOR EACH SEARCH, ONE CALL DONE FOR EACH ADD, AND ONE CALL FOR EACH CLICK TO THE NEXT/PREV PAGE. PLEASE KEEP THIS IN MIND!
To gain Unsplash API credentials, visit https://unsplash.com/login and click the "Join" button below login.
After enabling the module, you must visit /admin/config/media/media_entity_unsplash and enter your API credentials. At this time, only the Access Key is used. Other fields are available for future use.
The media type with fields is added automatically via the install config.
There are two options to add an Unsplash image to your media library:
1. Visit /media/add/unsplash and add an ID for an unsplash image to the "Unsplash ID" field, as
well as a name. You can find the ID in the image path for the unsplash image. In the URL
https://unsplash.com/photos/HJCywuQqKYY the ID is HJCywuQqKYY.
2. The second (and better) option is to go to /admin/config/media/media_entity_unsplash/search and type a key word in the search box and click search. Once the images load you will have an add button below each image. Click that button and the image will be added as a media item that can be seen at /admin/content/media.
Media generated from the search form are automatically named (contibutor name - id) After saving entities, it is advised to rename them so you can find them easier when adding them to content.



