KSC Open API  13.1
Kaspersky Security Center API description
TotpRegistration::SaveSecretForCurrentUser ( wstring  wstrSecretId,
wstring  wstrValidationCode 
)

Set TOTP 2FA authentication for current user. If validation code does not pass verification, function throws KLSTD::STDE_NOTPERM and current user TOTP settings don't change. If validation code passes verification, secret will be used as second factor when users logs in. If user already has registered TOTP secret, it will be replaced with new one.

Parameters:
wstrSecretIdSecret ID generated by GenerateSecret
wstrValidationCodeTOTP validation code