AfterShip v1 data reference

Estimated 5 minute read
|
Updated Oct 10, 2024, 1:58 PM EST
You will learn

You will learn

This guide refers to the AfterShip v1 integration, which was built by Klaviyo and is no longer allowing new installations. New customers should use the new AfterShip Tracking integration, built by AfterShip. Learn how to integrate with AfterShip Tracking.

Learn about data synced from Klaviyo's v1 AfterShip integration. You can personalize and target emails based on the shipping events and status of orders tracked by AfterShip. Synced data includes shipment tracking numbers and order IDs, and when a shipment is marked as shipped or delivered. 

View synced data

View synced data

To view your synced data:

  1. Click the Analytics dropdown and select Metrics.
  2. Select one of the AfterShip metrics — for instance, Received Delivery — and click on the Activity Feed icon. You can filter metrics by AfterShip, and all AfterShip metrics will have an AfterShip icon.
    Metrics tab in Klaviyo filtered by AfterShip with Received Delivery in list
  3. If your integration has begun syncing data, you'll start to see Received Delivery events being added to this Activity Feed. When your AfterShip integration has a green bar in your account's Enabled Integrations list (found under Account Name > Integrations), your historic data sync is complete.
  4. If you aren't seeing data, make sure the All events setting is enabled in the Notifications > Webhooks section of your AfterShip account.
AfterShip metrics

AfterShip metrics

AfterShip syncs the following metrics to Klaviyo:

  • Delivery Exception
  • Failed Delivery Attempt
  • In Transit
  • Out for Delivery
  • Received Delivery
  • Shipped Package

Metrics tab in Klaviyo filtered by AfterShip with a list of metrics including Delivery Exception and Shipped Package

Delivery Exception

Delivery Exception

This metric is recorded each time a delivery is assigned one of the following statuses: custom hold, undelivered, returned shipment to sender, or any shipping exceptions.

Failed Delivery Attempt

Failed Delivery Attempt

This metric is recorded when a carrier attempted to deliver the package but failed. The carrier will usually leave a notice and will try to deliver again.

In Transit

In Transit

This metric is recorded when a carrier has either accepted the shipment or picked up a shipment from a shipper. The shipment is on the way to its destination.

Out for Delivery

Out for Delivery

This metric is recorded when a carrier is about to deliver the shipment or the shipment is ready to pick up.

Received Delivery

Received Delivery

This metric is recorded every time a delivery is marked as received inside of AfterShip, and includes information about an order's tracking number and order ID.

With this metric, you can filter product review flows to send only to people who have received a delivery. You can also trigger a flow when a delivery is received, letting customers know when their packages arrive.

Shipped Package

Shipped Package

This metric is recorded every time an order is marked as shipped in AfterShip, and includes information about an order's tracking number and order ID.

With this metric, you can trigger flows to send messages confirming that a package has been shipped to a customer and provide them the tracking number to track their shipment.

Use AfterShip v1 data in Klaviyo

Use AfterShip v1 data in Klaviyo

Each of the metrics above are associated with additional data, also known as metadata. For example, the Out For Delivery metric tracks the package’s CurrentStatus, which includes the following possibilities: AttemptFail, Delivered, Exception, InfoReceived InTransit, OutForDelivery. This data can be used to create and trigger flows based on a shipment’s status.

Out for Delivery flow

Out for Delivery flow

Let your customers know that their order is out for delivery by using AfterShip metrics and metadata, and populate your flow email with dynamic order information.

  • Trigger: People enter this flow when an Out for Delivery event occurs

Flow in Klaviyo flow builder triggered by Out for Delivery

Notice that the flow email references dynamic customer order data (i.e., {{ event.extra.Title }}); when the message is sent, the dynamic placeholder will be replaced with the customer’s order number.

Add tracking information to emails

Add tracking information to emails

You can also use AfterShip data in direct interactions with your customers; for instance, auto filling their tracking information into a shipping notification email.

This method can only be used in flows with the AfterShip trigger Shipped Package.

  1. First, in AfterShip, click on Tracking pages.
    Tracking pages in menu in purple
  2. Select the tracking page you’d like to add to your email template and copy the following from the provided URL: klaviyo1m.aftership.com
    Tracking page preview with URL
  3. In Klaviyo, navigate to Flows. If you have previously set up an AfterShip flow, you can add the following to that flow. Otherwise, click Create Flow and filter by AfterShip.
    AfterShip flows in Klaviyo flow library including Order in Transit
  4. In this example, we’ll add the tracking number to the Order In Transit flow. Click on the Order In Transit flow.
  5. Select the email block and then click Edit.
    Klaviyo flow builder with flow email highlighted titled AfterShip in Transit Email #1
  6. Click Edit Content and select the main text box of the email. In this example template, the text box is set up with two columns, so select Column 2.
    Klaviyo email template builder with main text box selected
  7. Select the placeholder text next to Tracking Number and click the link button.
    Text box settings in template builder with Link button selected
  8. In the link menu, change the Protocol to https:// and paste your tracking URL, adding the following to the end:/{{ event.extra|lookup:'Tracking Number' }}
    Link info modal with URL in box
  9. Click OK. Then, save your changes to the block by clicking Save.
    Text box settings in template builder with tracking number variable linked
  10. You can preview your email by clicking the Preview button on the left hand side of the screen. Select an event to preview the email with, and then choose Show directly in Klaviyo to view the email in your browser. Click Preview Now to view the email and verify your link works.
  11. Once you’re happy with the way your email template looks, click Save & Return to Templates.
Additional resources

Additional resources

Was this article helpful?
Use this form only for article feedback. Learn how to contact support.

Explore more from Klaviyo

Community
Connect with peers, partners, and Klaviyo experts to find inspiration, share insights, and get answers to all of your questions.
Live training
Join a live session with Klaviyo experts to learn about best practices, how to set up key features, and more.
Support

Access support through your account.

Email support (free trial and paid accounts) Available 24/7

Chat/virtual assistance
Availability varies by location and plan type