hubspot guard

This commit is contained in:
Gabriel Rosa
2022-06-20 17:09:28 -03:00
parent 8c91551cdc
commit 072a9fee8e
4 changed files with 25 additions and 10 deletions
+13
View File
@@ -6,6 +6,8 @@ import {
Param,
Patch,
Post,
Req,
UseGuards,
} from '@nestjs/common';
import { InputsService } from './inputs.service';
import { InputsClientService } from 'src/clients/inputs/client.service';
@@ -21,6 +23,7 @@ import {
TestConnectionReq,
TestConnectionRes,
} from './dtos/input.model';
import { AuthGuard } from '@nestjs/passport';
@ApiTags('inputs')
@Controller('inputs')
@@ -125,4 +128,14 @@ export class InputsController {
return response;
}
@UseGuards(AuthGuard('hubspot'))
@Get('oauth/hubspot')
async oauthHubspot(@Req() req) {
return true;
}
@Get('oauth/hubspot/callback')
async oauthHubspotCallback(@Req() req) {
return true;
}
}