mothermachine

Browse / Video and streaming

MediaMTX

Single-binary media server for SRT, WebRTC, RTSP, RTMP, HLS, and MoQ, configured by one YAML file and a Control API.

AdaptableOperable ProductAPI / service Deterministic Go API License: MIT

A zero-dependency Go media router that publishes, reads, proxies, records, and plays back live streams across protocols. Every setting is in mediamtx.yml and hot-reloads; the same settings and all sessions are exposed through an HTTP Control API with an OpenAPI spec in the repo.

Use it when
  • I need to take an SRT or RTMP feed from a camera or OBS and hand it out as WebRTC and HLS from one box
  • I want an agent to add camera paths, start recordings, and kick sessions over HTTP
Gotchas
  • Control API is off by default and binds to localhost only; set api: yes and secure it before exposing
  • No transcoding: MediaMTX routes and remuxes; use ffmpeg hooks if you need to change codecs
  • Thin product surface by design; the value is the protocol matrix, not a UI

Last activity Sep 2, 2026. Fit: adaptable 3, operable 3.

Editions

Free · Free open source

For agents: JSON · Markdown

Adaptable: what is yours to change

Make it yours

Config only2 things to edit

Everything is in mediamtx.yml: protocol addresses, auth, recording, playback, hooks, and per-path settings under pathDefaults and paths. Set api: yes to enable the Control API. Any key can also be overridden with an MTX_-prefixed environment variable. No code changes needed for normal use.

Env vars
MTX_<PARAMNAME> (env override of any mediamtx.yml key, for example MTX_RTSPADDRESS)
Config files
mediamtx.yml
Prompt files
none
Accounts you need
none

Source

Operable: what an agent can drive

Interface

OfficialAPIpublished by the builderlocal

How an agent can drive an Operable Listing, in five levels: native (built for the agent as the primary interface), official (the Builder ships an agent interface), wrapped (a third party wraps the software's API), config (an agent can only drive it by editing files), gui (screen control only). An interface is official only when it is published by the same organization that ships the software. GUI-level Listings are allowed and sorted last.

Docs
mediamtx.org/docs/features/control-api

Reach

Complete coverage. 10 of 10 jobs reachable through the stated interface.

JobThrough the interfaceEvidence
Publish streams to the serverReachableapi/openapi.yaml: /v3/config/paths/add/{name}; publishers connect over any protocol
Read streams in another protocolReachableREADME: automatic conversion; paths served on every enabled protocol
Serve several streams on separate pathsReachableapi/openapi.yaml: /v3/config/paths/list, /v3/paths/list
Reload configuration without dropping clientsReachableapi/openapi.yaml: /v3/config/global/patch, /v3/config/pathdefaults/patch
Record streams to diskReachablepath config record keys through /v3/config/paths/patch; /v3/recordings/list
Play back recordingsReachablemediamtx.yml playback server; api/playback.openapi.yaml
Authenticate users (internal, HTTP, JWT)ReachableauthMethod, authInternalUsers, authHTTPAddress, authJWTJWKS keys settable through /v3/config/global/patch
Forward and proxy streams to other serversReachableapi/openapi.yaml: /v3/paths/forward/list; source key in path config
Kick sessions and inspect connectionsReachableapi/openapi.yaml: /v3/rtspsessions/kick/{id}, /v3/webrtcsessions/kick/{id}, /v3/srtconns/list
Run hooks on connect, publish, readReachablerunOnConnect, runOnInit, runOnReady keys in mediamtx.yml, patchable over the API

Code stack

Languages
Go
Frameworks
none
Package manager
go modules
Database
none
Hosting target
LinuxWindowsmacOSDockerRaspberry Pi
Built
Human-written (recorded, never ranked)

Evidence and confidence

FieldWhere it was seenConfidence
formFactorREADME: single executable server, no dependency or interpreter90%
executionModelno model at runtime99%
operabilityapi/openapi.yaml in the repo; Control API page at mediamtx.org published by the Builder95%
effortmediamtx.yml at repo root lists every key; README: hot reload95%
editionsMIT LICENSE; releases and Docker Hub99%
activeGitHub pushedAt 2026-09-02; release v1.20.1 2026-08-18–
reach90%

Open questions

  • Confirm the MTX_ environment variable convention from the mediamtx.org configuration page; it was not fetched this pass (the mediamtx.yml comments only show MTX_CONN_* hook variables)

Sources