Docs · CLI

The Shareable CLI

One command turns a local HTML file into a shareable link your team can revisit. Works the same way from your terminal, from Claude Code, and from Codex.

Install

One copy-paste sets up the CLI and wires it into your agent. Pick the one you use and run it in your terminal:

What that script does, in order: installs shareable globally via npm, drops the shareable-publish skill into your agent’s skills folder, appends a short note to your agent’s instructions file so it knows when to offer Shareable, then runs shareable login to authorize this device. Requires Node.js 20+ and npm.

Just want the CLI, no agent setup?

Install from npm directly. You’ll need to run shareable login yourself.

npm install -g shareable-cli
shareable login

Confirm it landed on your PATH:

shareable --version

Log in

The CLI authorizes your device through your browser — no copy-pasted tokens.

shareable login

A verification URL opens automatically. Approve the device, and the CLI writes a token to ~/.shareable/env. Sanity-check:

shareable whoami

Publish an artifact

Point the CLI at a single HTML file. The share URL is the only thing printed to stdout, so it composes well with other commands.

shareable publish ./report.html

With supporting assets (images, CSS, fonts, data files), point--assets at the directory. Shareable preserves the paths your HTML references.

shareable publish ./report.html \
  --assets ./assets \
  --title "Q2 forecast" \
  --description "Short context for the recipient"

To update an existing artifact at the same share URL, pass its id:

shareable publish ./report.html --artifact-id <id>

Commands

CommandDoes
shareable loginAuthorize this device through the browser. Writes the token to ~/.shareable/env.
shareable logoutRemove the saved token.
shareable whoamiPrint the account this device is signed in as.
shareable publish <file>Upload <file> (and optional assets) and print the share URL.
shareable --versionPrint the CLI version.
shareable --helpShow usage.

Publish options

FlagDoes
--assets <dir>Include a directory of supporting files (images, CSS, JS, fonts, data).
--title <title>Title for the artifact. Inferred from the filename if omitted.
--description <text>Short context shown alongside the share link.
--source <claude|codex|cli>Records which agent or tool produced the artifact.
--artifact-id <id>Update an existing artifact at the same share URL instead of creating a new one.

Environment

The CLI auto-loads ~/.shareable/env (and falls back to~/.annexo/env for installs from before the rename). The variables it reads:

VariablePurpose
SHAREABLE_API_TOKENAuth token. Written by `shareable login`.
SHAREABLE_BASE_URLAPI host. Defaults to https://www.shareable.page.
SHAREABLE_SOURCEDefault upload source for `shareable publish` (cli, claude, codex).

Use it from your agent

The “Get started with Claude” and “Get started with Codex” buttons on the home page run a one-line installer that (1) installs the CLI from npm, (2) drops the shareable-publish skill into the agent’s skills directory, (3) adds a small note to your agent’s instructions file so it knows to offer Shareable when an HTML artifact is ready, and (4) runs shareable login.

Once installed, the agent runs the same command you would:

shareable publish ./dist/index.html --assets ./dist --title "Pipeline walkthrough"

Troubleshooting

Token is invalid or expired

Run shareable login again. Tokens are not revoked automatically — old ones keep working until you revoke them in dashboard settings.

Could not reach https://…

Override the host if you self-host Shareable or hit a corporate proxy:

SHAREABLE_BASE_URL=https://shareable.example.com shareable login

The HTML does not include a viewport meta tag…

Shareable serves uploaded HTML inside a sandboxed iframe. Warnings don’t block publishing, but they are worth reading before sharing the link.

Security

  • Tokens are stored locally in ~/.shareable/env at mode 600. They are not synced to a cloud config.
  • Uploaded HTML is rendered in a sandboxed iframe and external resources are flagged with warnings.
  • Don’t publish content with secrets, credentials, or regulated data unless your recipient is authorized.
Need something not listed here? Open an issue on GitHub.