Info.plist Structure

Every plug-in bundle must contain a Contents/Info.plist file using Apple’s property-list XML format. This file tells Plex Media Server how to load and classify the plug-in.

Minimal Example

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN"
  "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>CFBundleIdentifier</key>
  <string>com.example.myplugin</string>
  <key>PlexPluginClass</key>
  <string>Agent</string>
  <key>PlexFrameworkVersion</key>
  <string>2</string>
</dict>
</plist>

Info.plist Keys Reference

Key

Type

Description

CFBundleIdentifier

string

Required. A globally unique reverse-DNS identifier for the plug-in (e.g. com.plexapp.agents.imdb). Used by the server to identify the bundle and for inter-plug-in messaging.

PlexPluginClass

string

The plug-in’s class. Determines what the plug-in can do. See PlexPluginClass values below. Common values: Agent, Resource. Channel plug-ins typically omit this key or use Resource.

PlexFrameworkVersion

string

The framework bootstrap version to use. Should always be "2" for modern plug-ins. This selects which Versions/ sub-directory inside Framework.bundle is loaded — it is not the same as the agent version attribute (see Agent version).

PlexClientPlatforms

string

Comma-separated list of client platforms that can access this plug-in, or "*" for all platforms. See ClientPlatform constants for known values. The value is matched against the X-Plex-Platform (or X-Plex-Client-Platform) HTTP header sent by the client. This field is not restricted to a fixed set — the framework does not validate the values, so client platforms added after the framework release (e.g. Xbox) may also work if the client sends the corresponding header.

PlexMediaTypes

string

Comma-separated media type IDs this plug-in supports. See Media type IDs below.

PlexPluginCodePolicy

string

Security policy for the plug-in sandbox. Standard (default) runs under normal RestrictedPython restrictions. Elevated relaxes those restrictions to allow native libraries, extra built-ins, and import whitelist extensions. See Policy System for the full description of each policy level.

PlexPluginAPIExclusions

array

List of API kit names to exclude from the sandbox. For example, ["Agent"] prevents the plug-in from registering agents.

PlexPluginModuleWhitelist

array

List of additional Python module names that can be imported. Only effective when PlexPluginCodePolicy is Elevated. The default whitelist (available in all policies) is: re, string, datetime, time.

PlexBundleVersion

string

Version number of the plug-in bundle.

PlexPluginClass Values

Value

Description

Agent

A metadata agent plug-in. Provides search() and update() methods to fetch metadata for library items.

Resource

A resource plug-in that provides services (URL Services, Search Services, Related Content Services) or shared code. Does not appear in the user interface directly.

Note

The official documentation listed Content as a valid value for channel plug-ins, but in practice most channel plug-ins omit PlexPluginClass entirely or use Resource.

PlexMediaTypes

ID

Media Type

1

Movie

2

TV Show

8

Artist (Music)

9

Album (Music)

13

Photo

Service Keys

Services can be declared in Info.plist using the old-style plist keys below, or in a separate ServiceInfo.plist file using the new-style format. See Channel Plugins for full details on both approaches.

Key

Description

PlexURLServices

Dict of URL services. Each entry maps a service name to a dict with Identifier (str), URLPatterns (array of regex strings), and optionally TestURLs (array of test URL strings), Fallback (bool), SourceTitle (str), Priority (int).

PlexSearchServices

Dict of search services. Each entry maps a service name to a dict with Identifier (str) and optionally TestQueries (array), SourceTitle (str).

PlexRelatedContentServices

Dict of related content services. Each entry maps a service name to a dict with Identifier (str) and optionally SourceTitle (str). Must share an Identifier with the associated URL service.

Old-style URL service example:

<key>PlexURLServices</key>
<dict>
  <key>YouTube</key>
  <dict>
    <key>Identifier</key>
    <string>com.plexapp.plugins.youtube</string>
    <key>URLPatterns</key>
    <array>
      <string>http://.*youtube\.com/(watch)?\?v=</string>
    </array>
    <key>TestURLs</key>
    <array>
      <string>http://youtube.com/watch?v=vzKbhxY1eQU</string>
    </array>
  </dict>
</dict>

Full Agent Example

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN"
  "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>CFBundleIdentifier</key>
  <string>com.plexapp.agents.mymovieagent</string>
  <key>PlexPluginClass</key>
  <string>Agent</string>
  <key>PlexClientPlatforms</key>
  <string>*</string>
  <key>PlexMediaTypes</key>
  <string>1</string>
  <key>PlexFrameworkVersion</key>
  <string>2</string>
  <key>PlexBundleVersion</key>
  <string>1.0.0</string>
</dict>
</plist>

Full Service Bundle Example

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN"
  "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>CFBundleIdentifier</key>
  <string>com.plexapp.plugins.myservice</string>
  <key>PlexPluginClass</key>
  <string>Resource</string>
  <key>PlexFrameworkVersion</key>
  <string>2</string>
  <key>PlexURLServices</key>
  <dict>
    <key>MyService</key>
    <dict>
      <key>Identifier</key>
      <string>com.plexapp.plugins.myservice</string>
      <key>URLPatterns</key>
      <array>
        <string>https?://.*example\.com/video/</string>
      </array>
    </dict>
  </dict>
  <key>PlexSearchServices</key>
  <dict>
    <key>MySearch</key>
    <dict>
      <key>Identifier</key>
      <string>com.plexapp.plugins.myservice</string>
    </dict>
  </dict>
</dict>
</plist>