Shopify- How to integrate with MSG91


You can integrate MSG91 with your Shopify store to send SMS, Emails, and WhatsApp to your customers via plugin on targeted conditions like when they place an order, etc. 


You can watch this video or follow the below steps.




1. Open your Shopify store. Go to the Apps section from the sidebar and search for msg91. 




2. Select MSG91from the app search results.



3. Select the Add App option. 



4. It will be added to your Shopify store. Click on the install app option to use it.



5. Now, click on the Connect option. It will ask you for the auth key of the associated msg91 account and the chat widget token. 



6. Click on Get Auth Key. It will direct you to the Authkey section of the Settings panel in your Msg91 account, only if you are logged in. Copy the auth key and paste it there. 




Note: After copy-pasting the authkey, make sure to go to the Campaign section from the MSG91 Dashboard (click on the four-squared icon available on Top-Left corner) & create a New Campaign.



7. Click on Get Token (on Shopify plugin). It will direct you to the Chat Inbox option under the Settings section of your Hello panel, only if you are logged in. Copy the widget token from the script on the right side and paste it there. 



Note: If you have multiple chat widgets, you can go to the Inbox section as before, select Chat from the dropdown, click on the Settings icon and select the Edit Widget option of the chat widget you wish to get the token of.




8. Click on Connect to MSG91 button.



9. Once the msg91 connection is established, go to the Triggers section.



10. Add a New Trigger.



11. Give the name of the trigger and select the status. In the Campaigns column, it will show you all the campaigns created in your msg91 account. Select one as per the trigger. Then select the relevant Shopify webhook as per the trigger. 



Note: Please refer to our help doc link: https://msg91.com/help/what-is-campaign-and-how-to-use-it to create a campaign on MSG91.


12. According to the steps of the campaign selected by you, enter the recipient's contact details in the To field. You can also add a custom email or phone number to it. Add CC or BCC, if required. Then map the variables specified in the campaign content with the Shopify variables and Save the trigger. You can turn the trigger on or off and also edit it.



13. Now, go to the Settings section and select the Hello tab. Enable the Chat widget option and the WhatsApp chat option for which it asks the WhatsApp number. This number should be linked in the Whatsapp section of your MSG91 account and should be shown active there.



14. Once saved, click on the view option on the online store in the sidebar to see the widget.



15. You will see an arrow at the bottom right of the page. Clicking on it will give the WhatsApp and Chat widget options.



If the widget doesn't show on the page, it might be because the MSG91 app isn't embedded in your theme. To do so, 


a. Select the Online Store option from the sidebar. Select Themes inside it and click on the Customize button on your current theme.



b. Go to Theme Settings from the bottom left corner.



c. Switch to App embeds section and turn on the MSG91 toggle if off. Save the settings.



View your page again as it should show the Chat widget and WhatsApp chat now.