protogrid

Search / io.github.abelce/codepic

CodePic

R1· needs a key

AI agent draws editable hand-drawn diagrams (flowchart, ER, architecture) via MCP, not static images

v1.0.0 · active · repository · descriptor JSON · versions

An agent can connect on its own if it already holds CODEPIC_TOKEN.Remote endpoint behind a static API key or header. The registry never sees the value; the agent fills the placeholder.
Quality76good
Trust86of 100
Uptime, 30 days94%
Latency p50352 ms

Connect

8 clients · secrets stay placeholders
{
  "mcpServers": {
    "codepic": {
      "type": "http",
      "url": "https://codepic.cc/api/mcp/mcp",
      "headers": {
        "Authorization": "Bearer ${CODEPIC_TOKEN}"
      }
    }
  }
}
claude mcp add --transport http codepic https://codepic.cc/api/mcp/mcp --header "Authorization: Bearer ${CODEPIC_TOKEN}"
[mcp_servers.codepic]
url = "https://codepic.cc/api/mcp/mcp"
bearer_token_env_var = "CODEPIC_TOKEN"
{
  "$schema": "https://opencode.ai/config.json",
  "mcp": {
    "codepic": {
      "type": "remote",
      "url": "https://codepic.cc/api/mcp/mcp",
      "enabled": true,
      "headers": {
        "Authorization": "Bearer {env:CODEPIC_TOKEN}"
      }
    }
  }
}
{
  "mcpServers": {
    "codepic": {
      "type": "http",
      "url": "https://codepic.cc/api/mcp/mcp",
      "headers": {
        "Authorization": "Bearer ${CODEPIC_TOKEN}"
      }
    }
  },
  "deeplink": "cursor://anysphere.cursor-deeplink/mcp/install?name=codepic&config=eyJ0eXBlIjoiaHR0cCIsInVybCI6Imh0dHBzOi8vY29kZXBpYy5jYy9hcGkvbWNwL21jcCIsImhlYWRlcnMiOnsiQXV0aG9yaXphdGlvbiI6IkJlYXJlciAke0NPREVQSUNfVE9LRU59In19"
}
{
  "servers": {
    "codepic": {
      "type": "http",
      "url": "https://codepic.cc/api/mcp/mcp",
      "headers": {
        "Authorization": "Bearer ${CODEPIC_TOKEN}"
      }
    }
  }
}
{
  "mcpServers": {
    "codepic": {
      "httpUrl": "https://codepic.cc/api/mcp/mcp",
      "headers": {
        "Authorization": "Bearer ${CODEPIC_TOKEN}"
      }
    }
  }
}
extensions:
  "codepic":
    enabled: true
    name: "codepic"
    type: streamable_http
    uri: "https://codepic.cc/api/mcp/mcp"
    headers:
      "Authorization": "Bearer ${CODEPIC_TOKEN}"
    timeout: 300

Placeholders to fill from your own secret store: ${CODEPIC_TOKEN}. The registry never accepts secret values.

Quality 76 / 100good

protocol75 · weight 25
  • warn
    protocol.modernnewest supported version is 2025-11-25; 2026-07-28 not supported, older versions are deprecated until 2027-07-28
  • n/a
    protocol.statelessonly applies to 2026-07-28 servers
  • pass
    protocol.transportstreamable HTTP
  • n/a
    protocol.list_ttlonly applies to 2026-07-28 servers
authorizationn/a · weight 15
  • n/a
    auth.prm, auth.as_metadata, auth.cimdno remote uses OAuth
  • n/a
    auth.secret_in_urlno templated URL
tool hygiene64 · weight 30
  • pass
    tools.descriptionsevery tool has a description
  • warn
    tools.description_length1 tools have descriptions over 1,024 characters, which crowds the context
  • pass
    tools.schemasevery tool has an object input schema
  • fail
    tools.annotationsno tool declares readOnlyHint or destructiveHint, so clients cannot tell safe calls from risky ones
  • fail
    tools.directory_hintsno tool declares all four of readOnlyHint, destructiveHint, idempotentHint and openWorldHint; missing: get_shape_docs (readOnlyHint, destructiveHint, idempotentHint, openWorldHint); create_diagram (readOnlyHint, destructiveHint, idempotentHint, openWorldHint); update_diagram (readOnlyHint, destructiveHint, idempotentHint, openWorldHint); …
  • pass
    tools.token_costabout 5,774 tokens to load every tool
  • pass
    tools.api_dumptools are not a one-to-one API dump
stability100 · weight 15
  • pass
    stability.changesno tool changes in 30 days
  • pass
    stability.rug_pullno tool changed its meaning under the same name
dependenciesn/a · weight 15
  • n/a
    deps.known_vulns, deps.mcp_sdk_version, deps.resolvableno npm or PyPI package

7 tools, about 5,774 tokens to load them all · tool set fd859b8b8e24 · checked 2026-10-19 10:20 UTC

Tool changes

No tool definition changes recorded. A server's first observation is its baseline; later probes record what changes.

Checks run on what our credential-free, read-only probes observe; tools are never called and no code audit is performed. How it is computed.

Trust 86 / 100

provenance80
liveness98
freshness65
hygiene100

+repository +namespace-matches-repo +reachable +uptime-94% ~updated-125d-ago

Derived from observable signals (official registry feed and our own credential-free probes); no code audit performed. How it is computed.

Endpoints

remoteauthreachableuptime 30dp50protocollast ok
https://codepic.cc/api/mcp/mcp streamable-httpapi_key ${CODEPIC_TOKEN}yes94%352 ms2025-11-252026-10-19

Tools (7)

create_diagramCreate a custom CodePic hand-drawn style diagram by specifying nodes and edges. Requires API Key authentication. Returns a public view URL. **THIS IS THE DEFAULT TOOL FOR ANY USER-DESCRIBED DIAGRAM.** Whenever the user describes a diagram they want ("draw an A/B test flowchart", "帮我画一个登录流程", "a system architecture with a load balancer and 3 servers", etc.), build it here from their description. Do NOT fall back to `create_from_template` / `list_templates` unless the user explicitly asked for a template. When responding to the user, present the returned URL as a clickable markdown link (e.g. `[Open in CodePic →](URL)`) so the user can click it directly in their AI client (Cursor / Claude / etc.). **Container nesting (IMPORTANT — use whenever possible):** - Set `parentId` on a node to nest it inside another node. ANY node type can be a container. - The parent automatically becomes draggable-as-a-group and users can keep dropping elements into it. - Call `get_shape_catalog` with tag `container-capable` to choose among native structural containers and adaptive semantic shapes such as rectangles, circles, ellipses, diamonds, cylinders, and hexagons. - Parent bounds are expanded automatically using the selected shape's title and outline safe area. - Use absolute canvas coordinates for all nodes — child coordinates are auto-converted to parent-relative. - Set node `name`, `description`, and `tags` when later MCP/Agent reads need stable business semantics beyond visible text. - **Rule**: whenever 2+ nodes logically belong to the same module / component / region, create a container node first and set `parentId` on each child. **Design tips for beautiful diagrams:** - Use semantic types: `button-primary` for CTA buttons (auto blue), `diamond` for decisions - Pick a color palette and apply it consistently — light fill + darker stroke of the same hue: • Blue: fillColor #e3f2fd / #bbdefb, strokeColor #1565c0, fontColor #1565c0 (or #ffffff on dark fill) • Green: fillColor #e8f5e9 / #c8e6c9, strokeColor #2e7d32, fontColor #1b5e20 • Purple: fillColor #f3e5f5 / #e1bee7, strokeColor #6a1b9a, fontColor #4a148c • Neutral: fillColor #f8fafc / #f1f5f9, strokeColor #475569, fontColor #1e293b - Each semantic group (decisions, processes, I/O) should share a fill color to create visual hierarchy - Dark fill (e.g. #1565c0, #ef4444) → fontColor #ffffff; light fill → fontColor #111827
create_from_templateCreate a new CodePic diagram from a predefined template. Requires API Key authentication. Returns a public view URL and edit URL. **STRICT USAGE RULE — READ BEFORE CALLING:** Only call this tool when the user has **explicitly** asked to use a template. Explicit signals include phrases like: "use a template", "from template", "用模板", "从模板创建", "list templates and pick one", or the user directly naming/selecting a template slug. If the user merely describes a diagram they want (e.g. "draw an A/B test flowchart", "帮我画一个登录流程", "给我做一个系统架构图"), **DO NOT** call this tool. Call `create_diagram` instead and build the diagram from the user's description. Never silently substitute a template for a described diagram — the user will get a generic result that does not match what they asked for. When responding to the user, present the returned URL as a clickable markdown link (e.g. `[Open in CodePic →](URL)`) so the user can click it directly in their AI client (Cursor / Claude / etc.).
get_diagramFetch the current state of an existing CodePic diagram. Returns a compact summary of all elements with their IDs, types, positions, and parent-child relationships. Use this before update_diagram when you need to: add nested children to existing containers, make targeted edits to specific elements, or understand the current structure. Requires API Key authentication.
get_shape_catalogReturn compact machine-readable shape metadata for planning a diagram: semantic tags, geometry family, container support, recommended padding, default size, and MCP availability. Use this before create_diagram when choosing shapes or containers. Unlike get_shape_docs, this tool is concise and filterable.
get_shape_docsReturn the full CodePic shape reference — all element types, their fields, data payloads, and JSON examples. Call get_shape_catalog first for concise shape selection and container capabilities; use this tool when you need complete fields or type-specific data (e.g. select options, triangle direction, callout tail). No authentication required.
list_templatesList all available CodePic diagram templates. Use this ONLY when the user has explicitly asked to browse, list, or pick from templates (e.g. "show me templates", "列出模板"). Do NOT call this as a preparatory step when the user just described a diagram they want — in that case go straight to `create_diagram`. Discovering slugs here is only meaningful before a user-confirmed `create_from_template` call.
update_diagramUpdate an existing CodePic diagram. You can rename it, replace all nodes/edges, or add/remove individual nodes and edges. Requires API Key authentication. When responding to the user, present the returned URL as a clickable markdown link (e.g. `[Open in CodePic →](URL)`) so the user can click it directly in their AI client (Cursor / Claude / etc.).

Schemas: list_tools.

Similar MCP servers

Official server.json
{
  "name": "io.github.abelce/codepic",
  "title": "CodePic",
  "$schema": "https://static.modelcontextprotocol.io/schemas/2025-12-11/server.schema.json",
  "remotes": [
    {
      "url": "https://codepic.cc/api/mcp/mcp",
      "type": "streamable-http",
      "headers": [
        {
          "name": "Authorization",
          "isSecret": true,
          "isRequired": true,
          "description": "Bearer API key from https://codepic.cc/settings/api-keys (format: cpk_...)"
        }
      ]
    }
  ],
  "version": "1.0.0",
  "repository": {
    "url": "https://github.com/abelce/codepic-mcp",
    "source": "github"
  },
  "description": "AI agent draws editable hand-drawn diagrams (flowchart, ER, architecture) via MCP, not static images"
}