Data & connectionsGuide

Email: providers, templates and sends

E-mail in Waiso has three parts: a provider — your own account that actually delivers the message — a template written in HTML with {{ values }}, and the Email step of a flow, which fills the template and sends it. Every send is recorded, with its status and the exact message that went out.

10 min readBefore this: Integrations, What a flow isOpen in Waiso
What you will learn
  • Turn on Email and connect a provider
  • Write a template with values, preview it and publish it
  • Send from a flow’s Email step, and from code through a flow
  • Read a template’s sends and resend one

How a send happens

Waiso does not deliver e-mail itself. It renders your template with the values of the run and hands the result to the provider you connected — over SMTP or the provider’s own API — and records the attempt. Because the provider is your account, the sender address, the deliverability and the bill are yours.

The Email step at the end of the flow fills a published template with values from the steps above it.

Email is a service of the project. Turn it on from Integrations → Add integration → Email (“Send emails from scripts and flows.”); its card then opens the Email page, where the template list sits on the left, the open template in the middle and Providers beside it.

Connect a provider

  1. Add the provider

    On the Email page, under Providers, click Add Provider and pick the service and, where there is a choice, the method.

  2. Fill its fields and confirm the variables

    Each method asks for what that service needs, with help text on where to find it. Saving lists Variables this provider creates: a provider named Transactional using an API key stores it as EMAIL_TRANSACTIONAL_API_KEY.

  3. Send a test

    Send test email asks for a Recipient email and sends through the real provider. With several providers, Set as default marks the one steps use when they do not pick one.

ProviderMethodsSecret variable
Custom SMTPUsername / Password (host, port 587 · 465 · 25)…_PASSWORD
GmailApp Password (SMTP) · Gmail REST API (an access token)…_PASSWORD or the token
Outlook / Microsoft 365App Password (SMTP) · Microsoft Graph API (an access token)…_PASSWORD or the token
SendGrid · ResendAPI Key…_API_KEY
Mailgun · BrevoAPI Key · SMTP…_API_KEY or …_PASSWORD
Amazon SESSMTP · AWS Access Key (SES API)…_PASSWORD, or …_ACCESS_KEY_ID + …_SECRET_ACCESS_KEY
PostmarkServer Token…_SERVER_TOKEN
Zoho MailApp Password…_PASSWORD

Write a template

New Template asks how to start — Use example (a filled-in sample) or Start from scratch — and the System Template Library offers ready ones to Import. The editor has HTML and CSS tabs, a Subject line and a live Preview you can switch between Desktop, Tablet and Mobile.

Values in a template

Templates use Jinja syntax. {{ name }} inserts a value, {{ user.name }} a field of one, {{ items[0] }} an element of a list; {% if %} and {% for %} decide and repeat. Every value the HTML or the subject uses appears under Template variables by itself, with a box to try it in the preview.

Expected outputThe HTML tab of a template with three values
<h1>Welcome, {{ name }}!</h1>
<p>Your workspace <strong>{{ workspace }}</strong> is ready.</p>
{% if trial_days %}
  <p>Your trial ends in {{ trial_days }} days.</p>
{% endif %}

Save, then publish

Save keeps your work; Publish makes it the version flows send. A badge says where a template stands — Never published, Unpublished changes or Published — and Send test always uses what is open in the editor. The History tab lists every save, publish and restore.

Send from a flow

Add a Send email step (the Email step) to a flow and fill its panel:

  • Connection — a provider, or Default connection.
  • Template — Choose a template. The flow sends its published version; the panel warns when it was never published or has unpublished changes.
  • Recipients — one address, several separated by commas, or a list from an earlier step.
  • Subject — leave empty to use the template’s; it can use the template’s values.
  • Template values — one binding per value the template uses, like any step input (Bindings).
  • Attachments — a file from an earlier step, up to 10 MB in total.

Preview e-mail shows The e-mail as it will be sent; values only known at run time are listed as such. After a run, the step’s output says what went out:

Expected outputSuccessThe Email step’s output
{
  "ok": true,
  "historyId": "9b2f6c1e-4d7a-4e0b-9a61-3f2d8c5e7a10",
  "to": [
    "ana@example.com"
  ],
  "subject": "Welcome, Ana!"
}

From a script

Scripts have no network, so they do not talk to a provider themselves. To send from code, run a flow whose Email step does it — the SDK’s run_flow waits for it and returns how it ended:

welcome_new_user.py
from waiso import run_flow

def main(email: str, name: str = "Ana"):
    result = run_flow("notify/welcome", {"email": email, "name": name})
    return {"status": result.status, "flowRunId": result.flow_run_id}

With a loop over a SQL step, one flow can send one e-mail per row — the complete recipe is in SQL report by e-mail.

Sends and resend

A template’s Sends tab lists every message sent with it — tests included — with To, Subject, Provider, Status and Sent At, filtered by All, Sent, Failed or Pending. A failed send shows Error details: the provider’s own answer.

Resend opens the send dialog filled in with that e-mail’s values — nothing goes out until you press Send, so you can fix an address first.

Limits and gotchas

  • A flow sends only a published template; one never published is refused (template_not_published).
  • Deleting a template makes every flow step that sends it fail.
  • A custom SMTP host must be a public address; a private one is refused with host_not_allowed.
  • Attachments add up to 10 MB per message.