Make it your own
The checklist for turning the template into your product.
Onyx is a template: you fork it, rebrand it, and replace the demo product with yours. This page is the full checklist, in the order that works best. Identity first, then infrastructure, then content, then the demo product.
1. Rebrand
Everything prose-level reads from @repo/brand, so this
step is small:
- Edit the
brandobject inprivate/brand/src/index.ts: name, slug, description, URLs, email, and author. Theslugdrives the locale and consent cookies, the API key prefix, the log service, and the analytics SDK tag. - Replace
private/brand/src/assets/logo.svgand the polygons inprivate/brand/src/mark.tsxwith your logo. Favicons and OG images derive from these. - Delete
private/brand/src/author-mark.tsxand its "built by" usages, and replaceassets/banner.png(the README banner). - Regenerate the OG snapshot baselines, which capture the old logo and name:
cd apps/web && pnpm test:e2e -- --update-snapshots og.spec.ts.
2. Rename the infrastructure
Cloudflare resource names live in config, which cannot import @repo/brand.
The convention is <slug>-<thing>. In apps/web/wrangler.jsonc and
apps/docs/wrangler.jsonc:
- Worker names
onyx-webandonyx-docs, and bothroutespatterns. onyx-db(also in themigratescripts inapps/web/package.json),onyx-storage,onyx-jobs, andonyx-jobs-dlq. Create your own resources per DEPLOY.md in the repository root and put the newdatabase_idinwrangler.jsonc.- The vars carry the template's live values and are all yours to replace:
BETTER_AUTH_URL,MAIL_FROM,STRIPE_PRICE_PAID,OPENPANEL_CLIENT_ID, andSENTRY_DSN(blank disables Sentry).
Run pnpm cf-typegen in apps/web after editing.
3. Connect your services
DEPLOY.md walks through every account and secret. Required: Cloudflare,
Stripe, Resend, Anthropic, and OpenPanel. Optional: Sentry, Turnstile, and
Google/GitHub OAuth. CI deploys on push to main once the repository secrets
listed there exist.
4. Set your plans and pricing
The whole catalog, features, plans, limits, and display prices, is
private/billing/src/plans.ts. Register each paid plan's
Stripe price in private/auth/src/stripe.ts.
5. Replace the content
All of it is placeholder describing Onyx itself:
- Messages: user-facing copy lives in
private/i18n/messages. Themarketing.jsonkeys are Onyx sales copy to rewrite in each locale; a unit test enforces key parity, so change all three together. - Blog and changelog:
apps/web/content/postsandapps/web/content/releases. The architecture section inprivate/ui/src/marketing/sections.tsrxlinks to theone-workerpost by slug; update it with your posts. - Marketing structure: feature cards, FAQ, and stack list in
private/ui/src/marketing/data.ts; prices inpricing.tsrx. - OG titles in
apps/web/og/config.tsand the pitch paragraph inapps/web/src/routes/llms[.]txt.ts. - Docs: this site. The
private/*pages document the packages and stay accurate; the introduction and thepublic/*pages describe Onyx and its npm packages.
6. Replace the demo product
Tasks, Notes, and the AI chat exist to prove the realtime, editor, and agent
plumbing. Their content lives in realtime rooms (Durable Objects, snapshotted
to the generic document table), not in tables of their own, so there is no
demo schema to drop. Deleting a demo page means also removing its tendrils:
/app/tasks(apps/web/src/tasks): thetask_createdevent inprivate/analytics/src/events.ts./app/notes(apps/web/src/notes): thementioned-in-notesnotification, thenote-imagekind inapps/web/src/files/kinds.ts, and the/org/notesroute in the@repo/apicontract andapps/web/src/api/router.ts./app/chat(private/ai): theaifeature in the billing catalog, which exists to demo a plan-gated feature.- All three: their nav items in
app-sidebar.tsrx, their message keys, their e2e specs, the "tasks and notes" sentence in thewelcome_bodymail message, and the "Workspace Content" category inapps/web/src/policystack.ts.
Your own entities get a schema file in private/db/src/schema
and server functions in apps/web/src; the webhooks, notifications, and
analytics registries show the pattern for fanning out from them.
7. Legal
- In
apps/web/src/policystack.ts, replace the company block (legal name and address are placeholders), review every purpose and retention, and describe what your product actually collects. Have a lawyer read the rendered/privacyand/cookiesbefore launch. - The repository's LICENSE.md is the Onyx License, which covers the template itself. Its End Products grant means your product ships under terms you choose; the template code you redistribute keeps its license and copyright notices, and the Onyx name stays JXD's.
- There is no terms-of-service page; add your own.
8. The published packages
published/* ships the API client, CLI, and Vite plugin to npm as
@jxdltd/onyx-*. If your product has no public API story, delete the
directory and .github/workflows/release.yml. To keep them, rename the
package scope and the identifiers they carry: the onyx CLI binary,
ONYX_API_URL/ONYX_API_KEY, the ~/.config/onyx directory,
DEFAULT_ORIGIN in both client and CLI, the virtual:onyx module id, and
the device-flow client_id: 'onyx-cli', which the auth server sees.
9. Before your first release
- Promote your first admin with the SQL one-liner in DEPLOY.md.
- Switch from
drizzle-kit pushto committed migrations once anyone besides you runs the product; "Switching to migrations" inprivate/db/README.mdis the recipe.