Email Template - MD5

As part of our integration each contact recieves a “login-salt” property for auto-login links use.

We created a login-link module that utlizes that property by concatenating its value with current timestamp and hashing it all with MD5 (all written in said module) - let’s call the MD5 hashing result the login-token.

The issue we have is that the MD5 method “triggers” before the contact’s properties are set in the email which results in a very wrong login-token.

following is an example of what we are doing:

{% set token = (unixtimestamp(local_dt)~contact.login_salt)|md5 %}

My question is - is there any way for getting the MD5 method to run only AFTER the contact.login_salt is filled with the proper value?

Is there a better way of implementing this for use in emails?

Thank you!

Hi, @AR_SA :waving_hand: Thank you for the interesting question. Adding a delay in the manner you need for your project doesn’t appear to be possible.

Hey, @Anton @MBERARD @Stephanie-OG, have you ever pondered a project like what @AR_SA? To add a delay this way in the context of an email?

Thank you for taking a look! — Jaycee

Hi @AR_SA ,

I would try something like this:

{% set token = (unixtimestamp(local_dt)~(contact.login_salt|render))|md5 %}

Hope it works.

Bests,

Matthieu

Hi!

Thanks for the reply.

However, this does not help :pensive_face:

Looks like the value is still asseset prematurely..