Skip to content
Versifer003Public

About

A network where founders and people ready to join a founding team find each other by skills, connect with a note, and message once accepted.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Foundry

A network where startups and founding teams form. Founders and builders (people ready to start or join a startup) connect through skills, share progress, find teammates, and message mutual connections.

Run

Requires Node 22.13+ (uses built-in node:sqlite, no dependencies).

npm start        # http://localhost:3000
npm test         # backend self-check

Data lives in foundry.db (override with DB_PATH). Delete it to reset.

Private settings such as sign-in provider keys go in a .env file next to server.js (one NAME=value per line). npm start loads it, and it's excluded from git and from uploads. On a host, set the same variables in its dashboard.

In development, emails (verification codes, reset links, notifications) are printed to the server console.

Demo data

On first run with an empty database, eight demo founders and two builders are created with posts, replies, connections, notifications, traction and focus statuses. Amara and Omar share Gridcell as co-founders, and Sara has a pending co-founder invite out to Marcus (sign in as marcus.bell@fastmail.com to accept it). All are email-verified; seven founders have the Verified badge. Every demo account uses the password foundry-demo-2026 — e.g. maya@helix.dev. Demo data is never created when NODE_ENV=production. The local preview config (.claude/launch.json) makes Maya an admin so you can try the Reports page.

Landing page

Signed-out visitors at / see the landing page (public/landing.js, styles under .lp in public/styles.css). All copy, links, ring colors, particle density, motion strength and the ring's position per section are in the LANDING object at the top of landing.js. The logo is loaded from public/logo.svg.

  • The glossy infinity ring and particles are drawn with plain WebGL (no libraries) and move with scroll position, so scrolling back up returns the ring to the same place.
  • Visitors can pause the motion. With "reduce motion" turned on in their system, the ring stays still and text doesn't animate. Without WebGL, a soft glow replaces the ring.
  • The page is always dark, whatever the system theme. It has no testimonials, member counts or prices; add them only once they're real.

How it works

  • Onboarding. Sign-up is four short steps (account, about you, company or team search, story and skills) with examples, a background length hint and one-click common skills so new members use names others match on. After sign-up, a welcome checklist covers verifying the email, adding a photo and sending a first request to suggested matches. The feed shows a profile-strength card until the profile has a photo, a 150+ character background, 3+ skills, a focus status and (for founders) a website.
  • Two member types. Founders add their startup, stage, and optionally a team status (looking for a co-founder, hiring a founding team). Builders have no company yet; they state what they bring, their goal (find a co-founder, join a founding team, build a team around an idea) and their availability (full-time now, within 3 months, part-time).
  • Profiles also require a headline, a 40+ character background, and two skill lists: Can help with (up to 12) and Looking for (up to 8).
  • Matching: suggestions rank people who can help with what you need first, then people who need what you know, then team fit (builders and recruiting founders), then shared skills. Discover filters by either skill list and by Founders / Looking for a team / Founders recruiting.
  • Verification: a 6-digit email code is required before sending connection requests. The Verified founder badge appears when the verified email's domain matches the startup website (free email providers never qualify). In development, codes are printed to the server console; pass sendCode to createApp to send real email.
  • Connections need a note (20–300 characters) and are limited to 15 per rolling week. Declines are silent: the requester keeps seeing "pending" and can't re-send. Profiles show a response rate after 3 received requests.
  • Messaging is enforced server-side: only accepted connections can message.
  • Block and report: blocking disconnects both founders and hides each from the other's search, feed, profile and messages. Reports are stored in the reports table for manual review.
  • Feed posts are typed (Update, Milestone, Ask, Team, Hiring, Insight) and can be filtered to your network. Ask and Team posts need 1–3 skill tags; members with those skills are notified and see them under For you, with an I can help / I'm interested button that sends a connection request linked to the post.
  • Replies on any post notify its author.
  • Profile photos: cropped square and re-encoded to JPEG in the browser (which also strips EXIF/GPS data), max 2 MB. The server checks the file's bytes, not just its declared type, and serves photos to signed-in members only.
  • Traction (founders, optional): revenue, team size and money raised, in fixed ranges rather than exact numbers.
  • Currently focused on: a short status shown with its age on profiles, Discover cards and company pages.
  • Companies and co-founders: every founder belongs to a company. A founder can invite a connection as a co-founder; on accepting, both share one company page, and any co-founder's edits to the company name, stage or traction apply to all of them. A builder who accepts becomes a founder with the role Co-founder. Switching your profile to builder takes you off the company.
  • Notifications: in-app Activity page with a live badge. Emails (requests, accepts, replies, matching posts, new messages) go out only when the member has no Foundry tab open, and can be turned off in Settings. In development, emails are printed to the server console; pass sendEmail to createApp to send real email.
  • Live updates over Server-Sent Events: messages and notifications arrive instantly.
  • Leaving a company: any co-founder can leave or remove another co-founder (who is notified). Either way the person's profile switches to "looking for a team" until they update it. The last founder to leave removes the company page.
  • Accounts: password reset by emailed link (30 minutes, single use, signs out every device), password change, and account deletion (needs the password; removes profile, posts, messages and connections).
  • Sign in with GitHub: the button appears on the sign-in and sign-up pages once the GitHub keys are set (see below). New members still complete their profile; their email counts as verified and they need no password. An existing account with the same email is linked if GitHub has verified that email. If the existing account had never verified its email, its password is cleared and its sessions ended, so whoever created it can't keep access. Members who signed up this way can set a password in Settings, or delete their account by typing DELETE.
  • Rate limits: sign-in (8 failed attempts per email and 30 attempts per IP per 15 minutes), sign-up (10 per IP per hour), reset requests (3 per email per hour), and password checks in Settings.
  • Moderation: members listed in ADMIN_EMAILS (once their email is verified) get a Reports page to dismiss reports or suspend members. Suspended members are signed out, can't sign in, and are hidden from search, feed, messages and profiles until the suspension is lifted.

Going live

Set these environment variables:

Variable
NODE_ENV=production Turns off demo data and checks the settings below at startup.
APP_URL Public https:// address, used in email links. HTTPS turns on the Secure cookie and HSTS.
RESEND_API_KEY, MAIL_FROM Email through Resend. MAIL_FROM must be on a domain verified there, e.g. Foundry <hello@yourdomain.com>.
ADMIN_EMAILS Comma-separated emails that can review reports.
DB_PATH Required. Where the SQLite file lives, on a persistent disk (e.g. /data/foundry.db on a Railway volume). Without it every deploy starts empty.
TRUST_PROXY=1 When behind exactly one proxy that appends the client IP to X-Forwarded-For (Railway does). Rate limits use the last entry.
PORT Defaults to 3000.
GITHUB_CLIENT_ID, GITHUB_CLIENT_SECRET Optional. Turns on "Continue with GitHub".

Any host that runs Node 22.13+ with a persistent disk works (for example Render, Railway or Fly.io): start command npm start, health check GET /api/health. The server refuses to start in production if the email settings are missing or APP_URL isn't HTTPS.

Cloudflare

Live at https://foundry.foundryhq.workers.dev. Files in public/ are served as Workers static assets; /api/* goes to one Durable Object (cf/worker.js) that runs this same server, with the Durable Object's built-in SQLite standing in for foundry.db (cf/sqlite.js, aliased as node:sqlite in wrangler.jsonc). Data persists across deploys.

  • npm run cf:dev: local Cloudflare runtime on http://localhost:8787, with demo data from .dev.vars (SEED_DEMO=1).
  • npm run cf:deploy: publish. NODE_ENV and APP_URL are in wrangler.jsonc; set secrets with npx wrangler secret put RESEND_API_KEY (same for MAIL_FROM, ADMIN_EMAILS, GITHUB_CLIENT_ID, GITHUB_CLIENT_SECRET).
  • Unlike npm start, the Worker does not refuse to run without email settings: verification codes then go to the Worker's logs, so only you can complete a sign-up.
  • Password hashing (scrypt) needs more CPU than the Workers free plan allows per request; use Workers Paid.

Sign in with GitHub

Register an OAuth app on GitHub: Settings → Developer settings → OAuth Apps → New OAuth App. Use your APP_URL as the Homepage URL and APP_URL + /api/auth/github/callback as the Authorization callback URL (locally: http://localhost:3000/api/auth/github/callback). Put the client ID and secret in GITHUB_CLIENT_ID and GITHUB_CLIENT_SECRET and restart the server.

Limits to know:

  • Run one server process: live events and rate limits are kept in memory (add Redis to run several).
  • Back up the SQLite file regularly (for example with Litestream).

About

A network where founders and people ready to join a founding team find each other by skills, connect with a note, and message once accepted.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages