Elysia Core Backend
Overview
Create a minimal, production-ready Elysia backend skeleton with auth, database, MCP, and security defaults. Follow the official generator workflow and then apply the standardized file structure and contents.
Workflow
- Confirm the target location and whether this is a brand-new scaffold or an existing Elysia server. If files already exist, avoid clobbering without explicit user approval.
- Use the official Elysia generator with latest templates and Bun installs:
bun create elysia@latest <target>. Do not hand-roll the project or keep stale generated dependencies. - Apply the exact folder structure, file contents, and package scripts from the reference guide.
- Add required environment variables to
.envand call out secrets that must be user-provided. - If the user requests, run migration commands and start the dev server.
- Verify security defaults: CORS allowlist, CSRF protection on non-auth routes, security headers. Ensure MCP is wired via
elysia-mcpplugin and not a rawMcpServer.
References
- Read
references/elysia-core-backend.mdfor the full scaffold steps, file contents, and required notes.