impeccable
The design vocabulary for your coding agent. Steer with polish and bolder, review with critique and audit, catch AI slop before it ships.
MCP server for OpenAI Images/Videos and Google GenAI (Veo) media generation.
Skills that teach the AI this kind of work; they work alongside this one
The design vocabulary for your coding agent. Steer with polish and bolder, review with critique and audit, catch AI slop before it ships.
Editorial diagram design for Claude Code, Codex, GitHub Copilot, Cursor, Factory Droid, Qoder, and Pi. 45 diagram types. Self-contained HTML + SVG. No shadows. No Mermaid slop.
Create beautiful slides on the web using a coding agent's frontend skills
Lists are ordered by a usage score (out of 100) built from these parts
| Popularity | 12/80 | GitHub stars or weekly downloads: the larger counts 60, the smaller 20 |
|---|---|---|
| Freshness | 3/12 | Full marks for a release or code change within 30 days |
| Still answering | 0/8 | The cloud endpoint answered at the last check |
| Usage score | 15/100 |
Quality: Passed 2/3 basic checks (shown, not used for ordering) · Momentum: No data yet (Used only on the Trending tab)
Pick the AI app you use, then copy the settings.
Let your AI install it with one sentence
Please install Media Gen MCP. Follow https://mcp.popnx.com/i/strato-space-media-gen-mcp.md, show me the commands and wait for my OK before running them.Paste it into an AI that can work on your computer (such as Claude Code or Cursor). It reads our steps, shows you the commands and waits for your OK. No key, no sign-up. · See the full text your AI reads
Passed 2/3 checks · Runs on your computer · ✓ Commands checked Nov 14, 2026
First: which AI do you use?
Pick your app and the steps appear below.
Works with Claude, with some setup first
You need a Media Gen MCP key (create it on the maker’s site) · Install Node.js on your computer first (one time) · Only the Claude desktop app (Windows or Mac), not the web or phone
Copy this message into a Claude chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Media Gen MCP for Claude on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "media-gen": { "command": "npx", "args": [ "-y", "@strato-space/media-gen-mcp" ], "env": { "OPENAI_API_KEY": "your-value", "GEMINI_API_KEY": "your-value", "GOOGLE_API_KEY": "your-value" } } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Media Gen MCP tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
node -vMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed
Open the Node.js download page ↗
When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v
Install once; it works for everything that needs Node.js
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
How to get a key is in the maker’s README below
SettingsDeveloperEdit Config
{
"mcpServers": {
"media-gen": {
"command": "npx",
"args": [
"-y",
"@strato-space/media-gen-mcp"
],
"env": {
"OPENAI_API_KEY": "your-value",
"GEMINI_API_KEY": "your-value",
"GOOGLE_API_KEY": "your-value"
}
}
}
}Paste the key only into the app’s field, never into a chat or to anyone
Use Media Gen MCP and tell me what you can do for me, then show me one thing✓ If Claude says it is using Media Gen MCP or shows a Media Gen MCP tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
GOOGLE_GENAI_USE_VERTEXAI Set to true to use Vertex AI for Google GenAI.GOOGLE_CLOUD_PROJECT GCP project id for Vertex AI.GOOGLE_CLOUD_LOCATION GCP region for Vertex AI (e.g. us-central1).AZURE_OPENAI_API_KEY Azure OpenAI API key (optional).AZURE_OPENAI_ENDPOINT Azure OpenAI endpoint hostname.OPENAI_API_VERSION Azure OpenAI API version.AZURE_OPENAI_DEPLOYMENT Azure OpenAI deployment name.MEDIA_GEN_DIRS Comma-separated output directories for media files.MEDIA_GEN_URLS Comma-separated URL prefixes allowed for fetch tools.MEDIA_GEN_MCP_URL_PREFIXES Public URL prefixes for mapping local output files.MEDIA_GEN_MCP_TEST_SAMPLE_DIR Path to sample images for the test-images tool.Descriptions are as written by the maker.
Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version
ChatGPT cannot connect Media Gen MCP yet
Media Gen MCP runs on your computer, but ChatGPT can only connect servers that run on the web
A · Use an app that can connect Media Gen MCP
B · Others in Design, images & audio that work with ChatGPT
Picked from the most used in the same category, only ones that connect by address with no key
Works with Claude Code, with some setup first
You need a Media Gen MCP key (create it on the maker’s site) · Install Node.js on your computer first (one time)
Copy this message into a Claude Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Media Gen MCP for Claude Code on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): claude mcp add --scope user media-gen --env OPENAI_API_KEY=your-value --env GEMINI_API_KEY=your-value --env GOOGLE_API_KEY=your-value -- npx -y @strato-space/media-gen-mcp 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Media Gen MCP tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
node -vMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed
Open the Node.js download page ↗
When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v
Install once; it works for everything that needs Node.js
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
How to get a key is in the maker’s README below
Mac: press Command+Space and type Terminal · Windows: open PowerShell
claude mcp add --scope user media-gen --env OPENAI_API_KEY=your-value --env GEMINI_API_KEY=your-value --env GOOGLE_API_KEY=your-value -- npx -y @strato-space/media-gen-mcpReplace “your-value” with your key before pressing Enter
Paste the key only into the app’s field, never into a chat or to anyone
You should see Media Gen MCP listed as connected
Use Media Gen MCP and tell me what you can do for me, then show me one thing✓ If Claude Code says it is using Media Gen MCP or shows a Media Gen MCP tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
GOOGLE_GENAI_USE_VERTEXAI Set to true to use Vertex AI for Google GenAI.GOOGLE_CLOUD_PROJECT GCP project id for Vertex AI.GOOGLE_CLOUD_LOCATION GCP region for Vertex AI (e.g. us-central1).AZURE_OPENAI_API_KEY Azure OpenAI API key (optional).AZURE_OPENAI_ENDPOINT Azure OpenAI endpoint hostname.OPENAI_API_VERSION Azure OpenAI API version.AZURE_OPENAI_DEPLOYMENT Azure OpenAI deployment name.MEDIA_GEN_DIRS Comma-separated output directories for media files.MEDIA_GEN_URLS Comma-separated URL prefixes allowed for fetch tools.MEDIA_GEN_MCP_URL_PREFIXES Public URL prefixes for mapping local output files.MEDIA_GEN_MCP_TEST_SAMPLE_DIR Path to sample images for the test-images tool.Descriptions are as written by the maker.
Menu names checked against Anthropic’s help page on Nov 11, 2026 · your screen may differ slightly by app version
Works with Cursor, with some setup first
You need a Media Gen MCP key (create it on the maker’s site) · Install Node.js on your computer first (one time)
Copy this message into a Cursor chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Media Gen MCP for Cursor on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "mcpServers": { "media-gen": { "command": "npx", "args": [ "-y", "@strato-space/media-gen-mcp" ], "env": { "OPENAI_API_KEY": "your-value", "GEMINI_API_KEY": "your-value", "GOOGLE_API_KEY": "your-value" } } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Media Gen MCP tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
node -vMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed
Open the Node.js download page ↗
When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v
Install once; it works for everything that needs Node.js
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
How to get a key is in the maker’s README below
In the Media Gen MCP settings, OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY is empty; add your key and save
Paste the key only into the app’s field, never into a chat or to anyone
Use Media Gen MCP and tell me what you can do for me, then show me one thing✓ If Cursor says it is using Media Gen MCP or shows a Media Gen MCP tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
GOOGLE_GENAI_USE_VERTEXAI Set to true to use Vertex AI for Google GenAI.GOOGLE_CLOUD_PROJECT GCP project id for Vertex AI.GOOGLE_CLOUD_LOCATION GCP region for Vertex AI (e.g. us-central1).AZURE_OPENAI_API_KEY Azure OpenAI API key (optional).AZURE_OPENAI_ENDPOINT Azure OpenAI endpoint hostname.OPENAI_API_VERSION Azure OpenAI API version.AZURE_OPENAI_DEPLOYMENT Azure OpenAI deployment name.MEDIA_GEN_DIRS Comma-separated output directories for media files.MEDIA_GEN_URLS Comma-separated URL prefixes allowed for fetch tools.MEDIA_GEN_MCP_URL_PREFIXES Public URL prefixes for mapping local output files.MEDIA_GEN_MCP_TEST_SAMPLE_DIR Path to sample images for the test-images tool.Descriptions are as written by the maker.
Menu names checked against Cursor’s help page on Nov 11, 2026 · your screen may differ slightly by app version
Works with VS Code, with some setup first
You need a Media Gen MCP key (create it on the maker’s site) · Install Node.js on your computer first (one time)
Copy this message into a VS Code chat. The AI checks your computer, tells you which file it will change, and waits for your OK every time.
Please install the MCP server Media Gen MCP for VS Code on this computer, in this order: 1) Check Node.js with node -v. If it is missing, tell me to install it from https://nodejs.org/en/download; do not install it yourself. 2) Use only this config (already checked by PopNx MCP): { "servers": { "media-gen": { "type": "stdio", "command": "npx", "args": [ "-y", "@strato-space/media-gen-mcp" ], "env": { "OPENAI_API_KEY": "your-value", "GEMINI_API_KEY": "your-value", "GOOGLE_API_KEY": "your-value" } } } } 3) Tell me the full path of the file you will change, or the command you will run, and wait for my OK. 4) For OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY, leave "your-value" in place and tell me to paste the real value myself into the file or the app’s field. Never ask me to type a key in chat. 5) Do what we agreed, then check that the Media Gen MCP tools really show up.This message has no key in it. If a key is needed, the AI will ask you to paste it yourself into the file or the app’s field.
Already installed? Check first · Open Terminal, type this command and press Enter
node -vMac: press ⌘ + Space, type Terminal, press Enter
Windows: open Start, type Windows PowerShell, then Open
Not installed: Open the official download page, pick the LTS version and the click-through installer: .pkg on Mac · .msi on Windows. Double-click and follow it to the end. No curl command needed
Open the Node.js download page ↗
When it’s done, close Terminal, open it again and run the same command. You should see a version number: node -v
Install once; it works for everything that needs Node.js
Open the maker’s site, sign up and create an API key for the next step. Check the maker’s site for pricing and free plans.
How to get a key is in the maker’s README below
In the Media Gen MCP settings, OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY is empty; add your key and save
Paste the key only into the app’s field, never into a chat or to anyone
Use Media Gen MCP and tell me what you can do for me, then show me one thing✓ If VS Code says it is using Media Gen MCP or shows a Media Gen MCP tool in the answer, you are connected
The command above works without these. Add them only if you want to change something, following the maker’s description.
GOOGLE_GENAI_USE_VERTEXAI Set to true to use Vertex AI for Google GenAI.GOOGLE_CLOUD_PROJECT GCP project id for Vertex AI.GOOGLE_CLOUD_LOCATION GCP region for Vertex AI (e.g. us-central1).AZURE_OPENAI_API_KEY Azure OpenAI API key (optional).AZURE_OPENAI_ENDPOINT Azure OpenAI endpoint hostname.OPENAI_API_VERSION Azure OpenAI API version.AZURE_OPENAI_DEPLOYMENT Azure OpenAI deployment name.MEDIA_GEN_DIRS Comma-separated output directories for media files.MEDIA_GEN_URLS Comma-separated URL prefixes allowed for fetch tools.MEDIA_GEN_MCP_URL_PREFIXES Public URL prefixes for mapping local output files.MEDIA_GEN_MCP_TEST_SAMPLE_DIR Path to sample images for the test-images tool.Descriptions are as written by the maker.
Menu names checked against VS Code’s help page on Nov 11, 2026 · your screen may differ slightly by app version
Other apps that use MCP, such as Windsurf, Zed or Gemini CLI, each add servers differently. See how in the app list.
JSON settings are under “For developers” below
Claude Code
claude mcp add --scope user media-gen --env OPENAI_API_KEY=your-value --env GEMINI_API_KEY=your-value --env GOOGLE_API_KEY=your-value -- npx -y @strato-space/media-gen-mcpClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"media-gen": {
"command": "npx",
"args": [
"-y",
"@strato-space/media-gen-mcp"
],
"env": {
"OPENAI_API_KEY": "your-value",
"GEMINI_API_KEY": "your-value",
"GOOGLE_API_KEY": "your-value"
}
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"media-gen": {
"command": "npx",
"args": [
"-y",
"@strato-space/media-gen-mcp"
],
"env": {
"OPENAI_API_KEY": "your-value",
"GEMINI_API_KEY": "your-value",
"GOOGLE_API_KEY": "your-value"
}
}
}
}VS Code (mcp.json)
{
"servers": {
"media-gen": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@strato-space/media-gen-mcp"
],
"env": {
"OPENAI_API_KEY": "your-value",
"GEMINI_API_KEY": "your-value",
"GOOGLE_API_KEY": "your-value"
}
}
}
}OPENAI_API_KEY secret required envGEMINI_API_KEY secret required envGOOGLE_API_KEY secret required envGOOGLE_GENAI_USE_VERTEXAI envGOOGLE_CLOUD_PROJECT envGOOGLE_CLOUD_LOCATION envAZURE_OPENAI_API_KEY secret envAZURE_OPENAI_ENDPOINT envOPENAI_API_VERSION envAZURE_OPENAI_DEPLOYMENT envMEDIA_GEN_DIRS envMEDIA_GEN_URLS envMEDIA_GEN_MCP_URL_PREFIXES envMEDIA_GEN_MCP_TEST_SAMPLE_DIR envDescriptions are as written by the maker.
These settings are generated from the maker’s registry entry. If the README says otherwise, follow the README.
Based on how this server connects and on each app’s own docs, checked Nov 10, 2026.
Run on your computer in
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
Runs on your computer; the tool list appears in your AI app after you install it.
We check information anyone can see; we have not read the code. Checks that do not apply are left out of the count. · Checked Nov 19, 2026
The registry name was verified with the GitHub account strato-space, which owns the repo
Code last changed 10 months ago, more than 6 months ago
Uses MIT
This one runs on your computer; there is no internet endpoint
Runs on your computer and uses local settings instead
Runs on your computer; we can only read tool lists from internet endpoints
No entries on OSV.dev for @strato-space/media-gen-mcp@1.0.4
Checks only this package version, not every dependency · checked Nov 15, 2026
If you made this, paste this code into your README. The badge links back to this page.
[](https://mcp.popnx.com/en/servers/strato-space-media-gen-mcp)Ask, share a tip or report that it does not work. Sorted by what people marked helpful.
No posts yet. Be the first to ask or share.
Posts here are written by users, not the PopNx team.
No reviews yet
Compared with every active server in this category in the registry. Stars count only when the publisher owns the repo.
It passed 2 of 3 applicable basic checks. We have not read the code. Before adding a key or token, see what access the server asks for and use a key with only the permissions you need.
You need to fill in: OPENAI_API_KEY, GEMINI_API_KEY, GOOGLE_API_KEY
It runs on your computer. Your AI app starts it when needed, and data does not pass through the maker’s servers (unless it calls an online service itself).
The GitHub repo last changed 10 months ago, and the latest version (1.0.4) reached the registry 11 months ago.
Apps that support MCP, such as Claude Desktop, Claude Code, Cursor and VS Code. You also need Node.js on your computer.
In the same category: HyperFrames by HeyGen, Pascal 3D Editor, draw.io, Figma MCP Server, Remocn: Remotion MCP server
Same category, other makers, commands already checked. Official ones first, then by stars.
Reading a card:↓ Downloads per weeki★ GitHub starsiThree pillars: reviews · checks · usageiUpdated = latest version published to the registryi
Official HyperFrames by HeyGen: the best AI video editor in chat. Captions, motion graphics, MP4.
Create, inspect, validate, and save editable 3D building scenes with Pascal's MCP server.
Create draw.io diagrams in chat from Mermaid or XML, shown live and interactive. 10,000+ shapes.
Figma’s official server gives AI your design data so it can turn designs into code or describe them accurately. Connects to Figma’s cloud.
Hosted MCP for Remotion videos: search Remocn components, read docs, plan a video, preview it.
| This one Media Gen MCP | HyperFrames by HeyGen | Pascal 3D Editor | draw.io | Figma MCP Server | Remocn: Remotion MCP server | |
|---|---|---|---|---|---|---|
| Runs where | Installs on your computer | Runs in the cloud, nothing to install | Cloud or install on your computer | Runs in the cloud, nothing to install | Runs in the cloud, nothing to install | Runs in the cloud, nothing to install |
| Needs a key | Yes | No | No | No | No | No |
| Add with + in Claude | No | No | No | No | Yes | No |
| Basic checks | 2/3 | 4/4 | 5/5 | 4/4 | 4/4 | 4/4 |
| License | MIT | Apache-2.0 | MIT | Apache-2.0 | – | MIT |
| Price | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry | No cost listed in the registry |
Copied from the maker’s repo as written. PopNx MCP has not reviewed or endorsed it. HTML, images and scripts are removed. Links lead off this site.
Media Gen MCP is a strict TypeScript Model Context Protocol (MCP) server for OpenAI Images (gpt-image-1.5, gpt-image-1), OpenAI Videos (Sora), and Google GenAI Videos (Veo): generate/edit images, create/remix video jobs, and fetch media from URLs or disk with smart resource_link vs inline image outputs and optional sharp processing. Production-focused (full strict typecheck, ESLint + Vitest CI). Works with fast-agent, Claude Desktop, ChatGPT, Cursor, VS Code, Windsurf, and any MCP-compatible client.
Design principle: spec-first, type-safe image tooling – strict OpenAI Images API + MCP compliance with fully static TypeScript types and flexible result placements/response formats for different clients.
gpt-image-1.5 model (with gpt-image-1 compatibility and DALL·E support planned in future versions).sora-2, sora-2-pro) with job create/remix/list/retrieve/delete and asset downloads.resource_link/resource outputs.test-images tool that mirrors production result placement (content, structuredContent, toplevel).CallToolResult objects from the latest MCP schema, including: content items (text, image, resource_link, resource), optional structuredContent, optional top-level files, and the isError flag for failures.openai-images-generate mirrors the OpenAI Images create API for gpt-image-1.5 (and gpt-image-1) (background, moderation, size, quality, output_format, output_compression, n, user, etc.).openai-images-edit mirrors the OpenAI Images createEdit API for gpt-image-1.5 (and gpt-image-1) (image, mask, n, quality, size, user).openai-videos-create mirrors videos/create and can optionally wait for completion.openai-videos-remix mirrors videos/remix.openai-videos-list mirrors videos/list.openai-videos-retrieve mirrors videos/retrieve.openai-videos-delete mirrors videos/delete.openai-videos-retrieve-content mirrors videos/content and downloads video / thumbnail / spritesheet assets to disk, returning MCP resource_link (default) or embedded resource blocks (via tool_result).google-videos-generate starts a long-running operation (ai.models.generateVideos) and can optionally wait for completion and download .mp4 outputs. Veo model referencegoogle-videos-retrieve-operation polls an existing operation.google-videos-retrieve-content downloads an .mp4 from a completed operation, returning MCP resource_link (default) or embedded resource blocks (via tool_result).fetch-images tool loads images from HTTP(S) URLs or local file paths with optional, user-controlled compression (disabled by default). Supports parallel processing of up to 20 images.fetch-videos tool lists local videos or downloads remote video URLs to disk and returns MCP resource_link (default) or embedded resource blocks (via tool_result).fetch-document tool downloads remote files or reuses local paths and returns MCP resource_link (default) or embedded resource blocks (via tool_result).openai-images-edit accepts image as a single string or an array of 1–16 file paths/base64 strings, matching the OpenAI spec for GPT Image models (gpt-image-1.5, gpt-image-1) image edits.file when the total response size exceeds a safe threshold.output_ _media-gen__ _ . filenames (images/documents use a generated UUID; videos use the OpenAI video_id) and exposed to MCP clients via content[] depending on tool_result (resource_link/image for images, resource_link/resource for video/document downloads).test-images reads sample images from a configured directory and returns them using the same result-building logic as production tools. Use tool_result and response_format parameters to test how different MCP clients handle content[] and structuredContent.isError: true and content: [{ type: "text", text: }], making failures easy to parse and surface in MCP clients.git clone https://github.com/strato-space/media-gen-mcp.git
cd media-gen-mcp
npm install npm run build
Build modes:
npm run build – strict TypeScript build with all strict flags enabled, including skipLibCheck: false. Incremental builds via .tsbuildinfo (~2-3s on warm cache).npm run esbuild – fast bundling via esbuild (no type checking, useful for rapid iteration).For development or when TypeScript compilation fails due to memory constraints:
npm run dev # Uses tsx to run TypeScript directly
npm run lint # ESLint with typescript-eslint
npm run typecheck # Strict tsc --noEmit npm run test # Unit tests (vitest) npm run test:watch # Watch mode for TDD npm run ci # lint + typecheck + test
The project uses vitest for unit testing. Tests are located in test/.
Covered modules:
| Module | Tests | Description |
|---|---|---|
compression | 12 | Image format detection, buffer processing, file I/O |
helpers | 31 | URL/path validation, output resolution, result placement, resource links |
env | 19 | Configuration parsing, env validation, defaults |
logger | 10 | Structured logging + truncation safety |
pricing | 5 | Sora pricing estimate helpers |
schemas | 69 | Zod schema validation for all tools, type inference |
fetch-images (integration) | 3 | End-to-end MCP tool call behavior |
fetch-videos (integration) | 3 | End-to-end MCP tool call behavior |
Test categories:
isCompressionAvailable, detectImageFormat, processBufferWithCompression, readAndProcessImageisHttpUrl, isAbsolutePath, isBase64Image, ensureDirectoryWritable, resolveOutputPath, getResultPlacement, buildResourceLinksMEDIA_GEN_* / MEDIA_GEN_MCP_* settingsopenai-images-*, openai-videos-*, fetch-images, fetch-videos, test-images inputs, boundary testing (prompt length, image count limits, path validation)npm run test
You can also run the server straight from a remote repo using npx:
npx -y github:strato-space/media-gen-mcp --env-file /path/to/media-gen.env
The --env-file argument tells the server which env file to load (e.g. when you keep secrets outside the cloned directory). The file should contain OPENAI_API_KEY, optional Azure variables, and any MEDIA_GEN_MCP_* settings.
secrets.yaml (optional)You can keep API keys (and optional Google Vertex AI settings) in a secrets.yaml file (compatible with the fast-agent secrets template):
openai:
api_key: anthropic: api_key: google: api_key: vertex_ai: enabled: true project_id: your-gcp-project-id location: europe-west4
media-gen-mcp loads `secr