Skip to content

Image Info

Read-only analysis tool that returns comprehensive image metadata including dimensions, format, color space, EXIF/ICC/XMP presence, and per-channel histogram statistics. Does not produce a processed output file.

API Endpoint

POST /api/v1/tools/info

Accepts multipart form data with an image file. No settings field is needed.

Parameters

This tool has no configurable parameters. Simply upload the image file.

FieldTypeRequiredDescription
filefileYesThe image to analyze

Example Request

bash
curl -X POST http://localhost:1349/api/v1/tools/info \
  -H "Authorization: Bearer si_your-api-key" \
  -F "[email protected]"

Example Response

json
{
  "filename": "photo.jpg",
  "fileSize": 2450000,
  "width": 4032,
  "height": 3024,
  "format": "jpeg",
  "channels": 3,
  "hasAlpha": false,
  "colorSpace": "srgb",
  "density": 72,
  "isProgressive": false,
  "orientation": 1,
  "hasProfile": true,
  "hasExif": true,
  "hasIcc": true,
  "hasXmp": false,
  "bitDepth": "8",
  "pages": 1,
  "histogram": [
    { "channel": "red", "min": 0, "max": 255, "mean": 128.45, "stdev": 52.31 },
    { "channel": "green", "min": 2, "max": 253, "mean": 115.22, "stdev": 48.76 },
    { "channel": "blue", "min": 0, "max": 250, "mean": 102.89, "stdev": 55.14 }
  ]
}

Response Fields

FieldTypeDescription
filenamestringSanitized filename
fileSizenumberFile size in bytes
widthnumberImage width in pixels
heightnumberImage height in pixels
formatstringDetected format (jpeg, png, webp, etc.)
channelsnumberNumber of color channels
hasAlphabooleanWhether the image has an alpha channel
colorSpacestringColor space (srgb, cmyk, etc.)
densitynumber or nullDPI/PPI resolution
isProgressivebooleanWhether JPEG uses progressive encoding
orientationnumber or nullEXIF orientation value (1-8)
hasProfilebooleanWhether an ICC profile is embedded
hasExifbooleanWhether EXIF metadata is present
hasIccbooleanWhether an ICC color profile is present
hasXmpbooleanWhether XMP metadata is present
bitDepthstring or nullBits per sample
pagesnumberNumber of pages (for multi-page formats like TIFF, GIF)
histogramarrayPer-channel statistics (min, max, mean, standard deviation)

Notes

  • This is a read-only endpoint. It does not produce a downloadable output file or a jobId.
  • For RAW format images (DNG, CR2, NEF, ARW, etc.), ExifTool is used to extract true sensor dimensions and metadata flags that Sharp cannot read directly.
  • HEIC/HEIF files are decoded to PNG internally to extract pixel statistics, since Sharp cannot decode HEVC pixels.
  • The histogram provides min/max/mean/stdev per channel, not a full 256-bin distribution.
  • The density field reflects the embedded DPI metadata, if present.