# WhatsApp campaign

Campaigns can be found in a separate section in the main sidebar under the "megaphone" icon.&#x20;

## Preparing contacts for the campaign

Before setting up a campaign, you need to prepare a list of contacts that will be used in the campaign.

These contacts are already included in the [Contact Directory](https://docs.mluvii.com/en/for-administrators/tenant-management/contact-directory), or you can import them using the **"Upload CSV"** button. Here you select the CSV file with the contacts and in the next step, you **map the columns contained in the CSV file to existing columns** in the Contact Directory (client's name, client's email, client's phone number, etc.).

{% hint style="info" %}
*In the next step, it's useful to **create a filter that allows you to select only a limited set of contacts to be sent a WhatsApp message for the campaign.***
{% endhint %}

{% hint style="success" %}
*Use the filter button to apply one of the existing filters or create a new filter.*
{% endhint %}

{% hint style="info" %}
*These filters can also be created when setting up a campaign when it is assumed that the Contacts Directory already contains contacts.*
{% endhint %}

## Create a campaign

To create a campaign, you need to click on the "**+ Create Campaign**" button, then select the **"WhatsApp"** type and enter a campaign name.

Next, select from the menu:&#x20;

* WhatsApp account (phone number)&#x20;
* Form (template message)&#x20;
* Language (if more than one)

{% hint style="info" %}
*You can also add a note to your campaign for better clarity.*
{% endhint %}

{% hint style="warning" %}
*The volume of messages sent is limited to a 24-hour window and may change over time. More information can be found here.*
{% endhint %}

{% hint style="success" %}
*To make sure you are always selecting from the current list of Meta-approved templates, we recommend always syncing the available forms using the **Synchronize Forms** button.*
{% endhint %}

{% hint style="danger" %}
*The status of each form may change over time (e.g. a form may be blocked, or the number of usable languages may change).*

*You can check the current status in the* [*Forms*](https://docs.mluvii.com/en/for-administrators/tenant-management/settings/forms) *section. You can see the details of the problems with a particular form by hovering over the warning icon. Most often this is unselected multimedia content (image, video), which can be solved in Forms, where you select the missing file for each language.*
{% endhint %}

## Adding contacts to a campaign

You can add contacts to a campaign in two ways:

### A) From the Contact Directory (via a previously created filter)

In addition to the filter mentioned above, you also select the **parameter from which the clients' phone numbers will be uploaded.** Following the selected template, you additionally select the **parameters** that are used to add dynamic values **(unique for each contact)**.&#x20;

{% hint style="info" %}
*In order not to send an empty value to the customer by mistake, you have the option to define a **default value** that will be used in case the **uploaded .csv file or contact in the contact directory does not contain any value.***
{% endhint %}

### B) By using a .csv file

{% hint style="success" %}
*We recommend using the prepared blank template, which you can download via the link that appears after clicking on the **Upload CSV option**.*
{% endhint %}

{% hint style="info" %}
*The order of the loaded columns in the .csv file affects which dynamic variables the column values appear.*\
\
Let's explain it with an example: We send a template: \
\&#xNAN;**"Hello, \[ ] \[ ], your order No. \[ ] has been processed."**

\
The CSV file contains columns:&#x20;

Client's phone number Address (Mr., Mrs.) Name

* Client's phone number
* Address (Mr., Mrs.)&#x20;
* Name
* Order number

**As you can see, the order of the columns is important!**
{% endhint %}

## WhatsApp campaign management

The operation of a WA campaign (starting, pausing, ending, or uploading contacts) is no different from a [telephone campaign](https://docs.mluvii.com/en/for-administrators/tenant-management/campaigns/telephone-campaign).

{% hint style="warning" %}
*Unlike traditional phone campaigns, WhatsApp uses configurable Template Messages. If you choose a* [*Template Message*](https://docs.mluvii.com/en/for-administrators/tenant-management/settings/whatsapp/template-messages) *for your campaign that contains dynamic variables, don't forget to add columns with the corresponding data to the uploaded .CSV file. Alternatively, the related columns must exist in the* [*Contact Directory*](https://docs.mluvii.com/en/for-administrators/tenant-management/contact-directory)*!*
{% endhint %}

{% hint style="info" %}
*Uploaded contacts can take on the following states:*

* *Initial - initial state immediately after uploading the contact*
* *In progress -* [*Template Message*](https://docs.mluvii.com/en/for-administrators/tenant-management/settings/whatsapp/template-messages) *is being sent*
* *Sent - the message has been sent*
* *Delivered - the message has been delivered*
* *Read - the message has been read by the client*
* *Retry scheduled - the message will be sent again see the time in the "Next attempt" column*
* *Error - message failed to send 3 times (no further attempts)*
* *Invalid record - the phone number of the uploaded contact does not have the usual parameters*
* *Sending failed - technical problems on the provider's side*
* *Canceled by admin - the campaign was terminated and the message was not sent to selected contacts*
  {% endhint %}
