HTML publishing CLI

Publish an HTML file from the command line in 1 command.

When the artifact already exists on disk, opening a dashboard and rebuilding its context is unnecessary. The HTML Docs CLI publishes the file from the directory where you created it and returns a live URL. That makes it a natural last step for scripts, coding agents, and repeatable report workflows.

The shortest publishing path should start where the file lives.

A command-line workflow avoids drag-and-drop handoffs and lets the publishing step become part of the agent task or generation script. Unlike a bare file host, the resulting page can participate in comments, versions, API updates, and later collaboration.

How it works

From local output to a reviewed artifact.

01

Install the CLI

Use the package directly with npx or install it into your preferred agent workflow.

02

Run publish

Point the command at a complete local HTML file.

03

Use the returned URL

Open it, share it, or pass it to the next automation step.

04

Update through the API

Keep the page current without changing the reviewer-facing link.

What changes when review is built into the page

Fits the generation loop

Publish immediately after the file is created.

Automation friendly

Use stable commands and JSON-capable API operations in scripts.

Collaboration after publish

The output is a document, not only a static upload.

HTML Docs vs. Manual upload

Choose for the job you actually need to finish. This comparison focuses on workflow, not a blanket claim that one tool replaces another.

CriterionHTML DocsManual upload
Context switchStay in the terminalOpen a browser and select the file
AutomationScriptable CLI and APIHuman interaction required
Agent useDirect skill and command workflowAgent must hand the file back to a person

Frequently asked questions

What is the publish command?

Run `npx @html-docs/cli publish page.html` with the path to your HTML file.

Do I need an account for the first publish?

Anonymous publishing is supported. Keep the returned document token private because it authorizes later updates.

Can the command request a custom slug?

Yes. Authenticated and eligible workflows can request or manage a memorable published slug.

Is there an API as well as a CLI?

Yes. The v1 REST API covers documents, regions, comments, versions, folders, sites, webhooks, and search.

Publish the next artifact from where it was created.

npx @html-docs/cli publish page.html