Skip to content

Photos

The Photos resource provides fake photo data with URLs, thumbnails, and album relationships.

Available Endpoints

MethodEndpointDescription
GET/v1/photosList all photos
GET/v1/photos/:idGet a specific photo
GET/v1/photos/album/:albumIdGet photos by album
{
"id": 1,
"albumId": 1,
"title": "Beach Sunset",
"url": "https://picsum.photos/seed/abc123/800/600",
"thumbnailUrl": "https://picsum.photos/seed/abc123/150/150",
"createdAt": "2026-01-15T10:30:00.000Z",
"updatedAt": "2026-01-15T10:30:00.000Z"
}
Field Type Description
id number Unique identifier
albumId number ID of the album
title string Photo title
url string Full-size image URL
thumbnailUrl string Thumbnail image URL
createdAt string ISO 8601 timestamp
updatedAt string ISO 8601 timestamp
Terminal window
curl https://api.phantomjson.app/v1/photos
Parameter Type Default Description
page number 1 Page number
limit number 20 Items per page (max: 100)
sort string Sort field and direction
q string Search query
fields string Fields to return
albumId number Filter by album ID
{
"data": [
{
"id": 1,
"albumId": 1,
"title": "Beach Sunset",
"url": "https://picsum.photos/seed/abc123/800/600",
"thumbnailUrl": "https://picsum.photos/seed/abc123/150/150"
}
],
"meta": {
"total": 750,
"page": 1,
"limit": 20,
"totalPages": 38
}
}
Terminal window
curl https://api.phantomjson.app/v1/photos/1
{
"data": {
"id": 1,
"albumId": 1,
"title": "Beach Sunset",
"url": "https://picsum.photos/seed/abc123/800/600",
"thumbnailUrl": "https://picsum.photos/seed/abc123/150/150"
}
}
Terminal window
curl https://api.phantomjson.app/v1/photos/album/1
{
"data": [
{
"id": 1,
"albumId": 1,
"title": "Beach Sunset",
"url": "https://picsum.photos/seed/abc123/800/600",
"thumbnailUrl": "https://picsum.photos/seed/abc123/150/150"
}
],
"meta": {
"total": 4,
"page": 1,
"limit": 20,
"totalPages": 1
}
}
Terminal window
curl "https://api.phantomjson.app/v1/photos?q=sunset"
Terminal window
curl "https://api.phantomjson.app/v1/photos?albumId=1"
Terminal window
curl "https://api.phantomjson.app/v1/photos?sort=title:asc"
Terminal window
curl "https://api.phantomjson.app/v1/photos?fields=id,title,url"

All photo URLs use Picsum Photos for realistic placeholder images:

  • Full size: https://picsum.photos/seed/{seed}/800/600
  • Thumbnail: https://picsum.photos/seed/{seed}/150/150
  • Album — Each photo belongs to an album (albumId)
  • Access photos for a specific album via /v1/photos/album/:albumId