tool
EmailTool
Bases: BaseTool
Tool for working with email.
Attributes:
Name | Type | Description |
---|---|---|
username |
Optional[str]
|
Username/email address used to send email via the SMTP protocol and retrieve email via the IMAP protocol. Example: bender@futurama.com. |
password |
Optional[str]
|
Password used to send email via the SMTP protocol and retrieve email via the IMAP protocol. If using gmail, this would be an App Password. |
email_max_retrieve_count |
Optional[int]
|
Used to limit the number of messages retrieved during any given activities. |
smtp_host |
Optional[str]
|
Hostname or url of the SMTP server. Example: smtp.gmail.com. Required when using the |
smtp_port |
Optional[int]
|
Port of the SMTP server. Example: 465. Required when using the |
smtp_use_ssl |
bool
|
Whether to use SSL when sending email via the SMTP protocol. |
smtp_user |
Optional[str]
|
Username/email address used to send email via the SMTP protocol. Overrides username for SMTP only. Required when using the |
smtp_password |
Optional[str]
|
Password to send email via the SMTP protocol. Overrides password for SMTP only. Required when using the |
imap_url |
Optional[str]
|
Hostname or url of the IMAP server. Example: imap.gmail.com. Required when using the |
imap_user |
Optional[str]
|
Username/email address used to retrieve email via the IMAP protocol. Overrides username for IMAP only. Required when using the |
imap_password |
Optional[str]
|
Password to retrieve email via the IMAP protocol. Overrides password for IMAP only. Required when using the |
mailboxes |
dict[str, Optional[str]]
|
Descriptions of mailboxes available for retrieving email via the IMAP protocol. Required when using the |
email_loader |
EmailLoader
|
Instance of |
Source code in griptape/tools/email/tool.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 |
|