Skip to main content
BuildReviewed Aug 31, 2026

Mediaserver Operation

v4.0.0New

Unsigned, install at your own risk

Unverified

This skill has no cryptographic signature attached. We can't verify the contents match what the publisher intended.

Install this skill

No account required. Pick your tool, then copy.

Run in your terminal. It detects your AI tool.

npx @skills-hub-ai/cli install moviepilot-mediaserver-operation

What this does: Use this skill when the user asks to inspect, diagnose, or directly operate a configured Emby, Jellyfin, Plex, ZSpace, UGREEN, TrimeMedia, or Navidrome server. It discovers provider capabilities on demand and supports libraries, native movie/music search, episode coverage, recent media, resume state, playback sessions, statistics, scans, metadata refreshes, and provider play URLs without adding permanent tools.

Or get the file:
Browse all CLI commands →
Manual setup by platform

Claude Code

~/.claude/skills/moviepilot-mediaserver-operation/SKILL.md

Setup guide →
0Save

Instructions

Media Server Operation

Use scripts/mp-mediaserver.py. The helper reads MoviePilot's local server
configuration and credentials itself. Never request, print, or pass a host,
username, password, API key, token, Cookie, or arbitrary URL.

Run the bundled copy from the MoviePilot program directory with its project
runtime, for example:

cd <MOVIEPILOT_ROOT>
python skills/mediaserver-operation/scripts/mp-mediaserver.py instances

The Agent command environment routes python to the project-specific moviepilot-python
entry when available and falls back to the project or Docker VENV_PATH Python otherwise.
Media-server connections may depend on macOS local-network permissions, so use the provided
python command for every operation.

The runtime sets MOVIEPILOT_ROOT for copied skills. If you run a copied
script directly from <CONFIG_PATH>/agent/skills/, set that variable to the
program directory first; otherwise the helper returns a clear relocation
error. Do not use a system python3 when it does not meet MoviePilot's
required Python version.

Boundary

  • Keep library.exists in moviepilot-api for canonical duplicate checks. It
    aggregates configured servers and applies MoviePilot media identity and music
    matching rules.
  • Use this Skill for server-native exploration, diagnostics, playback state,
    library browsing, scans, and metadata refreshes.
  • The separate REST library.latest operation returns nullable item_type,
    played, and unplayed_count for the querying account. Emby/Jellyfin/Plex
    Series/Season counts mean existing unwatched episodes, never missing episodes.
    Unsupported or absent fields stay unknown; never infer watched state from
    library membership or replace unknown counts with zero. Refresh the same
    account/server/item scope after playback; bound-credential failures do not
    fall back to an administrator. These fields do not extend this skill's
    provider-native action arguments.
  • A provider result is not automatically a MoviePilot transfer, subscription,
    or history fact. Use the appropriate MoviePilot API for those workflows.
  • Native App playback manifests select a stream source in the MoviePilot REST API:
    media-server items prefer the server's original stream and fall back to a readable
    local file when unsupported; single-file tickets from file management and media
    organization always read locally. This does not change this skill's playback
    session actions; never pass web links, credentials, or upstream URLs through the App bridge.

Instance And Provider Discovery

Fast path: call directly

Do not routinely call instances or capabilities before an operation. This
Skill already contains the full action contract, and the helper performs
instance resolution, provider support checks, complete argument validation, and
the action in one call invocation.

  • If the user or prior context provides the exact server name, pass it with
    --server and call the action immediately.
  • If no server name is known, omit --server. The helper automatically uses the
    only enabled media server.
  • If multiple servers remain ambiguous, the failed call lists every valid
    server name. Reuse that list for the next direct call; do not add a separate
    instances call unless the user explicitly asks to inspect instances.
  • Do not probe an action with empty or guessed arguments. Compose the complete
    JSON object from the contract below before calling.

The helper rejects unknown fields and reports all detectable argument errors in
one response before connecting to the provider, so correct every reported field
together instead of retrying one field at a time.

Optional discovery

python skills/mediaserver-operation/scripts/mp-mediaserver.py instances
python skills/mediaserver-operation/scripts/mp-mediaserver.py capabilities
python skills/mediaserver-operation/scripts/mp-mediaserver.py capabilities --server "living-room"

The complete action and argument contract is documented below. Use
capabilities only to confirm which documented actions a configured provider
supports. For a compact machine-readable copy of one action's same contract:

python skills/mediaserver-operation/scripts/mp-mediaserver.py capabilities \
  --server "living-room" \
  --action items.season_episodes

Do not inspect the helper source to discover arguments and do not guess a
provider-specific action. capabilities is optional and should be used only
when the configured provider itself is unknown or support must be diagnosed.

Call Shape

python skills/mediaserver-operation/scripts/mp-mediaserver.py call \
  --server "living-room" \
  --action activity.latest \
  --arguments '{"limit":20}'

The --arguments value must be one JSON object. List reads default to 50 items
and cap at 200.

External MCP Contract

External MCP clients do not receive this SKILL.md and cannot use the hidden
execute_command tool. MoviePilot therefore exposes a separate admin-only MCP
tool named mediaserver_operation. Its tools/list inputSchema contains one
oneOf branch for every action below, including the function description,
supported providers, effect, field types, required/default values, enums,
nested metadata.refresh item fields, and cross-field rules. The external
client should select the matching branch and make one tools/call; it does not
need to call a discovery tool first.

The default schema mode is full. Clients explicitly sending
X-MCP-Schema-Mode: compact receive a best-effort projection for oversized
schemas, without action-specific branches. Use this contract or the full
GET /api/v1/mcp/tools/{tool_name}/schema response for exact arguments;
call-time validation and authorization are unchanged.

MCP call arguments use the same contract without shell quoting:

{
  "server": "living-room",
  "action": "items.season_episodes",
  "arguments": {
    "item_id": "exact-series-id",
    "season": 2
  }
}

server may be omitted when only one media server is enabled. If multiple
instances remain ambiguous, the result lists the valid server names.

Complete Action Contract

This is the complete Media Server Operation action contract. It comes directly from the script ACTIONS registry and matches the external MCP tools/list oneOf branches.
A field name ending in * is required. Put every action parameter in the arguments object.

actionPurpose and argument summary
activity.backdrops读取服务近期媒体的背景图。; arguments: limit, remote
activity.latest读取服务最近添加的媒体条目。; arguments: limit, username, query
activity.resume读取服务中正在观看或可继续播放的媒体条目。; arguments: limit, username, query
capabilities.list列出支持的媒体服务器动作及完整参数契约。; arguments: action_name
instances.list列出已配置的媒体服务器实例,不返回连接凭据。; no arguments
items.count统计指定媒体库或父条目下的内容数量。; arguments: parent
items.detail按服务原生标识读取单个媒体条目。; arguments: item_id*, query
items.list分页读取指定媒体库或父条目下的内容。; arguments: parent, offset, limit, query
items.movies.search按标题及可选年份搜索服务中的电影条目。; arguments: title*, year, query
items.music.search按标题、艺术家或专辑搜索服务中的音乐。; arguments: title, artist, album, query
items.season_episodes读取指定剧集及可选季的现有分集信息。; arguments: item_id, title, year, season, query
libraries.list列出可见媒体库。; arguments: hidden, username, query
library.scan触发媒体库扫描。; arguments: scan_mode
metadata.refresh刷新匹配条目的服务端元数据。; arguments: items*
playback.sessions读取正在进行的播放会话。; no arguments
playback.url生成单个条目的服务播放链接。; arguments: item_id*
server.statistics读取媒体数量及服务统计。; no arguments
server.user.library_folders读取当前用户可见的媒体库目录。; no arguments
server.users.count读取服务用户数量。; no arguments

activity.backdrops

读取服务近期媒体的背景图。 Effect: safe_read. Providers: ugreen, trimemedia, mediavault.

  • limit (integer; default 50): 返回条目数量,范围为 1 至 200。
  • remote (boolean; default False): 是否返回可远程访问的服务 URL。

activity.latest

读取服务最近添加的媒体条目。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • limit (integer; default 50): 返回条目数量,范围为 1 至 200。
  • username (string): 按该用户名读取;Emby、Jellyfin 和 ZSpace 支持。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。

activity.resume

读取服务中正在观看或可继续播放的媒体条目。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • limit (integer; default 50): 返回条目数量,范围为 1 至 200。
  • username (string): 按该用户名读取;Emby、Jellyfin 和 ZSpace 支持。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。

capabilities.list

列出支持的媒体服务器动作及完整参数契约。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • action_name (string): 可选的精确动作名称,填写时只返回该动作的能力契约。

instances.list

列出已配置的媒体服务器实例,不返回连接凭据。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • arguments: {}

items.count

统计指定媒体库或父条目下的内容数量。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • parent (string|integer): 媒体库或父条目标识;Navidrome 可省略并使用 music。
  • Rule: 除 Navidrome 外必须提供 parent;Navidrome 默认使用 music。

items.detail

按服务原生标识读取单个媒体条目。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • item_id* (string): 所选媒体服务器返回的原生条目标识。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。

items.list

分页读取指定媒体库或父条目下的内容。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • parent (string|integer): 媒体库或父条目标识;Navidrome 可省略并使用 music。
  • offset (integer; default 0): 列表偏移量,从 0 开始。
  • limit (integer; default 50): 返回条目数量,范围为 1 至 200。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。
  • Rule: 除 Navidrome 外必须提供 parent;Navidrome 忽略该参数。

items.movies.search

按标题及可选年份搜索服务中的电影条目。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, mediavault.

  • title* (string): 电影标题。
  • year (string|integer): 可选的发行年份。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。

items.music.search

按标题、艺术家或专辑搜索服务中的音乐。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, navidrome.

  • title (string): 曲目、专辑或音乐条目标题。
  • artist (string): 艺术家名称。
  • album (string): 专辑名称;须提供 title、artist 或 album。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。
  • Rule: Provide at least one of title, artist, and album.

items.season_episodes

读取指定剧集及可选季的现有分集信息。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, mediavault.

  • item_id (string): 所选媒体服务器返回的原生条目标识。
  • title (string): 剧集标题;须提供本字段或 item_id。
  • year (string|integer): 可选的首播年份。
  • season (integer): 可选的季编号。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。
  • Rule: Provide at least one of item_id and title.

libraries.list

列出可见媒体库。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • hidden (boolean; default False): 只返回已配置为同步的媒体库。
  • username (string): 读取该用户名可见的媒体库;Emby、Jellyfin 和 ZSpace 支持。
  • query (object): 统一内容投影,如 {"fields":["identity","path"]};省略或 fields=null 保留原内容,fields=[] 仅取基础信息。

library.scan

触发媒体库扫描。 Effect: external_side_effect. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • scan_mode (string|integer): UGREEN 原生扫描模式;其他服务必须省略。

metadata.refresh

刷新匹配条目的服务端元数据。 Effect: external_side_effect. Providers: emby, plex, zspace, ugreen, trimemedia.

  • items* (object[]): 待刷新的条目。每项支持 title 字符串、year 字符串或整数、type 精确 MoviePilot 媒体类型值、category 字符串及 target_path 字符串。

playback.sessions

读取正在进行的播放会话。 Effect: safe_read. Providers: emby, jellyfin, plex.

  • arguments: {}

playback.url

生成单个条目的服务播放链接。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • item_id* (string): 所选媒体服务器返回的原生条目标识。

server.statistics

读取媒体数量及服务统计。 Effect: safe_read. Providers: emby, jellyfin, plex, zspace, ugreen, trimemedia, navidrome, mediavault.

  • arguments: {}

server.user.library_folders

读取当前用户可见的媒体库目录。 Effect: safe_read. Providers: emby, jellyfin, zspace.

  • arguments: {}

server.users.count

读取服务用户数量。 Effect: safe_read. Providers: emby, jellyfin, zspace, ugreen, trimemedia, navidrome, mediavault.

  • arguments: {}

Safety And Verification

  • Before library.scan, confirm the exact server and scan scope/mode.
  • Before metadata.refresh, confirm the exact item list because providers may
    perform a broad library refresh when a precise item cannot be mapped.
  • After a scan or refresh, verify with activity.latest, items.detail, or the
    smallest relevant library query.
  • If a provider does not advertise an action, report it as unsupported. Never
    fall back to raw HTTP, arbitrary SDK methods, or credentials copied from
    MoviePilot settings.

Query Content Projection

Emby, Jellyfin, Plex and Navidrome read actions accept an optional query object.
Omit it for ZSpace, TrimeMedia, UGREEN and Vyo, whose adapters have not adopted it.
Omitting query or setting fields to null preserves the existing content;
fields: [] requests only the information required by the operation.

{"parent":"movies","limit":50,"query":{"fields":["identity","path","year"]}}

The field groups are library, original_title, year, identity, path,
music, user_state, images, counts and link. Matching and scope checks
retain their required dependencies, including music album completeness.
Adapters translate supported options into remote request parameters. Servers may
still return default attributes when their protocol cannot select those fields.
See docs/media-server-query.md for the mappings and compatibility limits.

Manual watched-state changes in the native App use REST POST /api/v1/mediaserver/played
with server, item_id, and boolean played. This requires the current user's valid
Emby/Jellyfin/Plex binding and never falls back to an administrator. A successful
unmark returns success=true,data=false; refresh authoritative item and parent
counts afterward. This REST route does not add a gateway or provider action.

This skill doesn’t include stateful context yet, instructions only. Learn about stateful skills.

Security

Loading security scan...

Reviews (0)

Browse all →
anysearchReal-time search engine supporting web search, vertical domain search, parallel batch search, and URL content extraction.0 installsdownloader-operationUse this skill when the user asks to inspect, diagnose, or directly control a configured qBittorrent, Transmission, or rTorrent instance. It exposes provider capabilities on demand without adding permanent Agent tools, and is suitable for task files and selection, trackers, peers, queue order, limits, tags, locations, rechecks, direct provider submissions, or batch task control.0 installsgenerate-identifiersUse this skill when a user provides a torrent name or file name and wants to fix recognition issues, or asks to add/manage custom identifiers (自定义识别词). This skill generates identifier rules based on the WordsMatcher preprocessing logic, checks for duplicates against existing rules, and saves them through the structured MoviePilot API gateway. Because custom identifiers are global, generated rules must default to conservative, sample-specific regex patterns instead of broad matches unless the user explicitly wants global cleanup. Applicable scenarios include: 1) A torrent or file name is incorrectly recognized (wrong title, season, episode, etc.); 2) The user wants to block unwanted keywords from torrent names; 3) The user needs episode offset rules for series with non-standard numbering; 4) The user wants to force recognition of a specific media by source-native ID; 5) The user wants TV recognition to use a specific TMDB episode group.0 installscommand-dispatchUse this skill when the user sends a slash command or asks to run a MoviePilot system or plugin command in natural language. Discover the live command catalog, resolve the exact command, and dispatch it through the structured API gateway.0 installsmoviepilot-updateUse this skill to check MoviePilot versions, inspect Release update state, download a Release update in the background, confirm installation, restart MoviePilot, or retain the existing Dev branch update flow. Prefer the built-in system APIs instead of container commands or manual file replacement.0 installscreate-moviepilot-skillUse this skill when the user asks to create, scaffold, update, or review a MoviePilot agent skill. This includes adding a new built-in skill under the repository `skills/` directory, editing an existing built-in skill, writing `SKILL.md` frontmatter and workflow instructions, choosing `allowed-tools`, adding helper scripts when needed, and bumping the built-in skill `version` so changes can sync into `config/agent/skills`.0 installs

More from MoviePilot

View source →
publish-moviepilot-pluginUse this skill when the user asks to publish, upload, sync, pull, push, diff, or maintain a MoviePilot local plugin in a GitHub repository. Covers using the configured MoviePilot GitHub token, PLUGIN_LOCAL_REPO_PATHS local plugin repositories, package.json/package.v2.json/package.v3.json metadata, plugins/plugins.v2/plugins.v3 layouts, safe file exclusion, diff preview before publishing, incremental GitHub Contents API updates, and syncing local plugin changes back from GitHub. Includes asking whether to use an existing repository or create a new public repository when no target repository is available. Also use for Chinese requests mentioning 插件发布, 插件维护, 推送插件到 GitHub, 从 GitHub 拉取插件, 同步本地插件仓库, 增量发布插件, 插件仓库维护.1 installsmoviepilot-apiUse this skill for MoviePilot product operations such as media search, torrent search, downloads, subscriptions, library checks, sites, storage, workflows, schedulers, plugins, filter rules, and system settings. It authorizes the structured moviepilot_api gateway only; it does not authorize arbitrary HTTP, legacy Agent tools, MCP compatibility commands, authentication headers, or API tokens.0 installsdatabase-operationUse this skill when you need to inspect, query, maintain, or carefully modify the MoviePilot database. This skill uses the bundled scripts/mp-db.py helper, which reads MoviePilot local settings itself and never requires database passwords or full PostgreSQL DSNs in the agent prompt. Applicable scenarios include data statistics, counts, aggregations, inspecting or fixing records, cleanup requests, and questions like "how many downloads", "show site stats", "delete old records", or "why is this subscription stuck".0 installssubmit-pull-requestUse this skill ONLY when the user explicitly asks to create, submit, push, or open a GitHub Pull Request for code changes. It prepares an isolated clone, reuses or creates the authenticated user's Fork, previews the real Git diff, and after exact confirmation commits and pushes the branch before creating the PR. It does not support submitting files from a non-Git directory.0 installsfeedback-issueUse this skill ONLY when the user EXPLICITLY requests filing an upstream issue for MoviePilot core, frontend, or an installed plugin, for example "反馈 issue", "提 issue", "报 bug", "给 MP 提 issue", "让上游修一下", "提交错误报告", "提问题", "提需求", "功能请求", or English "file an issue / report a bug / open an upstream issue / feature request". A bare problem report is not enough: diagnose locally first. This skill uses its own scripts under `scripts/`; it does not add or call dedicated Agent tools for collect / prepare / submit.0 installsbrowser-useUse this skill when the user asks the agent to open, browse, inspect, extract content from, click through, fill forms on, screenshot, or verify a web page with a browser. Also use it for MoviePilot scenarios that need browser interaction, such as checking a site page, confirming a JavaScript-rendered result, testing login state, capturing visible errors, or updating and validating tracker site cookies.0 installs

More Build skills

Browse category →
senior-frontendBuild and review React, Next.js, TypeScript or Tailwind frontends: components, scaffolding, performance and bundle size. Use whenever the user wants a new component or app, a page feels slow, the bundle is too big, or asks for a frontend code review.653 installsui-design-systemUse when building a design system: tokens, component docs, responsive scales or developer handoff. Generates tokens with design_token_generator.py.553 installsfrontend-designGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making choices that don't read as templated defaults.365 installssenior-backendBuild and fix backend services: REST or GraphQL APIs, auth, microservices, PostgreSQL queries, migrations and load tests. Use whenever the user's API is slow or broken, needs login or auth added, a schema change, or a new endpoint or service scaffolded.266 installsself-improving-agentCurate what the agent has learned into durable project knowledge. Reviews Claude Code auto-memory (MEMORY.md and its topic files) for learnings worth keeping, promotes proven ones into CLAUDE.md or .claude/rules/, records a correction as a lesson that persists across sessions, prunes stale or duplicate entries, and turns a recurring fix into a reusable skill. Use whenever the user asks what you have learned or saved about the project, which memories should become permanent rules, to remember a lesson or stop repeating a mistake, or to clean up, audit or check memory health.185 installsusing-superpowersUse when starting any conversation - establishes how to find and use skills, requiring skill invocation before ANY response including clarifying questions149 installs

Frequently asked questions about mediaserver-operation

What does the mediaserver-operation skill do?

Use this skill when the user asks to inspect, diagnose, or directly operate a configured Emby, Jellyfin, Plex, ZSpace, UGREEN, TrimeMedia, or Navidrome server. It discovers provider capabilities on demand and supports libraries, native movie/music search, episode coverage, recent media, resume state, playback sessions, statistics, scans, metadata refreshes, and provider play URLs without adding permanent tools. It's a reusable SKILL.md instruction set that loads into your AI coding assistant on demand, no prompt engineering, no copy-pasting every session.

How do I install the mediaserver-operation skill?

Run `npx @skills-hub-ai/cli install moviepilot-mediaserver-operation` from your terminal. The CLI writes the SKILL.md to the correct location for your AI tool (e.g. ~/.claude/skills/moviepilot-mediaserver-operation/ for Claude Code or ~/.cursor/skills/ for Cursor with --target cursor) and adds it to your project's .skills.json lockfile.

Which AI tools does mediaserver-operation work with?

mediaserver-operation runs in Claude Code. It follows the open Agent Skills standard (SKILL.md), so the same skill works in every supported tool without modification.

Is the mediaserver-operation skill free?

Yes. Every skill on skills-hub.ai is free and open-source. There are no premium tiers, paywalls, or usage limits. You only pay for whatever AI assistant you're already using.

How do I use mediaserver-operation after installing it?

In Claude Code, type `/moviepilot-mediaserver-operation` (or whatever slash command the skill registers) and the AI follows the skill's instructions immediately. You can also reference it by name in natural language, your AI loads the skill into context when relevant.

Can I share the mediaserver-operation skill with my team?

Yes. Commit your project's .skills.json lockfile and teammates run `npx @skills-hub-ai/cli install` (no args) to install every skill at the exact version you pinned. Organization-scoped installs work via skills-hub.ai organizations.