{"id":52335,"date":"2025-09-04T09:28:23","date_gmt":"2025-09-04T09:28:23","guid":{"rendered":"https:\/\/www.devopsschool.com\/blog\/?p=52335"},"modified":"2026-02-21T08:15:54","modified_gmt":"2026-02-21T08:15:54","slug":"whatsapp-cloud-api-direct-integration-with-meta","status":"publish","type":"post","link":"https:\/\/www.devopsschool.com\/blog\/whatsapp-cloud-api-direct-integration-with-meta\/","title":{"rendered":"WhatsApp Cloud API: Direct Integration with Meta"},"content":{"rendered":"\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"904\" height=\"628\" src=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2025\/09\/image-1.png\" alt=\"\" class=\"wp-image-52337\" srcset=\"https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2025\/09\/image-1.png 904w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2025\/09\/image-1-300x208.png 300w, https:\/\/www.devopsschool.com\/blog\/wp-content\/uploads\/2025\/09\/image-1-768x534.png 768w\" sizes=\"auto, (max-width: 904px) 100vw, 904px\" \/><\/figure>\n\n\n\n<p>You can do this <strong>directly with Meta\u2019s WhatsApp Business Platform (Cloud API)<\/strong> from your own app\/website. Below is a complete, no-BSP, end-to-end checklist you can follow. I\u2019ve included short code samples and the exact places in Meta where each step lives.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h1 class=\"wp-block-heading\">Prerequisites (before you start)<\/h1>\n\n\n\n<ul class=\"wp-block-list\">\n<li>A <strong>Meta Business<\/strong> account (Business Manager) with admin access.<\/li>\n\n\n\n<li>A <strong>Meta Developer<\/strong> account.<\/li>\n\n\n\n<li>A <strong>phone number<\/strong> that can receive SMS\/voice for verification (new number is easiest; existing numbers can be onboarded or migrated).<\/li>\n\n\n\n<li>A <strong>public HTTPS endpoint<\/strong> for webhooks (e.g., yourdomain.com\/whatsapp\/webhook).<\/li>\n\n\n\n<li>Basic server (Node, PHP, etc.) to <strong>store tokens safely<\/strong> and call the Graph API (never call it from the browser). ()<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h1 class=\"wp-block-heading\">Step-by-step setup (Cloud API, hosted by Meta)<\/h1>\n\n\n\n<h2 class=\"wp-block-heading\">1) Create a Meta App &amp; add the WhatsApp product<\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Go to <strong>Meta for Developers \u2192 My Apps \u2192 Create App<\/strong> (choose \u201cBusiness\u201d).<\/li>\n\n\n\n<li>In your app, <strong>Add Product \u2192 WhatsApp<\/strong>.<\/li>\n\n\n\n<li>Open the <strong>WhatsApp<\/strong> product\u2019s <strong>Getting Started<\/strong> page.<br>This creates the base assets and guides you through initial test-message steps. ()<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\">2) Create\/confirm your WhatsApp Business Account (WABA)<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>In <strong>Business Manager \u2192 Accounts \u2192 WhatsApp Accounts (WhatsApp Manager)<\/strong> you\u2019ll see or create your <strong>WABA<\/strong> and manage numbers, templates, metrics, etc. ()<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">3) Verify your business in Business Manager (Production requirement)<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Business Settings \u2192 Security Center \u2192 Start Verification.<\/strong><\/li>\n\n\n\n<li>Submit legal details and documents. Admin privilege is required.<br>Business verification unlocks production sending at scale and higher limits. (, )<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">4) Request <strong>Display Name<\/strong> approval<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Your WA <strong>display name<\/strong> must follow Meta\u2019s rules (no \u201cofficial\u201d, no Meta brands in the name, must reflect your business).<\/li>\n\n\n\n<li>Submit\/approve in <strong>WhatsApp Manager<\/strong> when adding the number. ()<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">5) Add a phone number (new number) <strong>or<\/strong> onboard\/migrate an existing one<\/h2>\n\n\n\n<p><strong>A. New number (simplest):<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>In <strong>App Dashboard \u2192 WhatsApp \u2192 Configuration \u2192 Add phone number<\/strong>, verify via SMS\/voice, and you\u2019ll receive a <strong>Phone Number ID<\/strong>. (, )<\/li>\n<\/ul>\n\n\n\n<p><strong>B. Existing number options:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Embedded Signup<\/strong> supports numbers already used with the <strong>WhatsApp Business App<\/strong> (special flow).<\/li>\n\n\n\n<li><strong>Migrate<\/strong> a number from one WABA\/BSP to another with <strong>Embedded Signup<\/strong>; you keep display name, quality rating, and limits. (, )<\/li>\n<\/ul>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>You\u2019ll end up with two IDs you\u2019ll use everywhere: your <strong>WABA ID<\/strong> and your <strong>Phone Number ID<\/strong>. Keep both.<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">6) Generate a <strong>permanent access token<\/strong> (server-side only)<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>In <strong>Business Settings \u2192 Users \u2192 System Users<\/strong>, create a system user, assign your app + WhatsApp permissions, then <strong>Generate Token<\/strong>.<\/li>\n\n\n\n<li>Store the token in your backend secrets manager; do <strong>not<\/strong> embed in client code. ()<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">7) Set up your <strong>Webhook<\/strong> endpoint &amp; subscribe<\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Build an HTTPS endpoint that can respond to the <strong>verification handshake<\/strong> with <code>hub.challenge<\/code> when Meta calls it.<\/li>\n\n\n\n<li>In <strong>App Dashboard \u2192 WhatsApp \u2192 Configuration<\/strong>, add your <strong>Callback URL<\/strong> and <strong>Verify Token<\/strong> and <strong>Verify &amp; Save<\/strong>.<\/li>\n\n\n\n<li>Subscribe to <strong>message<\/strong> and <strong>status<\/strong> events; use the \u201cSend test\u201d button to check delivery to your endpoint. (, , )<\/li>\n<\/ol>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>Tip (verification): your endpoint must echo back the <code>hub.challenge<\/code> when it receives the GET verification call. After saving, you\u2019ll start receiving JSON webhooks for inbound messages, delivery\/read receipts, and errors. ()<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">8) Create <strong>Message Templates<\/strong> (Marketing \/ Utility \/ Authentication)<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Create in <strong>WhatsApp Manager<\/strong> or via the <strong>Business Management API<\/strong>; wait for approval.<\/li>\n\n\n\n<li>You\u2019ll reference templates by <strong>name<\/strong> (+ language) when sending. (, )<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">9) Understand 2026 <strong>pricing<\/strong> &amp; free windows (so your flows are cost-efficient)<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>As of <strong>July 1, 2026<\/strong>, Meta charges <strong>per delivered message<\/strong> for <strong>template<\/strong> categories (Marketing, Utility, Authentication) with <strong>country-based rate cards<\/strong> and <strong>volume tiers<\/strong> (discounts for Utility &amp; Authentication).<\/li>\n\n\n\n<li><strong>Service<\/strong> replies during the <strong>24-hour customer service window<\/strong> are free; <strong>Utility<\/strong> templates sent inside that window are free.<\/li>\n\n\n\n<li><strong>Free Entry Point (FEP):<\/strong> Messages are <strong>free for 72 hours<\/strong> when the user comes from <strong>Click-to-WhatsApp Ads<\/strong> or <strong>Page CTA<\/strong> and you reply within 24h. (, )<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">10) Send your first message (from your backend)<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\">cURL (text message)<\/h3>\n\n\n<pre class=\"wp-block-code\" aria-describedby=\"shcb-language-1\" data-shcb-language-name=\"PHP\" data-shcb-language-slug=\"php\"><span><code class=\"hljs language-php\">curl -X POST <span class=\"hljs-string\">\"https:\/\/graph.facebook.com\/v19.0\/PHONE_NUMBER_ID\/messages\"<\/span> \n  -H <span class=\"hljs-string\">\"Authorization: Bearer YOUR_PERMANENT_ACCESS_TOKEN\"<\/span> \n  -H <span class=\"hljs-string\">\"Content-Type: application\/json\"<\/span> \n  -d <span class=\"hljs-string\">'{\n    \"messaging_product\":\"whatsapp\",\n    \"to\":\"&lt;E164_RECIPIENT&gt;\",\n    \"type\":\"text\",\n    \"text\":{\"body\":\"Hello from the WhatsApp Cloud API!\"}\n  }'<\/span>\n<\/code><\/span><small class=\"shcb-language\" id=\"shcb-language-1\"><span class=\"shcb-language__label\">Code language:<\/span> <span class=\"shcb-language__name\">PHP<\/span> <span class=\"shcb-language__paren\">(<\/span><span class=\"shcb-language__slug\">php<\/span><span class=\"shcb-language__paren\">)<\/span><\/small><\/pre>\n\n\n<p>Use <strong><code>\/{PHONE_NUMBER_ID}\/messages<\/code><\/strong>; same endpoint for text, media, interactive, or template sends. ()<\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>Prefer testing with Meta\u2019s <strong>official Postman collection<\/strong>\u2014it has ready-made calls for send, template, media, etc. ()<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">11) Handle delivery, read, and errors (webhooks)<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Update your DB on <strong>sent \/ delivered \/ read \/ failed<\/strong>; implement retries with backoff for transient errors (e.g., throughput 130429).<\/li>\n\n\n\n<li>Keep webhook response times <strong>fast<\/strong> (&lt;200 ms) to avoid drops. (, )<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">12) Go from test to production<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>After <strong>business verification<\/strong>, <strong>display name<\/strong> approval, and <strong>approved templates<\/strong>, you can send to any <strong>opt-in<\/strong> user (not just test recipients).<\/li>\n\n\n\n<li>Remove test tokens and use the <strong>system user<\/strong> token in production. ()<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h1 class=\"wp-block-heading\">Compliance &amp; policy must-dos<\/h1>\n\n\n\n<h2 class=\"wp-block-heading\">Opt-in &amp; content rules<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>You must have <strong>clear user opt-in<\/strong> (on your site\/app, form, or chat) and follow WhatsApp\u2019s <strong>Business Messaging Policy<\/strong>. Store consent (time\/IP\/method).<\/li>\n\n\n\n<li>Respect the <strong>template categories<\/strong> and avoid spammy content; users can block\/report\u2014low quality hurts your limits. ()<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Rate limits &amp; messaging limits<\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Throughput:<\/strong> Cloud API supports <strong>~80 messages\/sec per number<\/strong> by default; eligible accounts auto-upgrade up to <strong>1,000 mps<\/strong>.<\/li>\n\n\n\n<li><strong>Messaging limits (by phone number):<\/strong> new numbers start low (e.g., 250\/1k), and scale to <strong>10k \u2192 100k \u2192 unlimited<\/strong> based on quality &amp; volume. ()<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h1 class=\"wp-block-heading\">Minimal production architecture<\/h1>\n\n\n\n<p><strong>Client (web\/app)<\/strong> \u2192 <strong>Your Backend API<\/strong> (stores token, picks template, logs send) \u2192 <strong>Meta Graph API (Cloud API)<\/strong><br><strong>Meta Webhooks<\/strong> \u2192 <strong>Your Backend Webhook<\/strong> (updates message status, triggers retries, analytics). ()<\/p>\n\n\n\n<p><strong>Key objects to store<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>waba_id<\/code>, <code>phone_number_id<\/code>, <code>display_name<\/code>, <code>permanent_access_token<\/code><\/li>\n\n\n\n<li>Templates (<code>name<\/code>, <code>category<\/code>, <code>language<\/code>, <code>status<\/code>)<\/li>\n\n\n\n<li>Messages (<code>to<\/code>, <code>template\/text<\/code>, <code>meta_message_id<\/code>, <code>status<\/code>, <code>error_code<\/code>)<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h1 class=\"wp-block-heading\">Common pitfalls &amp; fixes<\/h1>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Webhook verification fails<\/strong> \u2192 ensure you echo <code>hub.challenge<\/code> exactly and verify token matches the one configured. ()<\/li>\n\n\n\n<li><strong>130429 throughput reached<\/strong> \u2192 you\u2019re sending too fast; throttle below 80 mps or request\/qualify for higher tiers. ()<\/li>\n\n\n\n<li><strong>Template rejected<\/strong> \u2192 align with policy; avoid promotional content in Utility\/Auth; include sample variables. ()<\/li>\n\n\n\n<li><strong>Display name not showing<\/strong> \u2192 confirm <strong>display name approved<\/strong> and number in <strong>Connected<\/strong> state in WhatsApp Manager. ()<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h1 class=\"wp-block-heading\">Optional, money-saving add-ons (direct with Meta)<\/h1>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Click-to-WhatsApp Ads \/ Page CTA<\/strong> to trigger <strong>72-hour free<\/strong> messaging windows (great for onboarding &amp; flows).<\/li>\n\n\n\n<li>Use <strong>Service + Utility (inside CSW)<\/strong> wherever possible; reserve <strong>Marketing<\/strong> for necessary promos. (, )<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<h2 class=\"wp-block-heading\">Quick checklist <\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Create <strong>Meta App<\/strong> &amp; <strong>add WhatsApp<\/strong> product. ()<\/li>\n\n\n\n<li>Ensure <strong>WABA<\/strong> exists in <strong>WhatsApp Manager<\/strong>. ()<\/li>\n\n\n\n<li>Complete <strong>Business Verification<\/strong>. ()<\/li>\n\n\n\n<li>Submit <strong>Display Name<\/strong> for approval. ()<\/li>\n\n\n\n<li><strong>Add\/migrate phone number<\/strong> \u2192 get <strong>Phone Number ID<\/strong>. ()<\/li>\n\n\n\n<li>Create <strong>System User<\/strong> &amp; <strong>generate permanent token<\/strong>. ()<\/li>\n\n\n\n<li>Build &amp; verify <strong>Webhook<\/strong>; subscribe to events. ()<\/li>\n\n\n\n<li><strong>Create templates<\/strong> (Marketing\/Utility\/Auth) &amp; get approval. ()<\/li>\n\n\n\n<li><strong>Send test message<\/strong> via <code>\/{PHONE_NUMBER_ID}\/messages<\/code>. ()<\/li>\n\n\n\n<li>Go <strong>live<\/strong> (respect pricing windows &amp; limits). ()<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\">\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Short &amp; clear<\/h3>\n\n\n\n<ol class=\"wp-block-list\">\n<li>WhatsApp Cloud API: Direct Integration with Meta (2026)<\/li>\n\n\n\n<li>Send WhatsApp Messages Directly via Meta (No BSP)<\/li>\n\n\n\n<li>WhatsApp Business Platform: End-to-End Setup Guide<\/li>\n\n\n\n<li>Meta WhatsApp Cloud API: Step-by-Step for Apps &amp; Websites<\/li>\n\n\n\n<li>WhatsApp Business Messaging: Direct Meta Setup<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">Step-by-step \/ how-to<\/h3>\n\n\n\n<ol start=\"6\" class=\"wp-block-list\">\n<li>How to Enable WhatsApp Messaging Directly with Meta (Cloud API)<\/li>\n\n\n\n<li>From Zero to Live: WhatsApp Business Cloud API Setup (2026)<\/li>\n\n\n\n<li>Implement WhatsApp Messaging in Your App\u2014No Third-Party Needed<\/li>\n\n\n\n<li>WhatsApp Business Platform Setup: Templates, Webhooks, Tokens &amp; Go-Live<\/li>\n\n\n\n<li>Direct WhatsApp Messaging with Meta: A Complete Developer Guide<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">Business\/India-focused<\/h3>\n\n\n\n<ol start=\"11\" class=\"wp-block-list\">\n<li>Cheapest Path to WhatsApp Messaging in India: Go Direct with Meta<\/li>\n\n\n\n<li>Scale WhatsApp Messaging for SMBs &amp; Enterprises\u2014Direct with Meta<\/li>\n\n\n\n<li>Meta WhatsApp Cloud API for OTP, Alerts &amp; Marketing (India Guide)<\/li>\n\n\n\n<li>Enterprise-Ready WhatsApp Messaging: Direct Integration Blueprint<\/li>\n\n\n\n<li>WhatsApp Business Messaging Compliance &amp; Setup (No BSP)<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\">Premium\/evergreen<\/h3>\n\n\n\n<ol start=\"16\" class=\"wp-block-list\">\n<li>The Definitive Guide to Meta\u2019s WhatsApp Business Platform (2026)<\/li>\n\n\n\n<li>Production-Ready WhatsApp Cloud API: Architecture, Limits, Pricing<\/li>\n\n\n\n<li>WhatsApp Messaging via Meta: Secure, Scalable, and Cost-Efficient<\/li>\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>You can do this directly with Meta\u2019s WhatsApp Business Platform (Cloud API) from your own app\/website. Below is a complete, no-BSP, end-to-end checklist you can follow. I\u2019ve included short code&#8230; <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_joinchat":[],"footnotes":""},"categories":[2],"tags":[],"class_list":["post-52335","post","type-post","status-publish","format-standard","hentry","category-uncategorised"],"_links":{"self":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/52335","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/comments?post=52335"}],"version-history":[{"count":3,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/52335\/revisions"}],"predecessor-version":[{"id":59577,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/posts\/52335\/revisions\/59577"}],"wp:attachment":[{"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/media?parent=52335"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/categories?post=52335"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.devopsschool.com\/blog\/wp-json\/wp\/v2\/tags?post=52335"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}