- Introduction
- What is a Zap
- Ready to Use Zap Templates
- Add Contacts / Leads Zap
- Send Email with Mailjet Template Zap
- Send HTML Email Zap
- Send Email Campaign to a Mailjet Contact List Zap
- Parse Inbound Emails Zap
- Email Events Zap
- Troubleshooting
- Conclusion
Introduction
Zapier is an online automation tool that allows you to connect two or more apps to automate repetitive tasks – like synchronizing information between them – without coding or relying on developers to build the integration. Most importantly, workflows can be created with only a few clicks, which makes it extremely easy.
Below we will guide you through the steps to create zaps between your SugarCRM and Mailjet accounts, which we believe will help you better take advantage of both platforms’ capabilities.
What is a Zap
A zap is basically an automated task that you want run over and over again between two online apps. A zap consists of a trigger and an action:
When this happens (Trigger), do something (Action).
Once you have created your zap, Zapier will check your trigger every few minutes for new data. If the zap is triggered, Zapier will automatically perform the action! There is no involvement needed from you - your data will flow from one app to the other.
With Mailjet, you have the following Trigger options:
- Subscribe Contact to Mailjet List
- Unsubscribe Contact from Mailjet List
- Parse Inbound Email (when new email is sent to your Parse API email address)
- Email Events (when an event occurs with a Mailjet contact - send, open, click, bounce, spam, block)
And several Actions :
- Subscribe Contact to Mailjet List
- Unsubscribe Contact from Mailjet List
- Send a Plain Text Email
- Send an HTML Email
- Send Email Using a Saved Mailjet Template
- Send an Email Campaign to a Mailjet List
- Update Contact Properties (in Mailjet)
Ready to Use Zap Templates
Zapier also allows the creation of templates for commonly used zaps. They will streamline the process for you, by hiding unnecessary options and allowing you to select only the ones you need for your zap. If such a template is available, we will include it in the ‘General Information’ section of the respective zap.
Keep in mind that there will be several important differences between using the templates and the way you create a zap directly from the ‘Make a Zap!’ option on the Zapier site:
- The Trigger and Action Apps will be pre-selected for your convenience.
- Since the template has been created with a specific trigger and action in mind, all other triggers and actions will be hidden to avoid mistakes.
- During trigger and action configuration generally only mandatory options will be displayed. You can view the optional configurations by clicking on ‘Show advanced options‘.
Add Contacts / Leads Zap
General Information
One of the most commonly used Zaps when it comes to integrating a CRM service with Mailjet is to automatically add new contacts from the CRM to a Mailjet contact list.
When you create new contacts / prospects in SugarCRM, you may want to subscribe the associated emails to your different Mailjet contact lists. With Zapier you can streamline this process, saving valuable time and enabling the distribution of automated emails and marketing campaigns through Mailjet straight away.
We will now create a zap to add details for new SugarCRM Contacts to a Mailjet contact list. You can follow the exact same instructions for adding Leads to a contact list – just choose a New Lead trigger instead of New Contact.
To start, go to your Zapier account dashboard and click on ‘Make a Zap!’.
-
Enter a name for your new zap.
-
You have entered the trigger phase. Choose a trigger app by entering SugarCRM in the search bar and choosing the result.
-
Select a trigger. You need to add the details of a newly added Contact to your Mailjet contact list, so please choose ‘New Contact’ and click on ‘Save + Continue’.
-
Select a linked SugarCRM account you want to use, then click on ‘Continue’. If you don’t have a SugarCRM account linked to Zapier, or want to select a new one to use, click on ‘Create a New Account’.
For this example, we will connect a new SugarCRM account to use.
In the pop-up window enter the install / on-demand URL provided by SugarCRM, as well as your SugarCRM username and password, then click on ‘Yes, Continue’ to submit the details.
Go back to the Zapier page and you will see the new ‘SugarCRM 6.2+ #’ account. If you wish to change this default name, just click on the pencil icon and enter a new name.
Select the account and click on ‘Save + Continue’.
-
You will need to test the trigger now by pulling an existing contact from SugarCRM. Click on ‘Fetch & Continue’ to initiate the test.
-
If the test is successful, you will see the respective message. If not, click on ‘Re-test’ to try again. Once the trigger has been successfully tested, click on ‘Continue’.
Action Phase
-
You have entered the Action phase. First, enter ‘Mailjet’ in the search bar and select the result.
-
You need to choose an Action now. You want to add the newly added SugarCRM Contact to the respective Mailjet Contact List, so select ‘Subscribe Contact to Mailjet List’ and click on ‘Save + Continue’.
-
Select the Mailjet account you want to use. If no account has been registered or you want to link a different one, click on ‘Connect a New Account’.
For this example, we will add a new account by selecting the ‘Connect a New Account’ option.
In the pop-up window, add your Mailjet API Public Key (User) and Secret Key (Password). You can find this information on your Mailjet account’s API Key Management page.
Click on ‘Yes, continue’.
The new account will appear as “Mailjet Account #”. To change its name, just click on the pencil icon and enter a new one.
Select your Mailjet account and click on ‘Save + Continue’.
-
Select the Mailjet Contact List you want to use for this zap. The lists are fetched from your Mailjet account, so you need to have a Contact List already created. In case you don’t have one, you can create it in the Mailjet Contact Lists section.
-
You will now need to match the contact properties from Mailjet to information present on SugarCRM. To do this, click on the ‘Insert a field’ button to call up the drop-down menu, then select the contact detail that corresponds to the respective property.
‘Email’ is the only mandatory contact property. However, it is useful to match additional ones – e.g. Full Name, Date of Birth, Address etc. This will help you later for personalizing emails in Mailjet, or for segmentation of the contact list for marketing campaigns, for example.
In the end, you will have a result similar to the picture below.
When you are ready, click on ‘Continue’.
-
You will see the details of the pulled account matched to the Mailjet contact properties.
You can test the zap by clicking on ‘Create & Continue’. Keep in mind that this will add the pulled contact information to the Mailjet contact list. Alternatively, you can click on ‘Skip Test & Continue’. In both cases, you will be asked to ‘Finish’ the zap.
-
The only thing left is to turn on the zap by clicking on the toggle button and you are ready to go!
Combining Zaps with Mailjet Email Automation
Thanks to the Mailjet Email Automation feature, it is possible to create and manage automated workflows of emails, triggered by various events. This can be used in conjunction with zaps to send automatic emails to the email address registered with a Contact / Lead, when the Contact / Lead information is being added to a Mailjet contact list.
To do this, you need to configure a Welcome automation scenario for the respective contact list. For more information, please visit the Mailjet Email Automation Guide.
Send Email with Mailjet Template Zap
General Information
In every business it is often necessary to communicate quickly about new developments. You may need to promptly contact other partners or employees about new contacts, leads, opportunities etc. that have been added to SugarCRM. To do this automatically, you can create a zap with the ‘Send Email with Mailjet Template’ action.
You can create highly customizable templates in Mailjet using our powerful and easy-to-use drag-and-drop Email Editor tool. You can then use these templates to send automatic emails to concerned parties, whenever the Zap is triggered.
The main benefits from using Mailjet’s Email Editor templates are:
- Extremely user-friendly interface
- Variety of options to customize your emails
- Easy to collaborate between teams on template design and content
- Templates are stored in the Email Editor and can be reused for other purposes
The zap will work like this:
- You create a trigger on your SugarCRM for a certain event of your choice – e.g. a new Contact, Lead, Opportunity etc.
- You then create an action on Mailjet to ‘Send Email Using a Saved Mailjet Template’ when the respective event occurs.
Trigger Phase
- Click on ‘Make a Zap!’, choose a zap name, then for a Trigger app select SugarCRM. For reference click here.
-
Afterwards, choose the actual trigger – be it a New Contact, New Opportunity, New Lead etc. For this example we will choose a New Opportunity trigger.
-
Select the SugarCRM account you will use, then test the trigger, as usual. Click here for reference.
Action Phase
- You have entered the Action phase. Search for Mailjet in the Action App search bar and select the result.
-
Select the ‘Send Email Using a Saved Mailjet Template’ action and click on ‘Continue’.
-
Select the Mailjet account you want to use, or connect a new one. For reference click here.
-
The initial selections you need to make are the usual ones – for a Sender Address, Sender Name, Recipients and Email Subject.
-
Once you are done, you need to select a Mailjet template to use for the zap.
You will need to scroll through the list of templates, or simply use the Search menu, to find the one you need.
-
Once you have selected the template you want to use, you will be given the option to enable or disable the Template Language. You need this option turned on, if you want to personalize the email with contact properties or SugarCRM variables.
-
You can link these emails to a Campaign for better email tracking and statistics. You can link it to an existing campaign, or – using a Custom Value – create a new one to use for that purpose.
-
You can also choose an email, where you will receive any error reports connected to issues with the use of templating language within the emails.
-
Now we come to the options to personalize your email template. You can add different variables in the text of your email in order to include details relevant to the communication.
Simply choose a detail from SugarCRM that you want to include by selecting it from the drop-down menu.
You can select up to 5 variables to include in your email.
In the end you will have a selection similar to the below.
Remember – you need to add the variables to the template text in order to include the necessary information. They are defined as
{{var:var1:”default text”}}
for the first one,{{var:var2:”default text”}}
for the 2nd one etc. The “default text” can be changed to accommodate situations where there is no value for the respective variable.Here is an example of how a template will look in the Email Editor with variables included and default text added to them.
When you are ready in Zapier with your template configuration, click on ‘Continue’.
-
You will now need to test the template – you will see the details you entered, as well as the information pulled from SugarCRM for the variables you have opted to use.
Review the information and click on ‘Create & Continue’.
-
The only thing left is for you to ‘Finish’ and turn on the zap, and you are ready to go!
Send HTML Email Zap
General Information
Should you need a faster way to send an email, creating a template isn’t mandatory, you can also send plain HTML content directly from Zapier using the ‘Send HTML Email‘ action. The template will lack the customizable design of the Email Editor, but that removes the necessity of creating a template in the Email Editor in the first place, so you will be able to create your zap quickly.
Trigger Phase
To configure the trigger please follow the same steps as in the Send Email with Mailjet Template Zap.
Action Phase
- Search for and then select ‘Mailjet‘ as an Action App.
- Select the ‘Send HTML Email’ action and click on ‘Save + Continue’.
-
Afterwards select the Mailjet account you want to use, or connect a new one to Zapier. Click here for reference.
-
You will now be asked to create the email template by choosing a Sender email address, Sender name, Recipient Email address or addresses, Subject Line and email body.
You will also be able to choose a ‘Reply To’ address. This is optional, but allows you to select a different email address, where replies from recipients will be received.
You can personalize the email body or Subject field by inserting fields from SugarCRM containing important information like the name of the new Lead, contact information etc.
-
Once you are ready, click on ‘Continue’ and you will be asked to test the new template.
Click on ‘Create & Continue’, or if you wish to skip the test, select ‘Skip Test & Continue’.
-
Once you have successfully tested the zap, or skipped the test, you will need to ‘Finish’ the zap creation process.
-
All that’s left now is to turn on the zap and you are ready to go!
Send Email Campaign to a Mailjet Contact List Zap
General Information
The list of people you need to contact regarding certain developments can be ever changing. If you keep it in a contact list in your Mailjet account, you will probably find it more convenient to configure your zap to send emails to the respective contact list as a whole.
The main advantages of using a Mailjet contact list are:
- You only need to update your Mailjet contact list with the proper recipients in order to ensure that every person is added - no need to update every single Zap you’ve created whenever an email address needs to be added or removed.
- You can view your campaign stats in Mailjet to check deliverability reports and open / click rates.
Trigger Phase
To configure a trigger, please follow the same steps as in the Send Email with Mailjet Template Zap. For our example, we have again chosen the ‘New Opportunity’ trigger.
Action Phase
-
You have entered the Action phase. Search for Mailjet in the Action App search bar and select the result.
-
Select the ‘Send an Email Campaign to a List’ action and click on ‘Save + Continue’.
-
Choose a linked Mailjet account, or connect a new one that you wish to use. For reference click here.
-
You will now be asked to set up the campaign by choosing a Sender email address, Sender name, Contact List, Campaign Title, Subject Line and email body.
You will also be able to choose a ‘Reply To’ address. This is optional, but allows you to select a different email address, where replies from recipients will be received.
You can personalize the email body or Subject field by inserting fields from SugarCRM containing important information like the opportunity name, assigned account, close date etc.
Once you are ready, click on ‘Continue’.
-
You will be asked to review and test the new template.
Click on ‘Send Test to Mailjet’, or if you wish to skip the test, select ‘Skip Test’.
-
Once you have successfully tested the zap, or skipped the test, you will need to ‘Finish’ the zap creation process.
-
All that’s left now is to turn on the zap and you are ready to go!
View Your Campaign Statistics
Every time a zap with the ‘Send Email Campaign to a List’ action is triggered, it will create a campaign and send out the email template you configured to the contact list you have selected.
The respective campaign will be recorded in Mailjet and you can see your campaign stats at any time by going to your Mailjet Campaigns and clicking on the name of the one you want to view.
For more information on Mailjet campaign stats, please visit our dedicated guide.
Parse Inbound Emails Zap
General Information
You can take advantage of the contact forms you set up to your website, in order to streamline the contact registration process. For example, a sales prospect fills out the Sales contact form on your website. With a properly set up zap, the email – with the key information in the email custom headers – will be transferred into SugarCRM and automatically create a new prospect.
Trigger Phase
-
Go to your Zapier account dashboard, click on ‘Make a Zap!’, then choose a name for your new Zap. Click here for reference.
-
From the ‘Choose a Trigger App’ search box, enter and select ‘Mailjet’.
-
Select the ‘Parse Inbound Email’ trigger and click ‘Save + Continue’.
-
Select the Mailjet account you want to use, or connect a new one. For reference click here.
-
As this point you will need to ask Mailjet to create a new parse email address for your Zap.
Although the long list of instructions on Zapier may look confusing, it is quite simple! :)
You can generate a parse email address using the Mac Command Terminal, Postman, Hurl.it or your favourite API Request Builder.
For this example, we will create the parse email address using Hurl.IT.
Open a new browser window and go to www.Hurl.it.
From the drop down list, select ‘POST’. Then paste in Mailjet Parse Route URL: https://api.mailjet.com/v3/REST/parseroute
(The Mailjet Parse Route URL will parse the inbound emails and send the contents to another location - in this case Zapier.)
Click the ‘+ Add Authentication’ link.
Add your Mailjet API Key (username) and Secret Key (password) into the respective text boxes. You can find this information in the API Key Management section of your Mailjet account.
Now you need to provide destination URL where the parsed email content should be sent. This URL is called a webhook URL.
Go back to your Zapier page and scroll to the bottom to find the webhook URL.
Click on the ‘Copy to clipboard’ button.
Go back to the Hurl.it page and click the ‘+Add Parameter(s)’ link.
In the name text box, enter: URL
And paste the webhook into the second text box.
Click the checkbox to confirm you are not a robot ;)
Then click on ‘Launch Request’.
Congratulations - you have made your first parse email address! When an email is sent to this parse email address, Mailjet will parse the elements of the email and send them to Zapier. Then your zap will forward the parsed elements to Pipedrive or any other Zapier connected app.
And yes, the parse email address is quite long - please record it somewhere for future reference. ;)
-
Now you need to send a test email to your new parse email address to activate it.
Please ensure the email headers contain the information needed to create a new Contact in SugarCRM. The minimum information needed to create a new Contact is the contact’s last name and language, but we suggest adding fields for contact information (email, phone), so you can contact them back, as well as any additional details you find appropriate. Once you have sent the test email, switch back to your Zapier screen and click on ‘OK, I did this’.
You should see the ‘Test Successful!’ Page with a link to view your parse inbound email (the test email you had sent a few minutes earlier).
If the test was not successful, use the ‘Re-test Mailjet’ option to get another parse email address, or send another test email to the parse email address.
-
Click on ‘Continue’ to complete the Parse Inbound Email Trigger!
Action Phase
-
You have entered the Action App phase. This is where you tell Zapier what to do with the information that Mailjet parses from the email and sends to Zapier. In this use case, we are telling Zapier to add a new Contact to SugarCRM!
From the ‘Choose an Action App’ search box, enter ‘SugarCRM’ and select it from the list.
-
From the list of options choose the appropriate Action for your Zap – in this case ‘Create Contact’, then click on ‘Save + Continue’.
-
Select (or connect) a SugarCRM account to use for this zap. Click here for reference.
-
You will now see all the fields associated with a SugarCRM Contact’s details.
-
You need to match the information from your test email to the respective SugarCRM fields. Simply call up the drop down list for the desired SugarCRM field and match it to the email.
When you are ready, click on ‘Continue’.
-
You will see a page with the pulled information and will be able to test the zap Action. If you wish to skip the test, click on ‘Skip Test & Continue’.
-
If the test is successful, or if you skipped it, you will be asked to Finish the zap.
-
The only thing left is to turn on the zap.
You are done! When your Zap is on, it will automatically run when an email is sent to your parse email address.
Email Events Zap
General Information
The Email Events trigger allows you to set up a Zap, which will activate upon a certain email event – e.g. the mail is opened, a link within it is clicked, it bounces and cannot be delivered etc. This allows you to transfer information back to your SugarCRM account for the respective emails you are interested in.
Naturally, the ways to configure the Zap depend on the Zapier actions available for SugarCRM. Here as an example we will configure a Zap to Create a Note in a SugarCRM contact every time this contact ‘clicks’ an email.
Trigger Phase
- Click on ‘Make a Zap!’, enter the name of your zap and choose Mailjet as the Trigger App.
-
Select the ‘Email Events’ trigger, then click on ‘Continue’.
-
Choose a Mailjet account to use, or link a new one to Zapier, if needed. For more information click here.
-
You will now need to select the events you want to automatically track for this trigger. Event Tracking simply means whenever there is an event, an event is dispatched to the provided Endpoint URL, containing meaningful context about the event (like the recipient email, timestamp, etc). From here, the customer can script actions to be done following it.
We will use the URL provided to allow Zapier to recognize when a link in an email was clicked, and subsequently trigger the Zap. To do that, first please copy the provided URL to your clipboard.
Then go to the Trigger Events section of your Mailjet account.
Follow the below instructions to configure the Endpoint URL for the Click trigger.
A. Tick the checkbox next to the ‘Click’ event.
B. Paste the previously copied URL into the ‘Endpoint URL’ field for the ‘Click’ event.
C. You can test the URL by clicking on the ‘Send’ button – if it is correct, you will receive a ‘OK, Code 200’ response.
D. Click on ‘Save’ to submit the changes.
-
Once you have done this, go back to Zapier and click on ‘Continue’.
-
You will be given the option to select a contact list for the zap. Call up the drop-down menu and choose the list you want to use.
Once you have made your selection, click on ‘Continue’.
-
You will be asked to review your selections – make sure that you have added the Endpoint URL link and selected the proper contact list.
-
The system will now want to test the trigger. Make sure that you have recent events matching your selections so far. In this case, we need a contact from the ‘Mail Events List’ contact list, who has clicked on a link in a Mailjet campaign recently.
-
Once the test is successful, click on ‘Continue’ to complete the trigger configuration.
Action Phase
-
Search for and select SugarCRM as the Action App.
-
Choose the action you want the Zap to perform. In our example this will be a ‘Create Entry (Other Module)’ action. It will be located under ‘show less common options’. When you select it, click on ‘Continue’.
-
Select the SugarCRM account you want to use, or connect a new one to Zapier. Once you have chosen the account, click on ‘Continue’. For reference click here.
-
You will now need to configured the note. First, you will be asked to choose a Module – select Notes from the drop-down menu.
-
You will need to configure the note. Once you have configured it on your end, click on ‘Continue’.
-
Zapier will now ask you to test the zap – click on ‘Create & Continue’ to do that, or on ‘Skip Test & Continue’ to skip it. Afterward simply Finish the Zap and turn it on and you are all set!
Troubleshooting
If you experience difficulties or have questions about the SugarCRM platform, please visit the SugarCRM Contact Us page.
The Zapier Help page can assist you with answers to questions about Zap functionalities and common issues.
Of course, feel free to contact our Customer Support team, in case you come across any technical difficulties with the Mailjet product - our team of specialists will be more than happy to assist you! Please visit the Mailjet ‘Contact Us’ page for more information.
Conclusion
We hope you find this guide helpful. Let us know what you think of the Zapier integration process, or especially what functionality we should introduce next by emailing plugins@mailjet.com.
Happy Zapping,
Mailjet Integrations Team