The agentdraft CLI is a single Go binary with no runtime dependencies.
# Release binary for linux/darwin on amd64/arm64; SHA-256 verified against checksums.txt
curl -fsSL https://raw.githubusercontent.com/Tapetide-hq/agentdraft/main/cli/install.sh | sh
# Or from source (Go 1.24+). Resolves to the latest tagged release.
go install github.com/Tapetide-hq/agentdraft/cli@latestWindows: download the .zip from the releases page.
agentdraft --version reports the release version either way.
State lives in ~/.agentdraft/ (dir 0700, files 0600):
config.json—{ "api_url": "https://api.agentdraft.tapetide.com" }credentials.json—{ "api_key": "ad_…", "account_id": "acct_…" }drafts.json— maps local file paths to draft IDs so re-uploads update the same draft
agentdraft auth login Interactive: paste an API key (verified server-side)
agentdraft auth set <key> Store an API key non-interactively (verified server-side)
agentdraft auth logout Remove stored credentials
Prints the current account, auth method, and scopes.
Upload an HTML or Markdown file. A .md file is rendered server-side for browser
reading, with the exact source retrievable at /raw. Creates a new draft, or updates the mapped draft if this file was
uploaded before.
--project <name|id> Assign to a project (created if a new name)
--draft <id> Force-update a specific draft
--new Always create a new draft
--description <text> Short label
--title <text> Override the extracted <title>
--idempotency-key <k> Dedupe retries (same key = same version)
--private Create it owner-only (overrides the account default)
--public Create it public (overrides the account default)
Output: public URL, draft id, version number, title. Warnings print to stderr. Blocked HTML fails with the server's validation error codes.
--private / --public apply only when the draft is CREATED. Re-uploading to an existing
draft never changes its visibility — silently flipping a link you already shared would be a
nasty surprise. Use agentdraft visibility for that.
Change who can read a draft. The URL never changes.
--all Apply to EVERY existing draft in the account
--default Set the default for NEW drafts (existing drafts untouched)
The target accepts a draft id, a full content URL, or a local file path you have uploaded
before (resolved through the same drafts.json mapping upload uses).
agentdraft visibility private plan.md # the draft this file publishes to
agentdraft visibility public a1b2c3d4e5f6 # by id
agentdraft visibility private --default # only affects NEW drafts
agentdraft visibility public --all # every existing draftA private draft's link still works for you: it redirects through the dashboard, which
verifies you own it. Anyone else gets a sign-in page. --all reports how many drafts
actually changed, so a no-op says so instead of claiming success.
Upload any file (screenshot, recording, log, PDF, archive) and get a public URL. Unlike
upload (which renders HTML/Markdown as a readable document), file stores raw bytes and
serves them as-is.
--content-type <mime> Override the type sent to the server
--idempotency-key <k> Dedupe retries; a replay returns the same file
Images, MP4/WebM, MP3, plain text, and PDF preview in the browser; everything else downloads. Files are not versioned — each upload is a new URL. Max size 100 MB. Files are public to anyone holding the URL — do not upload secrets.
agentdraft file screenshot.png
# URL: https://agentdraft.tapetide.com/f/vhfkhc4sv7a03nau6ciojgDownload a draft's source bytes: the Markdown for a .md draft, the HTML otherwise.
-o, --output <file> Write to a file instead of stdout
--version <n> Fetch a specific version
Works on PRIVATE drafts too, provided you own them: the content origin answers with a redirect, and the CLI retries through the authenticated API rather than following it. That matters because following the redirect would write the dashboard's HTML login page to your output file and exit 0 — a silent wrong-content success. With no stored credentials the command exits 1 and writes nothing.
List your drafts.
--project <id> Filter by project
--json JSON output
--limit <n> Max results (default 100)
List your projects. --json for machine output.
agentdraft config Show current config
agentdraft config --api-url <url> Point the CLI at a different instance
The agentdraft skill teaches Claude Code, Codex, Kiro and other agents
these commands, when to use upload versus file, and the pitfalls. Install it with
npx skills add Tapetide-hq/agentdraft -g.
agentdraft upload plan.html --project "my-project" --description "Architecture v2"
agentdraft fetch https://agentdraft-content.<sub>.workers.dev/d/abc123 # or curl the URL
agentdraft list --jsonThe CLI collects git metadata (branch, commit, dirty flag) automatically when run inside a repository and attaches it to the version record.