SOLVED

Re: Marketo System Asset ID to attached to links as Parameter in Email

Go to solution
Diana-Gilman
Level 1
Hi Everyone, I'm looking for some help with Velocity scripting to auto populate the Email ID (or Asset ID) in order to include this Marketo system Asset ID as a parameter attached to the links in my email. I found a few articles in the community (like this one: https://nation.marketo.com/t5/ideas/email-id-system-token/idi-p/278839#comments) that uses Velocity scripting to extract the email ID from the xMarketoIdHdr header. 
 
I used the script from this post and the VS token I created does work and populated the Asset ID if added to the email as token within a text element. However, when I add this token or variable to my URL as a parameter, this does not appear to work unless I disable my tracking which is what I don't want.
 
So, when I append the URL to include this VS Token parameter, this is the result and the EmailID looks like this (also note that the Asset ID isn't populated here:

https://www.example.com/index.html?cta_id=article-ban-masthead&EmailID=&mkt_tok=MjEyLVRDVS0wMzQAAAGc...

However, when I disable tracking, the URL looks like:
https://www.example.com/index.html?cta_id=article-ban-masthead&EmailID=26408
 
Does anyone know if there are any tricks or a solution or work around? 

Thanks a lot!
1 ACCEPTED SOLUTION
SanfordWhiteman
Level 10 - Community Moderator

OK. If you can’t use Velocity to generate links, I think using {{campaign.id}} is your only path forward.

 


We have instances where a smart campaign is sending more than one email for example if a drip-style send is requested.


If you switch those to executables, you’ll have a unique {{campaign.id}}. Shouldn’t be too tough.

 


We also have instances where an email program (not a smart campaign) is sending a program.

There’s an underlying {{campaign.id}} for those, so that’s fine.

 

Another method is to use Munchkin to send a synthetic Click Link activity (that is, in addition to the automatic Click Email) that includes the Email ID. You will need a developer for this.

View solution in original post

5 REPLIES 5
Diana-Gilman
Level 1

To improve our tracking and data collection in Adobe Analytics, we would like to have a unique identifier, like the Email Asset ID, as a parameter on all the URLs in our emails.  This will ensure that the identifier is associated with each individual email, making it readily available and captured for tracking purposes in Adobe Analytics.

 
Open to any other suggestions to track URLs linked to a single email asset!
Tags (2)
SanfordWhiteman
Level 10 - Community Moderator
Do you send more than one email using the same Smart Campaign?
Diana-Gilman
Level 1

We have instances where a smart campaign is sending more than one email for example if a drip-style send is requested. We also have instances where an email program (not a smart campaign) is sending a program.

 

SanfordWhiteman
Level 10 - Community Moderator

OK. If you can’t use Velocity to generate links, I think using {{campaign.id}} is your only path forward.

 


We have instances where a smart campaign is sending more than one email for example if a drip-style send is requested.


If you switch those to executables, you’ll have a unique {{campaign.id}}. Shouldn’t be too tough.

 


We also have instances where an email program (not a smart campaign) is sending a program.

There’s an underlying {{campaign.id}} for those, so that’s fine.

 

Another method is to use Munchkin to send a synthetic Click Link activity (that is, in addition to the automatic Click Email) that includes the Email ID. You will need a developer for this.

SanfordWhiteman
Level 10 - Community Moderator

The only supported way to use tracked links + Velocity is to output the entire <a> tag from Velocity.

 

But let’s step back and make sure we don’t have an XY Problem. What is the full business requirement (not specific technical implementation) that you are trying to meet?