Skip to main content
Solved

AirTable Automations Are Breaking My Links

  • October 21, 2020
  • 20 replies
  • 145 views

I have built an automation that fires off an email to a key stake holder with information found in different fields.
One of these fields contains a link. When the automation fires, the email is sent along with a slack notification.

The slack notifaction contains the same information the email should, BUT the link in the email is altered by the automation and the link in the slack message seemingly works.

The automation is grabbing the same URL from the same field. I am not sure why the URL is changes in the email but not the slack message.

To add additional information, the email is removing the under-scores from the URL and the Slack message is not.

Can anyone help?

Best answer by Justin_Barrett

I tried using the same text and it still is not work out for me. The slack message is sending the proper link. And the email is removing the under_scores from the link.


I ran a quick test that confirmed this markdown connection. Apparently the field data is inserted before markdown processing occurs, so underscores that come from fields are viewed as italics highlight markers.

The way I got the second URL to pass through was by using a formula field that adds a backslash before each underscore. It was a longshot because backslashes are often used in strings to “escape” a character that should not be processed normally (e.g. quotes in strings), and sure enough it works to “escape” the underscores so that the markdown process ignores them. Here’s my formula:

SUBSTITUTE(URL, "_", "\_")

Insert that formula field in the email body, and it’ll work.

20 replies

Kamille_Parks11
Forum|alt.badge.img+27

Can you screenshot that portion of the Automation for both you Slack and Email steps?


  • Author
  • Participating Frequently
  • 5 replies
  • October 21, 2020


  • Author
  • Participating Frequently
  • 5 replies
  • October 21, 2020


Kamille_Parks11
Forum|alt.badge.img+27


Weird. It may have something to do with Email’s message field doing something weird with markdown formatting. Try doing [Link to doc](Record (Step 1: Trigger) | Field values | link to Doc).

If that doesn’t work try using the exact same text as your are in the Slack message.


Justin_Barrett
Forum|alt.badge.img+21
  • Inspiring
  • 4647 replies
  • October 21, 2020

Welcome to the community, @xavier_williams! :grinning_face_with_big_eyes: What triggers the automation? My first reaction when automations contain incomplete information from a record is that the automation is firing in the middle of an update. However, if only the email is being affected and not the Slack message, that would seem to shoot down that theory, but I’m still curious to know what the trigger is.


  • Author
  • Participating Frequently
  • 5 replies
  • October 21, 2020

Weird. It may have something to do with Email’s message field doing something weird with markdown formatting. Try doing [Link to doc](Record (Step 1: Trigger) | Field values | link to Doc).

If that doesn’t work try using the exact same text as your are in the Slack message.


I tried using the same text and it still is not work out for me. The slack message is sending the proper link. And the email is removing the under_scores from the link.


Kamille_Parks11
Forum|alt.badge.img+27

I tried using the same text and it still is not work out for me. The slack message is sending the proper link. And the email is removing the under_scores from the link.


Did you try formatting the link as a markdown link using the (display text)[actual link] syntax?


  • Author
  • Participating Frequently
  • 5 replies
  • October 21, 2020

Did you try formatting the link as a markdown link using the (display text)[actual link] syntax?


How do I do that? Within the automation or within the table?


Kamille_Parks11
Forum|alt.badge.img+27

How do I do that? Within the automation or within the table?


Within the automation. Precede the input from the trigger record with (some display text) and wrap the input value with square brackets. I’m not sure if that’ll work but it might be worth a shot.


  • Author
  • Participating Frequently
  • 5 replies
  • October 21, 2020

Within the automation. Precede the input from the trigger record with (some display text) and wrap the input value with square brackets. I’m not sure if that’ll work but it might be worth a shot.


I gave that a shot, and it did not work either.


Justin_Barrett
Forum|alt.badge.img+21
  • Inspiring
  • 4647 replies
  • Answer
  • October 24, 2020

I tried using the same text and it still is not work out for me. The slack message is sending the proper link. And the email is removing the under_scores from the link.


I ran a quick test that confirmed this markdown connection. Apparently the field data is inserted before markdown processing occurs, so underscores that come from fields are viewed as italics highlight markers.

The way I got the second URL to pass through was by using a formula field that adds a backslash before each underscore. It was a longshot because backslashes are often used in strings to “escape” a character that should not be processed normally (e.g. quotes in strings), and sure enough it works to “escape” the underscores so that the markdown process ignores them. Here’s my formula:

SUBSTITUTE(URL, "_", "\_")

Insert that formula field in the email body, and it’ll work.


Forum|alt.badge.img+2
  • Known Participant
  • 12 replies
  • March 26, 2021

Does anyone have suggestions on how to fix this if it’s just a test field? I have values with underscores in them that are getting stripped out with the email automation.
example:
Company_Campaign_Date_032421

I tried the above fix but I just get a blank in that spot on the email send.
Thanks!


Justin_Barrett
Forum|alt.badge.img+21
  • Inspiring
  • 4647 replies
  • March 26, 2021

Does anyone have suggestions on how to fix this if it’s just a test field? I have values with underscores in them that are getting stripped out with the email automation.
example:
Company_Campaign_Date_032421

I tried the above fix but I just get a blank in that spot on the email send.
Thanks!


@Jeannie_Ruesch_BDC Can you share a screenshot showing what you tried? I’m guessing something might be a little off, but without seeing the details it’s hard to say what that might be.


kuovonne
Forum|alt.badge.img+29
  • Brainy
  • 6009 replies
  • March 27, 2021

You can also try inserting the url in markdown format. [square brackets around the text to display](https://parenthesis.around.the.actual.link) make sure there is no space between the closing square bracket and the opening parentheses.


ScottWorld
Forum|alt.badge.img+35
  • Genius
  • 9773 replies
  • March 27, 2021

You can also try inserting the url in markdown format. [square brackets around the text to display](https://parenthesis.around.the.actual.link) make sure there is no space between the closing square bracket and the opening parentheses.


Sadly, this only works when the field is a normal URL field, or if you hardcode the URL into the message body itself.

If the field is a formula field that results in a URL, it fails. :frowning:

I’m going to report this to support@airtable.com, and hopefully they will fix this at some point.


  • New Participant
  • 1 reply
  • August 21, 2021

I ran a quick test that confirmed this markdown connection. Apparently the field data is inserted before markdown processing occurs, so underscores that come from fields are viewed as italics highlight markers.

The way I got the second URL to pass through was by using a formula field that adds a backslash before each underscore. It was a longshot because backslashes are often used in strings to “escape” a character that should not be processed normally (e.g. quotes in strings), and sure enough it works to “escape” the underscores so that the markdown process ignores them. Here’s my formula:

SUBSTITUTE(URL, "_", "\_")

Insert that formula field in the email body, and it’ll work.


Hi! I can’t get this to work. Do you know if this solution is still possible? When i try to make a formula field that uses your formula, the link is still broken when inserted into the email.


  • New Participant
  • 1 reply
  • October 15, 2021

Hi! I can’t get this to work. Do you know if this solution is still possible? When i try to make a formula field that uses your formula, the link is still broken when inserted into the email.


The quickest way I got this to work was by setting the text to Markdown syntax. Using tick marks… It removes font formatting, but it maintains “_” without having to create yet another column.

apiKey is your secret API token.


Forum|alt.badge.img
  • New Participant
  • 1 reply
  • February 16, 2022

FWIW. I had the same exact issue that started this thread and followed the instructions presented by kuovonne (above) and it worked for me. Thank you.


  • New Participant
  • 1 reply
  • March 21, 2022

Sadly, this only works when the field is a normal URL field, or if you hardcode the URL into the message body itself.

If the field is a formula field that results in a URL, it fails. :frowning:

I’m going to report this to support@airtable.com, and hopefully they will fix this at some point.


me too. When I inserted a field into the body email, it’s show the whole url in the result.


Forum|alt.badge.img+9
  • Inspiring
  • 24 replies
  • May 2, 2022

Sadly, this only works when the field is a normal URL field, or if you hardcode the URL into the message body itself.

If the field is a formula field that results in a URL, it fails. :frowning:

I’m going to report this to support@airtable.com, and hopefully they will fix this at some point.


I figured it out for URLs produced with formulas!

You’re right, when the URL is hardcoded into the email, escaping the backspaces works fine, but for some reason, URLs produced by a formula and then inserted into the email dynamically always break.

I realized that no matter what you do, the underscore has to be hardcoded into the email.

So I used formulas that break up the URL into the sections around the underscores, and then put it all together in the email.

[dynamic inserted url portion]_[dynamic inserted url portion2]

So you have to create several fields, one for each portion of the url broken by an underscore, and then put those fields into the email around a hardcoded “_”.

It’s annoying, but it totally solves the problem.