Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The Malomo and Sendlane Integration relies on orders to be placed in order to function. Prior to setting up an Automation, ensure you have installed the Sendlane integration successfully and you have had new orders placed after the installation. You may also place and fulfill a “fake” order to yourself to trigger Malomo data to sync to Sendlane.

How to Trigger an Automation with a Malomo Event

  1. Within your Sendlane account, navigate to Automations.

  2. Click New Automation.

  3. Select Start From Scratch and name the automation.

  4. Click + Add trigger.

  5. Select the Custom tab

  6. Click Custom Event

  7. Select Malomo Custom Integration in the Store dropdown.

  8. Select No Limit in the Limit Per Contact dropdown.

  9. Select the desired Malomo event in the Event dropdown. See here for a list of available Malomo Event Triggers.

  10. Click Done

You’re now ready to build out your automation using Sendlane automation actions, timing, and logic. To send order and shipment notifications to your customers, select the action Send Message and then drop the Email or Send SMS into the automation under the trigger. To learn more about using Malomo data in automation messages, see here.

Available Malomo Event Triggers
Anchor
triggers
triggers

This integration supports the following Malomo events as automation triggers.

Event name

Description

Malomo: Shopify Order Created

Shopify records a new order placed by a customer.

Malomo: Shipment Created

Shopify records a new shipment on an order and that shipment registers in the Malomo platform.

Malomo: Shipment First In Transit

Only the first scan event when the shipment is in the carrier’s possession and is en route to its destination.

Malomo: Shipment First Out For Delivery

Only the first scan event when the shipment is currently on its last mile and is en route to the destination address.

Malomo: Shipment Delivered

The local delivery vehicle has reported the package was delivered.

Malomo: Shipment Return To Sender

The shipment was not successfully delivered and is en route back to sender.

Malomo: Shipment Available For Pickup

The shipment is available for pickup from the carrier’s facility such as a post office.

Malomo: Shipment Delivery Attempted

A delivery was attempted but the shipment could not be delivered. 

How to Include Malomo Data in Automation Messages
Anchor
data
data

To display Malomo order and shipment data in automation messages, the message must include a set data trigger code snippet and the Malomo data tags.

Add a Set Data Trigger Tag

The first line of each message must include the tag {% set data = trigger.getCustomEventData() %}, which allows Malomo data to be pulled into your message. Without this snippet, none of your data will load, and contacts will receive mostly or entirely blank emails.

...

Code Block
{% set data = trigger.getCustomEventData() %}

Add Malomo Data Tags

...

See the lists below for the most common data tags to add to your Sendlane templates.

Tracking Information Data Tags

INFORMATION

EXAMPLE

OUTPUT

OUTPUT 

DATA TAG

First Name

Mister

Malomo Tracking Link

"Track Package" button

{{ data.order

.meta.shopify_order.customer.first_name }}

Last Name

Rogers

.url }}

Estimated Delivery Date

September 19, 2021, 9PM

{{ data.properties.estimated_delivery_date }}

Actual Delivery Date

September 19, 2020 10 PM

{{ data.properties.tracker_delivered_at }}

Carrier Name

FedEx

{{ data.

order

properties.

meta.shopify_order.customer.last_name }}

Email

misterrogers@pabs.com

carrier_name }}

Carrier Service

Ground Home Delivery

{{ data.properties.carrier_service }}

Tracking Number

99812911999333

{{ data.

order

properties.

meta.shopify_order.customer.email

tracking_code }}

Phone Number

123-456-7890

Latest Scan Event Description

“Held at Post Office, at Customer Request, in Bryan, TX.”

{{ data.

order

properties.

meta.shopify

scan_

order

events.

customer

0.

phone

description }}

...

Customer Information Data Tags

INFORMATION

EXAMPLE

OUTPUT 

OUTPUT

DATA TAG

Estimated Delivery Date

September 19, 2021, 9PM

First Name

Mister

{{ data.customer.

estimated_delivery_date }}

Actual Delivery Date

September 19, 2020 10 PM

first_name }}

Last Name

Rogers

{{ data.customer.last_name }}

Email

misterrogers@pabs.com

{{ data.customer.email }}

Phone Number

123-456-7890

{{ data.customer.

delivered_at

phone }}

Shipping Address Information Data Tags

INFORMATION

EXAMPLE OUTPUT 

DATA TAG

Ship First Name

Mister

{{ data.order

.meta

.

shopify_order.

shipping_address.first_name }}

Ship Last Name

Rogers

{{ data.order.

meta.shopify_order.

shipping_address.last_name }}

Ship Company

Malomo

{{ data.order.

meta.shopify_order.

shipping_address.company }}

Ship Phone

123-456-7890

{{ data

.order.meta

.

shopify_

order.shipping_address.phone }}

Ship Address Line 1

123 Rogers Lane

{{ data

.order.meta

.

shopify_

order.shipping_address.address1 }}

Ship Address Line 2

Apt. 305

{{ data.order.

meta.shopify_order.

shipping_address.address2 }}

Ship City

Pittsburgh

{{ data.order.

meta.shopify_order.

shipping_address.city }}

Ship Province

Pennsylvania

{{ data

.order.meta

.

shopify_

order.shipping_address.province }}

Ship Province Code

PA

{{ data.order.

meta.shopify_order.

shipping_address.province_code }}

Ship Zip

46205

{{ data.order.

meta.shopify_order.

shipping_address.zip }}

Ship Country Code

US

{{ data.order

.meta

.

shopify_order.

shipping_address.country_code }}

Ship Country

United States

{{ data

.order.meta

.

shopify_

order.shipping_address.country }}

...

Order Information Data Tags

INFORMATION

EXAMPLE OUTPUT 

DATA TAG

Carrier Service

Order Number

FedEx

1012

{{ data.

carrier_name }}

Tracking Number

99812911999333

{{ data.tracking_code

order.number }}

Tracking Link

"Track Package" button

Order Name

#1012

{{ data.order.

url }}

ORDER DETAILS

INFORMATION

EXAMPLE OUTPUT 

DATA TAG

Order Number

Code Block
1012
Code Block{{ event.extra.order.number

meta.shopify_order.name }}

Shopify Order

Name
Code Block
#1012
Code Block{{ event.extra

Status URL

https://goodestboi.com/6140756068/orders

{{ data.order.meta.shopify_order.

name

order_status_url }}

Order Created at Date

Code Block

July

2,

2019

5:16

PM

code

{{

event.extra.order.meta.shopify_

data.order.created_at

}}

Order Note

Code Block
This is a note from the 
Shopify order notes section.
Code Block{{ event.extra.order.meta.shopify_order.note

}}

Discount Codes

Code Block
THANKYOU10
Code Block
{{ event.extra.order.meta.shopify_order.discount_codes }}

Total Discount

Code Block

0.00

Code Block

{{

event.extra

data.order.meta.shopify_order.total_discounts

}}

Subtotal Price

Code Block

102.00

code

{{

event.extra

data.order.meta.shopify_order.subtotal_price

}}

Tax Price

Code Block

7.14

Code Block

{{

event

data.

extra.

order.meta.shopify_order.tax_price

}}

Shipping Price

code

2.13

code

{{

event.extra

data.order.meta.shopify_order.shipping_price

}}

Total Price

code

109.14

code

{{

event

data.

extra.

order.meta.shopify_order.total_price

code

}}

Financial Status

Code Block
PAID

Total Refunded

56.76

{{

event.extra

data.order.meta.shopify_order.

financial_status Code Block{{ event.extra

total_refunded_amount }}

Total Paid

Code Block
109.14

Order Line Item Title

Boopy Snoots Biscuits

{{ data.order.meta.shopify_order.

total_price Code Block{{ event.extra.

line_items.0.title }}

Cancelled on Date

Code Block
July 1, 2019 11:03 PM

Order Line Item Variant Title

Default Title

{{ data.order.meta.shopify_order.

cancelled_at }}

Cancellation Reason

Code Block
Refund
Code Block
{{ event.extra.order.meta.shopify_order.cancel_reason }}

Total Refunded

Code Block
56.76
Code Block{{ event.extra

line_items.0.variant.title }}

Order Line Item Current Quantity

1

{{ data.order.meta.shopify_order.

total_refunded_amount

line_items.0.current_quantity }}

 

LINE ITEMS

Each line item represents a product purchased by the customer who is receiving the email. You can choose to show either all the products a customer ordered or all the products for an individual shipment.

 

LINE ITEMS IN ORDER

We recommend using a dynamic table block in Klaviyo to show all products a customer ordered. To do this, configure the data source elements as: 

...

Order Line Item Image Source

https://cdn.shopify.com/s/files/1/0061

{{ data.order.meta.shopify_order.line_items

...

 

Next, you'll use these variables within your dynamic table block: 

INFORMATION

EXAMPLE OUTPUT 

EVENT VARIABLE

Item Title

Code Block
Red Sweater
Code Block
{{ line_item.title }}

Item Quantity

Code Block
1
Code Block
{{ line_item.quantity }}

Item Variant Title:

Code Block
Long Sleeve
Code Block
{{ line_item.variant.title }}

Item Image

Code Block
Shows image of product
Code Block
{{ line_item.image.src }}

Item Link

Code Block
URL for PDP
Code Block
{{ line_item.product.url }}

Item Final Line Price

Code Block
$102.00
Code Block
{{ line_item.final_line_price }}

 

LINE ITEMS IN FULFILLMENT

We recommend using a static table block in Klaviyo to show all products in a customer's shipment. To do this, add the following code before the static product block:

...

.0.image.src }}

Order Line Item Original Price

$75.00

{{ data.order.meta.shopify_order.

...

And add the following code after the static product block: 

Code Block
{% endfor %}{% endwith %}

 

Next, you'll use these variables within your static table block: 

INFORMATION

EXAMPLE OUTPUT 

EVENT VARIABLE

Item Title

Code Block
Red Sweater
Code Block
{{ i.line_item.title }}

Item Quantity

Code Block
1
Code Block
{{ i.line_item.quantity }}

Item Variant Title:

Code Block
Long Sleeve
Code Block
{{ i.line_item.variant.title }}

Item Image

Code Block
Shows image of product
Code Block
{{ i.line_item.image.src }}

Item Link

Code Block
URL for PDP
Code Block
{{ i.line_item.product.url }}

Item Final Line Price

Code Block
$102.00
Code Block
{{ i.line_item.final_line_price }}

Event Data Tag

Description

Example

Order Status URL

The URL of your shop’s order tracking page. It can be a Shopify page or Malomo-hosted page.

“https://ppeev.myshopify.com/pages/order-tracking?_m_id=001d961a-2c3b-4cee-b22c-2a3d3b64b5e8"

Order Number

The order number assigned by Shopify

“1000”

{{ event.extra

line_items.0.original_price }}

Order Line Item Total Discount

$10.00

{{ data.order.meta.shopify_order.line_items.0.line_level_total_discount }}

Order Line Item Final Price

$65.00

{{ data.order.meta.shopify_order.

name }}

Tracking EDD

The shipment’s original estimated delivery date provided by the carrier, if available

“2019-01-30 13:30:00”

Tracking Latest Status Detail

Standardized tracking message with relevant shipment information

“arrived_at_destination”

Tracking Latest Status

Current tracking status of the shipment

“delivered”

Customer Email

Customer email address

“john@example.com”

Tracking Number

Tracking number

“9400000000000000000000”

Customer Name

Customer first and last name

“John Smith”

Shipping Address

Customer shipping address

“INDIANAPOLIS, US, 46203, IN”

Tracking Latest Update

The timestamp of the latest shipment update provided by the carrier

2019-01-30 13:30:00

Tracking URL

The carrier’s tracking page URL

“https://tools.usps.com/go/TrackConfirmAction?qtc_tLabels1=9400000000000000000000”

Carrier Name

Carrier name

USPS

Carrier Service

Carrier service level

First-Class Package Service

line_items.0.final_price }}

Info

Need help or experiencing issues with the integration? Please reach out to either the Malomo Team or Sendlane Support.