The core API layer for the SylvaLens platform, built with NestJS and TypeORM.
- Spatial Queries: Optimized PostGIS routing for administrative and BD Forêt geometry.
- Microservice Proxy: Integrates with the FastAPI raster service for heavy geospatial computation.
- Authentication: JWT-based auth for user accounts and map state persistence.
- OpenAPI / Swagger: Automatically generates API contracts for frontend consumption.
- Node.js (v20+)
- pnpm
- A running PostGIS database and Raster service (use the
infrarepository's local compose stack).
Copy the .env.example file to .env:
cp .env.example .envEnsure DB_PORT=5433 if you are using the default local infra stack.
pnpm install
pnpm run start:devThe API will be available at http://localhost:4000.
Swagger documentation is available at http://localhost:4000/api/docs.
See the sylvalens/infra repository for production deployment orchestration.