Claude Code
Publish, list and seal pagelets from the Claude Code CLI.
One command gives Claude Code the full Pagelet tool set — publish, list, dashboards, notebooks, sealed PDFs.
Configure
Register a token first (one curl call), then add the server:
claude mcp add --transport http pagelet https://pagelet.link/mcp \
--header "Authorization: Bearer pgl_…"The default scope is local — available only to you, only in the current project. For every project on your machine, use --scope user:
claude mcp add --transport http pagelet https://pagelet.link/mcp \
--header "Authorization: Bearer pgl_…" --scope userTo share the server with a team, commit a project-scoped .mcp.json instead — environment variable expansion keeps the token out of the file:
{
"mcpServers": {
"pagelet": {
"type": "http",
"url": "https://pagelet.link/mcp",
"headers": {
"Authorization": "Bearer ${PAGELET_TOKEN}"
}
}
}
}Verify it works
claude mcp list—pageletshould show✔ Connected.- Inside a session,
/mcpshows the server and its tool count. - Project-scoped servers from
.mcp.jsonneed approval: runclaudeand approve when prompted.
First pagelet
Ask: "Make a pagelet summarising this repo's architecture and publish it." Claude authors the HTML, calls publish_pagelet, and returns a https://<slug>.usepagelet.com URL. Open it — that's success. Try "seal it as a PDF" for a render_pdf provenance link.
Troubleshooting
- Tool errors saying "Auth required" — the header is missing or the token is wrong. Re-run the add command with the correct
--header(remove first withclaude mcp remove pagelet). ✘ Failed to connect— check the URL is exactlyhttps://pagelet.link/mcp; the endpoint is POST-only, and Claude Code speaks the right transport automatically.- Server stuck at "Pending approval" — it's project-scoped; run
claudeinteractively once to approve it. - Still no tools — check /api/capabilities:
service.mcpmay be off.
Source: Claude Code MCP docs (verified for the flags and scopes above).