From bb5e577e56fbfabf14f3318105cbabdd8942bba5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=98=D0=B2=D0=B0=D0=BD?= Date: Mon, 8 Dec 2025 22:16:51 +0300 Subject: [PATCH] fix prefix --- src/main.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main.ts b/src/main.ts index 4167657..cdba7dd 100644 --- a/src/main.ts +++ b/src/main.ts @@ -5,6 +5,8 @@ import { AppModule } from './app.module'; async function bootstrap() { const app = await NestFactory.create(AppModule); + app.setGlobalPrefix('api'); + const config = new DocumentBuilder() .setTitle('Travelmarine backend') .setDescription('Backend API for Travelmarine service') @@ -12,7 +14,7 @@ async function bootstrap() { .build(); const documentFactory = () => SwaggerModule.createDocument(app, config); - SwaggerModule.setup('api', app, documentFactory); + SwaggerModule.setup('/api', app, documentFactory); await app.listen(process.env.PORT ?? 4000); }