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

trmnl-cli

v0.1.6

Published

CLI tool for TRMNL e-ink displays - send, validate, and track payloads

Readme

trmnl-cli

npm

CLI for TRMNL e-ink displays. Send, validate, preview, and track payloads from your terminal.

Documentation · npm

Install

npm install -g trmnl-cli@latest

Requires Node.js 22.6.0 or later. Or run without installing:

npx trmnl-cli@latest send --help

Quick Start

# Add your first plugin (webhook)
trmnl plugin add home "https://trmnl.com/api/custom_plugins/YOUR_UUID"

# Send content
trmnl send --content '<div class="layout">Hello TRMNL!</div>'

# Or from a file
trmnl send --file ./output.html

Commands

trmnl send

Send content to your TRMNL display.

# Direct content
trmnl send --content '<div class="layout">Hello</div>'

# From file
trmnl send --file ./output.html

# To a specific plugin
trmnl send --file ./output.html --plugin office

# From stdin
echo '{"merge_variables":{"content":"..."}}' | trmnl send

| Flag | Description | |------|-------------| | -c, --content <html> | HTML content to send | | -f, --file <path> | Read content from file | | -p, --plugin <name> | Plugin to use (default: default plugin) | | -w, --webhook <url> | Override webhook URL directly | | --skip-validation | Skip payload validation | | --skip-log | Don't log to history | | --json | Output result as JSON |

trmnl validate

Validate a payload without sending. Checks size against your tier limit.

trmnl validate --file ./output.html
trmnl validate --content "..." --tier plus

| Flag | Description | |------|-------------| | -c, --content <html> | HTML content to validate | | -f, --file <path> | Read content from file | | -t, --tier <tier> | Override tier (free or plus) | | --json | Output result as JSON |

trmnl preview

Render content locally using the actual TRMNL framework and take a screenshot. Useful for checking layout, overflow, and visual appearance before sending to a device.

Requires Playwright. Install browsers once with npx playwright install chromium.

# Preview a file
trmnl preview --file ./output.html

# Preview and open in default viewer
trmnl preview --file ./output.html --open

# Preview for a specific device
trmnl preview --file ./output.html --device v2

# From stdin
echo '<div class="layout">Hello</div>' | trmnl preview

| Flag | Description | |------|-------------| | -c, --content <html> | HTML content to preview | | -f, --file <path> | Read content from file | | -o, --output <path> | Screenshot output path | | --open | Open screenshot in default viewer | | --device <id> | Device profile: og, v2, x (default: og) | | --no-overflow-check | Skip overflow detection | | --update-framework | Force-update cached TRMNL framework before rendering | | --json | Output result as JSON |

Device profiles:

| Device | Resolution | Bit depth | |--------|------------|-----------| | og | 800 x 480 | 2-bit | | v2 | 1040 x 780 | 4-bit | | x | 1872 x 1404 | 4-bit |

The exit code is 1 if overflow is detected, 0 otherwise.

trmnl framework

Manage the cached TRMNL CSS/JS framework used by preview.

trmnl framework status    # Show cached framework info
trmnl framework update    # Fetch latest from CDN
trmnl framework check     # Check if an update is available

trmnl plugin

Manage webhook plugins. Each plugin is a named reference to a TRMNL custom plugin webhook URL.

# List plugins
trmnl plugin

# Add a plugin
trmnl plugin add home "https://trmnl.com/api/custom_plugins/abc123"
trmnl plugin add office "https://trmnl.com/api/custom_plugins/xyz789" --desc "Office display"

# Set default
trmnl plugin default home

# Update a plugin
trmnl plugin set home --url "https://..."

# Remove a plugin
trmnl plugin rm office

trmnl config

Show current configuration: plugins, tier, history path, and environment variables.

trmnl config

trmnl tier

Get or set the payload size tier.

trmnl tier         # Show current tier
trmnl tier plus    # Set to plus (5 KB limit)
trmnl tier free    # Set to free (2 KB limit)

trmnl history

View and filter send history.

trmnl history              # Last 10 sends
trmnl history --last 20    # Last N sends
trmnl history --today      # Today's sends
trmnl history --failed     # Failed sends only
trmnl history --plugin home  # Filter by plugin
trmnl history stats        # Statistics
trmnl history clear --confirm  # Clear history

Configuration

Config file

Settings are stored in ~/.trmnl/config.json:

{
  "plugins": {
    "home": {
      "url": "https://trmnl.com/api/custom_plugins/...",
      "description": "Living room display"
    }
  },
  "defaultPlugin": "home",
  "tier": "free"
}

Environment variables

| Variable | Description | |----------|-------------| | TRMNL_WEBHOOK | Webhook URL (overrides config, highest priority) |

Data directory

All data is stored in ~/.trmnl/:

| File | Description | |------|-------------| | config.json | Plugin and tier configuration | | history.jsonl | Send history (one JSON entry per line) |

Tier limits

| Tier | Payload limit | Rate limit | |------|---------------|------------| | Free | 2 KB (2,048 bytes) | 12 requests/hour | | Plus | 5 KB (5,120 bytes) | 30 requests/hour |

License

MIT