X-Plex-Client-Profile-Extra Documentation

I want to know about how the X-Plex-Client-Profile-Extra header works, what options are available, what they do, and how they interface with the xml profile files.

Looking around a bit, I see these are some of the valid directives for the header:

  • append-transcode-target-codec
  • restrict-transcode-target-codec
  • add-transcode-target-audio-codec
  • add-transcode-target-settings
  • add-direct-play-profile

One example of a valid value for this header is:

add-transcode-target-audio-codec(type=videoProfile&context=streaming&protocol=hls&audioCodec=%s)+add-limitation(scope=videoAudioCodec&scopeName=%s&type=upperBound&name=audio.channels&value=6&onlyTranscodes=true&replace=true)

In my specific case, I want to know this because I want to start with the Web profile (X-Plex-Device: Web) and modify itwith that header to make it only give webvtt subtitles instead of ass.

I’ve googled around a ton and see no documentation on this header at all. I would appreciate any help or information.

That information is proprietary to the Plex apps.
You might be able to arrange a NDA (Non-Disclosure Agreement) with HQ but it’s not something which can be discussed in an open forum.

Can you provide more details about who to contact? How would this affect development if the information were used on an open source project?

You can use the contact form at www.plex.tv (at the bottom)

It’s pretty easy to figure out on your own using verbose logging and header/Url param interception&modification.

Honestly can’t even fathom how something so easy to reverse engineer (read as: trial and error with HTTP) could require an NDA​:sweat_smile::rofl:.

Plex is officially closed-source and a for-profit company.
As such, they own the API.
I’m not the person who is authorized to say “Sure, go use it as you see fit”.
That’s all I’m saying. It requires HQ / the business folks to do that. (chain of command stuff).

I am likely going to just accept ASS subtitles and use Subtitle Octopus to render them instead. Plex appears to use libjass (Plex licenses) which is now no longer worked on, and the project recommends using Subtitle Octopus instead. Probably for the best since it’s a bit more fully features than webvtt.

Edit: Subtitle Octopus is looking like it requires the full subtitle file before it starts doing anything. Plex doesn’t give the entire subtitle at once but instead streams it over time. I’m going to use libjass instead since it has a nice method minimalASS. I have gotten stuff partially working with libjass. I’m having to write a custom stream reader for it to support seeking around in the video and having it restart the xhr or fetch request for the subtitles.