MCPcopy Create free account
hub / github.com/Keeper-Security/Commander / send

Method send

keepercommander/email_service.py:1030–1047  ·  view source on GitHub ↗

Send email via configured provider. Args: to: Recipient email address subject: Email subject body: Email body html: True if body is HTML Returns: True if sent successfully Raises: Exception: I

(self, to: str, subject: str, body: str, html: bool = False)

Source from the content-addressed store, hash-verified

1028 self.provider = provider_class(config)
1029
1030 def send(self, to: str, subject: str, body: str, html: bool = False) -> bool:
1031 """
1032 Send email via configured provider.
1033
1034 Args:
1035 to: Recipient email address
1036 subject: Email subject
1037 body: Email body
1038 html: True if body is HTML
1039
1040 Returns:
1041 True if sent successfully
1042
1043 Raises:
1044 Exception: If send fails
1045 """
1046 logging.info(f"[EMAIL] Sending email to {to} via {self.config.provider}")
1047 return self.provider.send(to, subject, body, html)
1048
1049 def test_connection(self) -> bool:
1050 """

Callers 8

executeMethod · 0.95
_send_emailMethod · 0.95
test_email_configFunction · 0.95
sendMethod · 0.45
sendMethod · 0.45

Calls 1

infoMethod · 0.45

Tested by 2

test_email_configFunction · 0.76