import { NestFactory } from '@nestjs/core'; import { AppModule } from './app.module'; import { FastifyAdapter, NestFastifyApplication } from '@nestjs/platform-fastify'; async function bootstrap() { const app = await NestFactory.create(AppModule, new FastifyAdapter(), { cors: true, logger: ['error', 'warn'] }); app.setGlobalPrefix('api'); await app.listen(3000, () => { console.log('Application is running on: http://localhost:3000'); }); } bootstrap();