Skip to main content
November 19, 2015
Question

Having problems with tokens not being shown in web link

  • November 19, 2015
  • 2 replies
  • 1714 views

I have a question regarding the API and tokens:

We're sending emails through the REST api's Request Campaign endpoint. The emails are being sent just fine, and tokens are being placed as one would expect. What fails though, is the option for "Include View as Web Page" under Program > Email > Settings.

The snippet gets included as you would expect, but the tokens are not being shown through this web link.

My question is, since one of our emails are adding tokens: How do I make sure that tokens are respected and used in this view?

Thank you!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

2 replies

Grégoire_Miche2
Level 10
November 19, 2015

Hi Rasmus,

Are you using the token as a href value in the <a> tag :

<a target="_blank" href="{{system.viewAsWebpageLink}}">

-Greg

Grégoire_Miche2
Level 10
November 19, 2015

Second thought,

{{system.viewAsWebpageLink}} is a system token, not a program token. You cannot change it's value.

-Greg

Dory_Viscoglio
Level 10
February 10, 2016

Hey Greg, the issue Rasmus was having is that he was sending tokens through the request campaign API, but those are discarded after 1 hour. When they were going through the "View as a Webpage" token, the other tokens that the API previously programmed were now showing "empty". The tokens have to be added outside of the request campaign API if you want them to be persistent.

Dory_Viscoglio
Level 10
February 10, 2016

Hey Rasmus, not sure if you're still dealing with this, but if you're adding the tokens through the request campaign, the issue is that those tokens are discarded after 1 hour. You need to add the tokens as explained in the Developers link below.

http://developers.marketo.com/documentation/asset-api/create-token-by-folder-id

Re: REST API - Invalid token