clipwright/cli
pedro-bento edcfeaf9d5 refactor: remove cloud/ billing mode and flatten to self-hosted-only
- Delete the entire cloud/ package (Stripe billing, auth/OAuth, metering, API keys,
  account erasure, lifecycle/digest emails, R2 archive, autopilot, MCP OAuth,
  proxy ledger, managed keys) and all BILLING_ENABLED branches in app.py
- Keep self-host behavior via no-op shims; /api/config now returns
  {youtubeUrlEnabled, jobRetentionSeconds, localLlm}
- Remove cloud tests (31 files), alembic/, log_view.py, requirements-billing.txt,
  docker-compose.cloud.yml; update CLI to Postiz + /api/config; clean docs/skills
- Flatten dashboard: remove auth/billing/pricing/history chrome, inert config-only AuthContext
- Fix residual test drift; lint + build + compile all green
2026-10-04 17:02:55 +01:00
..
openshorts.egg-info Merge PR #70 (manual per-scene reframing) onto current main 2026-08-19 12:01:02 +02:00
openshorts_cli.py refactor: remove cloud/ billing mode and flatten to self-hosted-only 2026-10-04 17:02:55 +01:00
pyproject.toml refactor: remove cloud/ billing mode and flatten to self-hosted-only 2026-10-04 17:02:55 +01:00
README.md refactor: remove cloud/ billing mode and flatten to self-hosted-only 2026-10-04 17:02:55 +01:00

OpenShorts 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.

pip install openshorts        # or: uvx openshorts / pipx run openshorts

Use it against your own instance

OpenShorts 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:

export OPENSHORTS_API_URL=http://localhost:8000

openshorts process "https://youtube.com/watch?v=..." --wait
openshorts clips <job_id>
openshorts publish <job_id> 0 --platforms tiktok,youtube
openshorts 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 OPENSHORTS_API_KEY (osk_...) 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.

openshorts publish <job_id> 0 --platforms tiktok,youtube \
  --postiz-url https://postiz.example.com --postiz-key <key>

Quota

openshorts 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 OpenShorts POSTs once (HMAC-signed, X-OpenShorts-Signature: sha256=<hex>) when the job ends, with clip titles and durable download links.

The agent-native version of the same surface is the OpenShorts skill in skills/openshorts/.