(self, config: EmailConfig)
| 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 | """ |
nothing calls this directly
no test coverage detected