This document merges Meta configuration steps with application processes for WhatsApp Cloud API integration, including embedded login, chat module, gateway connectivity, and webhooks. Covers permanent tokens, contact management, and business phone setup.
Go to developers.facebook.com/apps.
Click "Create App".
Usage: Others
Select Type: Business.

In App Dashboard > App Settings > Basic.
Fill App ID, App Secret, Display Name, etc.
Add valid Privacy & policy page, Terms & condition page and User data deletion pages from your domain. In case you don't have any make sure to create the page from here,


Then add the App ID & App Secret here:

In Facebook Login For Business > Settings.
Enable the following:
Client OAuth login
Web OAuth login
Embedded Browser OAuth Login
Login with the JavaScript SDK
Then add the following urls according to your domain name here "Valid OAuth Redirect URIs"
https://{{your-domain}}/admin/gateway/whatsapp/cloud/api/embedded-callback
https://{{your-domain}}/user/gateway/whatsapp/cloud/api/embedded-callbackAlso add your domain here: "Allowed Domains for the JavaScript SDK"
And save changes

Now, you need to have advanced access for the following permissions to use the embedded login feature (Subject to change):

If you have set up the meta end corretcly you can now test the automatic gateway creation connecting you r facebook account and business to the platform directly with the embedded system

But if you face any difficulties you can still add the gateway manually

Make sure to fetch available templates for the gateway

After a successful fetch your templates will now be available in the system. We recommend to acquire the permanent token from Meta. Free tokens will get expired after a certain period of time.



Set Callback URL (e.g., https://yourdomain/webhook).
Verify Token (match with app's verify token).
Subscribe to fields (e.g., messages v23.0).
Use /v{version}/contacts endpoint to validate contacts (POST with phone hashes).
Retrieve phone numbers via GET /phone_numbers on WABA.
No direct list API; track via webhooks for incoming messages.
Select template, contacts and send.
Queue worker dispatches the messages
Webhook will update the status if it is added correctly.
Webhook receives incoming messages.
Display in Chats section.
Send replies via queue-worker (Make sure cron jobs or supervisors are running)
Update status via webhook callbacks.