Facebook Lead Ads · Real-Time Integration

Capture Leads.
Deliver Instantly.

A secure webhook that processes Facebook Lead Ads in real-time — stores every lead to your database and fires an email notification the moment a prospect submits your form.

Webhook URL https://leads.bizmo-tech.com/webhook/facebook
< 2s
Email Delivery
Forms Supported
SQLite
Local Storage
SHA-256
Signature Verified

From Form Submit to Your Inbox

The entire pipeline runs automatically — no manual steps required.

👤
Lead fills
Facebook form
📡
Meta sends
webhook POST
🔐
Signature
verified
🔗
Graph API
fetches data
💾
Saved to
SQLite
📧
Email sent
instantly

Everything You Need

Built on Laravel — production-ready, secure, and extensible.

🔗

Real-Time Webhook

Handles Meta's GET verification challenge and POST lead events. Responds with 200 OK instantly while processing in the background.

♾️

Multi-Form Support

Route leads from different Facebook forms to different email addresses. Add entries to the facebook_forms table per form ID.

🔐

X-Hub-Signature-256

Every incoming POST is verified against your App Secret using HMAC-SHA256. Invalid requests are rejected with 401 Unauthorized.

💾

SQLite Dump

All leads — including raw payload, field data, form ID, campaign ID, and ad ID — are persisted locally in SQLite automatically.

📧

Instant Email Alert

A beautifully formatted email with all lead fields is sent the moment data is fetched from the Graph API. Subject: New Facebook Lead Received.

📋

Full Logging

Every webhook call, API fetch, email dispatch, and error is logged via Laravel's logging system for easy debugging and audit.

Get Running in Minutes

Configure your .env file and register the webhook with Meta.

1

Configure Environment Variables

Open .env and fill in: FACEBOOK_VERIFY_TOKEN (any secret string you choose), FACEBOOK_APP_SECRET (from Meta App Dashboard), FACEBOOK_PAGE_ACCESS_TOKEN (from Graph API Explorer with leads_retrieval permission), and LEAD_NOTIFICATION_EMAIL.

2

Run Database Migrations

Run php artisan migrate to create the leads and facebook_forms tables in SQLite.

3

Register Webhook on Meta for Developers

In your Meta App → Webhooks → Add Webhook. Set the Callback URL to https://leads.bizmo-tech.com/webhook/facebook and the Verify Token to whatever you set in FACEBOOK_VERIFY_TOKEN. Subscribe to Page → leadgen.

4

Add Multiple Forms (Optional)

Insert a row into the facebook_forms table for each Facebook form ID with a specific notification_email. Leads from unmapped forms fall back to LEAD_NOTIFICATION_EMAIL.

5

Test with Meta Lead Testing Tool

In Meta for Developers → your Page → Lead Ads Testing Tool, submit a test lead. Check storage/logs/laravel.log and your inbox to verify delivery.