Spaces:
Running
Running
Update email_agent.py
Browse files- email_agent.py +2 -2
email_agent.py
CHANGED
@@ -9,8 +9,8 @@ from agents import Agent, function_tool
|
|
9 |
def send_email(subject: str, html_body: str) -> Dict[str, str]:
|
10 |
""" Send an email with the given subject and HTML body """
|
11 |
sg = sendgrid.SendGridAPIClient(api_key=os.environ.get('SENDGRID_API_KEY'))
|
12 |
-
from_email = Email("
|
13 |
-
to_email = To("
|
14 |
content = Content("text/html", html_body)
|
15 |
mail = Mail(from_email, to_email, subject, content).get()
|
16 |
response = sg.client.mail.send.post(request_body=mail)
|
|
|
9 |
def send_email(subject: str, html_body: str) -> Dict[str, str]:
|
10 |
""" Send an email with the given subject and HTML body """
|
11 |
sg = sendgrid.SendGridAPIClient(api_key=os.environ.get('SENDGRID_API_KEY'))
|
12 |
+
from_email = Email("cz78@illinois.edu") # put your verified sender here
|
13 |
+
to_email = To("ch315868@dal.ca") # put your recipient here
|
14 |
content = Content("text/html", html_body)
|
15 |
mail = Mail(from_email, to_email, subject, content).get()
|
16 |
response = sg.client.mail.send.post(request_body=mail)
|