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

Method __init__

keepercommander/email_service.py:455–465  ·  view source on GitHub ↗
(self, config: EmailConfig)

Source from the content-addressed store, hash-verified

453 """
454
455 def __init__(self, config: EmailConfig):
456 super().__init__(config)
457 # Import here to avoid dependency if not using SendGrid
458 try:
459 from sendgrid import SendGridAPIClient
460 from sendgrid.helpers.mail import Mail
461 self.SendGridAPIClient = SendGridAPIClient
462 self.Mail = Mail
463 except ImportError:
464 _, error_message = check_provider_dependencies('sendgrid')
465 raise ImportError(error_message)
466
467 def send(self, to: str, subject: str, body: str, html: bool = False) -> bool:
468 """

Callers

nothing calls this directly

Calls 2

__init__Method · 0.45

Tested by

no test coverage detected