mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-11-27 02:44:55 +00:00
Add activation code endpoint
This commit is contained in:
@ -8,6 +8,7 @@ import { PermissionsGuard } from 'src/guards/permissions.guard';
|
||||
import { Permissions } from 'src/decorators/permissions.decorator';
|
||||
import { JwtAuthGuard } from '@app/common/guards/jwt.auth.guard';
|
||||
import { CheckEmailDto } from '../dtos/check-email.dto';
|
||||
import { ActivateCodeDto } from '../dtos/active-code.dto';
|
||||
|
||||
@ApiTags('Invite User Module')
|
||||
@Controller({
|
||||
@ -51,4 +52,19 @@ export class InviteUserController {
|
||||
addUserInvitationDto,
|
||||
);
|
||||
}
|
||||
@ApiBearerAuth()
|
||||
@UseGuards(JwtAuthGuard)
|
||||
@Post('activation')
|
||||
@ApiOperation({
|
||||
summary: ControllerRoute.INVITE_USER.ACTIONS.ACTIVATION_CODE_SUMMARY,
|
||||
description:
|
||||
ControllerRoute.INVITE_USER.ACTIONS.ACTIVATION_CODE_DESCRIPTION,
|
||||
})
|
||||
async activationCodeController(
|
||||
@Body() activateCodeDto: ActivateCodeDto,
|
||||
): Promise<BaseResponseDto> {
|
||||
return await this.inviteUserService.activationCodeController(
|
||||
activateCodeDto,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user