AI generates HTML
Claude, Codex, Cursor — whatever your assistant — produces a self-contained pergam: a PR review board, a status dashboard, a spec with Mermaid.
A tiny self-hostable service that turns every HTML report, dashboard, or analysis your AI generates — from Claude Code, Cursor, Codex, or any tool that can curl — into a permanent, versioned URL you can share. Send one link; whoever opens it gets the real, interactive artifact — not a screenshot, not a PDF.
.html · lasts 1 year · max 1 MB
How it works
pergam is the glue between an AI that builds HTML artifacts and a team that needs to open and re-find them. Three steps, no UI to learn.
Claude, Codex, Cursor — whatever your assistant — produces a self-contained pergam: a PR review board, a status dashboard, a spec with Mermaid.
The companion Claude Code skill packages the HTML with title, type, and your email, then pushes to POST /pergam — no manual upload, no copy-paste.
Receive a stable URL like pergam.dev/a1b2c3d4/view. Re-publish the same id and you get v2, v3… latest always wins, history is preserved.
Why pergam vs. a generic HTML pastebin
Anonymous HTML hosts are fine for one-shot shares. pergam is for the workflow: your AI iterates, your team revisits, your infra stays private.
Send an analysis, dashboard, or report as one link. The recipient opens the live artifact — Mermaid, charts, dark theme intact — no repo, no deploy, no account. Hosted links last a year; self-host keeps them forever.
AI posts directly to your instance. No file upload step, no copy-paste, no leaving the terminal.
A handful of clean HTTP endpoints. Curl-friendly, library-free, easy to wrap from any agent runtime.
docker compose up behind your VPN. Your team's network is the trust boundary.
Re-POST to the same id → new version. History is forever. /view is always latest. Nothing gets clobbered.
Find your pergams by author, type, or title substring. The index is just another HTML page — opinionated, fast, no JS framework.
One Python file. One schema. Audit it in 10 minutes. Fork it. No vendor account, no telemetry, no surprise pricing.
Quickstart · pick your path
git clone to shareable URL in 60 seconds.Whichever path you take, you end up with the same thing: a stable URL your team will actually open.
# 1. Clone & install the skill once git clone https://github.com/diesilveira/pergam cp -r pergam/skills/post-pergam ~/.claude/skills/ # 2. Point it at a pergam (defaults to the hosted service) export PERGAM_URL="https://api.pergam.dev" # hosted — or just leave unset # export PERGAM_URL="http://localhost:1111" # self-hosted # 3. Inside any project, ask Claude: # "armá un pergam de X y publicalo" # → returns view_url, ready to share.
# 1. Clone git clone https://github.com/diesilveira/pergam cd pergam # 2. Bring up the stack docker compose up -d --build # 3. Verify and open curl http://localhost:1111/healthz # → {"ok":true} open http://localhost:1111/
Drop an .html file
or click to choose · public link, lasts 1 year · max 1 MB
It's a tiny self-hosted thing, not a SaaS. Stars are how I know it's solving a real problem — and how other devs find it.
FAQ
Devs and small teams whose AI assistant generates a steady stream of HTML artifacts — PR review boards, status dashboards, evaluation reports, design specs with Mermaid — that today die in chat scrollback.
Those strip CSS, break Mermaid, mangle dark themes, and require accounts. pergam keeps the artifact exactly as the AI rendered it.
Pergams are served from a sandboxed iframe on a different origin (api.pergam.dev) with a strict CSP that blocks everything except inline CSS and Mermaid from jsDelivr. Visitors are isolated. Rate limits and a 1 MB size cap keep any abuse cheap to contain.
Hosted links last a year. To keep pergams forever, self-host — you get a versioned, immutable history with no expiry.
Nothing. It's a markdown file in this repo. The AI's API costs are separate (whatever you pay for your Claude Code / Cursor / etc).
Those need a repo and a deploy step. pergam is a single POST /pergam with a body of HTML — that's the whole contract. It's the fastest way to turn an AI-built analysis into a link you can send: it opens the real, interactive artifact and lasts a year.
Anyone with this link can open the pergam for the next year.