Learn-skills.dev image-convert

Converts an image to a different format (PNG, JPG, WebP). Use when you need to change image formats, optimize for web, or prepare images for specific applications.

install
source · Clone the upstream repo
git clone https://github.com/NeverSight/learn-skills.dev
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/NeverSight/learn-skills.dev "$T" && mkdir -p ~/.claude/skills && cp -r "$T/data/skills-md/agntswrm/agent-media/image-convert" ~/.claude/skills/neversight-learn-skills-dev-image-convert && rm -rf "$T"
manifest: data/skills-md/agntswrm/agent-media/image-convert/SKILL.md
source content

Image Convert

Converts an image to a different format (PNG, JPG, or WebP).

Command

agent-media image convert --in <path> --format <format> [options]

Inputs

OptionRequiredDescription
--in
YesInput file path or URL
--format
YesOutput format:
png
,
jpg
,
webp
--quality
NoQuality for lossy formats (1-100, default: 80)
--out
NoOutput path, filename or directory (default: ./)
--provider
NoProvider to use (default: auto-detect)

Output

Returns a JSON object with the converted image path:

{
  "ok": true,
  "media_type": "image",
  "action": "convert",
  "provider": "local",
  "output_path": "converted_123_abc.webp",
  "mime": "image/webp",
  "bytes": 23456
}

Examples

Convert PNG to WebP:

agent-media image convert --in photo.png --format webp

Convert to high-quality JPEG:

agent-media image convert --in photo.png --format jpg --quality 95

Convert with custom output directory:

agent-media image convert --in image.png --format webp --out ./converted

Providers

  • local (default) - Uses sharp library, no API key required