Skip to main content
skill CX Codex

lifecycle-messaging — Claude Code skill for email and SMS

This skill guides the design of email and SMS messaging, covering consent, delivery, and the split between transactional and marketing messages. Use it when adding a messaging feature or choosing a provider.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add avelikiy/great_cto --skill lifecycle-messaging -a claude-code
Open on GitHub

What lifecycle-messaging does

The skill provides a framework for choosing a provider, setting up SPF, DKIM, and DMARC, recording consent, and handling opt-outs. It separates transactional messages from marketing sends, which have different consent rules and sending identities. Email options include Postmark, Resend, and SendGrid; SMS options include Twilio and Telnyx.

When applied, the skill proposes a Messaging section in docs/integrations/INTEGRATE-{slug}.md. The section records channels, sending domains, consent, quiet hours, suppression, and the idempotency key. For US application-to-person SMS, A2P 10DLC registration is required before sending. Quiet hours use the recipient’s local time, not the server’s.

What it helps with

  • separate transactional messages from marketing sends
  • choose an email or SMS provider
  • plan SPF, DKIM, and DMARC for a sending domain
  • check consent and suppress opted-out recipients before sending
  • document messaging channels in an integration contract

Example prompts for the agent

  • Design booking reminders and classify each message as transactional or marketing.
  • Plan an email-provider integration with SPF, DKIM, and DMARC.
  • Review consent, STOP handling, and quiet hours for US marketing SMS.

How to install lifecycle-messaging

1Skills CLI (Vercel)

npx skills add avelikiy/great_cto --skill lifecycle-messaging -a claude-code

2Manually: put the files in place

~/.claude/skills/lifecycle-messaging/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/lifecycle-messaging/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about lifecycle-messaging

How do I install lifecycle-messaging in Claude Code?

Run npx skills add avelikiy/great_cto --skill lifecycle-messaging -a claude-code. The skill file is at ~/.claude/skills/lifecycle-messaging/SKILL.md.

What does lifecycle-messaging do?

It guides email and SMS integrations, including provider choice, domain authentication, consent, and suppression. It also distinguishes transactional messages from marketing sends.

Does lifecycle-messaging cover US SMS registration?

Yes. It requires A2P 10DLC brand and campaign registration before sending US application-to-person SMS. It also covers automatic handling of STOP, UNSTOP, and HELP.

Source text

SKILL.md · MIT
---
name: lifecycle-messaging
description: Email/SMS lifecycle and deliverability framework for SMB Product-Builder products that send transactional or lifecycle messages (booking reminders, CRM sequences, receipts, win-back). Codifies provider selection (Resend/Postmark/Twilio/SendGrid), domain auth (SPF/DKIM/DMARC), consent and compliance (TCPA, CAN-SPAM, CASL, quiet hours, double opt-in), suppression-list discipline, and the transactional-vs-marketing split. Applied by integrations-engineer and senior-dev whenever a feature sends messages — so deliverability and consent are designed in, not bolted on after the first spam complaint.
when_to_use: |
  Apply when a feature sends email or SMS:
  - integrations-engineer designing a Twilio / email-provider integration
  - senior-dev implementing booking reminders, CRM sequences, receipts, or win-back
  - architect deciding the messaging provider + domain-auth setup for a crm/booking product
  Do NOT apply for purely in-app notifications with no email/SMS leg.
effort: medium
allowed-tools: Read, Write, Grep, Glob, WebFetch
paths:
  - "docs/integrations/**"
  - "docs/architecture/**"
---

# Lifecycle messaging — deliverable, consented, compliant

Messages that don't arrive (poor deliverability) or that arrive without consent (TCPA/
CAN-SPAM violations) are both fatal for an SMB product. This skill makes both correct by
construction. **Design the consent + deliverability posture before the first send.**

## 1. Transactional vs marketing — split them

Decide per message which bucket it is; they have different rules and should use different
sending identities (often different subdomains / providers):

| | Transactional | Marketing / lifecycle |
|---|---|---|
| Examples | receipt, booking confirm/reminder, password reset | win-back, promo, newsletter, nurture step |
| Consent | implied by the transaction | **explicit opt-in required** |
| Unsubscribe | not required (but honor STOP) | **required**, one-click, honored fast |
| Sending domain | `txn.` subdomain | `mail.`/`news.` subdomain |

Never send marketing content on the transactional channel "because it delivers better" —
that's how the transactional domain gets burned.

## 2. Provider selection (pick one, justify it)

- **Email** — Postmark (best transactional deliverability, strict on marketing), Resend
  (DX-first, good default), SendGrid (scale). Default: **Resend for transactional**,
  add a marketing-grade ESP only when lifecycle volume justifies it.
- **SMS** — Twilio (messaging service + sender pool), or Telnyx. Use a Messaging Service,
  not a single number, for scale + failover. A2P 10DLC registration is **required** for
  US application-to-person SMS — register the brand/campaign before sending.

## 3. Domain authentication (non-negotiable for email)

- **SPF** — sender IP authorized in DNS.
- **DKIM** — provider signing key published; messages signed.
- **DMARC** — start `p=none` with rua reporting, ramp to `p=quarantine`→`p=reject` once
  aligned. Without DMARC alignment, lifecycle mail lands in spam.
- Warm up a new sending domain gradually; never blast from a cold domain.

## 4. Consent + compliance (US-first)

- **CAN-SPAM (email)** — valid physical postal address, accurate From/Subject, working
  one-click unsubscribe honored within 10 days.
- **TCPA (SMS/voice)** — prior express written consent for marketing SMS; honor STOP/UNSTOP/
  HELP keywords automatically; respect **quiet hours** (no marketing 9pm–8am recipient
  local time). Keep proof of consent (timestamp, source).
- **CASL** (if CA recipients) — express opt-in + identification + unsubscribe.
- **Double opt-in** for marketing lists where feasible — protects deliverability and proves
  consent.

## 5. Suppression discipline (the deliverability lifeline)

Maintain a single **suppression list** the sender checks before every send:
- hard bounces → suppress permanently
- spam complaints (FBL) → suppress + investigate
- unsubscribes / STOP → suppress for that channel immediately
- never re-import a suppressed address from a migration without re-consent

A send that ignores suppression is the fastest path to a blocklist.

## 6. Reliability patterns

- Idempotent sends keyed on the domain event (a reminder for booking X sends once, even on
  retry) — coordinate the key with integrations-engineer.
- Status-callback / webhook reconciliation: record delivered/bounced/failed; surface
  failures, don't swallow them.
- Rate-limit + queue lifecycle sends; never loop-send.
- Quiet-hours + timezone are computed from the **recipient's** locale, not the server's.

## Output

When applied, contribute a **Messaging** section to the integration contract
(`docs/integrations/INTEGRATE-{slug}.md`):

```
## Messaging
- channels: email <provider> / sms <provider>
- identities: txn = <subdomain>, marketing = <subdomain/ESP>
- domain auth: SPF/DKIM/DMARC plan = <state>
- consent: <implied/explicit per message type>; STOP/HELP = handled
- quiet hours: <recipient-local window>; 10DLC: <registered?>
- suppression: <store> checked pre-send
- idempotency key: <derivation>
```

© avelikiy · MIT · avelikiy/great_cto

Similar skills

All skills for Backend and APIs →

From the same set26

pre-mortem This skill works backward from a failed project to find specific causes and add safeguards to the plan. Run it before building high-impact or hard-to-reverse changes. CX Codex +1 ★ 107repo stars pm-planning Turns an approved architecture document into a Beads task list with dependencies, time-boxes and acceptance criteria. Built for the pm agent handing work to senior-dev. CX Codex +1 ★ 107repo stars opportunity-solution-tree This skill maps a measurable product outcome to customer needs, candidate solutions, and experiments. Use it when a team is deciding which problem to pursue next. CX Codex +1 ★ 107repo stars observability-baseline Bakes error capture in Sentry, request-id structured logs and /healthz plus /readyz endpoints into a freshly generated service. Useful when the app is still being scaffolded and you don't want the first prod failure to go unseen. CX Codex +1 ★ 107repo stars great_cto The skill turns Claude into a pipeline orchestrator: you describe the task in plain words and the right agents run on their own. Useful when one agent drives a whole project. CX Codex +1 ★ 107repo stars done-blocked Enforces a strict terminal reporting contract for agents: exactly DONE or BLOCKED with structured evidence. Stops vague handoffs in multi-agent pipelines. CX Codex +1 ★ 107repo stars discovery This skill prompts an agent to check project context and constraints before making architecture, audit, or security-plan recommendations. Use it when the request leaves key details open. CX Codex +1 ★ 107repo stars deploy-landed The skill checks that the revision being served is the commit you meant, that its env reached the running process, and that the product actually works. Useful after any deploy or restart. CX Codex +1 ★ 107repo stars

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor