Quickstart
Get a project on screen in under a minute.
1. Create a project
Section titled “1. Create a project”Run the scaffolder:
npx create-nestforge@latestAnswer the prompts for a project name, variant, and OAuth providers — Express + REST or Express + GraphQL — or skip them for automation:
npx create-nestforge@latest --project-name my-app --variant graphql --oauth-providers googleThe project is created in the current directory, named after the project. The
CLI copies the template, sets the package name, and creates a .env from the
example.
2. Install dependencies
Section titled “2. Install dependencies”cd my-apppnpm install3. Configure the environment
Section titled “3. Configure the environment”cp .env.example .env4. Run with Docker (recommended)
Section titled “4. Run with Docker (recommended)”The compose.yaml brings up the whole stack — the app, Redis, Postgres, and a
Traefik reverse proxy — with nothing else installed locally:
docker compose up --buildBy default the app builds from Dockerfile.dev and runs in watch mode
(start:dev). It is served through Traefik at http://localhost.
For a production image, set NODE_ENV=production to build from
Dockerfile.production:
NODE_ENV=production docker compose up --build -dOnly need infrastructure, not the app? Start individual services:
docker compose up redis5. Run manually
Section titled “5. Run manually”This route requires Redis running locally:
docker run -p 6379:6379 redis:latestThen start the app:
pnpm start:devThe app runs at http://localhost:3000, with interactive API docs at
http://localhost:3000/api-docs. The page is a Scalar UI
rendered from the Swagger/OpenAPI document, so you can browse endpoints and try
requests in one place. In the GraphQL variant, Apollo Sandbox is at
http://localhost:3000/graphql.
Lint and format
Section titled “Lint and format”Run the project linter:
pnpm lintThe generated project uses oxlint for fast, focused checks and Prettier for formatting.
Next steps
Section titled “Next steps”Read the Introduction for what is inside, or head to the GitHub repository for the full API surface.