# Clipwright CLI Clip long videos into vertical 9:16 shorts from the terminal. Zero dependencies; talks to the same self-hosted REST API the dashboard uses. ```bash pip install clipwright # or: uvx clipwright / pipx run clipwright ``` ## Use it against your own instance Clipwright is free, open source under MIT and self-hosted with Docker. There is no hosted edition and no paid plan, so there is no account to create. Point the CLI at your instance: ```bash export CLIPWRIGHT_API_URL=http://localhost:8000 clipwright process "https://youtube.com/watch?v=..." --wait clipwright clips clipwright publish 0 --platforms tiktok,youtube clipwright quota ``` Self-hosted instances are open by default and need no API key. You do need a Google Gemini key: put it in the server's environment, or send it per call as an `X-Gemini-Key` header. If you put your own instance behind a key, the CLI sends `CLIPWRIGHT_API_KEY` (`clw_...`) as a bearer token. ## Publish through Postiz Publishing goes through your self-hosted Postiz instance. Pass the base URL and API key with `--postiz-url` / `--postiz-key`, or set `POSTIZ_URL` / `POSTIZ_API_KEY`; the CLI forwards them to the server as `X-Postiz-Url` / `X-Postiz-Key`. ```bash clipwright publish 0 --platforms tiktok,youtube \ --postiz-url https://postiz.example.com --postiz-key ``` ## Quota `clipwright quota` prints the instance config it reads from `GET /api/config`: the job-retention window, whether YouTube-URL ingest is enabled, and the local-LLM setting. A self-hosted instance has no minute quota, so none is reported. ## Pipelines and webhooks Prefer the webhook to `--wait`: pass `--webhook` and `--webhook-secret` and Clipwright POSTs once (HMAC-signed, `X-Clipwright-Signature: sha256=`) when the job ends, with each clip's title and `video_url`. Set `PUBLIC_API_URL` on the server so those links are absolute; otherwise they are relative to your instance.