wakit
WhatsApp

WhatsApp setup

Connect wakit to the WhatsApp Cloud API via a Meta App.

Each wakit deployment requires its own dedicated Meta App. You cannot share a Meta App between multiple deployments.

1. Create a Meta App

  1. Go to developers.facebook.com/apps
  2. Click Create App
  3. Select: Use case → Connect with customers through WhatsApp, App type → Business
  4. Add the WhatsApp product

2. Create a system user

  1. Go to Meta Business Suite > Settings > System users
  2. Add an admin system user
  3. Copy the IDMETA_SYSTEM_USER_ID
  4. Assign your app with full control
  5. Generate a token with permissions:
    • business_management
    • whatsapp_business_messaging
    • whatsapp_business_management
  6. Copy the Access TokenMETA_SYSTEM_USER_ACCESS_TOKEN

3. Get app credentials

In the App Dashboard > App settings > Basic:

  • App IDMETA_APP_ID
  • App secretMETA_APP_SECRET

4. Configure the webhook

In the App Dashboard > WhatsApp > Configuration:

  • Callback URL: https://{SUPABASE_PROJECT_ID}.supabase.co/functions/v1/whatsapp-webhook
  • Verify token: choose a secure value → WHATSAPP_VERIFY_TOKEN
  • Click Verify and save

Subscribe to these webhook fields:

  • messages
  • account_update
  • history
  • smb_message_echoes
  • smb_app_state_sync

5. Set Edge Function secrets

Add these secrets in Supabase > Edge Functions > Secrets:

SecretValue
META_APP_IDYour App ID
META_APP_SECRETYour App Secret
META_SYSTEM_USER_IDSystem User ID
META_SYSTEM_USER_ACCESS_TOKENSystem User Token
WHATSAPP_VERIFY_TOKENYour chosen verify token

6. Configure Facebook Login for Business

For Embedded Signup to work:

  1. In the App Dashboard, go to Facebook Login for Business > Configurations
  2. Create a new configuration: WhatsApp Embedded Signup
  3. Note the Configuration ID → used as VITE_FB_LOGIN_CONFIG_ID in the UI
  4. Go to Facebook Login for Business > Settings:
    • Enable Login with the JavaScript SDK
    • Add your domain to Allowed Domains for the JavaScript SDK

7. App Review

For production use, request Advanced Access for:

  • whatsapp_business_management
  • whatsapp_business_messaging

Your Meta Business must be verified first. Submit via Review > App Review in the App Dashboard.

On this page