Mermaid API skill

AI agent · Coding agent · Engineering & development by Mermaid

Let your coding agent check, repair, and draw diagrams directly in your terminal and codebase.

Mermaid API skill is an AI agent tool designed for coding assistants like Claude Code, Cursor, and Codex to perform diagramming tasks autonomously. It allows these agents to validate, repair, and generate Mermaid diagram code directly within a developer's workflow using the Mermaid API. The skill enables agents to render diagrams into SVG, PNG, or PDF files or display them as ASCII art in the terminal. It is built to help developers maintain documentation and visualize system architecture without leaving their coding environment. The tool is currently in beta and requires a Mermaid API key to

Languages
English
Supported formats
SVG, PNG, PDF, ASCII
Operating systems
macOS, Linux, WSL
Validation cost
1 credit
Rendering cost
5 credits
AI generation cost
25 credits

Overview

Mermaid API skill is an AI agent tool designed for coding assistants like Claude Code, Cursor, and Codex to perform diagramming tasks autonomously. It allows these agents to validate, repair, and generate Mermaid diagram code directly within a developer's workflow using the Mermaid API. The skill enables agents to render diagrams into SVG, PNG, or PDF files or display them as ASCII art in the terminal. It is built to help developers maintain documentation and visualize system architecture without leaving their coding environment. The tool is currently in beta and requires a Mermaid API key to function.

Diagramming Tasks

  • Validate diagram code: The skill allows agents to check diagram code for errors and receive specific line and column reports for fixes.
  • Repair invalid code: Agents can fix invalid code using Mermaid AI and return a corrected version that parses correctly.
  • Generate from description: The skill enables agents to create new diagrams from plain-language descriptions.
  • Render to file formats: Agents can render diagrams to SVG, PNG, or PDF files at a specified file path.
  • ASCII terminal rendering: The skill supports displaying diagrams as ASCII art directly within the terminal chat window.

Agent Ecosystems

  • Claude Code integration: The skill is designed for Claude Code and can be installed via the plugin marketplace.
  • Codex and Cursor support: It supports coding agents that read.agents/ files, including Codex and Cursor.
  • System dependencies: The skill requires curl and jq to be installed on the host system for data processing.
  • Operating system support: It operates on macOS, Linux, and WSL environments.

Usage and Credits

  • Validation cost: Each validation call costs 1 API credit from the user's balance.
  • Rendering cost: Rendering a diagram to a file costs 5 API credits per call.
  • AI generation cost: Generating or repairing a diagram with AI costs 25 API credits per call.
  • Balance checks: Checking the current credit balance or key status is provided for free.

Specifications

Supported formats
SVG, PNG, PDF, ASCII
Operating systems
macOS, Linux, WSL
Validation cost
1 credit
Rendering cost
5 credits
AI generation cost
25 credits

Added by AntSpace from public sources (mermaid.ai).

More AI agents by Mermaid