Diagent CLI — Development skill for Claude Code
CLI for encoding and decoding Diagent diagram URLs.
How to install Diagent CLI
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open daniellee-ux/diagent-cli and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Diagent CLI does
CLI for encoding and decoding Diagent diagram URLs. Includes Claude Code skill.
Alternatives in Development
- Understand Anything — Graphs that teach graphs that impress 80.7k ★
- OpenAI Codex CLI — (Rust implementation) 67.8k ★
- Mempalace Help — Show comprehensive MemPalace help — available skills, MCP tools, CLI commands, hooks, and architecture 58.6k ★
README
@diagent/cli
Command-line tool to encode and decode Diagent shareable diagram URLs. Designed for agents (Claude Code, Cursor) and humans alike.
By default, `diagent encode` produces a **short URL** like `https://diagent.dev/d/abcdefghij` (~31 chars, constant size regardless of diagram complexity). This works by calling the Diagent backend's `POST /api/s` endpoint, which stores the Mermaid in Cloudflare KV and returns a content-addressed short ID.
If the backend is unreachable (dev, offline, rate-limit, Cloudflare outage), `diagent encode` **automatically falls back** to an inline URL of the form `https://diagent.dev/?code=`, which carries the full Mermaid source in the `code` query parameter. The feature never fully breaks — worst case, you get a longer URL and a stderr notice. Pass `--inline` to skip the backend entirely and always produce the inline format.
Install
**From npm:**
npx -y @diagent/cli --help
# or install globally
npm install -g @diagent/cli
**From source (contributors):**
cd cli
npm install
npm run build
npm link # puts `diagent` on your global PATH
Usage
diagent encode [FILE] [--base-url URL] [--inline]
Encode Mermaid from FILE or stdin -> URL on stdout
(tries backend short URL, falls back to inline)
diagent decode Decode inline ?code= URL -> Mermaid source on stdout
diagent decode - Decode URL read from stdin
diagent --help Show help
diagent --version Show version
**Encode from stdin (produces a short URL):**
cat flow.mmd | diagent encode
# https://diagent.dev/d/kwtsgx5o24
**Encode from a file:**
diagent encode flow.mmd
**Force inline format (skip backend):**
diagent encode flow.mmd --inline
# https://diagent.dev/?code=GYGw9g7gxg...
**Encode against a
Related Skills
Claude Code Termux
Termux workaround for running Claude Code CLI on Android. The npm package no longer includes a global CLI, so
CLI Anything Capcut
CapCut/JianYing draft scripting CLI built on pyCapCut. Includes Claude Code skill.
Grok Build Showcase
A living, executable showcase and practical toolkit for Grok Build (xAI). Includes reusable skills, exemplary
Hark Viewer
Live transcript page and recording controls for hark, the macOS audio capture and transcription CLI. Includes
Plainly
Say it again in plain language — same facts, none of the decoding
Bypass 403
Probe a 403/401 endpoint with the most-paid bypass tricks (header injection, path encoding, method swap, WAF f
Related Agents
Karr Ref Worker
App::karr Git/ref storage worker — Git::Native and CLI fallback, refs-backed BoardStore persistence, CAS, lock
Milestone Publisher
Publish explicitly approved GitHub milestones and issue associations, verifying actual IDs and URLs with GitHu
Design Infoviz
Information Visualization Designer on the Atlas bench. Maps every visual mark to a typed ontology fact and mea