Integrations
Facebook & Instagram
Lead Ads, Messenger and Instagram DMs, publishing and the Conversions API — with the Meta app setup that actually works.
This is the longest setup in PipeBase, almost entirely because of Meta's app dashboard. The order below matters — several steps can't be completed until an earlier one is done.
What you get
| Capability | What it does |
|---|---|
| Lead Ads | A Facebook or Instagram lead form submission becomes a contact and a deal, with your field mapping. |
| Social inbox | Messenger and Instagram DMs answered from inside the CRM. |
| Publishing | Post to Pages and Instagram together, scheduled or immediate. |
| Conversions API | Won deals sent back to Meta so ad optimisation sees real revenue. |
Before you start
- A Meta Business account owning the Pages you want to connect.
- Instagram accounts must be Business or Creator and linked to a Page. A personal account returns nothing and cannot be connected.
- For the Conversions API, an ad account with a pixel.
- Business verification — start it early. It gates most permissions and takes days.
1. Create the app
developers.facebook.com → Create App → type Business.
Don't reuse an app that already serves another product. The consent screen shows the app's name, so your customers would see the wrong brand — and webhook callback URLs are one-per-object, so the two integrations would fight.
2. Add the right use cases
The wizard opens on a Featured tab. Nothing you need is on it. Switch to All, and add:
| Use case | Gives you |
|---|---|
| Manage everything on your Page | Page publishing, Page webhooks |
| Capture & manage ad leads with Marketing API | Lead Ads |
| Engage with customers on Messenger from Meta | Messenger DMs |
| Manage messaging & content on Instagram | Instagram DMs and publishing |
| Create & manage ads with Marketing API | Conversions API, pixel discovery |
Add nothing else. Every extra use case drags its own App Review requirements — WhatsApp wants a business portfolio, Threads wants its own setup — and unmet requirements block you later.
Instagram: pick the right variant. If the Instagram use case shows its own separate app ID and secret, and permissions named
instagram_business_*, you have Instagram API with Instagram Login — the wrong one. Click "switch to the API setup with Facebook login" on that page. PipeBase reaches Instagram through the linked Page's token, which is the same token that carries Lead Ads and Messenger.
3. Basic settings
App Settings → Basic:
App domains: yourdomain.com
Privacy policy URL: https://yourdomain.com/legal/privacy-policy
Terms of Service URL: https://yourdomain.com/legal/terms-of-service
Category: Business
App icon: 1024x1024 PNG
Both legal URLs must serve real HTML. Reviewers open them, and they reject single-page-app shells that render nothing to a crawler.
At the very bottom, + Add Platform → Website, Site URL https://yourdomain.com.
4. Facebook Login settings
This page is not under App Settings. It's under the Login use case's Customize → Settings, or reachable directly at:
https://developers.facebook.com/apps/<APP_ID>/fb-login/settings/
Set:
Client OAuth login Yes
Web OAuth login Yes
Enforce HTTPS Yes
Use Strict Mode for redirect URIs Yes
Valid OAuth Redirect URIs:
https://yourdomain.com/api/meta/callback
Deauthorize callback URL:
https://yourdomain.com/api/meta-webhooks/deauthorize
Data Deletion Request URL:
https://yourdomain.com/api/meta-webhooks/data-deletion
If you get "Can't load URL — the domain of this URL isn't included in the app's domains", the message is misleading. It almost always means Valid OAuth Redirect URIs is empty, not that App Domains is wrong. There's a Redirect URI Validator at the top of this page — use it to confirm.
5. Webhooks
Webhooks are configured per use case, not in one central place. Set the same callback URL and verify token in each:
Callback URL: https://yourdomain.com/api/meta-webhooks
Verify token: (any long random string — must match META_WEBHOOK_VERIFY_TOKEN)
| Use case | Subscribe these fields |
|---|---|
| Manage everything on your Page | leadgen, feed |
| Engage with customers on Messenger | messages, messaging_postbacks, message_reactions, messaging_referrals |
| Manage messaging & content on Instagram | messages |
Adding the callback URL only verifies the endpoint. Each field has its own Subscribe toggle — a webhook with a green callback and no subscribed fields delivers nothing.
6. Connect in PipeBase
Settings → Integrations → Facebook & Instagram → Connect Facebook.
One click does the rest: exchanges the code for a long-lived token, discovers your Pages and their linked Instagram accounts, ad accounts and pixels, and subscribes each Page to the webhook. Pages showing Live are subscribed.
New Pages default to Lead Ads, Messages and Publishing all on. Turn off the ones you don't work — otherwise every DM to every Page lands in your inbox.
7. Lead Ad forms
Sync forms, then map each question to a CRM field and set routing — pipeline, stage, owner, product, deal value. Unmapped questions are kept verbatim on the lead and appended to the deal notes.
A lead that arrives before you've mapped anything is still saved. Fix the mapping and hit Retry.
Permissions requested
pages_show_list pages_read_engagement pages_manage_metadata
leads_retrieval pages_manage_ads pages_messaging
instagram_basic instagram_manage_messages
pages_manage_posts instagram_content_publish
ads_read ads_management business_management
Meta rejects the entire authorization dialog if any single permission is invalid for your app. If you see "Invalid Scopes: …", those permissions aren't enabled on your use cases — being in a use case isn't the same as being enabled in it. Check Customize → Permissions and features for each.
Things that will bite you later
Tokens expire after ~60 days. Page tokens don't, so Lead Ads, DMs and publishing keep working. The Conversions API uses the user token, so it stops on that date until an admin clicks Reconnect. The card shows the expiry.
App Review. Publishing your app makes it visible; it does not grant advanced access. Until each permission is approved, only people with a role on the app can connect. Multi-tenant apps accessing customers' Pages also need Tech Provider registration.
Instagram insights may be unavailable depending on your use case configuration. Without it, Instagram reach and saves read as blank; likes and comments still work.