From 52b404ded80807ca95f093fdd7012ebcbf976c8f Mon Sep 17 00:00:00 2001 From: Shiwon Park Date: Mon, 2 Sep 2024 20:37:38 +0900 Subject: [PATCH] update: swagger docu --- src/client/client.controller.ts | 4 ++-- src/main.ts | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/client/client.controller.ts b/src/client/client.controller.ts index 93756a8..33611c4 100644 --- a/src/client/client.controller.ts +++ b/src/client/client.controller.ts @@ -83,7 +83,7 @@ export class ClientController { @ApiUnauthorizedResponse() @ApiForbiddenResponse() @ApiInternalServerErrorResponse() - @ApiBasicAuth() + @ApiBasicAuth('client') @Post('authority') @UseGuards(ClientGuard) async addAuthority( @@ -101,7 +101,7 @@ export class ClientController { @ApiUnauthorizedResponse() @ApiForbiddenResponse() @ApiInternalServerErrorResponse() - @ApiBasicAuth() + @ApiBasicAuth('client') @Delete('authority') @UseGuards(ClientGuard) async removeAuthority( diff --git a/src/main.ts b/src/main.ts index 49aee6f..80db8ff 100644 --- a/src/main.ts +++ b/src/main.ts @@ -12,6 +12,12 @@ async function bootstrap() { .setTitle('Groups API') .setDescription('The Groups API') .setVersion('1.0') + .addBasicAuth( + { + type: 'http', + }, + 'client', + ) .addOAuth2( { type: 'oauth2',