Skip to content

RTMP

media.ingest.rtmp

Description

Sapsan can pull an RTMP stream from another server in client (pull) mode. For accepting incoming RTMP publishing (push into Sapsan), see publishing.

Configuration

Configure the stream through the central API. Stream configuration fragment:

streams:
  - name: relay
    inputs:
    - rtmp:
        url: rtmp://origin.example.com/live/streamkey
        peer_timeout_ms: 5000

Parameters

Parameter Description
url remote RTMP stream address.
peer_timeout_ms data inactivity timeout.

Authentication

Use URL credentials: rtmp://user:password@origin.example.com/live/streamkey. Adobe/FMS authmod=adobe authentication is supported.

Transport options

RTMP over TCP. Audio-only streams are supported.

Supported codecs

  • H.264
  • HEVC (Enhanced RTMP, hvc1)
  • AV1 (Enhanced RTMP, av01)
  • AAC
  • MP3

RTMP carries FLV messages; Enhanced RTMP identifies video codecs by FourCC. The list describes receiving compressed frames and passing them into the pipeline. AV1 requires Enhanced RTMP with av01; selecting AV1 at the sender without this packaging is insufficient. MP3 is accepted as FLV audio, separately from AAC.

Error handling

Server rejection codes are distinguished and visible in the input status: stream not found, access denied, stream stopped, protocol error. A dropped connection and a silent server (peer_timeout_ms) are also distinguished. LSI switches to a backup input on any of these.

Applying changes

Changing url restarts the source; changing only peer_timeout_ms applies in place.

Counters

The tables give exact protocol statistics field names, including event counters and current-value gauges. Zero fields may be omitted. API and Prometheus expose different projections; the full list is not necessarily present in one Admin API response. Detailed statistics depend on the counter license.

Common input totals: bytes, frames, errors, warnings. They aggregate protocol data and must not be added to protocol counters again.

Rtmp

Field Type
bytes counter
outgoing_bytes counter
frames counter
rtmp_script_data counter
memory_bytes gauge

Other details

onMetaData metadata accompanies the stream. Malformed optional metadata does not stop video and audio ingest.

Next steps