Skip to content

Recording

The [download] section in server/config.toml controls how the recorder pulls a stream.

[download]
max_concurrent = 5
preferred_quality = "1080"
segment_concurrency = 4
network_attempts = 5
server_error_attempts = 5
cdn_lag_attempts = 3
auth_refresh_attempts = 2
max_gap_ratio = 0.01
strict = false
enable_av1 = false
disable_hevc = false
max_restart_gap_seconds = 120
KeyWhat it does
max_concurrentCap on parallel recordings across the whole server.
segment_concurrencyParallel HLS segment fetches inside a single recording.

Bump max_concurrent if you record many channels at once and have the disk + network for it. Bump segment_concurrency only if a single recording is bottlenecked on download throughput.

preferred_quality is a target. The recorder picks the closest variant the channel offers. Common values:

  • "1080" — 1080p60 if the channel ladder includes it, else next best.
  • "720", "480", "360" — same logic.
  • "audio_only" — record audio only.
KeyDefaultEffect
enable_av1falseAllow AV1 variants when the channel ladder includes them.
disable_hevcfalseRefuse HEVC variants even when offered.

HEVC and AV1 are gated behind authenticated playback on some channels. Set TWITCH_SERVICE_ACCOUNT_REFRESH_TOKEN in server/.env to a Twitch refresh token if you want those variants on those channels.

KeyWhen it applies
network_attemptsGeneric network failures (TCP reset, DNS, etc.).
server_error_attemptsTwitch returned 5xx for a segment.
cdn_lag_attemptsSegment isn’t on the CDN yet.
auth_refresh_attemptsPlayback token expired and needs refresh.

Retry budgets are per-segment, not per-recording. The recorder gives up on a segment after exhausting its budget; it does not give up on the recording.

KeyDefaultEffect
max_gap_ratio0.01Tolerated fraction of dropped segments before the recording is marked incomplete.
strictfalseIf true, any gap fails the recording. If false, gaps under the ratio are auto-healed.
max_restart_gap_seconds120If the stream drops and comes back within this window, the recorder appends to the same VOD instead of starting a new one.