Prepare Your Lumail Account for Lumail 2.0.0
An operational guide for AI agents migrating marketing email to Lumail Workflows with clear branding and a reason for sending.
This guide gives an AI agent the rules and sequence for preparing a Lumail account for Lumail 2.0.0. The central change is simple: marketing email belongs in Workflows, not in the transactional email API or SMTP.
Read https://lumail.io/docs/ai-integration/prepare-account-2-0.md, then call get_skill with type workflow before changing anything. Audit the current Lumail account and the connected application. Classify every email as transactional or marketing. Keep immediate user-requested messages transactional. Move newsletters, nurture sequences, product announcements, promotions, and other marketing communication into Lumail Workflow drafts. Every marketing EMAIL step must include visible branding, a specific reason-for-sending sentence, the organization address, and an unsubscribe link. Reuse existing snippets when possible. Do not publish, activate, enroll subscribers, schedule, or send without my explicit approval. Return the audit, the drafts created or changed, and everything still requiring approval.Non-negotiable routing rule
Classify the purpose of the message before choosing a Lumail API.
| Message | Correct Lumail path | Examples |
|---|---|---|
| Transactional | Transactional API, SDK lumail.emails.send, or SMTP | OTP, password reset, receipt, requested export, security alert |
| Marketing | Lumail Workflow with one or more EMAIL steps | Welcome nurture, newsletter, educational sequence, product announcement, promotion |
Do not use the transactional endpoint as a shortcut for marketing, even when the application already has the recipient's email address. Adding a delay, a promotional subject, or an unsubscribe link does not turn a transactional send into a compliant marketing workflow.
A message is transactional only when it is expected as the direct result of a recipient action and its primary purpose is to complete or confirm that action. If the primary purpose is engagement, education, retention, or sales, route it through a Workflow.
What a prepared account contains
Before the agent reports the migration as ready, the account should have:
- A verified sender for every Workflow email.
- A reusable branded header or footer snippet.
- A specific reason-for-sending line in every marketing email.
- A physical address and unsubscribe link in every marketing email.
- Workflow drafts for every marketing lifecycle.
- A documented trigger for each workflow, such as subscriber created, tag added, event received, or manual enrollment.
- Test evidence for every email and graph path.
Drafts are preparation. Publication and activation are separate, approval-gated actions.
Phase 1: audit without sending
Start read-only. Do not create a workflow until the current state and the connected application's sends are understood.
- Call
get_skill({ type: "docs", page: "ai-integration/prepare-account-2-0" }). - Call
get_skill({ type: "workflow" })and use the returned live schema. - Read
get_organization_settings,get_email_senders,get_writing_style, andget_email_snippets. - List existing Workflows and read each relevant workflow with
get_workflow. - Search the connected application for transactional API, SDK, and SMTP sends.
- Produce an inventory with one row per email: trigger, purpose, audience, current path, required path, and migration action.
Use this decision table during the audit:
| Current email | Classification | Action |
|---|---|---|
| Sign-in code sent after a login request | Transactional | Keep on transactional send |
| Receipt sent immediately after payment | Transactional | Keep on transactional send |
| Welcome education after signup | Marketing | Add subscriber/tag, then enter a Workflow |
| Trial tips over several days | Marketing | Build a timed Workflow |
| Product launch announcement | Marketing | Use a Workflow and an eligible subscribed audience |
| “We miss you” re-engagement | Marketing | Use a Workflow with clear exit conditions |
If the purpose is mixed, treat the message as marketing or split it into one necessary transactional message and a separate marketing workflow.
Phase 2: create reusable email identity
Read existing snippets before creating another one. Prefer one shared header and one shared compliance footer so all Workflow emails stay consistent.
Clear branding
Every marketing email must make the sender identifiable in a few seconds. Include at least one visible identifier:
- Organization or product name
- Recognizable logo with useful alt text
- Website domain displayed as text
Put branding near the top when possible. A compact footer is acceptable for personal, text-first email, but the identity must remain readable. Follow the complete Clear Branding guide.
Clear reason for sending
Every marketing email must explain the real action that placed the subscriber in this audience:
You're receiving this email because you subscribed to the Acme newsletter at acme.com.
For several legitimate sources, list the real possibilities:
You're receiving this email because you subscribed through acme.com, completed one of our quizzes, or joined an Acme program.
Do not use circular wording such as “because you subscribed to my emails” or “for marketing purposes.” Follow the complete Reason for Sending guide.
Required marketing footer
The reusable footer must contain all three:
- The reason-for-sending sentence.
- The organization address with
{{org-adresse}}. - A visible unsubscribe link using
{{unsubscribeUrl}}.
Use get_email_snippets and get_email_snippet before create_email_snippet or update_email_snippet. Updating a shared snippet changes every email that uses it, so report the affected snippets and Workflows before saving.
Phase 3: move marketing into Workflow drafts
For each marketing lifecycle:
- Define the entry event and eligible subscriber status.
- Reuse an existing draft or call
create_workflowwith a descriptive name. - Read the new or existing workflow with
get_workflowand keep its exactupdatedAtvalue. - Build the complete graph with triggers, waits,
EMAILsteps, branches, goals, exits, and edges. - Put complete inline email content on each
EMAILstep, including branding and the required footer. - Call
configure_workflow_draftonce with the complete graph andexpectedUpdatedAt. - Read the workflow again and verify the saved graph and every owned email.
configure_workflow_draft is the safe preparation tool: it validates and saves the draft atomically, but it never publishes, activates, enrolls, or sends.
Do not call create_campaign for a Workflow email. Each EMAIL step owns its internal email content.
Phase 4: connect the application
The application should provide subscriber state and events, not send the marketing email itself.
Typical integration flow:
User action in the app
↓
Create or update the Lumail subscriber
↓
Add the trigger tag or track the expected event
↓
Lumail Workflow enrolls the eligible subscriber
↓
Workflow waits, branches, sends, and exitsPublic signups should respect double opt-in. With double opt-in enabled, subscriber-created and tag-added workflows wait until the subscriber confirms. Never put skipDoubleOptIn: true on a public or client-side form.
Keep Add transactional recipients to the marketing list off unless the organization has a valid marketing-consent reason. Receiving an OTP or receipt does not make someone a marketing subscriber.
Phase 5: test and stop for approval
Before requesting publication:
- Validate every graph path and branch.
- Run a dry test with a test subscriber.
- Send test copies of every Workflow email only to the approved test address.
- Check mobile rendering, links, variables, dark mode, sender, branding, reason for sending, address, and unsubscribe.
- Confirm Branding is
5/5and Reason for sending is10/10in Content checks. - Read the Workflow again and report its status as
DRAFT.
Then stop. publish_workflow, activation, enrollment, scheduling, and real sending require explicit human approval. Never infer approval from “prepare,” “migrate,” “configure,” or “make it ready.”
Agent completion report
Return a concise report with:
- Transactional sends kept in the application
- Marketing sends removed or queued for removal from transactional code
- Workflow drafts created or updated
- Trigger and audience for each Workflow
- Shared snippets created or reused
- Branding and reason-for-sending evidence for every email
- Test results and unresolved validation errors
- Exact actions still awaiting approval
Do not report the account as migrated if marketing remains on lumail.emails.send, /api/v2/emails, /api/v1/emails, or SMTP.