Skip to main content
Solved

add customers payment method to order confirmation


Forum|alt.badge.img+3
  • Contributor IV
  • 8 replies

Hey, I want to to setup an order confirmation flow which shows the customers selected payment method (with no real coding experience).

There are a couple of methods like Amazon Pay, Paypal, Klarna and more  in the shopify Store.

I came across:

https://shopify.dev/docs/themes/liquid/reference/objects/transaction#transaction-gateway but https://shopify.dev/docs/themes/liquid/reference/objects/transaction#transaction-payment_details seems to fit my needs better.

But when i add

{{ transaction.extra.gateway_display_name }} or {{ transaction.extra.gateway }} or {{ event.extra.payment_details }} or {{ event.extra.payment_details.credit_card_company }} my preview always shows nothing.

Paypal isn’t a credit card company maybe that’s why i see no result.

Can someone give me a hint or a ressource on how to get the payment method based on customers Choice?

Thanks in advance.

Best answer by David To

Hello @Frank,

I would first recommend looking into the following articles as they would guide you on how to pull in event data to be displayed within Klaviyo emails. Both Klaviyo and Shopify use different syntaxes and therefore the syntaxes provided in those Shopify documents would not translate over to Klaviyo as they would only be meant for Shopify Notification Templates.

Keep in mind that Klaviyo emails can only parse and display syntaxes/tags referencing event data within their appropriate Flows and not with a campaign or an email template not housed within a flow. Therefore, if you were previewing the email you created in either a campaign or as a general email template, those syntaxes would not display. 

Using the Klaviyo preview tool within your Flow email allows you to see a list of all the metadata that is shared and synced to Klaviyo. Doing so would allow you to select the variable and value you want to display and also offer you the dynamic syntax needed to add to your templates to display them when previewing as highlighted in the gif found in the How to Find Event Variables section of the About Using Event Variables to Personalize Flows article. 

Hope this helps!

-David

 

View original
Did this topic or the replies in the thread help you find an answer to your question?

7 replies

David To
Klaviyo Employee
Forum|alt.badge.img+60
  • Klaviyo Employee
  • 2456 replies
  • Answer
  • May 1, 2021

Hello @Frank,

I would first recommend looking into the following articles as they would guide you on how to pull in event data to be displayed within Klaviyo emails. Both Klaviyo and Shopify use different syntaxes and therefore the syntaxes provided in those Shopify documents would not translate over to Klaviyo as they would only be meant for Shopify Notification Templates.

Keep in mind that Klaviyo emails can only parse and display syntaxes/tags referencing event data within their appropriate Flows and not with a campaign or an email template not housed within a flow. Therefore, if you were previewing the email you created in either a campaign or as a general email template, those syntaxes would not display. 

Using the Klaviyo preview tool within your Flow email allows you to see a list of all the metadata that is shared and synced to Klaviyo. Doing so would allow you to select the variable and value you want to display and also offer you the dynamic syntax needed to add to your templates to display them when previewing as highlighted in the gif found in the How to Find Event Variables section of the About Using Event Variables to Personalize Flows article. 

Hope this helps!

-David

 


Forum|alt.badge.img+3
  • Author
  • Contributor IV
  • 8 replies
  • May 1, 2021

Hey @david.to,

thank you for your time and effort. Exactly what i needed! It helped me a lot already!

:relaxed:

Frank


Forum|alt.badge.img+2
  • Contributor III
  • 6 replies
  • September 15, 2021

Hi Frank! Just wanted to ask what event variable you used for this? 


Forum|alt.badge.img+3
  • Author
  • Contributor IV
  • 8 replies
  • September 24, 2021

Hey @jdbrngr,

i took {{ event.extra.gateway }}.


Forum|alt.badge.img+2
  • Contributor I
  • 2 replies
  • August 12, 2022

Hi @David To,

The links you pointed to isn’t working any longer. Do you know where I can find them now?


David To
Klaviyo Employee
Forum|alt.badge.img+60
  • Klaviyo Employee
  • 2456 replies
  • August 12, 2022

Hey @Tomas,

Thanks for pointing that out! Those links should now be leading to the correct Help Center articles. 

In addition, our template specialist, @Anna McCarthy recently provided a very helpful Community post on building dynamic table blocks from your event data which I’ve included below:

David


Forum|alt.badge.img+2
  • Active Contributor III
  • 34 replies
  • June 12, 2024

Hi All - is there an updated response here on how to include the payment method/details for an order in the order confirmation email for a store that is integrated with Shopify? Thank you in advance.