WhatsApp Action

This guide shows you how to add a WhatsApp Send Text Message action to a Zaplane workflow, so a WhatsApp message is sent automatically whenever your trigger fires. You will first create a Meta app and get your WhatsApp credentials, then connect them to Zaplane and build the workflow.

Step 1: Create a Meta App

Go to Meta for Developers and log in, then click My Apps at the top right.

Create a Meta App
On the Apps page, click Create App. 
On the Apps page, click Create App
Follow the setup steps, choosing the Other use case when asked. On the details screen, enter an App name and App contact email, then click Create app. When your app opens, find WhatsApp under Available products and click Set up. 
Create app. When your app opens

Step 2: Get Your Access Token and Phone Number ID

In your app dashboard, open WhatsApp > Step 1. Try it out from the left menu. Copy your Phone Number ID and Access token (use Generate new token if you need a new one) and keep them handy for the next step. This recording also shows the Webhooks page of your Meta app, which you will use later to register your webhook.
Get Your Access Token and Phone Number ID
To use WhatsApp with real customers, also complete Step 2. Production setup and Step 3. Business verification from the same WhatsApp menu. 
To use WhatsApp with real customers

Step 3: Create the Connection in Zaplane

Go to Zaplane > Connections from your WordPress dashboard, then click Create credential.
Create the Connection in Zaplane
In the Select an app panel, choose WhatsApp. 
Select an app panel, choose WhatsApp
Paste your Access Token and Phone Number ID. The API Version field is optional, and Zaplane uses v26.0 if you leave it blank. Then click Save Connection. 
Then click Save Connection

Step 4: Create a Workflow

Go to Zaplane > Workflows from your WordPress dashboard, then click Create Workflow to open the workflow editor.

Before adding a WhatsApp action, you need to set up a trigger first. Here is how to do it quickly:

Click Select an app under the Trigger box and choose Apps.
Search for and select the app that will start your workflow (for example, Storeengine Product Purchased ).
Choose the Trigger Type that matches the event, then click Continue.
On the Configure tab, set any required options, then click Continue.
On the Test tab, click Test Trigger to confirm it works, then click Save.

Step 5: Add an Action

Click the + button next to your trigger. In the Add Action panel, choose Apps.

Add Action panel, choose Apps.

Step 6: Select the WhatsApp App

Find WhatsApp in the app list, select it, and click Continue.

Select the WhatsApp App

Step 7: Choose the Action Type and Connection

On the Select tab, open the Action Type dropdown and pick what you want WhatsApp to do. In this example we choose Send Text Message. Then open the Select Connection dropdown, choose the WhatsApp connection you created in Step 3, and click Continue.

Choose the Action Type and Connection

Step 8: Configure the Action

On the Configure tab, enter the Recipient Phone Number and the Message Body (both are required). Use the If this customer is in the Inbox dropdown to choose between Send only when workflows answer them (avoids double replies) and Always send (order updates and other notifications). Click Continue when you are done.

Configure the Action

Step 9: Test the Action

On the Test tab, click Test Action to check that WhatsApp responds as expected, then click Save.

WhatsApp responds as expected

Step 10: Update and Activate the Workflow

Back in the workflow editor, set the workflow status to Active and click Update to publish your changes. You can use Logs to review every run.

Update and Activate the Workflow

Every time your trigger fires, Zaplane now sends a WhatsApp text message automatically.

Done!

WhatsApp is now connected to your workflow, and the Send Text Message action will run automatically whenever your trigger fires.