BastosConvert API

Media tools

Media tools

Four synchronous audio/video endpoints, powered by ffmpeg. Each takes multipart/form-data — a single file part plus any options as text fields — and returns the converted file in the response body. No key required (rate-limited per IP, see Rate limits). Files are converted in the cloud over an encrypted connection and auto-deleted right after.

Each endpoint enforces a size cap; oversized uploads return 413.

POST /media/convert_audio

Convert between mp3, wav, flac, ogg, m4a, opus. Fields: file + target_format. Max 100 MB.

curl -X POST https://bastosconvert.com/api/v1/media/convert_audio \
  -F file=@song.wav \
  -F target_format=mp3 \
  -o song.mp3

POST /media/convert_video

Convert between mp4, webm, mov, avi, mkv. Fields: file + target_format. Max 200 MB.

curl -X POST https://bastosconvert.com/api/v1/media/convert_video \
  -F file=@clip.mov \
  -F target_format=mp4 \
  -o clip.mp4

POST /media/gif_to_mp4

Turn a heavy animated GIF into a web-friendly MP4. Field: file. Max 50 MB.

curl -X POST https://bastosconvert.com/api/v1/media/gif_to_mp4 \
  -F file=@loop.gif \
  -o loop.mp4

POST /media/video_to_gif

Turn a short video into an animated GIF. Field: file, plus optional fps and width (px) to tune size/quality. Max 50 MB.

curl -X POST https://bastosconvert.com/api/v1/media/video_to_gif \
  -F file=@clip.mp4 \
  -F fps=15 \
  -F width=480 \
  -o clip.gif

The API reference (sidebar) carries the exact request/response schema and status codes for each endpoint.

On this page