visio-diagrams

Generate and edit native Microsoft Visio .vsdx diagrams from YAML or JSON specs.

2|Updated Jul 28, 2026
One-click install
npx skills add https://github.com/mbadali25/useful-claude-add-ons --skill visio-diagrams-mbadali25
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: visio-diagrams
Source: https://github.com/mbadali25/useful-claude-add-ons/tree/main/skills/visio-diagrams
Command: npx skills add https://github.com/mbadali25/useful-claude-add-ons --skill visio-diagrams-mbadali25

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires vsdx, pyyaml, cairosvg, and includes scripts (resource) and references (resource) components.

What problem does it solve? Creating editable Visio diagrams normally requires a Visio license and manual drawing, and no Python library can generate .vsdx files from scratch. This Skill writes native .vsdx files directly from a declarative spec, so network topologies, architecture diagrams, and process flows can be produced in CI, on Linux, or on machines without Visio installed. ## Core Features & Use Cases - Spec-driven generation: Define nodes, edges, styles, and layout direction in YAML or JSON, then produce a .vsdx plus an SVG preview with one command. - Two rendering paths: A stdlib-only Python writer for cross-platform/CI use, and a PowerShell COM automation path for real stencil masters (Cisco, AWS, Azure, corporate stencils) when Visio is installed. - Verification and editing: Round-trip generated files through the vsdx parser to catch structural errors, and edit existing .vsdx files (e.g., retitle shapes in a corporate template) without Visio. - Use Case: Turn a subnet list into a CAB-ready network diagram: write a short YAML spec of firewalls, switches, and databases, run the generator, preview the SVG, verify the .vsdx, and hand over an editable file for change-management review. ## Quick Start Ask the AI to turn your list of network components and connections into an editable Visio diagram and preview it before delivery.

Frequently Asked Questions about visio-diagrams

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a Visio diagram without Visio installed?

Write a YAML or JSON spec listing nodes and edges, then run diagram_from_spec.py to produce a native .vsdx file plus an SVG preview. The writer is stdlib-only Python, so it works on Linux, in CI, or on air-gapped machines.

Can the Python vsdx package create a .vsdx file from scratch?

No. The PyPI vsdx package only opens and edits existing files via VisioFile(path); it cannot create one. This Skill's vsdx_writer.py writes the OOXML package directly, which is the working approach for from-scratch generation.

How do I use Cisco, AWS, or corporate stencils in a generated diagram?

Use the COM automation path: run New-VisioDiagram.ps1 on Windows with Visio installed, passing your spec as JSON and the stencil name (e.g., PERIPH_U.VSSX). The Python path draws generic shapes only and cannot load stencil masters.

Why does Visio report unreadable content in a generated .vsdx?

Common causes are a missing part in [Content_Types].xml, that file not being the first ZIP entry, or an unresolved relationship Id. Run verify_vsdx.py to check OPC structure, and consult the symptom-to-cause table in the format reference.

When should I use Mermaid or SVG instead of Visio?

Use Mermaid or Graphviz when the diagram lives in a repo, PR, or wiki, since Visio binaries are not diffable. Use SVG or PNG for one-time viewing. Choose Visio only when a human must edit the diagram or compliance workflows mandate it.

Why does COM automation fail on a build server with error 0x80080005?

Visio COM automation cannot run under a service account in session 0 without an interactive desktop, producing CO_E_SERVER_EXEC_FAILURE. For CI or automated pipelines, use the Python vsdx_writer path instead, which runs headless anywhere.