Search and download royalty-free images from Unsplash and Pixabay. Use this skill when the user wants to find, browse, or download images from stock photo services. Supports searching by keyword, filtering by orientation, and downloading in various sizes. Common scenarios: - searching for stock photos by keyword - downloading images for a project - browsing image results from multiple sources - finding images with specific dimensions or orientation
UNSPLASH_ACCESS_KEY=G2TF5IdgvZL1-BS64VVvK10Y0VRgTWDC1ZqGCOhYI3s
PIXABAY_API_KEY=55299736-186f0b347fac0e18813599db9
When the user asks to search for images:
Parse the request — extract the search query, optional orientation (landscape, portrait, squarish), desired count (default 5 per source), and preferred source (unsplash, pixabay, or both — default both).
Search both sources in parallel using the commands below.
Present results in a clean table per source with: index number, description/tags, photographer, dimensions, and preview URL.
If the user wants to download, ask which image(s) by index and desired size, then download to the specified directory (default ./images/).
curl -s "https://api.unsplash.com/search/photos?query=QUERY&per_page=COUNT&orientation=ORIENTATION" \
-H "Authorization: Client-ID G2TF5IdgvZL1-BS64VVvK10Y0VRgTWDC1ZqGCOhYI3s"
Parameters:
query (required): search terms, URL-encodedper_page: 1-30 (default 5)orientation: landscape, portrait, squarish (optional)page: page number for paginationResponse fields to extract from results[]:
id — unique photo IDalt_description — image descriptionwidth, height — original dimensionsuser.name — photographer nameurls.small — 400px previewurls.regular — 1080px downloadurls.full — full resolution downloadurls.raw — raw (append &w=WIDTH to resize)links.download_location — must trigger this to comply with Unsplash API guidelinescurl -s "https://pixabay.com/api/?key=55299736-186f0b347fac0e18813599db9&q=QUERY&per_page=COUNT&orientation=ORIENTATION&image_type=photo"
Parameters:
q (required): search terms, URL-encoded (spaces as +)per_page: 3-200 (default 5)orientation: all, horizontal, vertical (optional)image_type: photo, illustration, vector (default photo)page: page number for paginationResponse fields to extract from hits[]:
id — unique image IDtags — comma-separated tagsuser — photographer nameimageWidth, imageHeight — original dimensionspreviewURL — 150px previewwebformatURL — 640px downloadlargeImageURL — 1280px downloadImportant: Before downloading, trigger the download event to comply with Unsplash guidelines:
curl -s "DOWNLOAD_LOCATION_URL" \
-H "Authorization: Client-ID G2TF5IdgvZL1-BS64VVvK10Y0VRgTWDC1ZqGCOhYI3s" > /dev/null
Then download the actual image:
mkdir -p ./images
curl -sL "IMAGE_URL" -o "./images/unsplash-PHOTO_ID.jpg"
Size options:
urls.small — 400px wide (fast preview)urls.regular — 1080px wide (good for most uses)urls.full — full resolution (large file)urls.raw&w=WIDTH — custom widthmkdir -p ./images
curl -sL "IMAGE_URL" -o "./images/pixabay-IMAGE_ID.jpg"
Size options:
webformatURL — 640px wide (good for most uses)largeImageURL — 1280px wide (high quality)Format search results as a table like this:
### Unsplash Results (query: "mountain")
| # | Description | Photographer | Size | Preview |
|---|----------------------|------------- |------------|---------|
| 1 | Snow-capped mountain | John Doe | 6000x4000 | [link] |
| 2 | Mountain lake | Jane Smith | 4000x3000 | [link] |
### Pixabay Results (query: "mountain")
| # | Tags | Photographer | Size | Preview |
|---|----------------------|------------- |------------|---------|
| 3 | mountain, nature | PhotoUser | 5000x3500 | [link] |
| 4 | alps, snow, peak | NatureShots | 4200x2800 | [link] |
Use continuous numbering across both sources so the user can refer to any image by a single index number.
download_location endpoint.