Running Facebook Ads is supposed to get you good quality leads.
And it does… sort of.
The problem?
When someone fills out a Facebook lead form, half the time you end up with:
Fake emails like
[email protected]Bogus phone numbers that don’t even have the right number of digits
Spammy submissions that waste your ad spend
Manually checking each one? Not happening.
You don’t have the time — and honestly, you shouldn’t need to.
So I built a workflow that:
Captures every Facebook lead form submission automatically
Validates and cleans the data (email, phone, name)
Generates a unique lead ID + spam score
Pushes only clean, trusted leads into Beehiiv as subscribers
And I didn’t write a single line of code.

The FLOW Framework
How to think about it:
F — Form → Facebook lead ad is the entry point.
L — Lead → Raw data lands in MindStudio.
O — Output → Validator agent structures & cleans into JSON.
W — Workflow → Auto-send to Beehiiv via webhook.
This is the blueprint that keeps the system clear and repeatable.
Here’s the Setup (Step-by-Step Without the Headache)
Step 1: Zapier Watches for New Leads
Zapier is like your virtual receptionist.
Someone fills out your Facebook Lead Ad form?
Boom — Zapier grabs it instantly and hands it off to the workflow.
Seriously, it’s like:
“Hey boss, we got a new signup on the Loyalty Form!”
No more downloading CSVs. No more manually checking Ads Manager. Zapier’s on watch 24/7.
Step 2: MindStudio Cleans the Lead (Like a Pro)
This is where the magic happens.
Raw Facebook leads can be messy — fake emails, weird phone numbers, or names like “Test Test.”
So I ran everything through a MindStudio Lead validation workflow.
I basically told it:
“Make sure the email looks real.”
“Normalize the phone number.”
“Split full names into first + last.”
“Give me a spam score if it looks sketchy.”
MindStudio takes care of all of that.
No manual cleanup. No spreadsheets. Just clean JSON that’s ready to go.
Step 3: Leads Go Straight Into Beehiiv
Here’s the part that made me breathe a little easier.
Instead of piling into some forgotten Google Sheet, the clean leads go straight into Beehiiv as subscribers.
No middleman. No manual import/export.
We didn’t write a backend app , just a few lines of vibe coding inside MindStudio to call the Beehiiv API.
One minute someone fills out your form, the next they’re a validated subscriber in Beehiiv, ready to get your next campaign.
It’s seamless. Fast. And it just works.
The Result
✅ Every Facebook ad lead is standardized and validated
✅ Fake emails + phone numbers get flagged instantly
✅ Spammy leads don’t clog up Beehiiv
✅ Only clean subscribers flow into your newsletter list
No manual reviews. No spreadsheet cleanup. Just clean leads on autopilot.
Why This Matters
Instead of paying for junk leads, you now:
Keep your Beehiiv (or CRM etc) list high-quality
Save time (no more manual cleanup)
Get a reliable audit trail (every lead has a unique ID + timestamp)
What’s Next
This is just the start. Future iterations could:
Auto-tag leads by campaign/ad set in Beehiiv
Trigger alerts for high-spam-score submissions
Enrich leads with extra data (like company info)
With this foundation, Facebook leads become clean, trustworthy subscribers in minutes.
👉 Want to try it yourself?
You can copy my workflow and be running clean leads to Beehiiv today.
Sign up to the Agent Foundry here to get started.
How to Set Up Your Facebook Lead Intake + Beehiiv Sync (Step-by-Step for Non-Techies)
This guide shows you exactly how to capture Facebook Lead Ads submissions, validate/standardize the data in MindStudio, and add clean subscribers to Beehiiv—all with copy-paste steps.
No coding. No dev team. Just follow along.
🛠️ Step 1: What You’ll Need (Checklist)
Make sure you’ve got these ready:
✅ 1) A Facebook Page + Lead Ads Form
You must be an admin on the page/ad account.
Your specific form (example used below):
Page: Wayback Burgers South Africa (ID:
000000000000)Form: Wayback Burger Loyalty Sign Up-copy (ID:
0000000000)
✅ 2) A Zapier Account
Sign up at zapier.com
You’ll use this to catch new Facebook leads and send them to MindStudio.
No coding required — it’s just click + map.
✅ 3) A MindStudio Account
Sign up at MindStudio (your link).
You’ll run a workflow that validates + standardizes each lead and posts to Beehiiv.
You can build from scratch or remix your existing Lead Intake workflow.
✅ 4) A Beehiiv (or “Beehivv”) API Key
Get your Beehiiv API key from your Beehiiv account.
Keep it secret.
Endpoint (as provided in your docs):
https://api.beehivv.com/v1/leads(use the exact URL you were given)
🔄 Step 2: What This Flow Actually Does
Someone submits your Facebook Lead Ad form
Zapier instantly grabs the lead data
MindStudio validates, normalizes, and scores it for spam
MindStudio then sends clean leads to Beehiiv as subscribers
Bad/incomplete leads can be flagged or filtered
All this happens in seconds — hands-free.
⚙️ Step 3: Create the Zap — Facebook Lead Ads Trigger
🔹 Part 1: Create a New Zap
Go to Zapier
Click Create Zap
Choose Facebook Lead Ads as the app
Select New Lead as the Trigger
🔹 Part 2: Connect Your Page + Form
Choose Page: Wayback Burgers South Africa (ID:
1764622706992206)Choose Form: Wayback Burger Loyalty Sign Up-copy (ID:
783009260757647)
💡 This watches only that form—perfect for clean tracking by offer/campaign.
🔁 Step 4: Add the MindStudio Step in Zapier
🔹 Part 1: Add a New Action
Click “+” to add another step
Choose MindStudio (or Webhooks by Zapier if MindStudio isn’t listed — use POST to your MindStudio webhook URL)
🔹 Part 2: Run the Workflow
Action:
Run WorkflowTitle: Send Lead to MindStudio Workflow
App: LeadIntakeForm Updated (or your app name)
Workflow:
Main.flow(or the flow you remixed)
🔹 Part 3: Map Facebook Fields → MindStudio Inputs
Map your Zap fields to the inputs your MindStudio prompt expects:
MindStudio Field (expected) | What to Send from Facebook Lead Ads |
|---|---|
| {{ Facebook ad name }} |
| {{ Facebook ad set name or ID }} |
| {{ Facebook campaign ID }} |
| {{ Facebook campaign name }} |
| {{ Facebook form ID }} |
|
|
|
|
| {{ Facebook page name }} |
| {{ Lead phone }} |
| {{ Lead full name }} |
| {{ Lead email }} |
| {{ Custom disclaimer responses }} (if present) |
✅ Tip: Use these exact input names so the prompt can reference them reliably.
🧠 Step 5: Build the Validator in MindStudio (Prompt)
Create a prompt node (or function) in your MindStudio workflow and paste this (update only the variable bindings if your names differ):
Validate the following lead information and check for potential spam indicators. Generate a unique lead_id, calculate a spam score, and return a standardized lead object:
<lead_data>
First Name: {{fullName}}
Email: {{email}}
Phone: {{phone}}
Platform: {{platform}}
Ad Name: {{adName}}
Form ID: {{formID}}
Lead ID: {{leadID}}
Ad Set ID: {{adSetId}}
Page Name: {{pageName}}
Campaign ID: {{campaignID}}
Campaign Name: {{campaignName}}
</lead_data>
Return ONLY a JSON object with this exact structure (no additional text)
Requirements:
- Generate unique lead_id format: "LD-YYYYMMDD-INITIALS####"
- Use current timestamp in ISO 8601 format
- Validate email format, phone format, and name completeness
- Calculate spam score (0.0-1.0) based on email domain, name patterns, phone format
- Extract first/last name from full_name
- Normalize phone to international format and detect country code
- List spam indicators as strings (e.g., "generic_email_domain", "suspicious_name_pattern")
Model setting: make sure the model returns JSON only (no prose).
Next node: parse/store the JSON as validatedLead.
(Optional) Example of what the JSON might look like after validation — for your understanding only:
{
"lead_id": "LD-20250919-JS0421",
"timestamp": "2025-09-19T14:03:27Z",
"first_name": "John",
"last_name": "Smith",
"email": "[email protected]",
"phone": "+14155550123",
"platform": "Facebook",
"campaign": {
"campaign_id": "1234567890",
"campaign_name": "Loyalty Sign Up",
"ad_set_id": "111222333",
"ad_name": "Wayback Loyalty Ad",
"form_id": "783009260757647",
"page_name": "Wayback Burgers South Africa",
"source_lead_id": "lead987654321"
},
"spam_score": 0.18,
"spam_indicators": ["generic_email_domain"],
"validation": {
"email_valid": true,
"phone_valid": true,
"name_valid": true,
"phone_country": "US"
}
}
🐝 Step 6: Send to Beehiiv (Inside MindStudio)
Add (or configure) your “Send Lead to Beehivv” function node after the validator.
Configuration (from your docs)
API Configuration
Beehivv API Key (Required): paste your secret key
Beehivv API Endpoint (Required):
https://api.beehivv.com/v1/leads(use your provided endpoint)
Data Configuration
Lead Data (Required): select the parsed
validatedLeadobjectMust contain:
lead_idraw_fields(object withfull_name,email,phone,platform,timestamp)(Optionally include spam score, validation status, campaign info as metadata)
Output Configuration
API Response Variable: e.g.,
beehivvResponseSuccess Status Variable: e.g.,
beehivvSuccess(boolean)
What it does
Validates required fields
Splits full name into first/last when possible
Transforms to Beehiiv’s required payload
Sends securely, handles errors, and exposes response/status
Best practices
Test with sample data first
Log
beehivvResponseandbeehivvSuccessfor visibilityKeep your API key secure
🧪 Step 7: Test the Flow
Submit a test entry to your Facebook Lead Form
(Optional: use Facebook’s Lead Ads Testing Tool for instant tests)
Confirm Zapier catches the lead and sends to MindStudio
In MindStudio, verify:
You receive valid JSON from the validator
The Beehiiv call runs and
beehivvSuccess === true
That’s it — clean leads now flow to Beehiiv automatically 🎉
💡 Step 8: Optional But Awesome Extras
Add This | What It Does |
|---|---|
Zapier Filter | Skip leads if |
Google Sheets | Log raw + validated leads, spam score, Beehiiv status |
Slack/Email Alerts | Notify your team when |
Tagging in Beehiiv | Include campaign/form metadata as tags or custom fields |
Deduping | Drop repeats if |
✅ Final Zap Summary
Step | App | What It Does |
|---|---|---|
1 | Facebook Lead Ads | Watches New Lead on: Page Wayback Burgers South Africa (ID |
2 | MindStudio | Run Workflow ( |
🧩 BONUS: Inside the MindStudio “Beehivv” Function (Quick Ref)
Validation
Checks required settings + lead shape
Verifies email/phone formats
Ensures API key/endpoint present
Name Processing
Splits
full_name→first_name/last_nameFalls back gracefully if ambiguous
Transformation
Builds Beehiiv-friendly payload
Adds optional metadata: validation status, spam score, campaign info
API Comms
Uses secure HTTPS
Handles network + API errors
Returns full response + success boolean
Outputs
beehivvResponse(object/string)beehivvSuccess(true/false)Logs for troubleshooting
🛠 What If Something Breaks?
Problem | How to Fix It |
|---|---|
Zap doesn’t see test leads | Submit a fresh form entry (or use Facebook’s tester). Ensure the exact form is selected. |
JSON parsing fails | Ensure the model returns JSON only (no extra text). Tighten prompt and enable JSON mode if available. |
Beehiiv returns 401 | Check the API key and that it’s pasted in the correct field. |
Beehiiv returns 404/422 | Confirm the endpoint URL, and required fields (email/lead_id) are present and valid. |
Phone/email invalid | Improve normalization rules or fallback logic in the validator. |
High spam false positives | Adjust spam scoring thresholds or indicators in your prompt logic. |
✅ You’re Done!
You’ve got a hands-free lead pipeline:
Facebook Lead Ad → Zapier catches it
MindStudio validates, standardizes, scores spam
Beehiiv receives clean subscribers you can trust
Scale to more forms, add tagging, and plug in alerts—without writing a single line of code.