Global Tokens

Almost 10 years ago, Marketo Nation veteran Grégoire Michel posted an idea to allow for my.tokens to be created at root or workspace level. And last week, Adobe finally heard his call and did it.

What does that mean, and why was that a great idea? Well, before last week, program tokens – or my.tokens – could only be created on folder or on program level. Which – if you read this blog you will know – was already immensely useful, and is one of Marketo’s greatest features. But these tokens, if created on folder level e.g., only cascaded down to anything underneath that folder, and not across folders and absolutely not across workspaces. Which means, if you had dozens of workspaces in your instances and you were a token fan – as you should be! – you would need to create the same token over and over. Not anymore.

So how does that look today? In the admin section, an icon has appeared that opens your standard token menu.

Any token you create here, will appear in the status “inherited” in your Workspaces, Folders and Programs.

Let’s see an example with the most global of global tokens:

You see that this token is now tied to the Workspace “Default” and its status is “Inherited”. You can edit its value and it’ll appear as “Overridden” as you are used to.

So now, if you are disciplined, you only need to set the current year once on global token level and have it been cascaded down to all your assets from this one global setting. And by “if you are disciplined” I mean: Don’t have tokens where they don’t belong. Whatever you define globally should usually not exist locally, unless you have a good reason to. {{my.Copyright_Year}} e.g. most likely should have just one value across your whole instance, so that tokens should never be local.

Overriding a token can make sense though. For instance, we believe that the From-Email-Address should always be a token. Marketers are not allowed to make up their own email address domains, as this is crucial for email delivery. So if you define {{my.From_Email_Address}} globally, you can absolutely override it on Workspace level to make it italy@mail.example.com, spain@mail.example.com or however else you might have organized your Workspaces.

And here’s one bonus tip: If you’re even too lazy to change your {{my.Copyright_Year}} once a year, you can make it a Script Token to grab the current year automatically. Just note that Script Tokens only work in emails, not on landing pages. So if you have a copyright year in the footer of your landing pages, the best you can do is to use a global my.token.

Here’s the script btw:

#set ($year = $date.get('YYYY'))
${year}