Email ID System Token

Email ID System Token

Being able to auto-populate the email ID in emails by making a {{email.id}} system token available, similar to {{program.id}} and {campaign.id}}

17 Comments
Keith_Nyberg2
Level 9 - Champion Alumni

Hey Anthony,

Can you elaborate on what you mean by email ID? Marketo has a couple tokens that could help here. A few listed below.

Email Address: {{lead.Email Address}}

Lead ID: {{lead.ID}} <- # that is shown in the record domain

     (Ex//: marketo.com/leadDatabase/loadLeadDetail?leadId=9611899)

How does the value you are asking for differ from what is available? Can you explain the use case?

Sincerely,

Keith Nyberg

Anonymous
Not applicable

Sorry, I probably should have worded it differently.  I mean the asset id.  Each email asset has its own 'id" similar to how a program or campaign does.  But we are not able to dynamically pull that ID using a token unlike the program id and campaign id.  This seems weird to me because when you get bulk exports of activity/email data, they are broken out by email id. 

SanfordWhiteman
Level 10 - Community Moderator

In Velocity:

  #set( $AssetId = $mktmail.xMarketoIdHdr.split(":")[5] )

FYI.

Grégoire_Miche2
Level 10

Hi Sandy,

How do you get to know this ???

-Greg

SanfordWhiteman
Level 10 - Community Moderator
Check all of your distractions/attractions
Social Life
Kids
Sleep
None of the above
Dan_Stevens_
Level 10 - Champion Alumni

Obviously this isn't documented anywhere in Marketo.  Did you ever think about writing a book about all of the undocumented information that's stored in your head (and some of it sprinkled here on the community and on your blog)?!

SanfordWhiteman
Level 10 - Community Moderator

I have thought about the three of us writing a book...

Chrystal_Martin
Level 1

This is fantastic. I've been looking for this for ages.

Is there a way to set a variable that pulls the Asset Name? For example, email asset 311 is named Prospects_ThankYou_Spring19

#set( $AssetId = $mktmail.xMarketoIdHdr.split(":")[5] ) gives me 311 when I use the $AssetID variable.

How can I set a variable $assetName that inserts Prospects_ThankYou_Spring19 instead? I'm trying to automate some of our UTM campaign tags, and our data team wants the Asset Name, not the asset ID.

Thanks!

SanfordWhiteman
Level 10 - Community Moderator

Unfortunately the name isn't surfaced here.

Bianca_Corey
Level 1

Hey - this was SO helpful. It solved our business problem.

However, it took referencing the token name again in the velocity script in order to populate. See here:

#set( $emailId = $mktmail.xMarketoIdHdr.split(":")[5] )
${emailId}

This worked!