fix(api): add remove otp sms and email to management api (#6721)

* fix(api): add remove otp sms and email to management api

* fix(console): remove otpsms and otpemail from user

---------

Co-authored-by: peintnermax <[email protected]>
This commit is contained in:
Livio Spring
2023-10-16 10:49:02 +03:00
committed by GitHub
co-authored by peintnermax
parent ce719a3fa4
commit cb0a0f996e
5 changed files with 147 additions and 3 deletions
+16
View File
@@ -322,8 +322,12 @@ import {
RemoveCustomLabelPolicyLogoDarkResponse,
RemoveCustomLabelPolicyLogoRequest,
RemoveCustomLabelPolicyLogoResponse,
RemoveHumanAuthFactorOTPEmailRequest,
RemoveHumanAuthFactorOTPEmailResponse,
RemoveHumanAuthFactorOTPRequest,
RemoveHumanAuthFactorOTPResponse,
RemoveHumanAuthFactorOTPSMSRequest,
RemoveHumanAuthFactorOTPSMSResponse,
RemoveHumanAuthFactorU2FRequest,
RemoveHumanAuthFactorU2FResponse,
RemoveHumanLinkedIDPRequest,
@@ -1805,6 +1809,18 @@ export class ManagementService {
return this.grpcService.mgmt.removeHumanAuthFactorU2F(req, null).then((resp) => resp.toObject());
}
public removeHumanAuthFactorOTPSMS(userId: string): Promise<RemoveHumanAuthFactorOTPSMSResponse.AsObject> {
const req = new RemoveHumanAuthFactorOTPSMSRequest();
req.setUserId(userId);
return this.grpcService.mgmt.removeHumanAuthFactorOTPSMS(req, null).then((resp) => resp.toObject());
}
public removeHumanAuthFactorOTPEmail(userId: string): Promise<RemoveHumanAuthFactorOTPEmailResponse.AsObject> {
const req = new RemoveHumanAuthFactorOTPEmailRequest();
req.setUserId(userId);
return this.grpcService.mgmt.removeHumanAuthFactorOTPEmail(req, null).then((resp) => resp.toObject());
}
public updateHumanProfile(
userId: string,
firstName?: string,