# Redplug Media — setup for AI agents

Redplug Media is a private MCP server for image, video, 4K export, narration, music, subtitles and background removal. An agent installs it with no person involved: it gets an anonymous connection key itself, installs for its client, checks the connection and then introduces the features to the user. Claude Code, Codex, OpenClaw and Gemini CLI all read the key from one environment variable. Only Claude Desktop custom connectors (OAuth accounts) sign in once in a browser.

- MCP URL: `https://ai.redplug.co.kr/v2/mcp` (streamable HTTP)
- Connection key (no password): header `Authorization: Bearer <key>`, read from the environment variable `REDPLUG_MEDIA_KEY`
- Get a key: https://www.redplug.co.kr/plugin-service/#key or `POST https://ai.redplug.co.kr/v2/keys` with JSON `{"email": "...", "name": "...", "privacy_consent": true}`
- Accounts (optional, Claude Desktop custom connectors): OAuth 2 + PKCE, client id `redplug-media-agents`, scopes `openid redplug:media`
- Plugins (Claude Code, Codex): public repository `azossy/redplug-media-plugins`, marketplace `redplug`
- Machine-readable: https://www.redplug.co.kr/downloads/redplug-media/v2/agent-setup.json
- Agent skill: https://www.redplug.co.kr/downloads/redplug-media/v2/SKILL.md
- Version: 2.18.0

Agents never type passwords and never print connection keys. The key is anonymous by default (no email, no consent needed); a key tied to an email is made only when the user asks, after they agree to the privacy notice.

## Quick start for agents (no person needed)

Install Redplug Media for the client you are running in, with no person involved, then tell the user what it can do and how to use it.

1. Know your client: claude-code, codex, openclaw, gemini-cli, claude-desktop or other (see clients).
2. Remove old installs first if present: clients.<client>.replaces and migrate_from_1x.
3. Connection key: use an existing one; otherwise get an anonymous key with connection_key.agent_issue (download the helper, check helper.sha256, run it; in Claude Code add --claude-code). Never print the key.
4. Install for your client: clients.<client> install / register / skill (Codex: the plugin; OpenClaw: register + skill; other MCP clients: the "other" method with SKILL.md).
5. Check: the helper output ok and verified.ok must be true (the key was accepted; verified.ready says whether every part can take work right now). With --claude-code, claude_code.mcp_list must say Connected. If your client already loaded the tools, call server_status yourself.
6. Introduce it: present verified.welcome (the same as media_guide(kind="overview", topic="welcome")) in the user's language: what it can do, example requests, how results appear, then three first things to try.
7. Say what is left for the user, if anything: restart the app that must load the new key or plugin (a new Claude Code session from a new terminal, the Codex app, the OpenClaw Gateway, Gemini CLI). Only Claude Desktop custom connectors use an account sign-in, which needs the user once.

## Connection key

Anyone may ask, as often as needed. Without email and name the key is anonymous: nothing personal is kept, so no consent is asked and an agent can get it with no person involved. With an email or name, send privacy_consent=true only after the user agreed to privacy_notice. Each key has its own jobs; put the same key on several computers to share them. Do not echo the key in chat or logs.

macOS/Linux: add the line  export REDPLUG_MEDIA_KEY=<key>  to ~/.zshrc (zsh) or ~/.bashrc (bash), replacing an older REDPLUG_MEDIA_KEY line; Windows: setx REDPLUG_MEDIA_KEY <key>. Then open a new terminal; apps that are already running read it after a restart.

### Getting a key as an agent

An agent gets the key itself, by default anonymously (no email, no consent, no person involved). Use --email only when the user asks for a key tied to their email; never invent an email or consent.

1. Check for an existing key: the environment variable REDPLUG_MEDIA_KEY (echo "${REDPLUG_MEDIA_KEY:+set}" prints only "set"), or for Claude Code an installed redplug-media plugin that connects (claude mcp list). If one exists, use it and do not get another.
2. Anonymous by default: no question to the user is needed. Only if the user wants the key tied to their email, ask for it (and an optional name).
3. With an email or name only: show privacy_notice in the user's language and get a clear yes; stop if they do not agree.
4. Download the helper and check its SHA-256: curl -fsSLo redplug-media-key.py https://www.redplug.co.kr/downloads/redplug-media/v2/redplug-media-key.py && shasum -a 256 redplug-media-key.py (Windows: certutil -hashfile redplug-media-key.py SHA256); it must equal helper.sha256.
5. Run it: python3 redplug-media-key.py [--claude-code] (anonymous), or with --email <email> --agree [--name <name>] (Windows: py redplug-media-key.py ...). It requests the key and writes it into the shell profile (export REDPLUG_MEDIA_KEY=...) or setx, calls server_status once with the key (verified.ok) and fetches the introduction for the user (verified.welcome); with --claude-code it also installs or updates the Claude Code plugin and checks that Claude Code connects (claude_code.mcp_list). With a key already set it requests no new one (--claude-code then sets up the plugin with that key). It prints JSON without the key; ok is false when a step failed.
6. Continue the client setup below, then present verified.welcome to the user and say which app needs a restart.

Helper: https://www.redplug.co.kr/downloads/redplug-media/v2/redplug-media-key.py (SHA-256 `b2a11e80afe9cddf64b98b2da9f756bdbd1a3b40fd0b2ee03d358477da41192a`, Python 3.8+ (standard library only)). Exit codes: 0 ok, 2 input or no consent, 3 server, network or key not accepted (error.code, message, guidance as JSON), 4 storing failed, 5 Claude Code did not connect (the key is stored).

Privacy notice (version 2026-11-27), show it before asking for consent:

> 이메일과 이름(선택)을 연결 키 발급과 관리, 문의 대응에 씁니다. 키를 회수하거나 삭제를 요청하실 때까지 보관합니다. 동의하지 않으면 키를 받을 수 없습니다.
>
> Your email and (optional) name are used to issue and manage connection keys and to answer inquiries. They are kept until the key is revoked or you ask for deletion. Without consent no key can be issued.

Without Python: POST to issue.url yourself and write the key straight into the profile line export REDPLUG_MEDIA_KEY=<key> (or setx) without displaying it; do not paste it into chat.

## Claude Code (plugin)

Key: The plugin reads the key from the environment variable REDPLUG_MEDIA_KEY (the same one Codex, OpenClaw and Gemini CLI read). Agents: run the key helper with --claude-code (connection_key.agent_issue): it stores the key, installs or updates the plugin and checks the connection, so the install step below is already done. A key typed into /plugin → Installed → redplug-media → Configure (system credential store) is used only while REDPLUG_MEDIA_KEY is unset; "1 userConfig option not yet set" after installing is normal when REDPLUG_MEDIA_KEY holds the key. Claude Code reads REDPLUG_MEDIA_KEY when it starts: start a new session from a new terminal (desktop app: quit and reopen it).

If an older direct registration exists, remove it first: claude mcp remove redplug-media --scope user; rm -rf ~/.claude/skills/redplug-media

```bash
claude plugin marketplace add azossy/redplug-media-plugins
claude plugin install redplug-media@redplug --scope user
```

Auto-update: Third-party marketplaces start with auto-update off. Turn it on: add "autoUpdate": true beside "source" in extraKnownMarketplaces.redplug of ~/.claude/settings.json, or in Claude Code /plugin → Marketplaces → redplug → Enable auto-update. Manual: claude plugin marketplace update redplug && claude plugin update redplug-media@redplug

Verify: `claude mcp list  (plugin:redplug-media:redplug-media … Connected)`.

## Codex app and CLI (plugin)

If ~/.codex/config.toml has a direct [mcp_servers.redplug-media] table or ~/.codex/skills/redplug-media exists, remove them first so the plugin is the only registration. Remove plugin 1.0.x first as well (migrate_from_1x): its marketplace has the same name, redplug.

```bash
codex plugin marketplace add azossy/redplug-media-plugins
codex plugin add redplug-media@redplug
```

Key: macOS/Linux: add the line  export REDPLUG_MEDIA_KEY=<key>  to ~/.zshrc (zsh) or ~/.bashrc (bash), replacing an older REDPLUG_MEDIA_KEY line; Windows: setx REDPLUG_MEDIA_KEY <key>. Then open a new terminal; apps that are already running read it after a restart. The Codex app reads the login shell environment: restart it afterwards.

Codex desktop app: if `codex` is not on PATH, use the CLI inside the app (macOS ChatGPT app: /Applications/ChatGPT.app/Contents/Resources/codex-cli/bin/codex). Restart the app afterwards. Codex does not update the plugin by itself (measured 2026-11-28: an install stayed on 2.7.0 through nine releases). To update: codex plugin marketplace upgrade redplug, then restart the Codex app; codex plugin list shows the installed version.

Verify: `codex mcp list  (redplug-media … Bearer token), then call server_status`.

## OpenClaw

```bash
openclaw mcp set redplug-media '{"url":"https://ai.redplug.co.kr/v2/mcp","transport":"streamable-http","headers":{"Authorization":"Bearer ${REDPLUG_MEDIA_KEY}"}}'
mkdir -p ~/.openclaw/skills/redplug-media && curl -fsSL https://www.redplug.co.kr/downloads/redplug-media/v2/SKILL.md -o ~/.openclaw/skills/redplug-media/SKILL.md
```

Key: macOS/Linux: add the line  export REDPLUG_MEDIA_KEY=<key>  to ~/.zshrc (zsh) or ~/.bashrc (bash), replacing an older REDPLUG_MEDIA_KEY line; Windows: setx REDPLUG_MEDIA_KEY <key>. Then open a new terminal; apps that are already running read it after a restart. The OpenClaw Gateway must see REDPLUG_MEDIA_KEY; restart it after setting the variable. OpenClaw replaces ${REDPLUG_MEDIA_KEY} in config values with the environment variable. Accounts can use OAuth instead: openclaw mcp set redplug-media '{"url":"https://ai.redplug.co.kr/v2/mcp","transport":"streamable-http","auth":"oauth","oauth":{"scope":"redplug:media"}}' and openclaw mcp login redplug-media. Verify: `openclaw mcp doctor redplug-media --probe`.

## Gemini CLI (extension)

Key: macOS/Linux: add the line  export REDPLUG_MEDIA_KEY=<key>  to ~/.zshrc (zsh) or ~/.bashrc (bash), replacing an older REDPLUG_MEDIA_KEY line; Windows: setx REDPLUG_MEDIA_KEY <key>. Then open a new terminal; apps that are already running read it after a restart. Gemini CLI reads it when it starts.

An older extension (OAuth, before 2.16.0) is replaced: gemini extensions uninstall redplug-media first.

```bash
curl -fsSLO https://www.redplug.co.kr/downloads/redplug-media/v2/redplug-media-gemini.zip
shasum -a 256 redplug-media-gemini.zip
unzip -o redplug-media-gemini.zip -d ~/.cache/redplug-media
gemini extensions install ~/.cache/redplug-media/redplug-media --consent
```

Zip SHA-256 `e2298b66feff91d9108bff076e885a7469ee901199af8c4b8c1c786e6fcb5678`: The shasum output must equal zip_sha256 (Windows: certutil -hashfile redplug-media-gemini.zip SHA256); stop if it does not. Without --consent Gemini CLI shows the server address and asks "Do you want to continue? [y/N]". The user asked for this install, so an agent passes --consent (measured 2026-11-28, Gemini CLI 0.71.1: installs with no prompt; an answer fed to the prompt through a pipe or a file was sometimes lost and the install was cancelled). Verify: With REDPLUG_MEDIA_KEY set: gemini mcp list  (redplug-media (from redplug-media) … Connected). If it shows Disabled, run it in a folder Gemini CLI trusts.

## Claude Desktop and claude.ai

Settings → Connectors → Add custom connector. URL https://ai.redplug.co.kr/v2/mcp. Advanced settings → OAuth Client ID redplug-media-agents (no client secret). Then Connect and sign in. Custom connectors sign in with OAuth, so they need an account (no connection key). Claude Desktop and claude.ai render the Redplug Media Studio cards (progress, preview, save, pick, save all).

## Other MCP clients

Add a remote MCP server (streamable HTTP) at https://ai.redplug.co.kr/v2/mcp that sends the header "Authorization: Bearer <key>" (read it from REDPLUG_MEDIA_KEY); accounts can use OAuth instead (client id redplug-media-agents, scopes openid redplug:media). Add SKILL.md as the agent instructions.

## Moving from plugin 1.0.x

Plugin 1.0.x (redplug-visual-engine) used the retired /visual/mcp address and revoked connection keys. It cannot update itself to 2.x; remove it, get a new key, then set up redplug-media as above. Old job ids keep working for their owners.

```bash
codex plugin remove redplug-visual-engine@redplug; codex plugin marketplace remove redplug
```

Old install files: rm -rf ~/.local/share/redplug-plugins (Windows: %LOCALAPPDATA%\Redplug\plugins)

## Updates

Server features, models and guides change on the server and reach every client at once. Plugin files (address, skill) update from the public plugin repository.

## After setup

Call `server_status(locale="ko") must return ready=true`. Then read `media_guide(kind="overview")`.
