forked from Shared/esg
fixed
This commit is contained in:
13
src/main.ts
13
src/main.ts
@@ -59,7 +59,9 @@ async function bootstrap(): Promise<void> {
|
||||
}),
|
||||
);
|
||||
|
||||
const swaggerConfig = new DocumentBuilder()
|
||||
const baseUrlProd = process.env.BASE_URL_PROD;
|
||||
|
||||
const documentBuilder = new DocumentBuilder()
|
||||
.setTitle('External Services Gateway')
|
||||
.setDescription(
|
||||
'Unified gateway for external inquiry providers with JWT authentication, RBAC, ' +
|
||||
@@ -67,8 +69,13 @@ async function bootstrap(): Promise<void> {
|
||||
)
|
||||
.setVersion('1.0')
|
||||
.addServer("http://localhost:8085")
|
||||
.addServer("https://apex.mic.co.ir/esg/api")
|
||||
.addServer(process.env.BASE_URL_PROD)
|
||||
.addServer("https://apex.mic.co.ir/esg/api");
|
||||
|
||||
if (baseUrlProd) {
|
||||
documentBuilder.addServer(baseUrlProd);
|
||||
}
|
||||
|
||||
const swaggerConfig = documentBuilder
|
||||
.addBearerAuth(
|
||||
{ type: 'http', scheme: 'bearer', bearerFormat: 'JWT', in: 'header' },
|
||||
'bearer',
|
||||
|
||||
Reference in New Issue
Block a user