MediaForge is a FastAPI-based media processing service that offers:
- Metadata editing and inspection
- Audio and video transformation
- YouTube video/audio downloading
- Output storage in a MinIO server
- Real-time dashboard for logs and job status
- External webhook support for job updates
All processing is handled by FFmpeg and yt-dlp, and outputs are managed via MinIO.
- View metadata (title, artist, date, etc.)
- Edit/remove metadata
- Add custom tags/descriptions
- Format conversion (MP3, WAV, FLAC, AAC, etc.)
- Extract audio from video
- Merge/mix audio with video
- Volume adjustment and normalization
- Remove or isolate audio tracks
- Modify bitrate, sample rate, or channels
- Format conversion (MP4, MKV, MOV, AVI, etc.)
- Resize, crop, pad, rotate, flip
- Trim/cut video sections
- Merge/concatenate videos
- Adjust frame rate (FPS)
- Add overlays/logos/watermarks
- Apply visual filters (blur, sharpen, grayscale)
- Extract frames/images
- Download via
yt-dlp - Extract audio only (optional)
- Auto-convert on download
- Save all output files to a defined MinIO bucket
- Files organized into folders (
/audio/,/video/,/images/) - Presigned URLs returned after processing
- UI dashboard to:
- Track jobs (Queued, Processing, Completed, Failed)
- View FFmpeg logs and commands
- Filter by job type
- Real-time updates via WebSocket or polling
- Built with HTMX, Vue, or React (optional)
- Allow clients to provide a
webhook_urlwith their job - On job completion (success/failure), send a POST request to the webhook URL with:
- Job ID
- Status
- Output URL(s)
- Log (optional)
- Timestamp
Example webhook payload:
{
"job_id": "abc123",
"status": "completed",
"output_urls": ["https://media.example.com/audio/abc123.mp3"],
"log_summary": "FFmpeg finished successfully",
"completed_at": "2025-06-22T14:30:00Z"
}/app
βββ main.py
βββ routers/
β βββ metadata.py
β βββ audio.py
β βββ video.py
β βββ youtube.py
β βββ dashboard.py
βββ services/
β βββ ffmpeg_utils.py
β βββ minio_client.py
β βββ job_tracker.py
β βββ webhook_notifier.py
βββ models/
βββ schemas.py
- FastAPI
- Uvicorn
- ffmpeg / ffprobe
- yt-dlp
- minio SDK
- python-multipart
- aiofiles
- websockets / sse-starlette
- httpx (for async webhook calls)
MINIO_ENDPOINT=localhost:9000
MINIO_ACCESS_KEY=minioadmin
MINIO_SECRET_KEY=minioadmin
MINIO_BUCKET=media-files
FFMPEG_PATH=/usr/bin/ffmpeg
FFPROBE_PATH=/usr/bin/ffprobe- Supports both file uploads and remote media URLs
- Webhooks and dashboard are optional but supported
- Async-first design for scalability and responsiveness
- Ready for future job queuing (Celery, RQ, etc.)