# DeckCP — Agent Guide

DeckCP is a slide-deck editor built for humans and AI agents. Decks are trees
of typed nodes on a 1920×1080 canvas, stored server-side. Humans edit on a
visual canvas (or by voice on a phone); agents edit over MCP. Both see the
same decks, live.

## Connect over MCP

- Endpoint: `https://deckcp.com/api/mcp` (MCP Streamable HTTP, protocol 2025-06-18)
- Auth: OAuth 2.1 + PKCE with dynamic client registration. Connect and your
  MCP client will walk the standard flow (discovery via the 401
  `WWW-Authenticate` header → `/.well-known/oauth-protected-resource`).
  A browser window opens once for Google sign-in and consent.
- Scope: `deckcp:all`

Client one-liners:

```bash
# Claude Code
claude mcp add --transport http deckcp https://deckcp.com/api/mcp
```

```json
// Cursor (~/.cursor/mcp.json) and most JSON-config clients
{ "mcpServers": { "deckcp": { "url": "https://deckcp.com/api/mcp" } } }
```

Claude Desktop / claude.ai: Settings → Connectors → Add custom connector →
paste `https://deckcp.com/api/mcp`.

## Tools

Deck CRUD: `whoami`, `list_decks`, `get_deck`, `create_deck`,
`update_deck`, `upsert_slides`, `delete_slides`, `delete_deck`.

Generation: `generate_outline` (context → reviewable outline),
`generate_slides_from_text` (wall of text → deck),
`generate_slides_from_outline` (approved outline → on-brand slides).

Seeing your work: `render_slides` returns actual slide images (inline
image blocks or URLs) — render after writing, always.

Quality: `check_slide` validates MDX against the class vocabulary and
scores layout balance BEFORE you write. `rewrite_slide` runs the copilot
on one slide. `get_authoring_guide` returns the full rendering contract +
component catalog — read it before authoring slides by hand.

Assets: `upload_asset` (images ≤8MB base64 or URL; videos ≤50MB via
`source_url`; returns a CDN URL), `search_assets` (semantic search over
the approved library — prefer reuse over generation).

Brand: `get_brand` returns the palette, logos, and non-negotiable design
rules for a brand. Slides you write are validated against them.

## The golden path

1. `get_authoring_guide` once per session.
2. `generate_outline` → show the human → `generate_slides_from_outline`.
3. `render_slides` to SEE the result; `check_slide` before manual edits.
4. `upload_asset` real media only — never invent image or video URLs.
5. Video on slides: `<video src="…" autoPlay muted loop playsInline />`
   with an uploaded URL. `muted` + `playsInline` or browsers block it.

## For humans

Setup instructions with screenshots: https://deckcp.com/mcp
The product: https://deckcp.com
