Sending email from your App
What your App can send
Your App can email its own users — a welcome note when somebody signs up, a receipt after a payment, a daily digest, a notification when a new record is saved. You write the email once, and you say when it goes out. Neither step involves code.
Open your App in the editor, choose the Equip tab, then Messages. For email, it has four parts:
- Email — the account your App sends through.
- Emails — the emails your App can send.
- Automatic — the rules that send them by themselves.
- Sent — everything that went out.
The same page also holds Push, Texts and Slack, the other ways your App reaches people.
Messages belong to your published App. Until your first publish its lists are empty, and pressing an add button or a Settings icon opens Publish first, which takes you to Publish on the Manage tab. Your emails and rules are saved with your Draft, and reach your Live App when you publish.
Connect a sending account first
Email goes out through an account you connect. Until you connect one, nothing is sent — a send says so rather than failing quietly later.
In Equip › Messages, select the Settings icon on Email. The window has one part per kind of account, each saying whether it is connected:
- Gmail and Outlook — select Connect and sign in to the account in the window that opens. Reconnect signs in again; Disconnect takes the account off this App.
- SMTP (any mailbox) — fill in the Host, Port, Username and Password, and optionally From, then select Connect. When you come back later, the settings you saved are filled in; only the password has to be typed again, because it is never shown once saved. Update saves a change.
- SendGrid — paste your SendGrid key as the Key and select Connect.
Once one is connected, Email on the Messages page reads Connected with the service and the account it sends from. Connecting a second account of a kind you already have asks first, because an App holds one account per service.
What you connect here is kept in your MotherFluxer account's vault, Settings › Account › Connections & Keys, not in the App. A Gmail or Outlook account is one entry there however many of your Apps send through it: signing in to it from another App uses the same entry, and reconnecting it once reconnects every App that sends through it. Disconnect takes the account off this App only — it stays in your vault for your other Apps, and only removing it there deletes it.
Connecting and disconnecting are the owner's. A collaborator sees which account is connected, and nothing to press.
The one kind of email that needs no connected account
There is a single exception, and it only reaches the person already signed in to your App: a confirmation, a receipt or a reminder sent to that visitor's own verified address. It appears as User email in the Email window in Equip › Messages, reading On or Off. There is nothing to connect: it turns on by itself once your App saves data.
It is deliberately narrow. Your App cannot use it to email anyone else, so nobody can turn a published App into a way of mailing strangers. Anything addressed to someone other than the signed-in visitor goes through a connected account.
If a visitor replies to one of these, the reply reaches our support inbox rather than vanishing — the address it was sent from only sends, it does not receive.
Write an email
In Equip › Messages, select New email (the + icon on Emails) and fill in:
- Name — what you call it here. A recipient never sees it.
- Id — the short name a rule uses to point at this email, in lowercase letters, numbers and dashes.
- Subject and Message — the words that go out. The message is plain text: leave a blank line between paragraphs.
- Button and Button link — optional. If you want a link in the email, this is how you add one, rather than putting a link in the message text. A button needs both.
- From name, From address and Reply to — who it appears to come from. Gmail and Outlook always send from the connected account, so they ignore these; SendGrid needs an address you have verified with them.
Select Save. Your message is painted with your App's own design system when it goes out, so your emails look like your App without you styling anything. A message your Live App sends wears the design you published with it, so a new look reaches your emails when you publish, not while you are still trying it in the Draft.
To change an email later, select its pencil icon. The trash icon deletes it, after asking first. An email a rule still sends can't be deleted — the editor says Still sent by a rule — so change or delete the rule first.
Fill in details with values
Write {{ name }} anywhere in the subject or the message and it is replaced with a real value when the email is sent. Which values exist depends on what sent it — a sign-up email can use the person's details, a receipt can use the amount paid.
Below the message, Values this email needs lists every value the email asks for, each with a box for a sample value. The Preview under it fills those samples in, so you see exactly what a recipient reads — it is painted by the same renderer that sends the real email. A value nothing fills comes out blank — never as a stray {{ name }} in somebody's inbox.
Send yourself a test
Under Send yourself a test in the email's window, type your address and select Send test. It goes through your Live App's connected account, using the sample values you typed and the email and design as you have them now, so what arrives is what your users will get once you publish.
If no account is connected, nothing is sent and the editor says so. If a value had no sample, the email still goes, and the editor names the values that came out blank.
Set it to go out automatically
A rule says which email goes out, to whom, and when. In Equip › Messages, select New rule (the + icon on Automatic) — you need at least one email first. Then fill in:
- Name and ID for the rule.
- Email — which of your emails it sends.
- When — the moment it fires:
- Record added or changed — pick the List, and whether Records that are Added or Changed send it. Deleted sends nothing.
- Sign-up — the first time a person creates an account in your App, never on later sign-ins.
- Payment — once per payment, even if the payment service tells us about it more than once.
- Schedule — on a repeating schedule you set with Repeat, Time and Time zone.
- On — whether the rule is running.
- Send to — who gets it. The choices depend on When: User (the person who signed up or paid), Owner (you), an Address you type, or A value from the record that fired it, such as its email field. Values lists what this kind of rule can use.
If the value a rule sends to comes back empty, nothing is sent rather than something being sent to the wrong place.
Each rule in Automatic shows which email it Sends and when, with a switch to turn it on or off, a pencil to edit it and a trash icon to delete it. While your App is unpublished, a rule on a schedule sends nothing and says Held until published again.
See what went out
Sent in Equip › Messages lists every message your App has sent — from your rules, your test sends, and anything your App's own code sent. Each row shows its Type, who it went To, its Subject, whether it was Sent, Not sent or Failed, its Cause, which account it went Via, which App sent it — Draft or Live — and When. Open a row to read it in full, including a failure's own reason.
The Cause says where it came from: Test, Automation (one of your rules), From the app’s code, or Sent by a visitor to themselves. Messages your App's code sent are listed on purpose: a log that only showed the emails you wrote would say nothing went out while your App was emailing all day.
Asking the AI to set it up
You can ask for the whole thing: "email new sign-ups a welcome note." The AI writes the email and the rule, and both appear in Equip › Messages exactly as if you had written them — editable, deletable, and with no separate AI-only copy anywhere.