SMTP Send
SMTP Send
Section titled “SMTP Send”Type: smtp-send · Package: SMTP / IMAP Email Activities v1.0.0
Sends an email through an SMTP server, without needing Outlook installed. Supports multiple recipients, copy (CC) and blind copy (BCC), body in text or HTML, and attachments. It is the activity to send notifications, reports and confirmations from a bot, also in unattended execution.
How it works
Section titled “How it works”It connects to the SMTP server with the credentials you give it and sends the email. The data for connection (host, port, username, password, security) are those of the sending server. The recipients (to, cc, bcc) can be text or a list.
Required parameters
Section titled “Required parameters”| Parameter | Editor | Description |
|---|---|---|
host | text | Servidor SMTP (e.g. smtp.gmail.com). |
username | text | User (usually your full email). |
password | credencial | Password or App Password. Use = credential(...). |
to | text | Recipient(s): a text or a list. |
subject | text | Asunto. |
body | text | Email body. |
Optional parameters
Section titled “Optional parameters”| Parameter | Editor | Description |
|---|---|---|
port | number | Puerto SMTP. Por defecto 587. |
from | text | Sender address. By default, username. |
replyTo | text | Reply address (Reply-To). |
isHtml | boolean | The body is HTML. By default false. |
cc | text | Copia: texto o list. |
bcc | text | Copia oculta: texto o list. |
attachments | text | Path(s) of files to attach: text or list. |
security | list | Cifrado: auto (def.) · none · ssl · starttls. |
Example
Section titled “Example”Send an attached invoice using secure credentials:
SMTP Send host = "smtp.gmail.com" username = = credential("correo-bot")["user"] password = = credential("correo-bot").ToPlainText() to = = cliente.correo subject = = "Factura " + numeroFactura body = "Adjuntamos su factura. Gracias por su compra." attachments = = arr("C:/facturas/" + numeroFactura + ".pdf")Related activities
Section titled “Related activities”- IMAP Read — read incoming emails.
- Outlook Send Email — alternative via Outlook client.