Using the JUNE x Magento integration, you can link both tools together.
The integration has two main functionalities:
Synchronize Newsletter Signups
1. Preparations in JUNE
To synchronize newsletter subscriptions to/from Magento, you first create an email list in JUNE.
Here you can learn how to create email lists.
To enable opt-in in Magento, you need to create a field in the JUNE list.
In the upper bar, go to Settings.
Click on Create Field. A new menu window will open.
Type in the following information.
Technical name: confirmation_code
Type: Text
Optionally, you can add more fields to store more information from Magento:
The first name of the subscriber
Technical name: firstname
Type: Text
The last name of the subscriber
Technical name: lastname
Type: Text
The store language
Technical name: locale
Type: Text
The store code
Technical name: store_code
Type: text
The website ID
Technical name: website_id
Type: Text
The subscription ID
Technical name: subscription_id
Type: Text
Once the fields are created, click API in the top bar and note the Collect Token, List ID and API Token.
2. Setup in Magento
After you have installed the Magento module, go to the configuration menu of Magento and enter the previously noted values from JUNE into the appropriate fields.
For Basic Authentication, think of a username and password and write down your data. These credentials will be needed later to transfer logins and logouts in JUNE to Magento.
As soon as the data is entered and the module is activated, new logins will be transferred to JUNE.
3. Add Synchronization in JUNE
To transfer the information from JUNE to Magento, you need to create three Journeys in JUNE's Workflow Builder that communicate with Magento.
You get to the Workflow Builder by clicking Actions in the top bar within an email list.
User is added to the email list
In the Workflow Builder, click Create Action.
Click on the Action User is added to email list.
Now you will see a Journey field. Click Add Service and select Integration.
Under Executing custom integration, select Magento 2 Subscriber Sync.
Below that, enter the required information (store URL, username, password).
Don't forget to save your entries.
User subscribes to the email list
In the Workflow Builder, click Create Action.
Click on the Action User subscribes.
Now you will see a Journey field. Click Add Service and select Integration.
Under Executing custom integration, select Magento 2 Subscriber Sync.
Below that, enter the required information (store URL, username, password).
Don't forget to save your entries.
User unsubscribes from the email list
In the Workflow Builder, click Create Action.
Click on the Action User unsubscribes.
Now you will see a Journey field. Click Add Service and select Integration.
Under Executing custom integration, select Magento 2 Subscriber Sync.
Below that, enter the required information (store URL, username, password).
Don't forget to save your entries.
Now all logins and logouts are transferred from JUNE to Magento. Your integration now communicates in both directions and the data updates immediately in both systems.
Service Mails
1. Preparations in JUNE
To send service mails via JUNE, you need to create a new list with the type Unstructured List.
Add four mandatory fields to store the necessary information from Magento
Go to Settings in the upper bar.
Click on Create Field. A new menu window will open.
Type in the following information.
Technical name: action_type
Type: Text
Repeat the process for the following fields:
Technical name: recipient_email
Type: Text
Technical name: user_data
Type: Object
Technical name: content_data
Type: object
Additionally, information about the Magento store (useful for multi-store setups) and products can be stored for order confirmations.
Add the following optional fields for this purpose:
Technical name: store_data
Type: Object
Technical name: product_data
Type: Object
Then go to the API tab at the top and note the Collect Token and the API Token. This information is needed for the Magento module.
2. Set up the Magento module
After you have installed the Magento module, go to the configuration menu of Magento and enter the previously noted API token in the appropriate field.
In the settings area below, you can now add and select multiple Magento emails to be processed by JUNE. These emails will no longer be sent by Magento from that point on and will be passed to JUNE instead.
For each selected email template, enter the Collect Token of the previously noted JUNE list.
All selected email templates will be passed to this list. If you want to separate the emails in JUNE to improve clarity, it is a good idea to create several lists in JUNE using the same principle and distribute the corresponding List Tokens to the email templates.
Our recommendation is to use different lists at least for user and order emails.
3. Set Email Sending in JUNE
Once the data arrives in the JUNE list, the emails can be created. Here is some information about the stored fields:
action_type: This is where the name of the Magento template is stored. With the help of the action type, you can distinguish the different types of service emails.
user_data: Here more information of the user (if available) and recipient addresses for the CC / BCC mailing (if set), are stored.
content_data: Contains the variables that Magento provides for the corresponding emails. For an order, all order information is stored here. For a user login, the activation link is stored here.
store_data: Information about the store from which the email was created is stored here. Both the URL of the store and the store code, website ID and locale used can be read here to create different emails in a multi-store setup.
product_data: Contains a clean list of all used product SKUs in a mail.
Build Workflows for Service Mails
Finally, you need to build a journey in JUNE's Workflow Builder. This is used to send service mails as soon as new information is saved.
You get to the Workflow Builder by clicking on Actions in the top bar within a list.
In the Workflow Builder, click Create Action.
Click on the action Data item is added to the list.
Set a condition depending on the type of service mail. To do this, click Add Condition and select Custom Segmentation. Create a rule using the action_type for the email you want to automate. For example, if you want to send a service mail for order confirmations, specify the corresponding action type here.
Click Add Service in the Journey field and select Send Email.
Select the appropriate Email to be used for sending and customize the mail if necessary.
Define the Subject Line and Sender Information.
Under Send To click Select and select the recipient_email field.
The workflow should finally look like this:
You can repeat this process for all types of service mails you need. Types of service mails are for example: Order, shipping and payment confirmation.
π§βπ» Contact & Support
Do you need help setting up an integration? Our developers are happy to help. Book your call here.