Post on 04-Aug-2021
description
WhatsApp Notifications for Magento 2 © Meetanshi
WhatsApp Notifications for Magento 2
User Guide
Table of Content
1. Extension Installation Guide
2. Twilio Registration
3. Configuration
4. Creating Twilio Message Templates
5. Order Placement Notification Settings
6. Order Invoice Notification Settings
7. Order Cancellation Notification Settings
8. Order Shipment Notification Settings
9. Credit Memo Notification Settings
10. Contact Inquiry Notification Settings
11. New Customer Registration Notification Settings
12. WhatsApp Notifications in Frontend
WhatsApp Notifications for Magento 2 © Meetanshi
1. Extension Installation • For Magento Marketplace Customers
o Create a folder structure in Magento root as app/code/Meetanshi/Wnotification
o Download and extract the zip folder and upload our extension files to the
app/code/Meetanshi/Wnotification via FTP.
o Login to your SSH and run below commands step by step:
▪ composer require twilio/sdk
▪ php bin/magento setup:upgrade ▪ For Magento version 2.0.x to 2.1.x - php bin/magento setup:static-content:deploy
▪ For Magento version 2.2.x & above - php bin/magento setup:static-content:deploy –f
▪ php bin/magento cache:flush
• For Meetanshi Customers
o Extract the zip folder and upload our extension to the root of your Magento 2 directory via
FTP.
o Login to your SSH and run below commands step by step:
▪ composer require twilio/sdk
▪ php bin/magento setup:upgrade
▪ For Magento version 2.0.x to 2.1.x - php bin/magento setup:static-content:deploy
▪ For Magento version 2.2.x & above - php bin/magento setup:static-content:deploy –f
▪ php bin/magento cache:flush
Note: Don’t forget to install Twilio library else our extension will not work.
2. Twilio Registration To use Twilio as a gateway to send WhatsApp notifications, you need to register with the Twilio
to get Account SID, Auth Token and Twilio Phone Number. • First of all, Sign Up for the Twilio account. Add the details and click to get started.
WhatsApp Notifications for Magento 2 © Meetanshi
• After the Email verification, enter your mobile number and click to “Verify”.
• Once you click “Verify”, you will get an OTP on the added mobile number. Enter the OTP and
verify the mobile number. Now move to Settings → General where you can see API details
both for live and testing. Copy the Account SID and Auth Token to use them in Magento 2
backend configuration for Twilio account.
WhatsApp Notifications for Magento 2 © Meetanshi
• Now, click three dots from the left sidebar, go to Programmable SMS and click Build under the
Learn and Build option. From here, you can get Twilio phone number to use for sending the
SMSs. Click on the “Get a number” button.
• You will get a number to choose. Click “Choose This Number”.
• Once you click the button, you will get a Twilio phone number. Copy this number and set it in
the Magento 2 backend configuration for Twilio account.
WhatsApp Notifications for Magento 2 © Meetanshi
3. Configuration To configure the extension, log in to Magento backend, move to Stores → Configuration →
WhatsApp Notifications where you can find various settings to configure the extension.
• WhatsApp Notifications: Enable or disable the WhatsApp Notifications extension.
• Admin Mobile Number: Enter mobile number of admin to receive the WhatsApp
Notifications.
4. API Settings The extension provides integration with the Twilio 3rd party API. Register with Twilio, buy
WhatsApp message credits, get API details to configure the API settings.
• API Provider: Select the API provider Twilio.
• Twilio SID: Enter Twilio SID received while registration with Twilio.
• Twilio Token: Enter Twilio token received while registration with Twilio.
• Twilio Number: Enter Twilio number received while registration with Twilio.
WhatsApp Notifications for Magento 2 © Meetanshi
5. Creating Twilio Message Templates Once you configure the extension, login to your Twilio account, go to
https://www.twilio.com/console/sms/whatsapp/senders/, and click the "plus" button to create
your first Business Profile. Complete the form and submit your WhatsApp Business Profile
request along with message templates.
Note: All Display Names must show consistency with the Business Name on the Facebook Business
Manager provided. See Display Name rules.
Twilio will use this information to provision your Business Profile in the next 5-10 business days.
Once your WhatsApp Sender is approved and enabled, you can see your WhatsApp number with
the approved status.
Under the “Message Templates” option, click + sign to add new message templates. Make use of
variables to add the message text same as Magento backend. Follow this guide to write the message
template in a proper format.
WhatsApp Notifications for Magento 2 © Meetanshi
6. Order Placement Notification Settings
The module allows to send WhatsApp notifications to both the admin and customers when they
place the order. To configure its settings, follow these steps as shown below:
• Order Placement Notification: Enable order placement notification to customers.
• WhatsApp Notification Text for Customers: Enter the order placement notification text to
send to customers.
• Order Placement Notification to Admin: Enable order placement notification to admin.
• WhatsApp Notification Text for Admin: Enter order placement notification text to send to
the admin.
WhatsApp Notifications for Magento 2 © Meetanshi
7. Order Invoice Notification Settings
You can send WhatsApp notification to customers as well as admin to let them know that the
Order Invoice is generated once the following settings are configured:
• Order Invoice Notification: Enable order invoice notification to customers.
• WhatsApp Notification Text for Customers: Enter the order invoice notification text to
send to customers.
• Order Invoice Notification to Admin: Enable order invoice notification to admin.
• WhatsApp Notification Text for Admin: Enter order invoice notification text to send to the
admin.
WhatsApp Notifications for Magento 2 © Meetanshi
8. Order Cancellation Notification Settings
To let customers know that their order has been cancelled successfully, a WhatsApp
Notifications is sent. Additionally, admin is also notified of a cancelled order. Follow these steps
for the same:
• Order Cancellation Notification: Enable order cancellation notification to customers.
• WhatsApp Notification Text for Customers: Enter the order cancellation notification text to
send to customers.
• Order Cancellation Notification to Admin: Enable order cancellation notification to admin.
• WhatsApp Notification Text for Admin: Enter order cancellation notification text to send to
the admin.
WhatsApp Notifications for Magento 2 © Meetanshi
9. Order Shipment Notification Settings
Customers get notifications when their shipment is off for delivery. Admin is also notified for the
same. This feature will be enabled when the following settings are configured:
• Order Shipment Notification: Enable order shipment notification to customers.
• WhatsApp Notification Text for Customers: Enter the order shipment notification text to
send to customers.
• Order Shipment Notification to Admin: Enable order shipment notification to admin.
• WhatsApp Notification Text for Admin: Enter order shipment notification text to send to
the admin.
WhatsApp Notifications for Magento 2 © Meetanshi
10. Credit Memo Notification Settings
To confirm with customers that their refund request has been accepted, a WhatsApp
notification will be sent to customers. Similarly, admin will be sent a WhatsApp Notification
when a credit memo is generated. Configure the following settings to enable this feature.
• Order Credit Memo Notification: Enable order credit memo notification to customers.
• WhatsApp Notification Text for Customers: Enter the order credit memo notification text
to send to customers.
• Order Credit Memo Notification to Admin: Enable order credit memo notification to
admin.
• WhatsApp Notification Text for Admin: Enter order credit memo notification text to send
to the admin.
WhatsApp Notifications for Magento 2 © Meetanshi
11. Contact Inquiry Notification Settings Admin is notified whenever there is a new contact inquiry. To enable this feature, configure
following settings:
• Contact Inquiry Notification: Enable new contact inquiry notification to admin.
• WhatsApp Notification Text for Admin: Enter contact inquiry notification text to send to
the admin.
12. New Customer Registration Notification Settings The admin is notified when a new customer registration takes place. To enable this notification,
following settings are to configured:
• New Customer Registration Notification: Enable new customer registration notification to
admin.
• WhatsApp Notification Text for Admin: Add new customer registration notification text to
send to admin.
WhatsApp Notifications for Magento 2 © Meetanshi
13. WhatsApp Notifications in Frontend
• New Registration WhatsApp Notification to Admin
When a customer registers a new account, admin is notified as shown below:
• New Order Placement WhatsApp Notification to Customers
A notification of acknowledgement of the order placement is sent to customers as shown
here:
WhatsApp Notifications for Magento 2 © Meetanshi
• New Order Placement WhatsApp Notification to Admin
Admin is notified when a new order is placed in the store as shown below:
• Order Invoice Generation WhatsApp Notification to Customers
When an Order Invoice is generated, a notification as shown below is sent to customers.
WhatsApp Notifications for Magento 2 © Meetanshi
• Order Invoice Generation WhatsApp Notification to Admin
When an Order Invoice is generated, a notification is sent to Admin as shown here:
• Order Shipment WhatsApp Notification to Customer
Customers get notified at the time of order shipment via WhatsApp as shown below:
WhatsApp Notifications for Magento 2 © Meetanshi
• Order Shipment WhatsApp Notification to Admin
Once the order gets shipped and shipment is generated, admin gets notified.
• Refund Request WhatsApp Notification to Customer
A customer gets notified of refund request approval as shown below:
WhatsApp Notifications for Magento 2 © Meetanshi
• Credit Memo Generation WhatsApp Notification to Admin
Credit memo generation notification sent to admin as shown below:
• New Contact Inquiry WhatsApp Notification to Admin
Whenever a customer inquires through submitting the contact form, admin is notified as
below: