# powerpoint-cli **Repository Path**: anderson2/powerpoint-cli ## Basic Information - **Project Name**: powerpoint-cli - **Description**: No description available - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-06-06 - **Last Updated**: 2026-06-06 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # powerpoint-cli A standalone CLI for creating and editing PowerPoint (`.pptx`) files, wrapping [office-powerpoint-mcp-server](https://github.com/GongRzhe/Office-PowerPoint-MCP-Server) via [mcporter](https://github.com/steipete/mcporter). The original project is an MCP (Model Context Protocol) server for PowerPoint manipulation. This repo packages it as a CLI so it can be used directly from the command line or as an [Agent Skills](https://agentskills.io)-compatible skill — without loading 37 tool schemas into agent context. ## What it does - Create presentations from scratch or from templates - Add slides, text, bullet points, images, tables, charts, shapes, connectors - Apply professional themes and color schemes - Auto-generate presentations from a topic - Extract text and inspect slide structure - Manage hyperlinks, transitions, fonts, and document properties ## What it doesn't do - Open or display presentations in a GUI - Convert to/from PDF or other formats - Handle animations or video/audio embeds - Edit existing text in-place (you can add new text or replace placeholders) ## Requirements - [Bun](https://bun.sh/) runtime - [uv](https://docs.astral.sh/uv/) (for the underlying Python MCP server, installed on first run) ## Installation ```bash # Install bun if needed curl -fsSL https://bun.sh/install | bash # Install uv if needed curl -LsSf https://astral.sh/uv/install.sh | sh # Clone git clone https://github.com/tmustier/powerpoint-cli.git ``` ### As a pi skill ```bash git clone https://github.com/tmustier/powerpoint-cli.git ~/.pi/agent/skills/powerpoint ``` The skill auto-loads when you ask your agent to work with PowerPoint files. ## Usage ### Batch mode (for multi-step workflows) The server is stateful — create, build, then save. Use the batch runner: ```bash echo '{ "commands": [ { "tool": "create_presentation" }, { "tool": "add_slide", "args": { "title": "Hello World" } }, { "tool": "manage_text", "args": { "slide_index": 0, "operation": "add", "left": 1, "top": 2, "width": 8, "height": 1, "text": "Welcome!", "font_size": 24 }}, { "tool": "save_presentation", "args": { "file_path": "./output.pptx" } } ] }' | bun powerpoint-batch.ts ``` Also accepts a file or `--recipe` flag: ```bash bun powerpoint-batch.ts recipe.json bun powerpoint-batch.ts --recipe '{"commands": [...]}' ``` The batch runner auto-tracks `presentation_id` across commands. ### Single-command mode For one-off or read-only operations: ```bash bun powerpoint-cli.js list-slide-templates bun powerpoint-cli.js get-template-info --template-id title_slide bun powerpoint-cli.js --help ``` See [SKILL.md](SKILL.md) for the full tool reference with all arguments. ## How it works `powerpoint-cli.js` is generated by [mcporter](https://github.com/steipete/mcporter) `generate-cli`. It spawns [office-powerpoint-mcp-server](https://github.com/GongRzhe/Office-PowerPoint-MCP-Server) as a subprocess over stdio and translates CLI flags / JSON into MCP tool calls. `powerpoint-batch.ts` keeps a single server session alive across multiple commands, working around a [known upstream bug](https://github.com/GongRzhe/Office-PowerPoint-MCP-Server/issues/19) where `create_presentation` doesn't set the active presentation ID (the wrapper that would do this is defined but never applied). ## Regenerating ```bash npx mcporter generate-cli \ --command "uvx --from office-powerpoint-mcp-server ppt_mcp_server" \ --name powerpoint \ --output powerpoint-cli.ts \ --bundle powerpoint-cli.js ``` ## Known issues The upstream MCP server has a [state persistence bug](https://github.com/GongRzhe/Office-PowerPoint-MCP-Server/issues/19) with stdio transport: `create_presentation` stores the presentation in memory but never sets it as the active one (the wrapper code for this exists but is never applied). Some MCP clients also respawn the stdio process per call, losing state entirely. The batch runner (`powerpoint-batch.ts`) works around both problems by keeping a single server process alive for the full session and auto-injecting `presentation_id` into subsequent commands. If you use `powerpoint-cli.js` directly, each invocation is independent — use it only for stateless/read-only commands. ## License MIT