KS
Killer-Skills

excalidraw — how to use excalidraw how to use excalidraw, excalidraw setup guide, excalidraw alternative, excalidraw vs graphviz, excalidraw install, what is excalidraw, excalidraw tutorial, excalidraw architecture diagram

v1.0.0
GitHub

About this Skill

Perfect for Architecture Analysis Agents needing advanced diagram generation capabilities for codebase visualization. Excalidraw is a diagram generator that creates architecture diagrams as .excalidraw files directly from codebase analysis, with optional export to PNG and SVG.

Features

Generates architecture diagrams as .excalidraw files from codebase analysis
Identifies components, services, databases, and APIs
Maps relationships and dependencies between system components
Exports diagrams to PNG and SVG formats
Analyzes codebases in any language or framework

# Core Topics

ooiyeefei ooiyeefei
[0]
[0]
Updated: 3/7/2026

Quality Score

Top 5%
54
Excellent
Based on code quality & docs
Installation
SYS Universal Install (Auto-Detect)
Cursor IDE Windsurf IDE VS Code IDE
> npx killer-skills add ooiyeefei/ccc/excalidraw

Agent Capability Analysis

The excalidraw MCP Server by ooiyeefei is an open-source Categories.community integration for Claude and other AI agents, enabling seamless task automation and capability expansion. Optimized for how to use excalidraw, excalidraw setup guide, excalidraw alternative.

Ideal Agent Persona

Perfect for Architecture Analysis Agents needing advanced diagram generation capabilities for codebase visualization.

Core Value

Empowers agents to generate architecture diagrams as .excalidraw files directly from codebase analysis, with optional export to PNG and SVG, mapping relationships and dependencies between components, services, and databases.

Capabilities Granted for excalidraw MCP Server

Generating architecture diagrams for codebase analysis
Visualizing system components and dependencies
Creating excalidraw files for project documentation

! Prerequisites & Limits

  • Requires codebase access for analysis
  • Limited to generating .excalidraw, PNG, and SVG files
Project
SKILL.md
7.3 KB
.cursorrules
1.2 KB
package.json
240 B
Ready
UTF-8

# Tags

[No tags]
SKILL.md
Readonly

Excalidraw Diagram Generator

Generate architecture diagrams as .excalidraw files directly from codebase analysis, with optional export to PNG and SVG.


Quick Start

User just asks:

"Generate an architecture diagram for this project"
"Create an excalidraw diagram of the system"
"Visualize this codebase as an excalidraw file"

Claude Code will:

  1. Analyze the codebase (any language/framework)
  2. Identify components, services, databases, APIs
  3. Map relationships and data flows
  4. Generate valid .excalidraw JSON with dynamic IDs and labels
  5. Optionally export to PNG and/or SVG using Playwright

No prerequisites: Works without existing diagrams, Terraform, or specific file types.


Critical Rules

1. NEVER Use Diamond Shapes

Diamond arrow connections are broken in raw Excalidraw JSON. Use styled rectangles instead:

Semantic MeaningRectangle Style
Orchestrator/HubCoral (#ffa8a8/#c92a2a) + strokeWidth: 3
Decision PointOrange (#ffd8a8/#e8590c) + dashed stroke

2. Labels Require TWO Elements

The label property does NOT work in raw JSON. Every labeled shape needs:

json
1// 1. Shape with boundElements reference 2{ 3 "id": "my-box", 4 "type": "rectangle", 5 "boundElements": [{ "type": "text", "id": "my-box-text" }] 6} 7 8// 2. Separate text element with containerId 9{ 10 "id": "my-box-text", 11 "type": "text", 12 "containerId": "my-box", 13 "text": "My Label" 14}

3. Elbow Arrows Need Three Properties

For 90-degree corners (not curved):

json
1{ 2 "type": "arrow", 3 "roughness": 0, // Clean lines 4 "roundness": null, // Sharp corners 5 "elbowed": true // 90-degree mode 6}

4. Arrow Edge Calculations

Arrows must start/end at shape edges, not centers:

EdgeFormula
Top(x + width/2, y)
Bottom(x + width/2, y + height)
Left(x, y + height/2)
Right(x + width, y + height/2)

Detailed arrow routing: See references/arrows.md


Element Types

TypeUse For
rectangleServices, databases, containers, orchestrators
ellipseUsers, external systems, start/end points
textLabels inside shapes, titles, annotations
arrowData flow, connections, dependencies
lineGrouping boundaries, separators

Full JSON format: See references/json-format.md


Workflow

Step 1: Analyze Codebase

Discover components by looking for:

Codebase TypeWhat to Look For
Monorepopackages/*/package.json, workspace configs
Microservicesdocker-compose.yml, k8s manifests
IaCTerraform/Pulumi resource definitions
Backend APIRoute definitions, controllers, DB models
FrontendComponent hierarchy, API calls

Use tools:

  • Glob**/package.json, **/Dockerfile, **/*.tf
  • Grepapp.get, @Controller, CREATE TABLE
  • Read → README, config files, entry points

Step 2: Plan Layout

Vertical flow (most common):

Row 1: Users/Entry points (y: 100)
Row 2: Frontend/Gateway (y: 230)
Row 3: Orchestration (y: 380)
Row 4: Services (y: 530)
Row 5: Data layer (y: 680)

Columns: x = 100, 300, 500, 700, 900
Element size: 160-200px x 80-90px

Other patterns: See references/examples.md

Step 3: Generate Elements

For each component:

  1. Create shape with unique id
  2. Add boundElements referencing text
  3. Create text with containerId
  4. Choose color based on type

Color palettes: See references/colors.md

Step 4: Add Connections

For each relationship:

  1. Calculate source edge point
  2. Plan elbow route (avoid overlaps)
  3. Create arrow with points array
  4. Match stroke color to destination type

Arrow patterns: See references/arrows.md

Step 5: Add Grouping (Optional)

For logical groupings:

  • Large transparent rectangle with strokeStyle: "dashed"
  • Standalone text label at top-left

Step 6: Validate and Write

Run validation before writing. Save to docs/ or user-specified path.

Validation checklist: See references/validation.md

Step 7: Export to PNG/SVG (Optional)

After writing the .excalidraw file, ask the user if they want PNG, SVG, or both exports.

Uses Playwright MCP tools and @excalidraw/utils to programmatically render the diagram — no manual upload to excalidraw.com needed.

Requires: Playwright MCP tools (browser_navigate, browser_run_code, browser_close).

Full export procedure: See references/export.md


Quick Arrow Reference

Straight down:

json
1{ "points": [[0, 0], [0, 110]], "x": 590, "y": 290 }

L-shape (left then down):

json
1{ "points": [[0, 0], [-325, 0], [-325, 125]], "x": 525, "y": 420 }

U-turn (callback):

json
1{ "points": [[0, 0], [50, 0], [50, -125], [20, -125]], "x": 710, "y": 440 }

Arrow width/height = bounding box of points:

points [[0,0], [-440,0], [-440,70]] → width=440, height=70

Multiple arrows from same edge - stagger positions:

5 arrows: 20%, 35%, 50%, 65%, 80% across edge width

Default Color Palette

ComponentBackgroundStroke
Frontend#a5d8ff#1971c2
Backend/API#d0bfff#7048e8
Database#b2f2bb#2f9e44
Storage#ffec99#f08c00
AI/ML#e599f7#9c36b5
External APIs#ffc9c9#e03131
Orchestration#ffa8a8#c92a2a
Message Queue#fff3bf#fab005
Cache#ffe8cc#fd7e14
Users#e7f5ff#1971c2

Cloud-specific palettes: See references/colors.md


Quick Validation Checklist

Before writing file:

  • Every shape with label has boundElements + text element
  • Text elements have containerId matching shape
  • Multi-point arrows have elbowed: true, roundness: null
  • Arrow x,y = source shape edge point
  • Arrow final point offset reaches target edge
  • No diamond shapes
  • No duplicate IDs

Full validation algorithm: See references/validation.md


Common Issues

IssueFix
Labels don't appearUse TWO elements (shape + text), not label property
Arrows curvedAdd elbowed: true, roundness: null, roughness: 0
Arrows floatingCalculate x,y from shape edge, not center
Arrows overlappingStagger start positions across edge

Detailed bug fixes: See references/validation.md


Reference Files

FileContents
references/json-format.mdElement types, required properties, text bindings
references/arrows.mdRouting algorithm, patterns, bindings, staggering
references/colors.mdDefault, AWS, Azure, GCP, K8s palettes
references/examples.mdComplete JSON examples, layout patterns
references/validation.mdChecklists, validation algorithm, bug fixes
references/export.mdPNG/SVG export procedure via Playwright

Output

  • Location: docs/architecture/ or user-specified
  • Filename: Descriptive, e.g., system-architecture.excalidraw
  • Exports (optional): system-architecture.svg and/or system-architecture.png in same directory
  • Testing: Open .excalidraw in https://excalidraw.com or VS Code extension; .svg and .png can be viewed directly or embedded in documentation

Related Skills

Looking for an alternative to excalidraw or building a Categories.community AI Agent? Explore these related open-source MCP Servers.

View All

widget-generator

Logo of f
f

widget-generator is an open-source AI agent skill for creating widget plugins that are injected into prompt feeds on prompts.chat. It supports two rendering modes: standard prompt widgets using default PromptCard styling and custom render widgets built as full React components.

149.6k
0
Design

chat-sdk

Logo of lobehub
lobehub

chat-sdk is a unified TypeScript SDK for building chat bots across multiple platforms, providing a single interface for deploying bot logic.

73.0k
0
Communication

zustand

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication

data-fetching

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
Communication