M3U via URL Issues

Hey folks, new Channels user here. Having trouble getting M3U to work, only when loading via URL, and I'm looking for one of two things:

  • How can I debug why my M3U playlist isn't working via url, but is working via text? When I paste the exact same data into the text option, works like a charm. Can't figure out if it's an encoding issue (I've tried UTF8 via M3u/M3U8 and ASCII) or something else.
  • Alternatively, can I update the text field via API? I am parsing my M3U data via PowerShell and uploading the resulting M3U, so I'm pretty flexible in how I get this M3U data into Channels.

Notes:

  • Version: 2023.01.06.1553
  • Error seen when playing stream from M3U URL via web player: The media could not be loaded, either because the server or network failed or because the format is not supported.
  • Error seen when playing stream from M3U URL via iOS app: Could not fetch polaylist: : Get "": unsupported protocol scheme ""

Thanks!

Resolved (or worked around, is more like it) via a PUT call to the /providers/m3u/sources/<name> endpoint.

Example via PowerShell, where $contents is your regular M3U data (not json-encoded, etc):

$headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]"
$headers.Add("Content-Type", "application/json")
$body =  "{
    `"name`": `"MyM3uSource`", 
    `"type`": `"HLS`",
    `"source`": `"Text`",
    `"text`": `"$($contents -join `"\n`" -replace '`"','\`"')`"
}"

$response = Invoke-RestMethod 'http://10.1.11.18:8089/providers/m3u/sources/MyM3uSource' -Method 'PUT' -Headers $headers -Body $body
$response | ConvertTo-Json

What url were you using that wasn't working?

Just a WebDAV share on TrueNAS.

  • Created my M3U
  • Upload M3U to WebDAV share
  • Point Channels at WebDAV share URL

It would parse the M3U fine, but then throw errors when you try to play the content. Uploading the same exact content via the Text field worked fine. Not sure what the issue would be;

Can you provide a sample URL? Im not familiar with WebDAV.

1 Like

It's just an HTTP server, effectively. URL would be something like: http://myserver.lan:8080/public/test.m3u

I'm curious, if it's just a regular HTTP call, why it didn't work. Can you try it again and then submit diagnostics?

2 posts were split to a new topic: WebDAV support