Generating dynamic URL based on a contact property
解決
I'm trying to figure out a way to generate a dynamic URL based on a contact property.
Here is the use case:
User signs up for a free trial via a HubSpot form
We send them an email with a link to activate their account
Clicking on this sends a webhook out to generate a "magic link" which is then pushed back to their HubSpot contact record
The email takes them to a landing page and the goal of the landing page is to have that dynamically generated unique link on the page which will activate their account.
The part I'm stuck on is how to query their contact record to pull the URL and dynamically insert it into the landing page.
I think I've managed to fix this. The clear property has worked - it didn't delete it from them email as I had initially thought. I just need to do more testing to make sure contacts can still re-enroll into this same workflow....
i'm really hoping someone can help me here. I had the same issue as mentioned in this thread....
I want to send a custom url to our contacts.
I created a workflow that sent an email triggered on custom url being known and the contact owner being X. This workflow then triggered an automatic email to the contact with a custom url link - great!
But my issue is, if we update or create a new custom url for the contact, how do i re-enroll them into this same workflow. Or how do I send them another email from contact owner X with their new custom url.
The custom url is generated automatically from an external source.
I tired to add "clear property value" for custom url property to the end of the workflow so that would remove them and then when i new url was added to the property the workflow would be triggered again. BUT this then just deleted the custom url link from the email too
Easy to do on the marketing side, of course, but I want to enroll specific contacts in sequences. There is a probably workflow workaround, but this feature would be quite powerful.
My use-case is the same as Jessica's, and we have successfully inserted dynamic links into emails, where those links are stored as Contact Properties and pushed from an external system.
The question I have is how to embed the link behind text. Pulling it in as a dynamic text field, we are able drop the bare link into an email, but would like to embed it behind text such as "click this link here". Does that make sense?
If you're creating the activation link entirely outside of HubSpot, you're correct that you should be able to just push that into a custom contact property and use it via a personalization token in an email. I'll try to quickly address the specific questions you asked:
Yes
No; it could just be a text field
Yes
No; but you could do this with the transactional email add on as well
I can't think of anything specific; putting links in contact properties, then including them in emails via personalization tokens is generally pretty straightforward.
I found this thread looking for whether it's possible to embed an activation link from an external system into a HubSpot email.
We have a custom CRM which auto generates an activation link, but we want to send the email with the activation link from within HubSpot. On that basis we have the following questions:
Is it as simple as just syncing this data with a custom field in HubSpot?
If so, are there any requirements around that field? How would this work?
If it's a custom field, presumably we just add a personalisation token into the email to add the activation link, as you have mentioned above?
Will we need the transactional email add-on to do this?
Are there any other things we should be aware of in terms of ensuring the activation link works - currently it is a 1-time use link and is custom generated per contact?
I understand; thanks for the clarification! So if the final landing page is hosted on HubSpot, and the link is stored in a contact property, you can simply include it on the landing page by using a personalization token and perhaps some smart content. The only tricky part would be making sure that the visitor coming to your site has that property populated.
When exactly is this link created / added to the contact record? If this happens on the form submission, then you can easily just direct the visitor to the landing page and be confident that the contact property will be populated by the time they get the email / click the link / reach the landing page.
If instead the link is created when a contact clicks into the email, you'll need to introduce a time delay of a few seconds to be confident that the contact property will be populated when the visitor reaches the landing page. Does the link in the email direct visitors to an external page? If so, you could potentially use the 'Get contact by usertoken' endpoint to check if that particular property exists. Does that make sense? Is that inline with what you were thinking?