Skip to main content
Contributor II
March 14, 2021
Solved

How do I display price including VAT in my Abandoned Cart email?

  • March 14, 2021
  • 8 replies
  • 3553 views

Hello,

The product price in the abandoned cart emails is without vat, i need to display price including vat, what should i change in this line here?

 

Quantity: {{ item.Quantity|floatformat:0 }} — Total: {% currency_format item.LineTotal|floatformat:2 %}

    This topic has been closed for replies.
    Best answer by elisegaines

    Hi @Fmsojo! Klaviyo is limited in that it can only display information from the “Event data” for the event that triggers the flow -- in this case, “started checkout”. You can check that event data to see if the price with VAT is included! To do this: 
    1. click the “eye” preview icon in the editor 

    2. Scroll through the data in the modal that pops up until you find the section with data on the items you ordered. It may be within the section labeled “Items”, or under “extra > line_items”, or similar. 

    3. Look at the price lines to see if the price you’d like to display is included. You can use Ctrl+F/Cmd+F to search for a specific number, if you happen to know what the VAT price is. 

    If you’re able to find the price you’d like to display, you can add it to the template! Make sure to adjust the template tag to match the format used in your dynamic block -- for example, if the correct template tag is {{ event.extra.line_items.price_vat }}, replace event.extra.line_items with just “item”, so the tag is {{ item.price_vat }}. 

     

    This guide has a little more information on using event data in flows: https://help.klaviyo.com/hc/en-us/articles/115005083467 

    8 replies

    Customer Ed.
    March 18, 2021

    Hi @Fmsojo! Klaviyo is limited in that it can only display information from the “Event data” for the event that triggers the flow -- in this case, “started checkout”. You can check that event data to see if the price with VAT is included! To do this: 
    1. click the “eye” preview icon in the editor 

    2. Scroll through the data in the modal that pops up until you find the section with data on the items you ordered. It may be within the section labeled “Items”, or under “extra > line_items”, or similar. 

    3. Look at the price lines to see if the price you’d like to display is included. You can use Ctrl+F/Cmd+F to search for a specific number, if you happen to know what the VAT price is. 

    If you’re able to find the price you’d like to display, you can add it to the template! Make sure to adjust the template tag to match the format used in your dynamic block -- for example, if the correct template tag is {{ event.extra.line_items.price_vat }}, replace event.extra.line_items with just “item”, so the tag is {{ item.price_vat }}. 

     

    This guide has a little more information on using event data in flows: https://help.klaviyo.com/hc/en-us/articles/115005083467 

    FmsojoAuthor
    Contributor II
    March 19, 2021

    Hello,

     

    This is the event for price including vat , {{ event.extra.Items.0.TotalWithTax }}

    And this is the original line,

    Quantity: {{ item.Quantity|floatformat:0 }} — Total: {% currency_format item.LineTotal|floatformat:2 %}

    How should i change it to include the event with the tax?, because i tried to add it like in the screenshot but i get an error

     

     

    Customer Ed.
    March 22, 2021

    Could you try this? {% currency_format item.TotalWithTax|floatformat:2 %} 

    But when you paste it, make sure to paste as “plain text” (use Ctrl+Shift+V or Cmd+Shift+V), to make sure no formatting is getting pasted in -- the formatting can sometimes break the code. 

    FmsojoAuthor
    Contributor II
    March 27, 2021

    Thank you that solved the issue.

    Contributor I
    July 15, 2022

    Hi,

    this works really good in abandon cart however the same does not work in order placed. Would you know what the array be for Order Placed and Completed? 

    Thanks 

    Problem Solver I
    August 18, 2022

    This has probably been resolved for @SK789, but for anyone else reading trying to get the total including VAT (and shipping) in the Placed Order event, try this:

    {{ event|lookup:’$value’|floatformat:2 }}

    Contributor I
    March 15, 2023

    Hello! Im needing your help :) Currently, Im creating the NL for abandoned carts. I want to show the product name AND the product price. 

     

    Everything is correct with the product name by using: {{ item.product.title }}

    However, I can not put te price. Could you please tell me what "code" I should use so that the price of my product appears below the name?

    Taylor Tarpley
    Community Manager
    Community Manager
    March 20, 2023

    Hi @irenebylia22

     

    I would encourage you to check out the codes shared earlier in this thread to help test this. In order to test its accuracy, you can trigger the flow yourself and add to your cart and see if the correct price comes to your email. However, I can see that you are conversing with a colleague of mine in a similar thread you created below.

     

    -Taylor