NewslettersCAN I VIBECODE
Klaviyo?
BUILD FIRST
- A non-sensitive or read-only version of the core experience
- A manual review step wherever correctness or trust matters
- A narrow companion tool that removes a real piece of work
LEAVE FOR LATER
- Regulated decisions, payments, or irreversible actions
- Claims of correctness, compliance, or uptime that the MVP cannot support
- Sensitive integrations until security, support, and auditability are ready
RESEARCH NOTES
What this tool actually does.
Klaviyo is a B2C CRM and AI marketing platform that combines customer data with email, SMS, mobile push, and web forms. It builds unified customer profiles from any data source, segments by attributes or past behavior, and automates cross-channel flows triggered by real-time events such as purchases, sign-ups, or product views. The email tooling includes drag-and-drop editor, pre-built templates, customizable signup forms, dynamic product recommendations, AI subject-line generation, Smart Send Time, A/B testing with winner selection, and predictive analytics for LTV, churn risk, and next order date. It advertises 350+ integrations and reputation repair for deliverability. The core workflow is visual: build a flow, define triggers and delays, send personalized campaigns or automated journeys to a segment, and attribute revenue back to the sending message.
RESEARCHED BUILD PROMPT
Give this to your coding agent.
Build a lightweight, self-hosted replacement for Klaviyo's email newsletter automation, focused on its distinctive 'flows + segments + campaigns' workflow typical of e-commerce email marketing. The app should let users: 1) Import a product catalog and customer event history (order placed, product viewed, subscribed) via CSV or a mock store integration; 2) Define reusable segments using rule conditions on profile attributes and event counts/timestamps (e.g., 'has ordered > 2 times', 'viewed product in last 7 days'); 3) Create automated flows via a drag-and-drop node graph with trigger node, delay node, condition branch, and email-send node, supporting welcome, post-purchase, and abandoned-cart journeys; 4) Compose emails with a block-based editor (text, image, button, product-recommendation block) and simple variable placeholders for customer attributes; 5) Send one-off campaigns to a segment with A/B subject-line testing and simulated best-time sending; 6) Track opens, clicks, and unsubscribes with a small dashboard per flow/campaign.
Technical direction: use Node.js + React or Python FastAPI + a React SPA; Postgres for profiles, events, segments, email templates, and outbox; Redis + BullMQ for delayed and queued flow steps; compile segment rules to SQL; render emails server-side from a JSON template schema; use Resend/Postmark for real sending and fall back to a local outbox log when no API key is set. Do not copy Klaviyo's brand or UI; use a neutral design language and rename flows 'Automation Paths' to avoid trademark.
Explicitly out of scope: SMS, mobile push, native apps, predictive AI models, billing/multi-tenancy, real sending-reputation management, and building a full e-commerce store.
Deliverable: a working monorepo with a README describing docker-compose setup (Postgres, Redis, app), the data model, demo-seed instructions, and important limitations (segment evaluation latency, no deliverability guarantees, and template rendering not intended to match production ESP scale).