← back to Studio Zero

README.md

52 lines

# Studio Zero

**0 → monetized AI YouTube channel in 90 days.** A guided 7-step web app that
runs the seven prompts from [@David263146](https://x.com/David263146/status/2079054195941147042)
verbatim through Claude and hands you real deliverables — niche, brand identity,
a 90-day content calendar, scripts, thumbnails/SEO, a monetization stack, and a
repurposing engine.

Built by the Claude web-dev accelerator. See `BRIEF.md` for the full intake.

## Run
```bash
PORT=4173 node server.js                 # open http://localhost:4173
```
- **Live mode** (default when a key resolves): calls the Anthropic API. The key
  is read at runtime from `ANTHROPIC_API_KEY`, then `./.env`, then the master
  secrets `.env` — never copied or committed. Model default `claude-sonnet-4-6`
  (override `SZ_MODEL`).
- **Demo mode** (no key): every step returns a canned deliverable so the whole
  flow is clickable at `$0`.
- **Fallback honesty**: if a *live* provider call fails mid-generation (e.g. an
  expired CLI/OAuth token 401s), the server substitutes canned demo content but
  flags it `fallback:true`, and the UI raises a **persistent "generation
  unavailable — placeholder demo content" banner** (with the real reason) plus a
  `fallback demo` badge — so a failed call is never silently mistaken for a real
  result. Guarded by `test/fallback.spec.js`.

Each generate shows its **estimated + actual $ cost**; the header keeps a running
session total.

## Auth (optional, default OFF)
The app ships open (firewalled/internal-only). To stage it for a future public
launch, set `SZ_BASIC_AUTH=1` and the whole app — including `/api/*` and the
health check — requires HTTP Basic-Auth. Credentials default `admin` / `DW2024!`,
overridable via `SZ_BASIC_USER` / `SZ_BASIC_PASS`. While the flag is unset,
behavior is byte-for-byte unchanged (no auth), so it never affects the current
`:9761` service or the `/deploy` `/api/config` smoke test. Guarded by
`test/auth.spec.js`.

## Layout
- `server.js` — static host + `POST /api/generate` (Anthropic proxy, cost
  accounting, demo fallback) + `/api/config` + `/api/prompts`.
- `data/prompts.json` — David's 7 verbatim prompts (single source of truth).
- `public/index.html` — the wizard (7-step stepper, niche carry-forward,
  Step-3 calendar as a sort+density grid, projects saved to localStorage with
  created date+time).

## Preview / launch
- Local preview: `/viewer` behind `admin / DW2024!` (accelerator Phase 5).
- Deploy is **Steve-gated** (accelerator Phase 6) — `.deploy.conf` is present so
  `/deploy` is one switch away, but DNS/publish/spend never run autonomously.