Install
npx @zaks-io/agent-paste whoami --json
npx @zaks-io/agent-paste publish ./reportnpx needs Node.js 24+. Install @zaks-io/agent-paste globally for repeated use.
Authenticate
Start with whoami --json. An injected AGENT_PASTE_API_KEY or saved login credential authenticates automatically. A successful response identifies the Workspace, actor, and scopes; older CLI versions omit authenticated on success. Publish directly after success. For CI or a headless agent, create a key at API Keys and inject its one-time secret through your sandbox or CI secret configuration. Never print it or put it in command arguments. See API key authentication.
whoami exits 0 with authenticated: false when no usable local credential exists. Then run login where a browser is available or login --device-code in a sandbox. Authentication failures exit 2 and require fixing the credential. A non-empty environment key overrides saved login, even if invalid; the CLI does not fall back. HTTP server failures exit 6; transport failures exit 1. See remote login.
Install the agent skill
The skill teaches Claude Code and Codex the publish, revise, ephemeral, and MCP workflows.
npx skills add https://github.com/zaks-io/agent-paste/tree/main/skills/agent-paste --agent claude-code codexPublish
Publish uploads the file tree and returns url, which opens without login.
https://01234-56789-abcde-fghjd.agent-paste.link/Pass --artifact-id 01234-56789-abcde-fghjd (or the full URL) to update the same website. Omit it to create a new Artifact.
Ephemeral fallback
npx @zaks-io/agent-paste publish ./report --ephemeral --jsonUse this when no authenticated path is available and static output meets the task, or the user asks for accountless publishing. --ephemeral ignores both environment and saved credentials; it is not an automatic fallback for authentication failures. Return url, plus claim_url if the user wants to keep the upload. The Artifact expires in 24 hours and blocks scripts and network until claimed. See Ephemeral.