ckweb-cli
v0.6.0
Published
CLI tool for interacting with ClaudeKit.cc API
Downloads
1,402
Readme
ckweb-cli
CLI tool for interacting with the ClaudeKit.cc API.
Related Repositories
- Backend / web app: claudekit/claudekit — local path:
/Volumes/GOON/www/claudekit/claudekit-web- Source of all
/api/admin/*endpoints consumed by this CLI.
- Source of all
Install
pnpm install
pnpm build
pnpm link --globalQuick Start
# Authenticate with your user API key
ckweb auth login
# Authenticate with admin API key
ckweb auth login --admin
# Check API health
ckweb health
# YouTube tools
ckweb youtube info "https://youtube.com/watch?v=..."
ckweb yt search "typescript tutorial"
# Website analysis
ckweb web review "https://example.com"
ckweb web convert "https://example.com"
# SEO insights
ckweb seo keywords "react framework"
ckweb seo traffic "example.com"Commands
Authentication
| Command | Description |
|---------|-------------|
| auth login [--admin] | Authenticate with API key |
| auth validate [--admin] | Validate stored key |
| auth logout [--admin\|--all] | Remove stored key(s) |
| auth status | Show authentication status |
Orders & Payments
| Command | Description |
|---------|-------------|
| orders get <id> | Get order details |
| orders status <id> | Check order status |
| checkout polar | Create Polar checkout (USD) |
| checkout sepay | Create SePay checkout (VND) |
| refunds request <orderId> | Request a refund |
Account
| Command | Description |
|---------|-------------|
| account export-data | Export your data (GDPR) |
| account delete | Delete your account (GDPR) |
| account update-github <userId> | Update GitHub username |
Referrals & Payouts
| Command | Description |
|---------|-------------|
| referrals dashboard | View referral stats |
| referrals request-payout | Request payout |
| referrals payout-history | View payout history |
| payout profile | View payout profiles |
| payout create-profile | Create payout profile |
| payout delete-profile | Delete payout profile |
Content
| Command | Description |
|---------|-------------|
| blog list | List blog articles |
| blog get <id> | Get article details |
| releases list [--tab] | List product releases |
Proxy Services (YouTube, Web, SEO)
| Command | Description |
|---------|-------------|
| youtube info\|caption\|summary\|screenshot\|search\|comments | YouTube tools |
| web review\|scrape\|extract\|convert\|summarize\|screenshot | Website tools |
| seo keywords\|difficulty\|traffic\|backlinks | SEO tools |
Pricing & Info
| Command | Description |
|---------|-------------|
| pricing validate-discount <code> | Validate discount code |
| pricing exchange-rate | Get USD/VND rate |
| pricing early-access | Early access status |
| loyalty eligibility | Check loyalty eligibility |
| stats users | Platform user count |
Other
| Command | Description |
|---------|-------------|
| github invite\|revoke | GitHub repo access |
| newsletter subscribe\|unsubscribe | Newsletter management |
| waitlist join | Join product waitlist |
| health | Check API health |
Admin Commands (requires admin key)
| Group | Commands |
|-------|----------|
| admin orders | list, search, get, invoice (--output), complete, refund, refund-keep-access, switch-product (engineer_kit/marketing_kit), resend-emails, resend-github-invite, export, stats (--start, --end, --status, --provider, --vat-requested) |
| admin users | get, update, update-github, update-rates, set-tier, delete-orphan (--reason), export, stats (--start, --end) |
| admin referrals | stats, user-stats, diagnose, export, tiers-stats |
| admin revenue | stats (--product, --no-team), export, maintainer, costs, add-cost, update-cost, delete-cost, reports |
| admin payouts | list (--search, --status, --limit, --offset), update, export, export-detailed, request-csv |
| admin loyalty | stats, blast-email |
| admin blog | create (--status, --scheduled-for), update (--status, --scheduled-for), delete, publish, run-scheduler, ai-generate, ai-transform, generate-metadata, upload-url, export, categories (list/get/create/update/delete), article-categories (add/remove), tags, tag-get, tag-create, tag-update, tag-delete, article-tag-add, article-tag-remove |
| admin keys | list, create, validate, revoke, rotate |
| admin licenses | update-github |
| admin invites | list, create, get, delete, resend, accept, validate |
| admin admins | list, get, promote, demote, permissions |
| admin discounts | list, create, update, delete, sync-status, export |
| admin discount-groups | list, get, create, update, delete |
| admin tiers | list |
Authentication
Two types of API keys:
- User key (
ck_live_*): For user-facing operations - Admin key (
ck_live_*, issued by admin tooling): For admin operations
Both key types share the same ck_live_ prefix and base64url format; the user/admin distinction is determined by which slot the key is stored in (or which env var is set), not by the key itself.
ckweb auth login # User key
ckweb auth login --admin # Admin key
ckweb auth status # Show stored keysConfig stored at ~/.config/ckweb-cli/config.json.
Environment Variables
| Variable | Description | Format / Default |
|----------|-------------|------------------|
| CKWEB_API_KEY | User API key — replaces ckweb auth login | ck_live_<32+ chars> |
| CKWEB_ADMIN_API_KEY | Admin API key — replaces ckweb auth login --admin | ck_live_<32+ chars> |
| CKWEB_API_URL | Override API base URL | https://claudekit.cc/api |
Resolution priority (first match wins)
- OS-level env —
export CKWEB_API_KEY=…in shell / CI secrets / inlineCKWEB_API_KEY=… ckweb … - Stored config — values saved via
ckweb auth login(orlogin --admin) - .env.* files in current working directory — loaded in order:
.env.local→.env
API keys must match format ck_live_<32+ base64url chars> or the tier is skipped and the next one is tried.
Examples
# One-off admin command via env var
CKWEB_ADMIN_API_KEY=ck_live_… ckweb admin orders list
# Project-local keys via .env file (auto-loaded from cwd)
echo 'CKWEB_API_KEY=ck_live_…' > .env
ckweb health
# Point CLI at a local dev server
CKWEB_API_URL=http://localhost:3000/api ckweb health
# Inspect what's being used
ckweb auth status # shows resolution source (env / config / .env)
.envis gitignored by default. Never commit keys to version control.
Output Modes
All commands support:
--json— Raw JSON output (for piping/scripting)--table— Formatted table (default for lists)--quiet— Minimal output
Development
pnpm install
pnpm dev # Watch mode
pnpm build # Production build
pnpm lint # Type check
pnpm test # Run unit + integration tests (hermetic, no key needed)
pnpm test:e2e # Run e2e tests against the real claudekit APIE2E tests
pnpm test:e2e builds the CLI and exercises the published binary against the real claudekit API.
Requires both CKWEB_API_KEY and CKWEB_ADMIN_API_KEY in .env (or shell env).
These tests run on PRs and on main push, gate the npm publish step in release.yml, and are duplicated inside the configured beta release workflow for dev.
Releasing
Auto bump (recommended)
Trigger via GitHub Actions UI or CLI:
# auto-detect from conventional commits since last tag
gh workflow run bump-version.yml -f bump=auto
# explicit bump
gh workflow run bump-version.yml -f bump=patch # or minor / majorBump rules (auto mode):
feat:→ minorfix:/perf:→ patchBREAKING CHANGEorfeat!:/fix!:→ major
Beta releases
Beta release automation is configured in .github/workflows/beta-release.yml for pushes to dev and manual dispatch.
The beta lane:
- Runs install, lint, unit/integration tests, build, and real API e2e tests.
- Computes semver prereleases like
0.5.2-beta.0,0.5.2-beta.1. - Updates root
CHANGELOG.md. - Checks that the target npm version does not already exist.
- Runs
npm publish --tag beta --dry-runbefore pushing the beta version commit and tag. - Pushes the beta commit/tag atomically to
dev, then publishes with npm dist-tagbeta.
Install beta builds with:
npm install -g ckweb-cli@betaCurrent status: verified on dev by Beta Release run 26159614526, published as [email protected] with npm dist-tag beta.
- no relevant commits → skipped
The workflow bumps package.json, creates chore(release): vX.Y.Z commit + tag,
pushes, then dispatches the Release workflow.
Manual bump
npm version patch # or minor / major
git push --follow-tagsRelease workflow
.github/workflows/release.yml (triggered by v* tag):
- Verifies tag matches
package.jsonversion - Runs
lint+test+build - Publishes to npm (requires
NPM_TOKENsecret) - Creates GitHub Release with auto-generated notes
Tech Stack
- TypeScript, Node.js 18+
- Commander.js (CLI framework)
- Conf (config storage)
- tsup (bundler)
