@rehelios/cli
CLI reference
A thin client over the rehelios API. Run with npx @rehelios/cli <command> —
the installed binary is rehelios. Add --json to any command for machine-readable output.
Commands
rehelios doctor Check your key, connectivity and permissions. Run this first.
--json
rehelios upload <file> Upload a video file; prints its embed URL.
--wait · --title · --collection · --json
rehelios import <url> Import a video from a public HTTP(S) URL.
--wait · --title · --collection · --json
rehelios ls List videos.
--status · --search · --collection · --page-size · --json
rehelios get <id> Show a video's full details.
--json
rehelios embed <id> Print the embed URL, or a full <iframe>.
--iframe
rehelios mcp Run the MCP server over stdio (used by AI clients).
rehelios doctor
Self-diagnose before you ship. doctor checks that your key is set and
well-formed, the API is reachable, and the key is actually accepted — then exits non-zero if anything critical fails (handy in CI or an agent's setup step).
$ npx @rehelios/cli doctor
✓ api_key REHELIOS_API_KEY is set (…a1b2)
✓ key_format key has the expected rh_live_ prefix
✓ api_url https://api.rehelios.com responded HTTP 200
✓ auth key accepted — 12 video(s) in this account
✓ app_url https://app.rehelios.com (used for embed URLs)
All critical checks passed — you're ready to ship video. Machine-readable output
Every command takes --json and prints structured output to stdout (progress goes to stderr, so pipes stay clean).
$ npx @rehelios/cli upload ./demo.mp4 --wait --json
{"id":"vid_8x2k","embedUrl":"https://app.rehelios.com/embed/vid_8x2k","status":"ready"}
$ npx @rehelios/cli ls --status ready --json | jq '.items[].id'
$ npx @rehelios/cli doctor --json
{"ok":true,"checks":[{"name":"api_key","status":"pass", … }]} Expected errors
Errors print to stderr as error [CODE]: message and the process exits non-zero. The common ones:
NO_API_KEY REHELIOS_API_KEY is unset. Create a key in the dashboard and export it.
401 / UNAUTHORIZED Key is missing, revoked, or mistyped. Generate a fresh key; check for stray whitespace.
403 / FORBIDDEN Key is valid but lacks permission for the action. Check the key's scopes in the dashboard.
404 / NOT_FOUND The video id doesn't exist in this account. Verify the id with rehelios ls.
429 / RATE_LIMITED Too many requests for this credential. Back off and retry after the window resets.
Configuration
REHELIOS_API_KEY — (required) REHELIOS_API_URL https://api.rehelios.com REHELIOS_APP_URL https://app.rehelios.com The same key drives the MCP server and the REST API. npm: @rehelios/cli.