scrapinghub / slackbot

A chat bot for Slack (https://slack.com).
MIT License
1.26k stars 396 forks source link

Get plaintext of URL passed in message #177

Closed ghost closed 6 years ago

ghost commented 6 years ago

When passing a URL in a message slack will pass an encoded version <http://myurl.com|myurl.com> wondering if there is a way to only get the myurl.com part of that string and pass that to a method?

thanks in advance

lins05 commented 6 years ago

You can use a regular expression to extract it.