DocsOverviewGetting startedPricingAuthentication & conceptsPostsDiagramsBrand & assetsTools & batchErrorsMCP server

Text-to-diagram MCP server

Connect Claude Code, Claude Desktop, claude.ai (web), VS Code, Cursor, Google Antigravity, a Google ADK agent, or any Model Context Protocol client directly to Capci's generation tools (diagrams, posts, charts, and more) as native tool calls.

Capci is a hosted, remote text-to-diagram MCP server. Point any MCP client at the live endpoint below, and your agent can generate a diagram from a prompt — architecture, flowchart, sequence, class, ER, mindmap, or Gantt — then refine it in plain English, all as native tool calls. Nothing to install and no local server to run: it's a standard Streamable HTTP MCP server you connect to with an API key.

Live remote endpoint: nothing to run yourself

Capci hosts the MCP server for you. Point any MCP client at:

https://mcp.capci.app/mcp

Add your Developer-plan x-api-key header and you're connected: no install, no server to keep running.

What it can do

  • Generate branded posts from a one-line prompt, with 20 built-in formats, auto-picked or pinned explicitly.
  • Generate diagrams (architecture, flowchart, sequence, class, ER, mindmap, Gantt) as a conversational resource you keep refining with plain English.
  • Animate a diagram into a reveal GIF.
  • Generate data charts (bar, line, donut, KPI tiles) directly from numbers, no prompt.
  • Restyle or resize anything for free: re-theme/resize a prior result without spending another generation call.
  • Configure a brand once and have every generation apply it automatically, with a per-call unbranded escape hatch.
  • Generate brand-kit assets (social covers, banners, cards) deterministically from your saved brand.
  • Generate a logo mark from a description: the one pay-per-use tool; everything above draws from your plan's generation volume (see Tools and Authentication below).

Tools

All eleven draw from your plan's monthly API/MCP volume except create_logo, which is pay-per-use on every plan. Fields marked * are required.

ToolWhat it doesKey inputs
create_postGenerate a branded social/marketing image from a prompt. Returns a PNG plus reusable content.prompt*, format, size, theme, style, brand, unbranded
restyle_contentFree re-theme/resize of a prior create_post/create_chart result, with no new generation.format*, content*, size, theme, brand
create_diagramGenerate a diagram from a prompt. Returns a durable id to refine/restyle/animate later. Unbranded with an adaptive frame by default — see account defaults below.prompt*, type, size, theme, nodeStyle, transparent, brand, unbranded
refine_diagramUpdate a diagram by id. With a prompt: content edit. Without: free instant restyle.id*, prompt, size, theme, nodeStyle, transparent, colors, brand, unbranded
animate_diagramTurn an existing diagram into a reveal GIF. Blocking: waits for completion.id*, anim, speed
create_chartGenerate a bar/line/donut/KPI chart directly from data: no prompt, fully deterministic.chartType*, series/slices/tiles, theme, size
set_brandConfigure the saved brand profile every later create_* call inherits by default.name, handle, tagline, logo, colors
list_brandkit_assetsList available brand-kit asset types (banners, covers, cards) and their ids.(none)
create_brandkit_assetGenerate a specific brand-kit asset from the saved brand: free, no prompt.id*, theme, tagline, pills
create_logo
Pay-per-use
Generate a logo mark from a description.prompt*
list_post_layoutsList post layout ids/schemas usable with create_post's format field.(none)

Diagram defaults over MCP

A diagram asked for through an agent usually ends up in a README, a deck, or a doc, so create_diagram defaults differ from the web app: no brand mark, and an adaptive frame (size: "auto") that renders vertical or landscape depending on the diagram's own shape. Override either per call (unbranded: false, size: "landscape"), or change the standing default for every call in Dashboard → Account → API & MCP defaults. Posts, charts and brand-kit assets are unaffected and stay branded.

Architecture diagrams also come back with an svgUrl alongside the usual viewUrl/downloadUrl — a standalone vector file with its fonts embedded, ideal for docs and decks. Other diagram types omit the field rather than advertise a link that wouldn't work.

Authentication

Every call needs a Capci API key (Dashboard → Account → API & MCP, shown once at creation). The MCP server itself has no login; you pass the key when you connect your client, and it's forwarded on every tool call. Free keys work as a bounded one-time trial (same 50-creation lifetime pool as the web app); Pro keys get 200 generations/mo and Developer keys get 900/mo, both resetting automatically each billing period (api_quota_exceeded once used up — see Errors).

x-api-key: capci_your_api_key_here

Most clients send the key as the x-api-key header above. For clients that can't set custom headers — notably the claude.ai web custom connector — pass it in the URL instead: https://mcp.capci.app/mcp?api_key=YOUR_KEY. It's treated identically; just keep that URL secret, since the key is in it.

Before you start

  1. A Capci account. Free works as a bounded one-time trial; Pro and Developer both get a real recurring monthly quota (200/mo and 900/mo — see Authentication below).
  2. Your API key. Dashboard → Account → API & MCP → Generate API Key. It's shown once: copy it somewhere safe immediately, you can't view it again later (you'd need to revoke and create a new one).
  3. The client app itself already installed, whichever one you're connecting below (Claude Code CLI, VS Code, Cursor, etc.). This page only covers pointing an already- installed client at Capci, not installing the client itself.

Connect a client

All configs below use the live remote endpoint: https://mcp.capci.app/mcp. Replace YOUR_KEY with the API key from step 2 above.

Claude Code

Easiest path, one terminal command, nothing to create by hand: run the CLI command below from your project folder. Verify it worked: run claude mcp list; you should see capci listed. If you'd rather manage config as a file instead, the second tab does the same thing manually: create a file named exactly .mcp.json (all lowercase, starts with a dot, in your project's root folder) with that content.

claude mcp add --transport http capci https://mcp.capci.app/mcp \
  --header "x-api-key: YOUR_KEY"

Claude Desktop

1. Open the config. Claude Desktop → Settings → Developer → Edit Config. That opens claude_desktop_config.json. 2. Paste the config below. Because Capci authenticates with an x-api-key header (not OAuth), the connection goes through the mcp-remote bridge, which forwards the header for you: no separate install, npx fetches it on first run (Node.js required). 3. Restart Claude Desktop. The Capci tools appear under the 🔌 connectors menu in a new chat.

{
  "mcpServers": {
    "capci": {
      "command": "npx",
      "args": [
        "-y", "mcp-remote", "https://mcp.capci.app/mcp",
        "--header", "x-api-key:YOUR_KEY"
      ]
    }
  }
}

Claude.ai (web)

1. Open connectors. claude.ai → Settings → Connectors → Add custom connector (custom connectors are available on Pro, Max, Team, and Enterprise plans). 2. Paste the URL below as the Remote MCP server URL, replacing YOUR_KEY with your key. Unlike the desktop apps, the web connector UI can't attach a custom x-api-key header, so Capci accepts the key as an ?api_key= query parameter instead — the server treats it exactly like the header. 3. Connect, then enable Capci in the chat's tools menu. Images render inline in the tool result as usual. Treat this URL like a password — anyone who has it has your key. Rotate it in Dashboard → Account → API & MCP if it leaks.

https://mcp.capci.app/mcp?api_key=YOUR_KEY

VS Code

1. Create the file. In your project's root folder, make a folder named exactly .vscode (all lowercase, starts with a dot, not .VSCode or .Vscode, this matters on Linux/macOS where file names are case-sensitive). Inside it, create a file named exactly mcp.json (all lowercase). Full path: .vscode/mcp.json. 2. Paste the config below into it. Note the top-level key is servers, not mcpServers (different from Claude Code/Cursor, easy to copy the wrong one by mistake). 3. Save the file. VS Code detects it automatically; it'll prompt you to enter the API key the first time a tool runs (that's what the inputs block is for: keeps your key out of the file itself). 4. Verify: Command Palette (Cmd/Ctrl+Shift+P) → "MCP: List Servers" → should show capci as running. Prefer a single config for every project instead of per-project files? Command Palette → "MCP: Open User Configuration" and paste the same JSON there.

{
  "servers": {
    "capci": {
      "type": "http",
      "url": "https://mcp.capci.app/mcp",
      "headers": { "x-api-key": "${input:capci-api-key}" }
    }
  },
  "inputs": [
    { "type": "promptString", "id": "capci-api-key", "description": "Capci API key", "password": true }
  ]
}

Cursor

1. Create the file. For one project only: in that project's root folder, make a folder named exactly .cursor (all lowercase, starts with a dot), then a file named exactly mcp.json inside it: full path .cursor/mcp.json. For every project on your machine instead: the same file name, but under your home folder: ~/.cursor/mcp.json. 2. Paste the config below. Cursor figures out it's an HTTP server from the presence of url; no separate "type" field needed, unlike VS Code. 3. Verify: Cursor Settings → MCP: capci should show a green/active status.

{
  "mcpServers": {
    "capci": {
      "url": "https://mcp.capci.app/mcp",
      "headers": { "x-api-key": "YOUR_KEY" }
    }
  }
}

Google Antigravity

1. Open the config. Edit ~/.gemini/config/mcp_config.json (or use Antigravity's MCP settings panel). 2. Paste the config below. Antigravity uses serverUrl for a remote Streamable-HTTP server, not url (the field name differs from VS Code and Cursor: an easy one to get wrong). Auth goes in the headers object. 3. Reload MCP servers. The agent can then generate diagrams inside your Antigravity workflow. Images come back as a right-sized inline preview automatically (plus a full-res viewUrl / downloadUrl) — no extra header needed.

{
  "mcpServers": {
    "capci": {
      "serverUrl": "https://mcp.capci.app/mcp",
      "headers": { "x-api-key": "YOUR_KEY" }
    }
  }
}

Gemini CLI

1. Open the config. Edit ~/.gemini/settings.json (global), or .gemini/settings.json in a project folder for that project only. 2. Paste the config below. Gemini CLI uses httpUrl for a remote Streamable-HTTP server, not url (which it treats as an SSE endpoint) or serverUrl (that's Antigravity): the field name matters. 3. Verify: run /mcp inside Gemini CLI; capci should list as connected. Images come back as a right-sized inline preview plus a full-res viewUrl / downloadUrl — no extra header needed.

{
  "mcpServers": {
    "capci": {
      "httpUrl": "https://mcp.capci.app/mcp",
      "headers": { "x-api-key": "YOUR_KEY" }
    }
  }
}

Google ADK (Python)

Unlike the clients above, this isn't a config file; it's a few lines in your own Python agent code. Prerequisite: pip install google-adk first. ADK's dev UI renders a markdown image from the model's text — not the tool-result image block — so tell the model to render the previewUrl (a right-sized inline copy), with a downloadUrl link below. Use previewUrl, not the full-res viewUrl — the latter overflows the pane. The User-Agent below tells the Capci server this is an ADK client, so it automatically skips the inline image block (which ADK can't show and would cost ~50K tokens of Gemini context per image) — no extra header needed. Use gemini-2.5-pro: gemini-2.5-flash tends to loop or write the tool call as code (UNEXPECTED_TOOL_CALL).

from google.adk.agents import Agent
from google.adk.tools.mcp_tool import McpToolset
from google.adk.tools.mcp_tool.mcp_session_manager import StreamableHTTPConnectionParams

capci_tools = McpToolset(
    connection_params=StreamableHTTPConnectionParams(
        url="https://mcp.capci.app/mcp",
        headers={
            "x-api-key": "YOUR_KEY",
            # Identifies the client as ADK — the Capci server sees this and returns a
            # URL preview instead of an inline block (which ADK can't render anyway).
            "User-Agent": "capci-adk-agent/1.0 (google-adk)",
        },
    ),
)

root_agent = Agent(
    model="gemini-2.5-pro",
    name="capci_agent",
    instruction=(
        "After a tool returns an image, display it as a markdown image using "
        "the previewUrl, then a [Download](downloadUrl) link below it."
    ),
    tools=[capci_tools],
)

Any other MCP client works the same way. This is a standard Streamable HTTP server: point it at the /mcp URL above and add an x-api-key header.

Image rendering: blocks vs. URLs

By default the server returns a right-sized inline image block (already downscaled, so it won't overflow a Gemini host's token budget) — this works with no extra header for Claude Desktop, Claude Code, Cursor, Antigravity, and Gemini CLI. Every result also carries a previewUrl (a right-sized copy) plus viewUrl / downloadUrl (full-res) — for hosts that render a markdown-image URL from the model's text instead of the tool block. Google ADK is detected automatically (by its User-Agent) and served URL-only, since it can't display the block. You rarely need to touch this, but you can override per request:

  • x-capci-inline: 0 — no inline block; render previewUrl as a markdown image instead. For URL-rendering hosts and headless pipelines.
  • omit the header — right-sized inline block (default). Best for Claude and other block-rendering hosts.

Example prompts

Copy any of these into your connected client as a starting point. They show the level of detail the tools handle well: multiple components, real relationships, and explicit flow. Then refine in plain English (refine_diagram) to make it yours.

Architecture diagramcreate_diagram

A multi-region SaaS on Google Cloud: a global load balancer routing to Cloud Run in us-central1 and europe-west1, each backed by a regional Cloud SQL replica, with Memorystore for caching and a Pub/Sub topic feeding a BigQuery analytics pipeline.

Sequence diagramcreate_diagram

Sequence diagram of a checkout flow: the browser calls our API, which reserves stock in the database and creates a payment order, then returns it to the browser; after payment, a webhook hits our API, we verify the signature, mark the order paid, and enqueue a fulfillment job.

Flowchartcreate_diagram

Flowchart of a CI/CD pipeline: on push, run lint and unit tests in parallel; if both pass, build a container image, deploy to staging, run smoke tests, then wait for manual approval before a canary rollout to production with automatic rollback on an error-rate spike.

ER diagramcreate_diagram

ER diagram for a multi-tenant B2B app: organizations have many users and many projects; projects have tasks; users are assigned to tasks through a join table; include an audit_log table referencing both user and organization.

Class diagramcreate_diagram

Class diagram for a payments module: an abstract PaymentMethod with CreditCard and UPI subclasses, a PaymentProcessor that takes a PaymentMethod, an Order with line items, and an Invoice generated from an Order.

Refine (follow-up)refine_diagram

Add a Redis cache between the API and the database, group the two regional stacks into labeled containers, and switch to a dark theme.

Animateanimate_diagram

Animate the request path through the architecture as a reveal GIF, medium speed.

Branded postcreate_post

A LinkedIn announcement post for a new feature launch: a bold headline, three benefit bullets, and a call to action, in a dark theme on brand.

Code sample (official SDKs)

The Python sample uses the official mcp SDK directly; see "Google ADK (Python)" above instead if you're building an ADK agent specifically.

import { Client } from '@modelcontextprotocol/sdk/client/index.js';
import { StreamableHTTPClientTransport } from '@modelcontextprotocol/sdk/client/streamableHttp.js';

const transport = new StreamableHTTPClientTransport(
  new URL('https://mcp.capci.app/mcp'),
  { requestInit: { headers: { 'x-api-key': process.env.CAPCI_API_KEY } } },
);
const client = new Client({ name: 'my-app', version: '1.0.0' });
await client.connect(transport);

// Create a diagram
const diagram = await client.callTool({
  name: 'create_diagram',
  arguments: {
    prompt: 'Users hit a load balancer, which fans out to two API servers backed by a database and a cache.',
    type: 'architecture',
    theme: 'dark',
  },
});

const meta = JSON.parse(diagram.content.find((b) => b.type === 'text' && b.text.startsWith('{'))?.text || '{}');
console.log('Diagram id:', meta.id);

// Refine it — same id, plain-English follow-up
await client.callTool({
  name: 'refine_diagram',
  arguments: { id: meta.id, prompt: 'Add a CDN in front of the load balancer.' },
});

await client.close();

Raw API sample

For integrating from a language without an MCP SDK, or to see the wire format directly. The server is stateless, so there's no session handshake to manage: just POST a JSON-RPC tools/call request with your API key, as shown below.

# The server is stateless — no initialize/session handshake needed, just call
# a tool directly with your API key. (list tools first with method: "tools/list"
# and no params, if you want to see the full catalog + schemas.)
curl -s -X POST https://mcp.capci.app/mcp \
  -H "x-api-key: YOUR_KEY" \
  -H 'content-type: application/json' -H 'accept: application/json, text/event-stream' \
  -d '{
    "jsonrpc": "2.0", "id": 1, "method": "tools/call",
    "params": { "name": "create_chart", "arguments": {
      "chartType": "bar", "title": "Quarterly Signups",
      "series": [{"label":"Q1","value":120},{"label":"Q2","value":210}]
    }}
  }'