mirror of
https://github.com/dadosfera/maestro.git
synced 2026-10-24 07:49:08 +00:00
FEAT: create user from identity provider
This commit is contained in:
@@ -421,21 +421,4 @@ export class AuthController {
|
||||
return this.authClient.resetUsers(body.users, metadata);
|
||||
}
|
||||
|
||||
@Get('/idp/:name/callback')
|
||||
@HttpCode(HttpStatus.OK)
|
||||
async callbackIdp(@Param('name') idpName: string, @Req() req: Request) {
|
||||
this.logger.info('/auth/idp/:name/callback');
|
||||
|
||||
const { params } = req;
|
||||
|
||||
if (!params || !params.code) {
|
||||
this.logger.error('No code received from IDP');
|
||||
throw new Error(ErrorCodes.IDENTITY_PROVIDER.INVALID_RESPONSE);
|
||||
}
|
||||
|
||||
return {
|
||||
ok: true
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user