Amplemarket Liquid Syntax Examples

Mica
Mica
  • Updated

Now that we have gone through the basics of Liquid Syntax by reading the article "Liquid Syntax for Email Templates", we will go through all instances of Liquid Syntax on Amplemarket and explain how they work. Please keep in mind that all of these instances can be edited to better fit your lead list and campaign.

If Title Contains: 


{% if title contains "CEO" or title contains "Chief Executive" %}

Is this something that could be interesting for your team?

{% elsif title contains "Director" or title contains "Manager" %}

Is this something that could be interesting to you?

{% else %}

Would you have time for a quick call {{tomorrow_or_next_day}}?

{% endif %}

 


{% if title contains "Marketing" or title contains "Sales" %}

Is this something that could be interesting to you?

{% elsif title contains "HR" or title contains "Human Resources" %}

Is this something that could be interesting for the employees at {{company_name}}?

{% else %}

Would you have time for a quick call {{tomorrow_or_next_day}}?

{% endif %}

 


Here we have two forms of “Title” liquid syntax where the messaging a lead receives is based on the title of their position. In the first instance we can see that we are filtering based on the position “CEO” or a position that contains “Chief Executive”, if you reach out to a lead whose position contains one of these phrases, they will receive the line “Is this something that could be interesting for your team?”. If we cannot find any leads whose title contains “Chief Officer” and instead reach out to somebody who holds the title of ‘Director’ or ‘Manager’, they will receive the line “Is this something that could be interesting to you?”. This change in messaging is determined based on the ‘elsif’ statement in the third line of this liquid syntax instance. If we reach out to a lead whose title does not contain ‘Cheif Executive’, ‘Manager’, or ‘Director’, then the lead will receive the message “Would you have time for a quick call tomorrow or the next day?’.



If Day of the Week:

{% if day_of_the_week == "Monday" or day_of_the_week == "Tuesday" or day_of_the_week == "Wednesday" %}

Would you have time for a quick call {{tomorrow_or_next_day}} so I can explain how this could work for {{company_name}}?

{% else %}

Would you be open to a quick call early next week?

{% endif %}

 

{% if day_of_the_week == "Saturday" or day_of_the_week == "Sunday" %}

Apologies for the email out of the blue, especially on a {{day_of_the_week}}.

{% else %}

Happy {{day_of_the_week}}.

{% endif %}


In these examples you can see liquid syntax that alters your copy based on the day of the week. In the first instance we can see that Monday, Tuesday, and Wednesday will all send the same message, (“Would you have time for a quick call {{tomorrow_or_next_day}} so I can explain how this could work for {{company_name}}?”), while the ‘else’ option, which refers to Thursday - Sunday, will send the message “Would you be open to a quick call early next week?”.
The second instance can be helpful if we plan on sending during the weekend as it has specific messaging referring to sending an email on those days. This instance can also be used on a weekday since the else statement (which refers to weekdays) will send the message “happy day of the week”. 


Assign time of Day:


{% assign time_of_day = "now" | date: "%H" | times:1 %}

{% if time_of_day <= 12 %}

Good morning {{first_name}}! I hope you are having a great start of your day.

{% else %}

Good afternoon {{first_name}}!

{% endif %}


This instance of Liquid Syntax changes depending on the time the Receiver gets the inbox. If the time is before 12:00 PM on any day of the week they will receive the message “Good Morning (First Name)! I hope you’re having a great start to your day.” If the lead receives this after 12:00 PM they receive an email that says “Good Afternoon”. These can be very useful when opening up an emails as it shows the lead we have reached out to them specifically by mentioning the time of day and making the email more personal. 

If Industry:

{% if industry == "Industry A" %}

Value proposition sentence OR case study OR customer examples...

{% elsif industry == "Industry B" %}

Value proposition sentence OR case study OR customer examples...

{% else %}

General value proposition sentence OR case study OR customer examples...

{% endif %}



The “Industry” form of liquid syntax requires a bit more effort on our end since we need to dictate the Industries we would like to focus on and create messaging specifically for leads in those industries. In terms of reading this form of liquid syntax, it is actually pretty simple because the messaging is based purely on the industry of the leads we are reaching out to. First we will dictate which industry will be industry ‘A’ and write a value proposition, case study, or customer examples on how you can benefit companies in that Industry. After we have completed this we will need to decide what “Industry B” will be and write a separate value proposition, case study, or customer examples of how you can benefit companies in this industry. After we have completed these two steps we just need to write a general value proposition for all the other leads we are sequencing that may not be in the two industries we filled in above.



If city is:


{% if city == "city A" %}

Value proposition sentence OR case study OR customer examples OR call to action...

{% elsif city == "city B" %}

Value proposition sentence OR case study OR customer examples OR call to action...

{% else %}

General value proposition sentence OR case study OR customer examples OR call to action...

{% endif %}


The “city” instance of liquid syntax is very similar to the “industry” version because it requires the same steps but can be leveraged differently. We know by now that we will have to create specific pitches for the leads in city A, city B, and all other cities, but we can also use this to make the email more personalized. Lets say we name Paris as “City A’ and Berlin as “City B”, we can have our pitch for city A be written in French, our pitch for city B written in German, and our generic value proposition can be written in English. This way we can show our leads that we have very specific messaging for them and it will not seem like just any other cold outreach.

Case Country: 

{% case country %}

{% when "France" %} Bonjour!

{% when "Spain" %} Hola!

{% else %} Hello

{% endcase %}


Using the  “Case Country” Liquid Syntax, we can alter the greeting of our messaging based on the location of the lead. This is very similar to the example above, just on a lower scale. In this case all leads in France will receive the greeting “Bonjour”, those in Spain will receive “Hola”, and all others will receive “Hello”. We can edit this sequence more to your liking by adding more countries using more {% When “country” %} statements or we can edit the countries already in use.


Assign Random Number: 


{% assign randomNumber = first_name | size | modulo: 3 | plus: 1 %}

{% if randomNumber == 1 %}

Would you have time for a quick call?

{% elsif randomNumber == 2 %}

What do you think?

{% else %}

Does this sound interesting to you?

{% endif %}

 

The Assign Random Number form of liquid syntax allows you to edit your messaging to leads based on a completely random component so that we can increase the variability of the emails we are sending. In this use we have the possibility of sending 3 different messages, as noted at the top with the message “modulo: 3”. This number can be edited to have only 2 messages or added onto so it has 4 or 5 possible messages, but to do this we would have to make more elsif statements. If we wanted to add another instance we could edit the liquid syntax to look like this:



{% assign randomNumber - first_name | size | modulo: 4 | plus: 1 %}
{% if randomNumber == 1 %}
Would you have time for a quick call?
{% if randomNumber == 2 %}
What do you think?
{% if randomNumber == 3 %}
Any thoughts? 
{% else %}
Does this sound interesting to you?
{% endif %}


Please note that the “plus: 1” did not change as it refers to the final else statement and this should not change when making your edits. The only change made was the amount assigning to the “Modulo” and one extra random number was added because of this. Please, also note, that the 4th module of this liquid syntax also refers to the final “else” statement and that all of these instances need to end with an {% endif %}.

If you have any questions about these forms of liquid syntax or editing Liquid Syntax, please reach out to support@amplemarket.com 



 

Was this article helpful?

0 out of 0 found this helpful

Have more questions? Submit a request