Skip to main content

Configuration

After installing and activating the WhatsApp Cloud API Chat & Marketing module, you need to configure the connection between Perfex CRM and the Meta WhatsApp Cloud API. This involves setting up a Meta Application, generating API credentials, configuring webhooks, and adjusting module settings.

Meta Application Configurationโ€‹

The WhatsApp Cloud API is accessed through a Meta (Facebook) App. If you haven't created one yet, follow these steps.

Step 1 โ€” Create a Facebook Developers Accountโ€‹

  1. Go to developers.facebook.com.
  2. Log in with your Facebook account.
  3. If prompted, register as a developer by accepting the terms and verifying your account.

Step 2 โ€” Create a Meta Appโ€‹

  1. In the Facebook Developers dashboard, click Create App.
  2. Select Business as the app type (or Other if Business is unavailable for your account type).
  3. Enter an App Name (e.g., "Perfex CRM WhatsApp") and your contact email.
  4. Select your Business Account (or create one if needed).
  5. Click Create App.

Step 3 โ€” Add WhatsApp to Your Appโ€‹

  1. On your new app's dashboard, find WhatsApp in the product list and click Set Up.
  2. Follow the guided setup to link a WhatsApp Business Account.
  3. A test phone number is automatically provided for development. You can add your own verified business phone number later.
info

The test phone number allows you to send messages to up to 5 pre-registered numbers. For production use, add and verify your own business phone number in the WhatsApp Business Account settings.

Step 4 โ€” Generate a Permanent Access Tokenโ€‹

The default temporary token expires after 24 hours. For production, generate a permanent System User token:

  1. Go to business.facebook.com and navigate to Business Settings > System Users.
  2. Create a new System User (or use an existing one) with Admin access.
  3. Click Generate New Token, select your WhatsApp app, and grant the following permissions:
    • whatsapp_business_messaging
    • whatsapp_business_management
  4. Copy the generated token โ€” this is your permanent access token.
warning

The permanent token is displayed only once. Store it securely. If lost, you will need to generate a new one and update your module settings.

Webhook Configurationโ€‹

Webhooks allow WhatsApp to notify your Perfex CRM instance of incoming messages, delivery receipts, and status updates in real time.

Setting Up the Webhookโ€‹

  1. In the Facebook Developers dashboard, go to your app's WhatsApp > Configuration page.
  2. Under Webhook, click Edit.
  3. Enter the Callback URL provided by the module (found in WhatsApp Module > Settings in Perfex CRM). It typically follows this format:
    https://your-perfex-domain.com/whatsapp_cloud_api/webhook
  4. Enter the Verify Token displayed in the module settings.
  5. Click Verify and Save.
  6. Subscribe to the following webhook fields:
    • messages
    • message_template_status_update
tip

Your Perfex CRM installation must be served over HTTPS with a valid SSL certificate. Meta will reject webhook URLs that use HTTP or have invalid/self-signed certificates.

Module Settingsโ€‹

After completing the Meta App setup, configure the module within Perfex CRM.

  1. Navigate to the WhatsApp Cloud API module in the Perfex CRM sidebar.
  2. Go to Settings and enter the following:
SettingDescription
Access TokenThe permanent System User token generated above
Phone Number IDFound in your Meta App's WhatsApp > Getting Started page
WhatsApp Business Account IDFound in your Meta App's WhatsApp settings
Webhook Verify TokenA custom string you define โ€” must match what you entered in the Meta webhook setup
App IDYour Meta App's ID (found on the app dashboard)
  1. Click Save Settings.
  2. Use the Test Connection button to verify that the module can communicate with the WhatsApp Cloud API.

Embed Configurationโ€‹

For advanced setups, the module supports embedding the WhatsApp chat widget on external pages or client portals. Navigate to WhatsApp Module > Settings > Embed to generate an embed code snippet and customize the widget appearance (colors, position, welcome message).

Business Verificationโ€‹

To unlock full messaging capacity and access to all template categories, complete your Meta Business verification:

  1. Go to business.facebook.com > Business Settings > Security Center.
  2. Click Start Verification and follow the guided process.
  3. Submit your business documents as requested by Meta.
  4. Verification typically takes 2-5 business days.
info

Without business verification, your messaging is limited to 250 unique recipients per 24-hour rolling window. After verification, limits increase progressively based on message quality and volume.

What's Next?โ€‹

  • Usage Guide โ€” learn how to use the chat interface, run campaigns, configure bots, and manage templates
  • WhatsApp Logs โ€” view comprehensive records of all automated interactions