
Developer guide · Updated November 2026
Meta API: Every Meta Developer API Explained
The Meta API is a family of APIs, not one. Here is what each one does, which accounts it reaches, how to get access and what it costs, then how a SaaS product can connect its users' WhatsApp, Instagram and Facebook conversations with a single API.
GET
graph.facebook.com/v27.0/me
200 OK
Table of Contents
Basics
For SaaS
Short answer
The Meta API is the family of developer APIs Meta offers for Facebook, Instagram, WhatsApp, Threads, advertising and AI. Most of them are products of the Graph API, Meta's versioned HTTP API at graph.facebook.com. You reach them through a Meta app, access tokens and permissions approved in App Review.
This guide maps each Meta API to what it does and who can use it, then explains access, cost and limits. If your product needs the conversations of its own users, the last section shows how to connect WhatsApp, Instagram and Messenger accounts through one messaging API.
With Unipile
Every Action Your CRM Can Run on WhatsApp, Instagram and Facebook
Through Unipile, one integration lets a CRM, helpdesk or AI agent act on the accounts its users connect: read and answer conversations, manage messages, follow profiles, publish and reply to comments, all in real time.
Search conversations
All 10
4
3
3
Today
Hi! Is the linen jacket still available in M?10:44
ForwardedYes, here is the size guide.10:46
PDF
Here is my last order, same size please.10:491order-2231.pdf184 KB
EditedPerfect, I've reserved a size M for you until Friday.10:51
Seen
Reply to Chloe on Instagram...
Webhooks
message.new
message.reaction.new
message.receipt.read
chat.update
message.update
The full action list, channel by channel
| Action | |||
|---|---|---|---|
| Connection | |||
| Connect with Hosted Auth | Yes | Yes | Yes |
| QR code or pairing code | Yes | n/a | n/a |
| Credentials with two factor authentication | n/a | Yes | Yes |
| Messaging | |||
| List chats and messages | Yes | Yes | Yes |
| Start a new conversation | Yes | Yes | Yes* |
| Send messages and attachments | Yes | Yes | Yes |
| Edit and delete messages | Yes | Yes | Yes |
| Forward messages | Yes | Yes | Yes |
| Reactions | Yes | Yes | Yes |
| Mark as read and read receipts | Yes | Yes | Yes |
| Group chats | Yes | Yes | Yes |
| Mute and archive chats | Yes | Yes | Yes |
| Pin messages | Yes | Yes | No |
| Typing indicator | Yes | Presence only | Yes |
| Users | |||
| User profiles | Yes | Yes | Yes |
| Follow, unfollow and followers | n/a | Yes | Yes |
| Invitations and follow requests | n/a | Yes | Yes |
| Block and unblock users | Yes | Yes | No |
| Posts | |||
| Read posts | n/a | Yes | Yes |
| Create, edit and delete posts | n/a | Yes | Yes |
| Stories | n/a | Yes | No |
| Comments and replies | n/a | Yes | Yes |
| Reactions on posts and comments | n/a | Yes | Yes |
| Real time | |||
| New messages in real time (webhook) | Yes | Yes | Yes |
Connect with Hosted Auth
AreaConnection
WhatsAppYes
InstagramYes
FacebookYes
QR code or pairing code
AreaConnection
WhatsAppYes
Instagramn/a
Facebookn/a
Credentials with two factor authentication
AreaConnection
WhatsAppn/a
InstagramYes
FacebookYes
List chats and messages
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Start a new conversation
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes*
Send messages and attachments
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Edit and delete messages
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Forward messages
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Reactions
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Mark as read and read receipts
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Group chats
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Mute and archive chats
AreaMessaging
WhatsAppYes
InstagramYes
FacebookYes
Pin messages
AreaMessaging
WhatsAppYes
InstagramYes
FacebookNo
Typing indicator
AreaMessaging
WhatsAppYes
InstagramPresence only
FacebookYes
User profiles
AreaUsers
WhatsAppYes
InstagramYes
FacebookYes
Follow, unfollow and followers
AreaUsers
WhatsAppn/a
InstagramYes
FacebookYes
Invitations and follow requests
AreaUsers
WhatsAppn/a
InstagramYes
FacebookYes
Block and unblock users
AreaUsers
WhatsAppYes
InstagramYes
FacebookNo
Read posts
AreaPosts
WhatsAppn/a
InstagramYes
FacebookYes
Create, edit and delete posts
AreaPosts
WhatsAppn/a
InstagramYes
FacebookYes
Stories
AreaPosts
WhatsAppn/a
InstagramYes
FacebookNo
Comments and replies
AreaPosts
WhatsAppn/a
InstagramYes
FacebookYes
Reactions on posts and comments
AreaPosts
WhatsAppn/a
InstagramYes
FacebookYes
New messages in real time (webhook)
AreaReal time
WhatsAppYes
InstagramYes
FacebookYes
* On Facebook, a personal account can start a conversation; a Page can only reply to people who wrote to it.
Source: Unipile's provider features (V2), read on November 18, 2026. Unipile is not an official Meta app and not a Meta Partner; each user connects their own account.
Definition
What Is the Meta API?
There is no single Meta API. Meta for Developers exposes several products, and most of them share one foundation: the Graph API, where every Facebook or Instagram object is a node you read and write over HTTPS.
Each product adds its own endpoints, permissions and review. Meta ships a new Graph API version several times a year: v27.0 arrived on November 4, 2026. Since July 1, 2025, Meta builds new APIs that do not depend on the Graph API on a separate REST framework based on OpenAPI; the Llama API was among the first. Existing Graph API integrations keep working.
Not to be confused with MetaApi, an unrelated trading API for MetaTrader. Searching for a Meta Business API? There is no product by that name: you probably need the Business SDK, the Business Management API (business portfolios, assets, system users), the Marketing API or the WhatsApp Business Platform.
Sources: Meta's Graph API overview and changelog, and the REST API overview. Last verified: November 2026.
Anatomy of a Graph API call
Version
v27.0, pinned in the URLNodeAn object with an ID: a Page, a user, a post, an ad account
EdgeA collection on that node, such as
/feed or /conversationsTokenA user, Page or system user access token
Map
The Meta APIs at a Glance
Ten APIs cover most needs. The first question is always the same: which account will your app act for, and what does Meta require before it lets you?
| API | What it does | Accounts it reaches | Access required |
|---|---|---|---|
| Graph API | Read and write Facebook and Instagram objects | Users, Pages, businesses | Meta app, access token, permissions |
| Pages API | Publish posts, moderate comments, read Page insights | Facebook Pages | Page access token, App Review |
| Messenger Platform | Send and receive Page conversations | Facebook Pages, Instagram professional accounts | Page token, messaging permission, App Review |
| Instagram Platform | Publish media, manage comments and DMs, read insights | Instagram professional accounts | Instagram or Facebook Login, App Review |
| WhatsApp Business Platform | Send templates and replies through the Cloud API | WhatsApp Business phone numbers | Business portfolio, verified number, per message billing |
| Threads API | Publish, read and reply to Threads posts | Threads profiles | Meta app with Threads use case, App Review |
| Marketing API | Create campaigns, audiences and reports | Ad accounts | Business verification, ads permissions |
| Conversions API | Send web, app and offline events for ads | Businesses running ads | Pixel or dataset, system user token |
| Content Library API | Query public content for research | Approved researchers | Application through Meta, not open to products |
| Meta Model API | Run Meta AI models such as Muse Spark | Developers (public preview) | API key from Meta, billed per token |
Graph API
What it doesRead and write Facebook and Instagram objects
Accounts it reachesUsers, Pages, businesses
Access requiredMeta app, access token, permissions
Pages API
What it doesPublish posts, moderate comments, read Page insights
Accounts it reachesFacebook Pages
Access requiredPage access token, App Review
Messenger Platform
What it doesSend and receive Page conversations
Accounts it reachesFacebook Pages, Instagram professional accounts
Access requiredPage token, messaging permission, App Review
Instagram Platform
What it doesPublish media, manage comments and DMs, read insights
Accounts it reachesInstagram professional accounts
Access requiredInstagram or Facebook Login, App Review
WhatsApp Business Platform
What it doesSend templates and replies through the Cloud API
Accounts it reachesWhatsApp Business phone numbers
Access requiredBusiness portfolio, verified number, per message billing
Threads API
What it doesPublish, read and reply to Threads posts
Accounts it reachesThreads profiles
Access requiredMeta app with Threads use case, App Review
Marketing API
What it doesCreate campaigns, audiences and reports
Accounts it reachesAd accounts
Access requiredBusiness verification, ads permissions
Conversions API
What it doesSend web, app and offline events for ads
Accounts it reachesBusinesses running ads
Access requiredPixel or dataset, system user token
Content Library API
What it doesQuery public content for research
Accounts it reachesApproved researchers
Access requiredApplication through Meta, not open to products
Meta Model API
What it doesRun Meta AI models such as Muse Spark
Accounts it reachesDevelopers (public preview)
Access requiredAPI key from Meta, billed per token
Going deeper on one platform: the Facebook API guide covers the Graph API, Pages and Messenger; the Instagram API guide covers the Instagram Platform; the WhatsApp API guide covers the Business Platform and its providers.
Decision
Which Meta API Do You Need?
Start from what your product does. Each need below points to one API.
You answer customers on your own Page or Instagram
Messenger Platform
Page conversations and Instagram DMs, inside the 24 hour messaging window.
You send notifications or support on WhatsApp
WhatsApp Cloud API
Templates outside the customer service window, billed per message.
You publish content
Pages, Instagram and Threads APIs
One API per network, each with its own review.
You run or measure ads
Marketing and Conversions APIs
Ad accounts, business verification, server side events.
You add AI to your product
Meta Model API
Meta models through an API key, billed per token.
Your users connect their own accounts in your SaaS
Unipile API
WhatsApp, Instagram and Facebook conversations of each user, one API and one webhook format.
Use cases
Meta API Use Cases by Provider
What teams actually build with Meta APIs, provider by provider, and where the official API ends and a connected account takes over.
CandidatesJobs
CandidateStage
Lina BenaliSure, Thursday 10am worksInterview
Tom KellerCV sent as PDFScreening
Nora SilvaThanks for the offer!Offer
Paul MartinIs the role remote?New
Meta API use cases on WhatsApp
Meta's Cloud API serves a business phone number: support desks, order updates and template campaigns, billed per message. When each recruiter, advisor or salesperson works from their own WhatsApp, Unipile connects that account by QR code so your ATS, CRM or inbox reads and sends their messages, groups included. WhatsApp API guide.
Candidate and client chats stay attached to the right record.
Instagram DMsOrders
MessageTopic
Emma DuvalDo you have it in blue?Product
Ravi ChandraWhere is order #2231?Order
Maya BrownLoved the packaging!Feedback
Jon LeeCollab for my channel?Partner
Meta API use cases on Instagram
The Instagram Platform covers professional accounts: publishing, comments, insights and DMs, after App Review. Shops, agencies and creator tools that need each user's own inbox connect the account through Unipile and handle DMs, attachments, posts and comments with the same endpoints as other channels. Instagram API guide.
DMs answered from the tool where orders and customers already live.
ContactsDeals
ContactStage
Julia ChenIs the demo still on?Qualified
Lucas MeyerSend me the quoteProposal
Sofia RiveraSigned, thanks!Won
Daniel MoreauLet's talk MondayNew
Meta API use cases on Facebook and Messenger
Meta's Pages API and Messenger Platform let a business answer and publish as its own Page. With Unipile, each user connects a personal account and the Pages they manage: Messenger chats flow into the CRM, and posts go out as the user or as the Page. Facebook Messenger CRM integration.
Every Messenger conversation saved on the right contact.
All channelsMine
ConversationChannel
Amir KhanCan I change my booking?WhatsApp
Chloe LambertSent you a photoInstagram
Ben NovakWhat are your hours?Messenger
Sara GomezThanks, all sortedWhatsApp
One inbox for Meta messaging
Helpdesks, AI agents and sales engagement tools often need all three channels at once. Built on Meta, that means three platforms, three webhook formats and three reviews. Through Unipile, every channel shares one chat and message model, one webhook URL and one authentication flow. Messaging API.
One integration for every Meta conversation your users have.
Use cases that stay on Meta's own APIs
Publishing tools
Threads API
Schedule and publish Threads posts, read replies and insights for a Threads profile, after App Review.
Ads, reporting and lead sync
Marketing, Conversions and Lead Ads
Build ad reporting, send server side events, and push Lead Ads forms to a CRM through the leadgen webhook.
AI features and agents
Meta Model API
Call Meta's models for summaries, replies or classification, billed per token, alongside your messaging data.
These three stay on Meta's own APIs: Unipile does not cover Threads, ads or AI models. It focuses on the conversations, posts and comments of the accounts your users connect.
By product
Meta API Integration by Product Type
The same three channels serve very different products. This grid shows what each type of software usually builds on WhatsApp, Instagram and Facebook.
| Product | Learn more | |||
|---|---|---|---|---|
| CRM and sales tools | Client chats on each rep's number | DMs from leads and customers | Page and personal Messenger chats on the contact | CRM use case |
| ATS and recruiting | Candidate follow up and interview scheduling | Replies to creator and talent outreach | Candidate messages from Pages and profiles | ATS use case |
| Helpdesk and unified inbox | Support conversations and groups | Order and product questions | Page inbox and Messenger requests | Unified inbox |
| Outreach and sales engagement | Personal follow ups in a sequence | DMs after a first contact | Messenger follow ups from the user's own account (a Page only replies) | Outreach use case |
| AI agents | Answer and summarize chats | Draft replies to DMs | Triage Page messages | AI agent use case |
| Social media tools | Not applicable | Posts, comments and DMs | Posts as a Page or a user, comments as the user | Social media API |
CRM and sales tools
WhatsAppClient chats on each rep's number
InstagramDMs from leads and customers
FacebookPage and personal Messenger chats on the contact
Learn moreCRM use case
ATS and recruiting
WhatsAppCandidate follow up and interview scheduling
InstagramReplies to creator and talent outreach
FacebookCandidate messages from Pages and profiles
Learn moreATS use case
Helpdesk and unified inbox
WhatsAppSupport conversations and groups
InstagramOrder and product questions
FacebookPage inbox and Messenger requests
Learn moreUnified inbox
Outreach and sales engagement
WhatsAppPersonal follow ups in a sequence
InstagramDMs after a first contact
FacebookMessenger follow ups from the user's own account (a Page only replies)
Learn moreOutreach use case
AI agents
WhatsAppAnswer and summarize chats
InstagramDraft replies to DMs
FacebookTriage Page messages
Learn moreAI agent use case
Social media tools
WhatsAppNot applicable
InstagramPosts, comments and DMs
FacebookPosts as a Page or a user, comments as the user
Learn moreSocial media API
Access
How to Get Meta API Access
There is no single Meta API key. You work with an app, access tokens and permissions, and each permission your users rely on goes through App Review.
1
Create a Meta developer account
Register on Meta for Developers with a Facebook account.
2
Create a Meta app
Choose the use case (Pages, Messenger, Instagram, WhatsApp, Threads, ads) and note the App ID and App Secret.
3
Get access tokens
Users and Page admins sign in to grant your app tokens. Server jobs use a system user token from a business portfolio.
4
Request permissions
For example pages_messaging, instagram_manage_messages or whatsapp_business_messaging.
5
Pass App Review and Business Verification
Advanced Access is required before people without a role on your app can use it.
Test your first call
In the Graph API Explorer, select your app, generate a token with the permissions you need and run a first request. In production, call the same endpoints over HTTPS or through Meta's Business SDK.
# Read the id and name of the token owner
curl "https://graph.facebook.com/v27.0/me?fields=id,name&access_token={ACCESS_TOKEN}"
Which permissions for which use case
| Use case | Main permissions |
|---|---|
| Answer Page messages on Messenger | pages_messaging, pages_manage_metadata |
| Publish and moderate on a Page | pages_manage_posts, pages_read_engagement, pages_manage_engagement |
| Instagram DMs | instagram_business_manage_messages (Instagram Login) or instagram_manage_messages (Facebook Login) |
| WhatsApp messaging | whatsapp_business_messaging, whatsapp_business_management |
| Lead Ads to a CRM | leads_retrieval, pages_manage_metadata |
| Ad reporting | ads_read |
| Threads publishing | threads_basic, threads_content_publish |
Answer Page messages on Messenger
Main permissions
pages_messaging, pages_manage_metadataPublish and moderate on a Page
Main permissions
pages_manage_posts, pages_read_engagement, pages_manage_engagementInstagram DMs
Main permissions
instagram_business_manage_messages (Instagram Login) or instagram_manage_messages (Facebook Login)WhatsApp messaging
Main permissions
whatsapp_business_messaging, whatsapp_business_managementLead Ads to a CRM
Main permissions
leads_retrieval, pages_manage_metadataAd reporting
Main permissions
ads_readThreads publishing
Main permissions
threads_basic, threads_content_publishThe Meta Model API is the exception: it uses a classic API key created in its own developer console, with no App Review. Tokens and permissions for Facebook are detailed in the Facebook API guide.
Sources: Meta's access tokens guide and App Review documentation, and the Graph API Explorer guide. Last verified: November 2026.
Troubleshooting
Common Meta API Errors and How to Fix Them
Most failed calls come back with one of a few error codes. Here is what they mean and what to do.
| Code | What it means | What to do |
|---|---|---|
190 | Access token expired, revoked or invalid | Refresh or exchange the token, and ask the user to reconnect if it was revoked |
10, 200 to 299 | Permission missing or not approved | Request the permission, check its access level and the Page tasks of the token owner |
4, 17, 32, 613 | Rate limit reached (app, user, Page or custom) | Back off, read the usage headers and spread calls over time |
368 | Action blocked for a policy reason | Stop the action and review Meta's platform terms and the content sent |
100 | Invalid parameter or object not reachable with this token | Check the ID, the fields requested and the token type |
131047 (WhatsApp) | Free form message sent outside the 24 hour window | Send an approved template instead |
190What it meansAccess token expired, revoked or invalid
What to doRefresh or exchange the token, and ask the user to reconnect if it was revoked
10, 200 to 299What it meansPermission missing or not approved
What to doRequest the permission, check its access level and the Page tasks of the token owner
4, 17, 32, 613What it meansRate limit reached (app, user, Page or custom)
What to doBack off, read the usage headers and spread calls over time
368What it meansAction blocked for a policy reason
What to doStop the action and review Meta's platform terms and the content sent
100What it meansInvalid parameter or object not reachable with this token
What to doCheck the ID, the fields requested and the token type
131047 (WhatsApp)What it meansFree form message sent outside the 24 hour window
What to doSend an approved template instead
Sources: Meta's Graph API error handling guide and WhatsApp Cloud API error codes. Last verified: November 2026.
Pricing
Does the Meta API Cost Anything?
Calling most Meta APIs is free. Money comes in through WhatsApp messages, ads, AI tokens and the engineering time to keep an integration running.
Graph, Pages, Instagram, ThreadsNo feeMeta does not charge per call. Your cost is the app, App Review and version upgrades.
WhatsApp Business PlatformPer messageBilled per delivered template message since July 1, 2025, by category and country.
Meta Model APIPer tokenInput and output tokens are billed, in public preview since July 2026.
Rate limits
Meta caps calls rather than charging for them. Graph API limits depend on the token: per app and number of users for user tokens, per Business Use Case for Pages, Instagram and ads. Each response carries usage headers such as X-App-Usage and X-Business-Use-Case-Usage, so your app can slow down before it is throttled.
WhatsApp rates are detailed in our WhatsApp Business API pricing guide.
Sources: Meta's rate limiting guide and WhatsApp pricing. Last verified: November 2026.
Limits
Where Official Meta APIs Stop for SaaS Products
Meta's APIs are built for a business managing its own Pages, numbers and ads. A Meta API integration for a SaaS product that serves many customers runs into four walls.
- Business accounts only. The Messenger Platform answers as a Facebook Page, the Instagram Platform needs a professional account, WhatsApp needs a Business number. Personal accounts are out of scope.
- One review per product. Each permission needs Advanced Access, and Meta reviews your use case, screencast and privacy policy before your customers can connect.
- Three platforms, three models. Messenger, Instagram and WhatsApp each have their own IDs, message formats, webhooks and messaging windows.
- Constant upgrades. Several Graph API versions ship every year and each one is supported for at least two years before it is retired, so integrations need regular maintenance.
Sources: Meta's Messenger Platform overview and versioning guide. Last verified: November 2026.
With Unipile
One API for Meta Messaging: WhatsApp, Instagram and Messenger
CRMs, helpdesks, recruiting tools and AI agents need the conversations of their own users, not of one company Page. With Unipile, each user links their account through a hosted authentication page, and your app calls one REST API for all three channels.
| Channel | What your app can do | Learn more |
|---|---|---|
| Connect a WhatsApp account by QR code, list chats, send messages and attachments, reactions, groups | WhatsApp API guide | |
| Connect an Instagram account, read and send DMs and attachments, profiles, posts and comments | Instagram API guide | |
| Connect a personal account and the Pages it manages, read and reply to Messenger chats, publish posts as a Page | Facebook Messenger API | |
| All three | Same endpoints, same objects and the same webhooks for new messages, reactions and read receipts | Provider features |
WhatsApp
What your app can doConnect a WhatsApp account by QR code, list chats, send messages and attachments, reactions, groups
Learn moreWhatsApp API guide
Instagram
What your app can doConnect an Instagram account, read and send DMs and attachments, profiles, posts and comments
Learn moreInstagram API guide
Facebook
What your app can doConnect a personal account and the Pages it manages, read and reply to Messenger chats, publish posts as a Page
Learn moreFacebook Messenger API
All three
What your app can doSame endpoints, same objects and the same webhooks for new messages, reactions and read receipts
Learn moreProvider features
List chats and reply, whatever the channel
Once a user connects an account, you get an account_id. The calls are identical for WhatsApp, Instagram and Facebook.
# 1. List the chats of a connected WhatsApp, Instagram or Facebook account
curl --request GET \
--url "https://api.unipile.com/v2/{ACCOUNT_ID}/chats" \
--header "X-API-KEY: {YOUR_API_KEY}"
# 2. Reply in one of those chats
curl --request POST \
--url "https://api.unipile.com/v2/{ACCOUNT_ID}/chats/{CHAT_ID}/messages/send" \
--header "X-API-KEY: {YOUR_API_KEY}" \
--header "content-type: application/json" \
--data '{ "text": "Thanks, your order ships today." }'
200 OK · message sent from the user's account
Full reference in the Unipile API documentation.
Compliance
Each user connects their own account
Unipile is an independent company, not an official Meta app and not a Meta Partner. It acts on behalf of authenticated users, who remain bound by Meta's terms. Use it for legitimate scenarios such as customer support, CRM and direct conversations.
Step by step
Meta API Integration in 5 Steps: WhatsApp, Instagram and Messenger
The same five steps connect any of the three Meta channels, so a team that ships WhatsApp first can add Instagram and Messenger without a new integration.
1
Create a Unipile account
Get your API key from the dashboard. The free trial lasts 7 days, with no credit card.
2
Open a Hosted Auth link
Call POST /v2/auth/link with the providers you offer, for example WhatsApp, Instagram and Facebook, then send your user to the returned link.
3
Receive the account_id
The user lands back on your redirect_uri with an account_id, and an account.add webhook confirms the account is ready.
4
Backfill chats and messages
List the chats of the account with GET /v2/{ACCOUNT_ID}/chats and store the history you need.
5
Go real time with webhooks
Subscribe one endpoint to message.new and the other message events, and reply with messages/send.
Connect an account and receive its messages
# Hosted Auth link for WhatsApp, Instagram and Facebook
curl --request POST \
--url "https://api.unipile.com/v2/auth/link" \
--header "X-API-KEY: {YOUR_API_KEY}" \
--header "content-type: application/json" \
--data '{
"providers": ["whatsapp", "instagram", "facebook"],
"redirect_uri": "https://yourapp.com/accounts/callback",
"expires_on": "2027-01-01T00:00:00.000Z"
}'
// One endpoint for every connected Meta account (Express)
app.post("/webhooks/unipile", express.raw({ type: "application/json" }), (req, res) => {
// Check the unipile-signature header with your endpoint secret first
const event = JSON.parse(req.body);
if (event.type === "message.new") {
// event.account_provider tells you WhatsApp, Instagram or Facebook
saveMessage(event.account_id, event.account_provider, event.payload);
}
res.sendStatus(200);
});
Full reference: Hosted Auth and webhooks in the Unipile documentation.
Webhooks
Meta API Webhooks: Three Platforms, Three Setups
Every Meta platform pushes events to a verified HTTPS endpoint, but each one is subscribed, shaped and filtered differently. Here is what you set up for each, compared with Unipile's single format.
| Platform | Where you subscribe | Fields or events | Signature header |
|---|---|---|---|
| Messenger Platform | Subscribe each Page to your app (subscribed_apps) | messages and related fields | X-Hub-Signature-256 |
| Instagram Platform | Subscribe the professional account (Instagram Login) or its linked Page (Facebook Login) | messages and related fields | X-Hub-Signature-256 |
| WhatsApp Cloud API | Subscribe the WhatsApp Business Account | messages, with delivery statuses in the same field | X-Hub-Signature-256 |
| Lead Ads | Subscribe each Page (pages_manage_metadata), then fetch the lead with leads_retrieval | leadgen | X-Hub-Signature-256 |
| Unipile | One endpoint for every connected account | message.new, message.update, message.reaction.new, message.receipt.read, account.add | unipile-signature |
Messenger Platform
Where you subscribeSubscribe each Page to your app (
subscribed_apps)Fields or events
messages and related fieldsSignature header
X-Hub-Signature-256Instagram Platform
Where you subscribeSubscribe the professional account (Instagram Login) or its linked Page (Facebook Login)
Fields or events
messages and related fieldsSignature header
X-Hub-Signature-256WhatsApp Cloud API
Where you subscribeSubscribe the WhatsApp Business Account
Fields or events
messages, with delivery statuses in the same fieldSignature header
X-Hub-Signature-256Lead Ads
Where you subscribeSubscribe each Page (
pages_manage_metadata), then fetch the lead with leads_retrievalFields or events
leadgenSignature header
X-Hub-Signature-256Unipile
Where you subscribeOne endpoint for every connected account
Fields or events
message.new, message.update, message.reaction.new, message.receipt.read, account.addSignature header
unipile-signatureOn Meta's side, your endpoint first answers a verification request with the hub.challenge value, then receives POST notifications signed with your app secret. Answer with a 200 quickly, process events in the background and ignore duplicates, because Meta retries deliveries that fail.
Sources: Meta's Webhooks getting started guide, Webhooks for Leads and Unipile's event types reference. Last verified: November 2026.
Comparison
Building on Meta APIs vs Unipile
Both paths are legitimate. The right one depends on whose accounts your product serves.
| Meta's official APIs | Unipile | |
|---|---|---|
| Accounts reached | Pages, Instagram professional accounts, WhatsApp Business numbers | The accounts your users connect: personal and business, Pages they manage |
| Setup before the first message | Meta app, permissions, App Review, Business Verification | API key and a Hosted Auth link |
| Channels | One platform per channel, each with its own model | WhatsApp, Instagram and Facebook with LinkedIn, Telegram, email and calendars |
| Webhooks | Three subscriptions and three payload formats | One endpoint, one event format |
| Maintenance | Each Graph API version is supported for at least two years, then retired | Unipile follows provider changes |
| Pricing | Free to call, WhatsApp billed per message | Billed per connected account, see API pricing |
| Out of scope | Personal accounts | Ads, Threads, Lead Ads and AI models |
Accounts reached
Meta's official APIsPages, Instagram professional accounts, WhatsApp Business numbers
UnipileThe accounts your users connect: personal and business, Pages they manage
Setup before the first message
Meta's official APIsMeta app, permissions, App Review, Business Verification
UnipileAPI key and a Hosted Auth link
Channels
Meta's official APIsOne platform per channel, each with its own model
UnipileWhatsApp, Instagram and Facebook with LinkedIn, Telegram, email and calendars
Webhooks
Meta's official APIsThree subscriptions and three payload formats
UnipileOne endpoint, one event format
Maintenance
Meta's official APIsEach Graph API version is supported for at least two years, then retired
UnipileUnipile follows provider changes
Pricing
Meta's official APIsFree to call, WhatsApp billed per message
UnipileBilled per connected account, see API pricing
Out of scope
Meta's official APIsPersonal accounts
UnipileAds, Threads, Lead Ads and AI models
Sources: Meta's Graph API versioning guide and Unipile's provider features. Last verified: November 2026.
Best practices
Meta API Best Practices and Compliance
Most rejected apps, blocked numbers and broken integrations come from the same handful of mistakes.
- Get consent first. Message people who contacted the business or opted in, and give them an easy way to stop.
- Respect messaging windows. On Messenger and Instagram, you can send standard messages within 24 hours of the person's last message; the
HUMAN_AGENTtag, which requires Meta's Human Agent permission, extends manual replies to 7 days. On WhatsApp, outside the 24 hour customer service window you can only send approved template messages. - Read the usage headers. Slow down when
X-App-UsageorX-Business-Use-Case-Usageclimbs, and retry with backoff. - Verify every webhook. Check the signature on the raw body, answer fast and make your handler idempotent.
- Pin and plan versions. Call a fixed Graph API version and upgrade before it is retired.
- Store tokens like passwords. Encrypt access tokens, scope them to what you need and revoke them when a customer leaves.
Compliance
Your users stay bound by Meta's terms
Unipile is not an official Meta app and not a Meta Partner. It is built in line with the Digital Markets Act, acts only on accounts that users connect themselves, and is meant for legitimate conversations such as support, CRM and recruiting.
Sources: Meta's Messenger send messages guide, rate limiting guide and WhatsApp pricing. Last verified: November 2026.
Pick the Meta API that matches your account model
Use Meta's own APIs when your company manages its own Pages, numbers, ads or AI usage. When your product needs the WhatsApp, Instagram and Facebook conversations of each of its users, connect their accounts through Unipile and keep one API for every channel.
Meta API FAQ
Quick answers on cost, access tokens, webhooks, Lead Ads and compliance.
Calling the Graph API, Pages, Instagram, Messenger and Threads APIs is free. WhatsApp Business Platform messages are billed per delivered template message since July 1, 2025, ads are paid as ad spend, and the Meta Model API is billed per token.
Yes, several. Meta for Developers offers the Graph API and products built on it (Pages, Messenger, Instagram, WhatsApp, Marketing and Conversions APIs), plus the Threads API, the Content Library API for researchers and the Meta Model API for AI.
Create a Meta app on Meta for Developers, then get tokens from the people who use it: a user token through Facebook Login, a Page token from /me/accounts, or a system user token from your business portfolio for server jobs. The Graph API Explorer gives a test token.
Meta documents it as the Conversations API of the Messenger Platform. It lists the conversations and messages of a Facebook Page or an Instagram professional account, for example GET /{page-id}/conversations?platform=instagram. Do not confuse it with the Conversions API, which sends ad events from your server.
They depend on the token. User and app tokens share a platform limit based on the number of users of your app; Pages, Instagram and ads calls count against Business Use Case limits. Meta returns usage headers with each response so you can slow down before you are throttled.
Unipile is built in line with the Digital Markets Act (DMA): its API focuses on messaging interoperability for accounts that users connect themselves, and user profiles are not stored. Unipile is not affiliated with Meta, and clients are expected to comply with the terms of each provider.
Not quite. The Graph API is the base HTTP API at graph.facebook.com that most Meta products are built on, including Pages, Messenger, Instagram, WhatsApp and the Marketing API. Threads runs on its own host, graph.threads.net, and the Meta Model API is a separate API with its own keys.
It retrieves the leads collected by Facebook and Instagram lead ad forms. You subscribe a Page to the leadgen webhook field, and each notification carries a leadgen_id that you read through the Graph API with the leads_retrieval permission.
You register a verified HTTPS endpoint in your Meta app and subscribe each Page, Instagram account or WhatsApp Business Account to the fields you need. Meta then sends signed POST notifications; check the X-Hub-Signature-256 header, answer with a 200 quickly and process events asynchronously.
Not on Meta's side: each channel has its own platform, permissions and webhooks. Unipile exposes WhatsApp, Instagram and Facebook Messenger through the same chat and message endpoints and one webhook format, for accounts your users connect themselves.

