A NestJS-based “codeless backend” platform that lets users:
- Create multiple Projects
- Expose a single dynamic GraphQL endpoint per project (
/api/:projectId/graphql)- GET returns
{ message: "Hello World from project <id>" } - POST runs the project-scoped GraphQL API
- GET returns
- Auto-generate dynamic REST CRUD endpoints per entity (
/api/:projectId/:entity) - Pick and connect a cloud database (MongoDB, Postgres, MySQL) via a single URI
- Define Entities & Fields (Resources & FieldDefs)—the system will
CREATE TABLE/CREATE COLLECTION
- Multi-tenant routing via
ProjectMiddleware - GraphQL (code-first) for schema management & admin APIs
- REST for user-friendly CRUD on any defined “collection”
- Dynamic provisioning: spins up schemas on user’s cloud DB
- JWT authentication + role-based guards
src/
├── auth/ # JWT Auth, guards, strategies
├── project/
│ ├── dto/ # GraphQL input types
│ ├── entities/ # Project, ProjectDetails, Resource, FieldDef
│ ├── graphql/ # Resolvers (project, dynamic)
│ ├── services/ # Dynamic REST, Schema provisioning
│ ├── rest/ # Dynamic REST controller
│ ├── project.middleware.ts# Middleware for dynamic routing
│ └── project.module.ts
├── user/ # User module & service
└── app.module.ts
git clone https://github.com/your-repo/flowforge-backend.git
cd flowforge-backend
npm installPORT=4000
JWT_SECRET=your_jwt_secret
# Optional base URL (for live URLs)
BASE_URL=http://localhost:4000Or set synchronize: true in ormconfig for development.
npm run typeorm migration:runnpm run start:dev- JWT-based with optional role checks.
- Protected routes use
@UseGuards(GqlJwtAuthGuard)or REST middleware.
-
Dynamic:
/api/:projectId/graphqlGET: returns{ message: "Hello World from project <id>" }POST: executes project-specific GraphQL queries
-
Example:
query { projects { id name details { liveUrl } } }
-
Dynamic:
/api/:projectId/:entityGET: list recordsPOST: create recordPUT: update recordDELETE: delete record
-
GraphQL mutation:
mutation { setDatabaseConfig( projectId: "your-project-id", config: { dbType: POSTGRES, connectionUri: "postgresql://user:pass@neon.tech/dbname" } ) { details { dbType connectionUri } } }
-
Create Project – via GraphQL or REST.
-
Configure Database – connect your cloud DB with a single connection URI.
-
Define Schema – create
ResourceandFieldDefrecords. -
Provisioning – backend generates tables/collections automatically.
-
Query – GraphQL & REST APIs work out of the box.
-
Dynamic Server – Each project gets a live URL, e.g.:
http://localhost:4000/api/<projectId>/graphql http://localhost:4000/api/<projectId>/<entity>
- NestJS – scalable Node.js framework
- TypeORM – flexible ORM supporting multiple databases
- GraphQL – code-first, with Apollo Server
- MongoDB / Postgres / MySQL – cloud DB support (Atlas, Neon, PlanetScale)
- JWT Auth & Role-Based Access – secure multi-tenant support
- Schema Designer UI – drag-and-drop entity & field definitions.
- Real-time Collaboration – live updates with WebSockets.
- Analytics & Monitoring – API usage metrics per project.
- Custom Domains & Webhooks – advanced developer tools.
- Use GraphQL Playground to explore:
http://localhost:4000/api/<projectId>/graphql - Check REST CRUD with Postman or browser:
http://localhost:4000/api/<projectId>/<entity> - Logs & errors appear in the terminal—watch for schema errors during provisioning.