image-convert

from agntswrm/agent-media

media cli for agents

1 stars0 forksUpdated Jan 21, 2026
npx skills add https://github.com/agntswrm/agent-media --skill image-convert

SKILL.md

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
--inYesInput file path or URL
--formatYesOutput format: png, jpg, webp
--qualityNoQuality for lossy formats (1-100, default: 80)
--outNoOutput path, filename or directory (default: ./)
--providerNoProvider 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

Repository Stats

Stars1
Forks0
LicenseApache License 2.0