A real-time block explorer for Farcaster.
Production: casterscan.com
Casterscan now runs as one TanStack Start app (Vite + Nitro) with both UI routes and API routes in the same runtime.
Browser → TanStack Start routes + /api/* server routes → upstream services (Neynar, Snapchain, Farcaster API, Optimism RPC)
Key notes:
- No separate
apps/web+apps/apisetup anymore. - Public app routes remain the same (
/,/casts/$hash,/fids/$fid, etc.). - Public API surface is
/api/*only. - Package manager is
bun.
- Install dependencies:
bun install
- Create env file:
cp .env.example .env.local
- Set required env vars (
NEYNAR_API_KEYat minimum). - Run dev server:
bun run dev
- Build + run production output locally:
bun run buildbun run start
Required:
NEYNAR_API_KEY: Neynar API key for user/cast lookups.
Optional:
REDIS_URL: enables Redis caching.BASE_URL: canonical app URL used in metadata and frame URLs.VITE_GOOGLE_ANALYTICS_ID: Google Analytics ID.
This repo includes a nixpacks.toml configured for a non-static TanStack Start Nitro deployment:
- install:
bun install --frozen-lockfile - build:
bun run build - start:
node .output/server/index.mjs
Coolify should expose port 3000 (Nitro default when PORT is unset).
bun run dev— run TanStack Start dev server on port3000.bun run build— build client + server (Nitro output in.output/).bun run start— start Nitro server.bun run lint— run ESLint.
Questions or ideas:
