npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@agent-canvas/cli

v0.11.0

Published

CLI tool for Agent Canvas - Excalidraw interface for AI agents

Readme

@agent-canvas/cli

CLI tool for drawing on Excalidraw canvas. Designed for AI agents but works great for humans too.

Part of Agent Canvas — an AI agent skill for drawing diagrams.

Installation

npm install -g @agent-canvas/cli
# or
bun add -g @agent-canvas/cli

Features

  • Real-time canvas in browser via WebSocket
  • Multi-canvas support: manage multiple diagrams with sidebar or CLI
  • Shapes: rectangle, ellipse, diamond, polygon
  • Text with 9 anchor points for precise positioning
  • Arrows: sharp, round (curved), elbow (90° turns)
  • Element manipulation: move, rotate, resize, group, delete
  • Import/export: .excalidraw files, PNG export

Usage

Start Canvas

agent-canvas start

Load File

agent-canvas load diagram.excalidraw  # Load into current canvas

Canvas Management

# List all canvases (* marks active)
agent-canvas list

# Create new canvas
agent-canvas new -n "Flowchart"
agent-canvas new -n "Architecture" --use  # Create and switch to it

# Switch to canvas by name
agent-canvas use "Flowchart"

# Rename current canvas
agent-canvas rename "New Name"

Drawing

# Add shapes
agent-canvas add-shape -t rectangle -x 100 -y 100 -w 200 -h 100 --background-color "#FFA07A" -l "My Box"
agent-canvas add-shape -t ellipse -x 300 -y 100 -w 100 -h 100
agent-canvas add-shape -t diamond -x 500 -y 100 -w 100 -h 100

# Add text (--ax/--ay = anchor point, -a = anchor type)
agent-canvas add-text -t "Hello World" --ax 100 --ay 300 --font-size 24
agent-canvas add-text -t "Centered" --ax 200 --ay 250 -a center
# Anchors: topLeft, topCenter, topRight, leftCenter, center, rightCenter, bottomLeft, bottomCenter (default), bottomRight

# Add lines and arrows
agent-canvas add-line -x 100 -y 400 --end-x 300 --end-y 400
agent-canvas add-arrow -x 100 -y 500 --end-x 300 --end-y 500

# Arrow types: sharp (default), round, elbow
agent-canvas add-arrow -x 100 -y 100 --end-x 100 --end-y 300 --arrow-type round --via "50,200"
agent-canvas add-arrow -x 175 -y 520 --end-x 175 --end-y 280 --arrow-type elbow --via "120,520;120,280"

# Add polygon
agent-canvas add-polygon -p '[{"x":0,"y":0},{"x":100,"y":0},{"x":50,"y":100}]'

Element Manipulation

# Delete elements (supports batch)
agent-canvas delete-elements -i <id1>,<id2>,<id3>

# Rotate elements (degrees, positive = clockwise)
agent-canvas rotate-elements -i <id1>,<id2> -a 45

# Move elements
agent-canvas move-elements -i <id1>,<id2> --delta-x 50 --delta-y 100

# Resize shapes (expand/contract edges)
agent-canvas resize-elements -i <id> --bottom 50              # Expand bottom by 50px
agent-canvas resize-elements -i <id> --right 30 --bottom 20   # Expand right-bottom corner
agent-canvas resize-elements -i <id> --left -20               # Contract left edge by 20px

# Group/ungroup
agent-canvas group-elements -i <id1>,<id2>,<id3>
agent-canvas ungroup-element -i <element-id>

Read & Export

# Read scene (TOON format - token efficient)
agent-canvas read

# Read scene (JSON format)
agent-canvas read --json

# Save to file
agent-canvas save diagram.excalidraw

# Export to PNG
agent-canvas export -o output.png
agent-canvas export -o output.png --scale 2 --dark --no-background

# Clear canvas
agent-canvas clear