def get_saml_assertion_verifying(self, app_id, device_id, state_token, otp_token=None, url_endpoint=None, do_not_notify=False):
self.clean_error()<EOL>try:<EOL><INDENT>if url_endpoint:<EOL><INDENT>url = url_endpoint<EOL><DEDENT>else:<EOL><INDENT>url = self.get_url(Constants.GET_SAML_VERIFY_FACTOR)<EOL><DEDENT>data = {<EOL>'<STR_LIT>': app_id,<EOL>'<STR_LIT>': str(device_id),<EOL>'<STR_LIT>': state_token,<EOL>'<STR_LIT>': do_not_notify<EOL>}<EOL>if otp_token:<EOL><INDENT>data['<STR_LIT>'] = otp_token<EOL><DEDENT>response = self.execute_call('<STR_LIT>', url, json=data)<EOL>if response.status_code == <NUM_LIT:200>:<EOL><INDENT>return self.handle_saml_endpoint_response(response)<EOL><DEDENT>else:<EOL><INDENT>self.error = str(response.status_code)<EOL>self.error_description = self.extract_error_message_from_response(response)<EOL><DEDENT><DEDENT>except Exception as e:<EOL><INDENT>self.error = <NUM_LIT><EOL>self.error_description = e.args[<NUM_LIT:0>]<EOL><DEDENT>
Verify a one-time password (OTP) value provided for a second factor when multi-factor authentication (MFA) is required for SAML authentication.

:param app_id: App ID of the app for which you want to generate a SAML token
:type app_id: integer

:param devide_id: Provide the MFA device_id you are submitting for verification.
:type subdomain: integer

:param state_token: Provide the state_token associated with the MFA device_id you are submitting for verification.
:type state_token: string

:param otp_token: Provide the OTP value for the MFA factor you are submitting for verification.
:type otp_token: string

:param url_endpoint: Specify an url where return the response.
:type url_endpoint: string

:param do_not_notify: When verifying MFA via Protect Push, set this to true to stop additional push notifications being sent to the OneLogin Protect device
:type do_not_notify: bool

Returns a SAMLEndpointResponse object with an encoded SAMLResponse
:return: true if success
:rtype: SAMLEndpointResponse

See https://developers.onelogin.com/api-docs/1/saml-assertions/verify-factor Verify Factor documentation