Dryplate

v0.1.2
io.github.dryplate/dryplate Checked 15 hours ago Published 25 days ago

Local image tools: convert, resize, compress, crop, blur, watermark, strip metadata.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

convert_image

Convert an image to JPEG, PNG, WebP or AVIF, for example an iPhone HEIC photo to JPEG. Writes a new file next to the input (name-converted.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
format *stringOutput format
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it

resize_image

Resize an image, keeping its aspect ratio. Give width, height, both (the image fits inside that box) or percent. Writes a new file next to the input (name-resized.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
heightintegerTarget height in px
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
percentnumberScale in percent, like 50 for half size
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it
widthintegerTarget width in px

compress_image

Make an image file smaller in its own format. Never returns a bigger file. Writes a new file next to the input (name-compressed.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
maxKbnumberTarget file size in KB. Without it, a sensible quality is used
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it

watermark_image

Draw a text watermark on an image, in one corner or tiled across it. Writes a new file next to the input (name-watermarked.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
text *stringWatermark text, like © 2026 Jane Doe
opacitynumberPercent. Default 60
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it
sizenumberText height as % of the short side. Default 5
tilebooleanRepeat across the image
xnumber0 left … 1 right. Default 1
ynumber0 top … 1 bottom. Default 1

generate_thumbnail

Make a small preview that fits inside a square box. Default 256 px WebP. Writes a new file next to the input (name-thumb.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
formatstringOutput format. Default webp
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it
sizeintegerBox edge in px. Default 256

crop_image

Crop an image to a centred aspect ratio (ratio) or to a region (box). Give one of them. Writes a new file next to the input (name-cropped.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
boxobjectRegion to keep, as fractions of the image
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it
ratiostringCentred crop, like "1:1" or "16:9"

rotate_image

Rotate an image clockwise by a quarter turn or more, and optionally mirror it. Writes a new file next to the input (name-rotated.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
degreesClockwise. Default 90
flipstringh mirrors left-right, v top-bottom
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it

blur_image

Blur a whole image, or only some areas of it (faces, plates, text). Writes a new file next to the input (name-blurred.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
areasarrayBlur only these regions. Default: the whole image
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it
strengthnumberBlur strength, 1–100. Default 20

remove_metadata

Remove location, camera and other hidden data. Lossless for JPEG, PNG and WebP; orientation is kept. HEIC and AVIF are re-encoded as JPEG, which can be bigger than the original. Writes a new file next to the input (name-clean.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
path *stringAbsolute path (or ~/…) of the image to read: JPEG, PNG, WebP, AVIF or HEIC. HEIC is written as JPEG unless a format is chosen.
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it

merge_images

Combine images side by side or stacked, scaled to the smallest shared edge. Writes a new file next to the input (name-merged.ext) unless output is given, never replaces a file unless overwrite is true, and returns the path, format and size change.

ParameterTypeDescription
paths *arrayAbsolute paths (or ~/…) of the images, in order
backgroundstringColour of the gap and any empty space. Default white
directionstringDefault horizontal
gapintegerPixels between images. Default 0
outputstringWhere to write. Default: next to the input, like photo-resized.jpg
overwritebooleanReplace an existing output file. Default false
qualityintegerQuality for lossy output (JPEG, WebP, AVIF), 1–100. PNG ignores it