MyOC is a high-resolution original-character gallery built on Cloudflare Workers. It gives character owners a focused place to create profiles, organize characters into folders, upload character media, preserve full-resolution art, and share clean profile or character links.
The app is intentionally gallery-first. It is not trying to be a social network, marketplace, custom website builder, or
general lore platform. See the product direction in the in-app /product-vision page and the source in
src/views/pages/ProductVisionPage.tsx.
- High-quality galleries: uploads keep their original image bytes and format while also generating fast previews.
- Character management: users can create characters, folders, profile images, descriptions, gallery tabs, and custom gallery layouts.
- Size charts: characters can have calibrated height-chart images that are searchable and shareable.
- Toyhou.se migration: authenticated users can import character and gallery data from Toyhou.se.
- Content controls: SFW/NSFW media variants, blur assets, user display preferences, and image approval workflows are part of the product model.
- Passkey support: accounts can use WebAuthn passkeys, recovery phrases, and session controls.
- Cloudflare-native operations: D1 stores relational data, R2 stores media, KV caches derived views, and scheduled Worker jobs handle backup, cleanup, and leaderboard refresh work.
- TypeScript, Hono, and
hono/jsxfor the Worker and server-rendered UI. - Tailwind CSS 4 and daisyUI 5 for styling.
- Cloudflare Workers, D1, R2, KV, Images, and Cron Triggers for runtime infrastructure.
- Vitest with
@cloudflare/vitest-pool-workersfor Worker-aware tests. - Biome, TypeScript, Knip, and Semgrep for quality checks.
- Node.js
>=24 <25 - npm 11
- Wrangler access to the Cloudflare account when running the full Worker locally or deploying
git clone https://github.com/razethion/myoc.git
cd myoc
npm ci
cp .dev.vars.example .dev.varsAuthenticate Wrangler if you are running the full Worker locally or deploying:
npx wrangler loginPrepare the local D1 database and seed development data:
npm run db:prepare:localStart the development server:
npm run devWrangler prints the local URL, usually http://localhost:8787.
Seeded local accounts:
| Username | Password | |
|---|---|---|
demo |
demo@example.test |
password123 |
artist |
artist@example.test |
password123 |
collector |
collector@example.test |
password123 |
Open the local site and sign in with a seeded account:
http://localhost:8787/login
Useful local routes:
/- homepage, search, discovery, and public gallery previews/characters- signed-in character and folder management/settings- profile, social links, passkeys, recovery, and sessions/migrate- Toyhou.se migration flow/search- user and character search/leaderboard- leaderboard view/size-chart- character size-chart comparison/whats-new- release notes from src/lib/releases.ts
Example read-only API request:
curl "http://localhost:8787/api/search?type=characters&q=raz"Common commands:
npm run build
npm run typecheck
npm run lint
npm run test
npm run coverage
npm run deadcode
npm run semgrep
npm run ci| Path | Purpose |
|---|---|
src/routes |
Page and API route handlers. |
src/views |
Server-rendered layouts, components, and pages. |
src/lib |
Auth, media, search, admin, gallery, and shared business logic. |
migrations |
D1 schema history. |
scripts |
Local utility scripts. |
.github |
Issue templates and CI/deployment workflows. |
MyOC is licensed under GPL-3.0-only.