2Slides Logo
How to Use Claude Code with the 2Slides MCP Server (2026 Guide)
2Slides Team
8 min read

How to Use Claude Code with the 2Slides MCP Server (2026 Guide)

Quick answer (≤60 words): Claude Code can generate real PowerPoint files by connecting to the 2Slides MCP server. Get an API key at 2slides.com/api, then run

claude mcp add --env API_KEY=xxx --transport stdio 2slides -- npx 2slides-mcp
for local stdio, or
claude mcp add --transport http 2slides https://2slides.com/api/mcp?apikey=KEY
for remote Streamable HTTP. Then just ask Claude Code to build a deck.

Claude Code is Anthropic's terminal-based coding agent, and it speaks the Model Context Protocol (MCP) natively. That means you can give it a tool that turns text into a finished

.pptx
file without ever leaving your shell. The 2Slides MCP server is that tool: a thin connector that exposes 2Slides' slide-generation, theming, narration, and export APIs as MCP tools Claude Code can call directly.

This guide shows you both ways to connect — local stdio and remote Streamable HTTP — which one to pick, what each tool does, and the exact prompts that turn a one-line request into a downloadable PowerPoint.

Why connect Claude Code to 2Slides at all?

Claude Code is excellent at reasoning over your repo, drafting content, and structuring an argument. What it cannot do on its own is emit a real, editable

.pptx
with shapes, charts, themes, and speaker notes. That is a file-generation problem, and it belongs to a dedicated tool.

The split is clean:

  • Claude Code reads your source material (a README, a spec, a CSV, a research note), reasons about it, and decides what goes on each slide.
  • The 2Slides MCP server takes that plan and renders an actual PowerPoint file — or image-based slides with AI voice narration and an MP4 export.

You stay in the terminal the whole time. Ask, wait ~30–60 seconds, get a download URL.

What you need first

  1. Claude Code installed and authenticated (
    claude
    on your PATH).
  2. A 2Slides API key. Create one at 2slides.com/api. The same page has a copy-paste MCP config and the Streamable HTTP endpoint.
  3. Node.js (for the stdio transport, which runs
    npx 2slides-mcp
    locally). The HTTP transport needs nothing local at all.

Stdio vs Streamable HTTP: which transport?

The 2Slides MCP server supports two transports. Both expose the identical tool set; they differ only in where the connector runs.

Stdio ProtocolStreamable HTTP Protocol
Where it runsLocally, via
npx 2slides-mcp
Remotely, hosted by 2Slides
Needs Node.js locallyYesNo
SetupAdd a stdio server +
API_KEY
env
Add one URL with
?apikey=
Best forLocal dev, offline-friendly, full controlContainers, CI, thin clients, zero local deps
Auth
API_KEY
env var
API key in the URL query (or
Authorization
header)

Rule of thumb: use stdio on your own machine for day-to-day work, and Streamable HTTP when Claude Code runs somewhere you cannot install Node (a remote box, a CI job, a locked-down container).

Method 1: Connect via stdio (local)

Run this once. The

--
separator splits Claude Code's own flags from the command it launches:

claude mcp add --env API_KEY=YOUR_2SLIDES_API_KEY --transport stdio 2slides -- npx 2slides-mcp

A few things worth knowing:

  • Keep
    --transport stdio
    (or another flag) between
    --env
    and the server name. Because
    --env
    accepts multiple
    KEY=value
    pairs, putting the name right after it can make the CLI read the name as another env var.
  • Everything after
    --
    is passed to the server untouched (
    npx 2slides-mcp
    ).
  • Add
    --scope user
    to make 2Slides available in every project, or
    --scope project
    to commit it to a shared
    .mcp.json
    for your team.

The resulting

.mcp.json
(project scope) looks like this — you can also hand-edit it:

{ "mcpServers": { "2slides": { "command": "npx", "args": ["2slides-mcp"], "env": { "API_KEY": "YOUR_2SLIDES_API_KEY" } } } }

Method 2: Connect via Streamable HTTP (remote)

No local install — just point Claude Code at the hosted endpoint:

claude mcp add --transport http 2slides https://2slides.com/api/mcp?apikey=YOUR_2SLIDES_API_KEY

Prefer to keep the key out of the URL? Send it as a header instead:

claude mcp add --transport http 2slides https://2slides.com/api/mcp \ --header "Authorization: Bearer YOUR_2SLIDES_API_KEY"

Verify the connection

claude mcp list # 2slides should appear and connect claude mcp get 2slides # show its config and discovered tools

Or, inside an interactive session, run the

/mcp
slash command to see connected servers, tool counts, and (for remote servers) the auth status.

Generate your first deck

Once connected, you do not call tools by hand — you just ask. Claude Code chains the 2Slides tools automatically:

Search the 2slides themes for a clean "business" style, then generate a 7-slide deck introducing our Q3 roadmap. Pull the content from ./ROADMAP.md. Return the download link.

Behind the scenes Claude Code runs

themes_search
to find a
themeId
, then
slides_generate
(Fast PPT) and hands you a
downloadUrl
. Total time: roughly 30–60 seconds for a themed PowerPoint.

Want custom, image-designed slides instead of a template? Ask for that and Claude Code will use the Nano Banana path (

slides_create_pdf_slides
), poll
jobs_get
until it is ready, and return the link.

The 2Slides MCP tool surface

Claude Code sees these tools once connected:

ToolWhat it doesCredits
themes_search
Find a
themeId
for Fast PPT
Free
slides_generate
Theme-based PowerPoint (Fast PPT), sync or async10 / page
slides_create_pdf_slides
Custom image-designed slides from text (Nano Banana)100 / page (1K/2K), 200 (4K)
slides_create_like_this
Slides matching a reference image's style100 / page (1K/2K), 200 (4K)
slides_generate_narration
Add AI voice narration to a Nano Banana job210 / page
slides_download_pages_voices
Export pages + audio as a ZIPFree
jobs_get
Poll an async job until
success
Free

Three typical chains:

  • Fast PPT:
    themes_search
    slides_generate
    (sync) → download.
  • Nano Banana:
    slides_create_pdf_slides
    (async) →
    jobs_get
    → download.
  • Narrated video assets: create slides →
    jobs_get
    slides_generate_narration
    jobs_get
    slides_download_pages_voices
    .

Common mistakes and troubleshooting

  • Server doesn't appear in
    claude mcp list
    .
    For stdio, check that the
    --env
    /name ordering is right (keep a flag between
    --env
    and the name). For HTTP, re-check the URL and that the API key is valid.
  • API_KEY
    missing.
    The stdio server needs the env var; the HTTP server needs
    ?apikey=
    or an
    Authorization
    header. Don't mix them up.
  • Asking for a
    .pptx
    without the tool.
    Without 2Slides connected, Claude Code can write an outline but cannot emit a real PowerPoint. Connect the server first.
  • Forgetting the theme. If you don't run
    themes_search
    or name a style, Fast PPT picks one for you. Specify it to control the look.
  • Polling too fast. Async jobs (Nano Banana, narration) should be polled with
    jobs_get
    about every 20 seconds, not in a tight loop.

Frequently asked questions

Does Claude Code support MCP servers natively?

Yes. Claude Code is a first-class MCP client. You add servers with

claude mcp add
(stdio, SSE, or HTTP transports), list them with
claude mcp list
, and inspect them in-session with
/mcp
. The 2Slides server works with all of these.

Stdio or Streamable HTTP — which should I use?

Use stdio on your local machine (it runs

npx 2slides-mcp
for you) and Streamable HTTP anywhere you can't or don't want to install Node — CI, containers, remote servers. Both expose the same tools and produce identical output.

Does this produce a real PowerPoint file?

Yes. The Fast PPT path (

slides_generate
) returns an editable
.pptx
with real shapes and themes. The Nano Banana paths return image-designed decks and can add AI voice narration and exportable assets. These are files you can open, edit, and present — not screenshots.

Where do I get the API key and config?

At 2slides.com/api?tab=mcp. That page shows your key, a ready-to-paste stdio config, and the Streamable HTTP endpoint URL.

Can I share the 2Slides server with my team?

Yes. Add it with

--scope project
to write a shared
.mcp.json
you commit to the repo. Teammates are prompted to approve it on first use. Use
--scope user
for a private, all-projects setup.

The takeaway

Claude Code does the thinking; the 2Slides MCP server does the file. Connect once — stdio for local, Streamable HTTP for remote — and "make me a deck" becomes a single sentence in your terminal.

If you live in Claude Code, this is the fastest path from an idea (or a file in your repo) to a finished, editable PowerPoint. For a broader look at wiring slides into agents, see how MCP is changing presentation workflows and the full PowerPoint MCP server ecosystem map. Using the desktop app instead of the CLI? See how to use Claude MCP to generate presentations.

Grab your key and config at 2slides.com/api?tab=mcp and generate your first deck from the terminal in under a minute.

Sources:

About 2Slides

Create stunning AI-powered presentations in seconds. Transform your ideas into professional slides with 2slides AI Agent.

Try For Free